[TUHS] Understanding the /bin, /sbin, /usr/bin, /usr/sbin Split

Warner Losh imp at bsdimp.com
Fri Feb 3 07:49:44 AEST 2012


On Feb 2, 2012, at 2:14 PM, Dave Horsfall wrote:

> On Thu, 2 Feb 2012, John Cowan wrote:
> 
>> Does anyone know what the "s" in sbin stands for?  "Superuser"?  I would 
>> have put these files in /root/bin, but perhaps /root did not yet exist.
> 
> I seem to recall that they were statically linked i.e. not using those 
> new-fangled shared library thingies.  And if you've ever tried to admin a 
> system with a trashed shared library, you'll understand; it usually 
> involves looking for the installation media.

/bin is also statically linked, at least on those distributions that support split / and /usr.  SunOS 4.x and 4.4BSD did this. Except for the ones that have gone to a dynamic root moving the shared libraries from /usr/lib to /lib.  Prior to the /etc -> /sbin moves, all binaries were statically linked.  Even after the move /bin and /sbin remained static, while /usr/bin and /usr/sbin were dynamic.  The needs of reliability vs space savings pushed all the binaries in /sbin and  /bin to be static.

Even after the split in more modern systems, init and sh tend to be the only binaries that are statically linked anymore.  Thankfully, most binaries are dynamic these days, which saves a ton of space on / (as a percentage of what's used).

Warner

>> Not everything in /usr/share comes from /etc; in particular, 
>> /usr/share/dict was formerly /usr/dict.
> 
> As I dimly recall, /usr/share was exported, hence the name.
> 
> -- Dave
> _______________________________________________
> TUHS mailing list
> TUHS at minnie.tuhs.org
> https://minnie.tuhs.org/mailman/listinfo/tuhs
> 
> 




More information about the TUHS mailing list