Re: A Grub Boot Question about initrd
On Sat, Jun 05, 2021 at 12:46:13PM -0500, Martin McCormick wrote:
> I have a plan but I need some more information. Is there any
> personalization done by the boot setup process?
Yes. One of the GRUB's tasks is to supply kernel which is about to boot
with root=... cmdline parameter. Root filesystem UUID can be used for
this.
> Do our UUID's or any other specific information pertaining to the
> installation make it in to the initrd files?
In Debian - no, unless you include it there for some bizarre reason.
It's not needed for the things initrd usually does.
> If that is so, then two computers using the same
> processor type should be able to use copies of the same initrd files
> and the only thing that is personalized on an individual computer
> is all the grub configuration in which the UUID's of at least /
> and /swap partitions are sprinkled throughout grub.cfg and
> /etc/default/grub.
It's not the CPU difference you need to worry about.
Different SATA controllers, video cards, NICs - i.e. what they call
periphery devices - those things require different kernel modules that
should be (or could be) used in early boot process, and therefore need
to be included in initrd.
Luckily, Debian uses initramfs-tools for building initrd, and
initramfs-tools should build initrd with everything and a kitchen sink
included (MODULES=most in /etc/initramfs-tools/initramfs.conf).
> One should be able to write a program to get the
> appropriate UUID's out of fstab on the working system
> and translate them in to corresponding UUID's for the system on
> the operating table.
Er, they've invented filesystem labels for exactly this many decades
ago.
> As an aside, one ought to be able to do something like
> this. It makes life a lot simpler. Both systems are using the
> same kernel and versions of the same processor the only real
> differences are the UUID's.
Perfectly possible for the last 15 years or so. Assuming Debian and
MODULES=most, of course.
Reco
Reply to: