Closed martinedelbrock closed 6 years ago
I'm rather sure this is the same issue as:
There are some errors reported before getting into GRUB cli in issue #209 and there are no errors in this case, so it is similar to #239
Here is yet another case, where we run into the problem that the GRUB cli is booted without displaying the menu:
ls
brings
(ahci0) (ahci0,gpt6) (ahci0,gpt5) (ahci0,gpt4) (ahci0,gpt3) (ahci0,gpt2) (ahci0,gpt1) (ahci1) (proc)
With a little playing around (ls
) I could figure out:
(ahci0)
is my local harddrive. Yes, this one is set up using GPT.(ahci1)
is my DVD ROM drive. Grub hangs, if there is no media loaded.Therefore, it seems like that grub can't find the USB pen, on which grub is installed (and thus cannot load its configuration files). The pen is a 123GB Verbatim USB 3.0 stick, formatted with msdos partition table and one FAT32 as a whole disk:
Disk /dev/sdb: 115.4 GiB, 123882962944 bytes, 241958912 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x240da7c8
Device Boot Start End Sectors Size Id Type
/dev/sdb1 * 2048 241956863 241954816 115.4G c W95 FAT32 (LBA)
Booting was performed using "F12" (temporary change of boot sequence).
Booting the stick via legacy boot and jumping from syslinux to grub2 works fine (but does not imply that it the stick was booted using EFI, which is a problem in my case, as I want to able to install Win10 in UEFI mode).
Ideas and suggestions welcome!
On the very same machine, there is an Debian 8 installed, which runs on GNU GRUB 2.02~beta2-22+deb8u1
(remember: the system is configured "UEFI only"). Using the command line environment with USB stick in the port, the result of ls
is different:
(hd0) (hd1) (hd1,gpt6) (hd1,gpt5) (hd1,gpt4) (hd1,gpt3) (hd1,gpt2) (hd1,gpt1) (cd0) (proc)
With a little of testing, I again come to the conlusion that
(hd0)
is the USB stick, but the partition table is not read (so no FS access possible). Running insmod part_msdos
makes it also accessible.(hd1)
is the GPT-based harddisk (from where this instance of grub was booted).(cd0)
is the DVD rom with the media in it. Yet another interesting aspect perhaps: Booting the USB stick again, I issued nativedisk
and got back the following error message:
error: disk 'usb0,msdos1' not found
Moreover, lspci
thinks that we have
...
00:14.0 8086:9d2f [0c03] USB Controller [PI 30]
...
And yet another observation. Same USB stick as mentioned above, now inserted into a computer running on an Asus M5A97 motherboard. The MB has both USB 2.0 and USB 3.0 hosts running.
ls
lists a ... (usb1) (usb1,msdos1) ...
out of the box and you can see that this is the stick, and the filesystem was loaded properly. (Therefore, it's unclear to me, why it fell through to the command line instead of going into "normal" mode)... (usb1) (usb1,msdos1) ...
devices are gone again. @openprivacy also reports in #209 that he can got his issue with an USB 3.0 stick.
I have created an overview wiki page for this entire topic, as apparently the issue is quite widespread.
yes, for me it was usb3.0 both port and stick
yes, for me it was usb3.0 both port and stick
Thanks for the update - I have adjusted the overview wiki page accordingly.
Hello,
Similar problem here, but not exactly: I can boot normally on UEFI system if I run it on a USB 2.0 port, but I enter inside the menu if I run it from a USB 3.0 port.
If I run it from the Usb 2.0, it hangs during something like 1mn, and then I can read:
(ahci0) (ahci0,gpt9) (ahci0,gpt8) ... (ahci0,gpt1)
(usb0) (usb0,msdos1) (ahci1) (proc) (lvm/mvg-DebianVar) (lvm/mvg-DebianHome) (lvm/mvg-DebianSystem)
If I try "ls", in the Usb 3.0 case I've (after 1mn of hanging):
(ahci0) (ahci0,gpt9) (ahci0,gpt8) ... (ahci0,gpt1)
(ahci1) (proc) (lvm/mvg-DebianVar) (lvm/mvg-DebianHome) (lvm/mvg-DebianSystem)
So no idea why the usb key does not appear in the list for 3.0... Especially because when I installed grub by myself on my key before that it worked like a charm.
@eaglerainbow issue occasionally self-fixed without any effort from my side. Graphical menu appears on boot, no CLI. All os images on pendrive (10+ images) seem to be working.
Still using same pendrive with no changes since issue was occuring (no-name aliexpress usb2.0 chinese pendrive).
And still not changed nor updated parrot os x64 (3.9 release) on lenovo netbook, same USB socket (it looks like 2.0 socket, not 3.0).
Same pendrive being plugged in in another socket is not recognised as bootable media.
@martinedelbrock Because I am suspecting the USB port, in which you boot the USB stick, just to be sure that I got it right what you said:
lspci
/lsusb
to cross-check?)Are you sure that you booted via (U)EFI and not via MBR?
To make things clear, if the grub2 drops you to shell then it means that it is unable to find the configuration file located at (usb0,gpt1)/multibootusb/grub.cfg. That is how the efi binary is compiled for UEFI booting.
I am looking for the solution to load the configuration file by scanning all devices by enbedding configuration file in to grub2 binary. The link would be helpful for some on how to do it https://www.gnu.org/software/grub/manual/grub/html_node/Embedded-configuration.html. This require some time for me to test and pushing it back to repo.
@eaglerainbow Thanks for the wiki. This will remind me of things to consider for the next commit.
The possible workaround:- as per this documentation, you need to find the device in the shell and set the root and prefix pointing to multibootusb directory. I will post the details later.
@mbusb Thought so already that the config file could not be loaded. In various locations, however, there are indications that the root cause for not being able to load the file seems to be that the entire drive (here: USB stick) cannot be found at all. So for my case, I manually checked all devices listed by ls
, but the necessary drive wasn't available.
Though not being a 100% safe indicator, in many cases it seems to be related with using either USB3.0 devices or USB3.0 ports (that's also one reason why I created the wiki page for it, to assist by bringing some more transparency into the topic. My gut-feeling tells me that we have "the same symptom but with multiple root causes").
@all users affected (esp. those mentioned on the wiki page): Please report back in which combination (USB2.0/USB3.0) of port and type of stick you are experiencing that issue. Please ensure that you are really using UEFI and do not boot using MBR/legacy booting.
I'd like to add some more details on the "research", which I did on the hardware (mainly stuff, which I currently just have around me by chance):
2.02~rc1
.lspci
reported back the following USB controllers on the corresponding systems:Motherboard | USB Controllers |
---|---|
Asus M5A97 LE | AMD SB7x0/8x0/9x0 USB OHCI0 controller AMD SB7x0/8x0/9x0 USB EHCI controller Asmedia ASM1042A USB3.0 Controller |
Asus P8Z77-V LE | Intel 7 series/C216 Chipset USB xHCI Intel 7 series/C216 Chipset USB EHCI Asmedia ASM1042A USB3.0 Controller |
Lenovo L560 | Intel Device 9d2f |
Here are my test result:
Motherboard | port | Boot after previous power-cycle | Boots to shell | status of device | effective grub.cfg location |
detectable by search -f /multibootusb/grub/grub.cfg |
comments |
---|---|---|---|---|---|---|---|
Asus M5A97 LE | USB 2.0 | yes | yes (shell) | detected at (usb1) | (usb1,msdos1)/multibootusb/grub/grub.cfg | yes | (usb0) does not exist |
Asus M5A97 LE | USB 2.0 | no | yes (shell) | detected at (usb1) | (usb1,msdos1)/multibootusb/grub/grub.cfg | yes | (usb0) does not exist |
Asus M5A97 LE | USB 3.0 | yes | yes (shell) | not detected | n/a | no | |
Asus M5A97 LE | USB 3.0 | no | yes (shell) | not detected | n/a | no | |
Asus P8Z77-V LE | USB 3.0 | yes | yes (shell) | not detected | n/a | no | hanging long time on ls |
Asus P8Z77-V LE | USB 3.0 | no | yes (shell) | not detected | n/a | no | hanging long time on ls |
Asus P8Z77-V LE | USB 2.0 | yes | no (menu) | detected at (usb0) | (usb0,msdos1)/multibootusb/grub/grub.cfg | yes | hanging long time on ls and search , with boot problems of some images |
Asus P8Z77-V LE | USB 2.0 | no | no (menu) | detected at (usb0) | (usb0,msdos1)/multibootusb/grub/grub.cfg | yes | hanging long time on ls and search , with boot problems of some images |
Lenovo L560 | USB 3.0 | yes | yes (shell) | not detected | n/a | no | hanging long time on ls |
Lenovo L560 | USB 3.0 | no | yes (shell) | not detected | n/a | no | hanging long time on ls |
NB: I did not investigate on the boot problems of the images - that seems to be yet another topic, which I expect is unrelated to the current discussion here.
Here is what I make out of it:
(usb1)
instead of (usb0)
. @mbusb I would expect that your efforts you are proposing to take in https://github.com/mbusb/multibootusb/issues/242#issuecomment-352843741 will solve my issue no. 3, but will leave my issue no. 2 unresolved.
HTH!
I have made a latest commit to devel to solve this issue. Tested by a user and it works fine. Can some one test and report back, so that I can prepare for new release.
Will try to as soon as possible and provide feedback via this ticket here.
If you confirm then I will release it by tomorrow.
On 30-Dec-2017 1:19 AM, "eaglerainbow" notifications@github.com wrote:
Will try to as soon as possible and provide feedback via this ticket here.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/mbusb/multibootusb/issues/242#issuecomment-354492606, or mute the thread https://github.com/notifications/unsubscribe-auth/AEC34PPz-TKNJ7mZTPhbprKWMXSFVHXPks5tFUJKgaJpZM4Q1LmB .
I am on it right now... However, I have to first create me a proper environment - otherwise the test will be for the toss 🤔
I currently struggle with
Traceback (most recent call last):
File "/usr/local/bin/multibootusb", line 149, in <module>
config.image_path = arg
NameError: name 'config' is not defined
when running some non-trivial variant like multibootusb -c -i ...
. However, /usr/local/lib/python3.5/dist-packages/scripts/config.py
is there and looks good to me.
Any clue what I could be doing wrong?
[Sorry for that noob-ish comment, but I am not familar with python at all]
Update: Found #238. Trying to understand it, but it does not match to what i see... Python is 3.5.2 running on ubuntu:16.04.3 LTS
Update: Mmmh.. made also sure that the packages python3-pyqt5 parted util-linux mtools python3-dbus python3-pyudev p7zip-full python3-six
are installed. Same situation...
Tossed now my initial environment and changed to the machine where I initially had installed multibootusb. I did a
dpkg -r python3-multibootusb
there. Afterwards I cloned your repository as of state 67f57a8d889dc4abf56cbf75ffcaf531941a271b, branch master
and created a fresh USB3.0 installation using a single iso image, plugging the stick into the USB3.0 port of the Lenovo L560:
ls <tab>
still does not list the USB device2.02~rc1
Switching over to my Asus M5A97 LE, I plugged it into an USB 2.0 port:
ls <tab>
lists again that (usb1,gpt1)
is there and there I can also find the grub.cfg
file at the place where I would expect it to be. In short: nope. Though it did not break anything major, it also did not solve neither issue 2 nor issue 3 for me.
Humpf... Just saw that you were asking for a test on branch devel
. Will repeat the entire procedure...
I wanted you to test devel branch not master.
On 30-Dec-2017 2:42 AM, "eaglerainbow" notifications@github.com wrote:
Tossed now my initial environment and changed to the machine where I initially had installed multibootusb. I did a
dpkg -r python3-multibootusb
there. Afterwards I cloned your repository as of state 67f57a8 https://github.com/mbusb/multibootusb/commit/67f57a8d889dc4abf56cbf75ffcaf531941a271b, branch master and created a fresh USB3.0 installation using a single iso image, plugging the stick into the USB3.0 port of the Lenovo L560:
- Grub again fell into shell mode
- ls
still does not list the USB device - Grub still is the old version 2.02~rc1
Switching over to my Asus M5A97 LE, I plugged it into an USB 2.0 port:
- Grub again fell into shell mode
- ls
lists again that (usb1,gpt1) is there and there I can also find the grub.cfg file at the place where I would expect it to be. In short: nope. Though it did not break anything major, it also did not solve neither issue 2 nor issue 3 for me.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/mbusb/multibootusb/issues/242#issuecomment-354501109, or mute the thread https://github.com/notifications/unsubscribe-auth/AEC34Iq8JRptO9BpB5gAoWChJOmWMmOXks5tFVXYgaJpZM4Q1LmB .
Status as of branch devel
, commit 22226a40fcd06f8950e893daaef6fd8804ce0ecc:
2.03
is being used(hd0,gpt1)
. ls
is now fast.Summary:
Based on that I am in favor of releasing the new version.
@martinedelbrock You are the initial reported of this issue (I only "hijacked" it with the intention of contribution 😛 ). Version 9.0.0 is out. Could you please check if this fixes your issue as well? If yes, please close this issue...
Is it somehow possible to upgrade the bootloader binaries on an existing stick? Or do I need to completely wipe it an start from the beginning?
It is better to rename multibootusb and efi directory.
On 04-Jan-2018 1:13 AM, "JanSchnacki" notifications@github.com wrote:
Is it somehow possible to upgrade the bootloader binaries on an existing stick? Or do I need to completely wipe it an start from the beginning?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/mbusb/multibootusb/issues/242#issuecomment-355106252, or mute the thread https://github.com/notifications/unsubscribe-auth/AEC34IoRrKt9rVD6ZQ_wzByDZnBR--6Lks5tG9dygaJpZM4Q1LmB .
I have had the exact same problem, and just tried with the current devel branch, and it worked great.
NOTE: For anyone else experiencing troubles even with lates devel branch, make sure you run it in a chroot or similar, or uninstalls the currently installed version of MultibootUSB. I couldn't understand why I would still get booted into GRUB 2.02~rc1 before I realized the downloaded devel branch would not use it's own mbr.bin, but rather use the one in /usr/share/multibootusb from the currently installed version.
Suggestion for an easy way to help others not make the same mistake: make this clear in a warning message when running the version in devel branch. Although I am open for the idea that people more used to debugging things straight from git just assumes things like this happens if you have the same software already installed.
The new version (9.1.0) fixed this issue. If anyone experience issue of similar sort may open new issue as it would allow me to narrow down to the latest version.
OS: 4.13.0-kali1-amd64 #1 SMP Debian 4.13.13-1kali1 (2017-11-17) x86_64 GNU/Linux MultiBootUsb linux version 8.9.0 64 gb alcor flash drive, prevously low-level formatted, checked for errors and formatted to fat32 single primary partition with boot flag
Issue: boots to GRUB command line, no menu
When checking inside program all works ok - menu shows up, but not working in real boot from usb
ls output:
(ahci0) (ahci0,gpt3) (ahci0,gpt2) (ahci0,gpt1) (proc)
syslinux.cfg: