2016-09-07 12:36 GMT+03:00 Rich Freeman <ri...@gentoo.org>:
> On Tue, Sep 6, 2016 at 11:36 PM, Mike Gilbert <flop...@gentoo.org> wrote:
>>
>> grub-mkconfig is not finding an initramfs, as evidenced by the lack of
>> an "initrd" in in grub.cfg.
>>
>> If it is unable to find an initramfs, it will always output
>> root=/dev/sdX instead of root=UUID=...
>>
>
> For whatever reason the three subsequent replies to this list ignored
> the actual explanation of the cause of the problems, which was this
> (not uncommon on this list it seems).
>
> This is also why it is helpful to post actual config files when you
> have problems.  The lines you consider most relevant aren't
> necessarily the ones containing the clues.
>
> When root=UUID=... was added manually to the command line, then the
> kernel refused to boot at all, because the kernel itself doesn't
> understand that syntax.

Yes, when the "root=UUID=***" has been added manually to /etc/default/grub
in the wrong way, it appeared in the GRUB menu entry in the wrong way that
stopped GRUB from booting in any case...

> So, the next question becomes, how are you generating an initramfs,
> and how is it named?  Pasting the output of "ls /boot" might be
> helpful here.

I generate initramfs by
# genkernel --install initramfs
and the rename it to match the name of the kernel, eg,
initramfs-4.4.6-gentoo
vmlinuz-4.4.6-gentoo

But I think that this is unrelevant to the problem because of the following
explanation I have just posted. (If I am wrong here, please, let me know
and I will post all the conf files you will ask.)

When I connected a new SATA disk to the SATA controller, the order of
hard disks during the boot time changed because the new disk "jumpt
in front" of the boot drive. As the result, the GRUB could not find the
boot partition by its UUID on the "wrong" non-boot drive and gave up,
without even trying to look for the boot partition by its UUID on other
hard drives!

When I connected the new hard disk after the boot, it (predictably)
did not "jumped in front" of other hard disks. So, doing
# grub-mkconfig -o /boot/grub/grub.cfg, creating a new initramfs,
etc, did not helped the GRUB to boot the system next time...

Only after I managed to boot the system manually editing the GRUB
menu entry during the boot time and the system booted with the new
hard disk connected, that in this case took its "usual" order, and then run
# grub-mkconfig -o /boot/grub/grub.cfg, the problem has been "solved."

Here, I am writing the "solved" in quotes because it has been solved
only for me and only on this computer: next time, when I or someone
else will add a new disk to any linux computer the problem may appear
again.

So, the question remains: why not to desing the GRUB in such a way
that it could look for the boot partition by its UUID on any available
hard drives?

Reply via email to