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

Re: Possibly erroneous "device not present" message during boot



On Thu 13 Apr 2017 at 17:48:41 (+0200), Pascal Hambourg wrote:
> Le 13/04/2017 à 13:40, Richard Owlett a écrit :
> >On 04/12/2017 02:03 PM, Pascal Hambourg wrote:
> >>Le 12/04/2017 à 20:33, Richard Owlett a écrit :
> >>>On 04/12/2017 12:13 PM, Pascal Hambourg wrote:
> >
> >[snip]
> >>>>- while the SD card is inserted, in the GRUB menu press "c" to enter a
> >>>>GRUB shell and report the result of the "ls" command.
> >>>
> >>>(hd0) (hd0, msdos9) (hd0, msdos8) (hd0, msdos7) (hd0, msdos6)
> >>>(hd0, msdos5) (hd0, msdos1) (hd1) (hd1, msdos1)
> >>
> >>Some BIOS expose a removable media only when booting from it, so my
> >>theory was that your BIOS did not expose the SD card and GRUB could
> >>not see it. The result of ls proves me wrong.
> >>
> >>Can you also report the output of "ls (hd1,msdos1)" to check what GRUB
> >>sees of the partition on the card ?
> >
> >It gives the partitioning description, UUID, and label of the USB flash
> >drive that was plugged in. It is FAT formatted and used to exchange
> >information with my Windows machine.
> 
> USB drive ? Then (hd1) is not the SD card ? If you boot with no USB
> drive plugged in, there is no (hd1), right ? Then the SD card does
> not appear as a usable device for GRUB and my twisted theory may
> still be correct after all.

This is just a guess. The OP says they "booted to the SD card". So
presumably the SD card was plugged in, and we have seen mention of
/dev/mmcblk0p1 which means it was plugged in when Grub made the
grub.cfg file. But I'm not yet convinced that the machine is actually
able to boot from an SD card (unless you put it in a USB card reader).

The boot stanza contains:

search --no-floppy --fs-uuid --set=root 380e2a6d-f851-4fd1-9db2-869a0982b511
[...]
linux /boot/vmlinuz-3.16.0-4-686-pae root=/dev/mmcblk0p1
initrd /boot/initrd.img-3.16.0-4-686-pae

So it's possible that the kernel and initrd are coming from the USB
stick that the OP has left in, or even the hard drive.

I normally expect to see
search --no-floppy --foo --set=root bar
[...]
linux /boot/vmlinuz-... root=foo=bar

where foo depends on whether you're using /dev/ or UUID or LABEL,
and bar is the value appropriate to foo.

That's not what the OP posted. Also their response

> It gives the partitioning description, UUID, and label of the USB
> flash drive that was plugged in. It is FAT formatted and used to
> exchange information with my Windows machine.

sadly lacks the actual information asked for as is often the case.
What is the UUID/LABEL of the USB device? I'm not bothered about
the Windows machine.

> >>>Any suggested reading on the "BASH like shell" I just used?
> >>
> >>The GRUB manual at <https://www.gnu.org/software/grub/manual/grub.html>
> >
> >It was what prompted me to ask ;/
> 
> Sorry, I do not know any better documentation.

I'm surprised the OP isn't best qualified to answer this question;
battling with Grub goes back at least five years.

Not being expert with Grub myself, I don't know how it reacts to a
failure during the search. Just a quick glance at my own cfg shows
that there are "set root" commands very early on in the file. So,
again I'm guessing, this may explain where the kernel is being
read from: one of those early commands has given Grub a fallback
device.

Cheers,
David.


Reply to: