[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

systemd and initrd and /usr



Hans Ullrich:
I do not understand the policy  behind systemd. As far as I know, It
> is historical in uinices, that each folder like /bin, /sbin, /var,
> /usr etc. is residing on its own partition. This is from the time of
> SCSI-drives (as you can have 16 drives on a controller).

Both of those latter two statements are wrong. The /usr split dates from the early 1970s, and originated in the machine that the developers of UNIX were using at the time not having enough disc space for everything to be on one disc. From that point onwards, it has stuck; even though its original use, of holding user home directories (hence the name) has long since vanished, the world having largely switched that to /home by the time of AT&T UNIX System 5 Release 4. (MINIX, roughly contemporaneously in 1987, had /usr and /user, the latter for user home directories. A few systems had /u.) The split was some five to ten years before even SASI existed, let alone the existence of SCSI, which it predates by about a decade.

It's rather sad to see the discussion of /usr sometimes, as some people have little to no awareness of history. Stephen Coffin, in his 1987 book UNIX System V Release 4: The Complete Reference observes that (in S5R4) /bin is a symbolic link to /usr/bin and /lib is a symbolic link to /usr/lib, and as he states this was one part of the new filesystem organization in Release 4. It's sad to see people think nowadays that this is somehow a newfangled fad. The so-called "/usr merge" had been done by many people in the UNIX world in the middle and late 1980s. People point to Solaris 11 incorporating a "/usr merge" in 2010 as historical precedent. But in fact Oracle is over 20 years late to the party. The AT&T System V world was doing this decades ago.

Of course, as you're discovering, the "/usr merge" is predicated on the idea that /usr is not on a separate volume, or is mounted so early on in the boot process that anything that uses stuff in /bin or /lib (really /usr/bin and /usr/lib) is able to find it without incident. Yes, having the /init program in your initramfs mount /usr is what you are expected to do if you choose to locate it in a separate disc volume. I'm not going to regurgitate other people's case in detail, here. If you want to find out more of the take of the Fedora and Freedesktop developers on the subject, go and read these:
* https://fedoraproject.org/wiki/Features/UsrMove
* http://www.freedesktop.org/wiki/Software/systemd/TheCaseForTheUsrMerge/

Also of interest is that even by the early 1980s, people had realized that /usr was a mess caused by historical accident. The authors of one 1986 book on UNIX system administration, David Fielder and Bruce Hunter, basically threw their hands in the air and declared that /usr was "The Mystery Directory" and primarily could be described as a miscellany, a hodge-podge grab-bag of things that were kept there because they had overflowed from elsewhere. You can read computer historian Rob Landley explaining that this is indeed exactly the case, a quarter of a century later, here:
* http://lists.busybox.net/pipermail/busybox/2010-December/074114.html

This is not systemd. This is not Lennart Poettering. This is a historical mess that people in the UNIX world were finding themselves stuck in, and were trying to edge out of, the year that Lennart Poettering was born. You're stuck in it, too; and your UNIX-alike operating system is repeating the history of UNIX. (-:


Reply to: