On Fri, Jul 19, 2019 at 12:37 PM Ian Zimmerman <i...@very.loosely.org> wrote:
>
> On 2019-07-19 20:58, Adam Carter wrote:
>
> > I experimented found the following worked in /etc/default/grub;
> >
> > GRUB_DEVICE="PARTUUID=d3554d49-02"
> >
> > Which writes grub.cfg as;
> > linux /vmlinuz-5.2.0-gentoo root=PARTUUID=d3554d49-02 ro
> > init=/usr/lib/systemd/systemd iommu=pt raid=noautodetect
> >
> > PARTUUID looked up with blkid. No initramfs required :)
>
> I don't get this.  blkid is userspace.  The _kernel_ needs to know what
> the root fs device is, before it even starts pid 1.

The kernel init code is able to find a device given its PARTUUID.

https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/init/do_mounts.c?h=v4.19.59#n172

Reply via email to