The case for the /usr merge
The case for the /usr merge
Posted Jan 27, 2012 6:28 UTC (Fri) by drag (guest, #31333)In reply to: The case for the /usr merge by rickmoen
Parent article: The case for the /usr merge
Yes. /boot.
The reasons you have /boot are for:
* Encrypted Root
* LVM
* File systems not supported by Grub
* Network boot
* Non bootable RAID devices (including software raid)
* Union file systems for /
etc etc.
How Linux works now is this:
Bios --> Executes boot loader
Grub --> Loads kernel + Initrd into ram and executes them
The purpose of having a /boot is to provide a platform for bootloader, of which Grub2 is one of many possible loaders, for boot strapping the kernel and initrd.
Initrd performs the necessary functions to get a root file system built up and configured correctly. Starts up software raid, mounts encrypted file systems, performs consistency checks, and can even provide for a emergency repair console if distributions choose to set it up that way.
The initial root file system in ram can perform all the necessary functions that originally having a separate / and /usr directory was meant to accomplish. Only now the 'kernel + initrd' is massively more robust and more flexible then a separate / ever was. Initrd is self contained, executes in ram, and can be loaded in dozens of different ways without breaking it and without it caring how it got loaded.
/boot is just the standard for boot strapping your system on x86 systems with a local hard drive. However there are many different ways it can be done.
A few commonly used examples:
* Load your kernel/initrd from PXE network boot
* Load it from a ISO with isolinux
* Load it from USB drive with syslinux
* Specify a abritrary kernel and initrd to be executed by Qemu/KVM via the command line or Libvirtd XML for launching virtual machines.
All sorts of stuff beyond that. Things that you could never, ever, pull off with trying to do a separate / partition, without massive headaches and all sorts of problems.
So not only has the most significant purposes of having a separate / file system have superseded by superior technologies, but having a separate / file system, for purposes of boot-strapping or rescuing the system, has been a fundamentally broken configuration for many years now. It's not just systemd or Lennart. It just isn't going to work well except in specific hand-crafted setups.
Try it for yourself sometime. Get rid of the initrd, make a custom kernel with everything you think you need, and try to boot / locally while mounting /usr over nfs. It can be done, but it's going to be a headache.
Seriously. I am surprised that somebody would think to try to defend a separate / while lambasting the idea that a separate /boot is necessary. If anything it would make more sense to try to use /boot to help defend the idea that preserving the ability to use a separate / would be necessary.
> Yeah, thanks loads, Lennart. So, every time I have to maintain fsck, filesystem-diagnostic, backup/restore, etc. contents that would normally be in /bin, I have to rebuild an initramfs filesystem image. Swell.
I don't know why you are thanking Lennart. You should be thanking hundreds, if not thousands of people, who put about 20 years of Linux operating system development into practice.
Have you not noticed that when ever you perform a significant system update on you rebuild your initrd? When you install lvm tools, or software raid stuff, or encrypted file system support that this usually causes your initrd to be be rebuilt. It's been like that for a long time.
