What the heck is a bus error?

Eric Eisenhart eric at eisenhart.com
Sat Mar 23 17:11:38 PST 2002


On Sat, Mar 23, 2002 at 01:52:04AM -0800, ME wrote:
> Many (possibly most) /sbin tools are compiled as static system bins, and
> are less efficient with memory when compared with shared objects/memory
> savings than apps that can load shared libs and be more efficient with
> memory usage. Perhaps the startup scripts are calling several startup
> items that are big memory users.... (?)

This made me curious, "how much of /sbin *is* static binaries?"

# ldd /sbin/* | grep --before-context=1 "not a dynamic executable"

I'm running Debian woody with a few bits from sid.  Not even vaguely a
stripped down box.

The only thing that came back that wasn't a shell script is /sbin/ldconfig

I checked in /bin, too; just more shell scripts.

(Though I did notice that /bin/x10 doesn't belong in /bin, since it requires
/usr/lib/libstdc++-libc6.2-2.so.3 to run -- bug report emailed off to Debian)

(For those that don't know, ldconfig is the program that sets up all those
symlinks so that the right library gets loaded.  It can't be dynamically
linked because it sets up what programs get dynamically linked to.  It
typically gets run when you install new libraries and it doesn't stay around
in memory)

I suppose if you installed one of those shells designed for going onto a
rescue disk that would have been in the list, too.

Okay, for those of you that want to check yourself, or that just like seeing
overly long command-lines:
for dir in /sbin /bin /usr/bin /usr/sbin /usr/bin/X11 /usr/local/bin /usr/local/sbin ; do for file in `ldd $dir/* 2>/dev/null | grep --before-context=1 "not a dynamic executable" | grep $dir | cut --delimiter=: --fields=1`; do file $file; done; done | egrep -v "Bourne shell script text executable|Bourne-Again shell script text executable|symbolic link to |text executable|ASCII text"

(all it found was /sbin/ldconfig and a "shell archive or script for antique
kernel text")
-- 
    Eric Eisenhart   Freedom is slavery.      http://eric.eisenhart.com/
 ^  ICQ#: 48217244   Ignorance is strength.   eric-dot-sig at eisenhart.com
/e\ Perl&SQL Coder   War is peace.            IRC Nicks: Falsch Freiheit
---                        -- George Orwell



More information about the talk mailing list