a1ive / grub2-filemanager

GRUB2-based file manager
https://a1ive.github.io/grub2-filemanager/
GNU General Public License v3.0
523 stars 105 forks source link

Boot Failure for Knoppix Runtime Live CD #167

Closed wimbrts closed 4 years ago

wimbrts commented 4 years ago

Knoppix Runtime Live CD fails to boot in case of Boot From ISO and in case of ISO map method. In case of partnew then booting with a1live Grub2 File Manager is working OK.

I have a working Grub2 menuentry that might be helpful to you to solve the issue. The critical part that can solve it is the asterisk in bootfrom=/dev/*$iso_path

if [ -e "$isopath/knoppix/runtimelivecd.iso" ]; then menuentry "ISO Knoppix - $isopath/knoppix/runtimelivecd.iso" { set iso_path=$isopath/knoppix/runtimelivecd.iso loopback loop $iso_path linux (loop)/boot/isolinux/linux bootfrom=/dev/*$iso_path lang=en apm=power-off nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 noswap tz=localtime initrd (loop)/boot/isolinux/minirt.gz loopback --delete loop } fi

a1ive commented 4 years ago

I can't boot this iso both on vm(vmware and virtualbox) and laptop.

wimbrts commented 4 years ago

I can boot this iso from USB made with USB_FORMAT Or UEFI_MULTI Booting in BIOS mode with Grub4dos menu and in UEFI Secure mode with Grub2 as EFI Manager selected (Addon-glim-agFM is not needed) The runtimelivecd.iso file is copied to folder images on USB

Grub4dos menu.lst entry iftitle [if exist /images/runtimelivecd.iso] ISO Knoppix - runtimelivecd.iso set iso_path=/images/runtimelivecd.iso map %iso_path% (0xff) map --hook root (0xff) kernel /boot/isolinux/linux bootfrom=/dev/*%iso_path% knoppix_dir=/KNOPPIX ramdisk_size=100000 lang=en apm=power-off nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 noswap tz=localtime initrd /boot/isolinux/minirt.gz

and Grub2 entry for runtimelivecd.iso in folder images on USB if [ -e "$iso_drive/images/runtimelivecd.iso" ]; then menuentry "ISO Knoppix - runtimelivecd.iso $iso_drive" { set iso_path=/images/runtimelivecd.iso loopback loop $iso_drive$iso_path linux (loop)/boot/isolinux/linux bootfrom=/dev/*$iso_path lang=en apm=power-off nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 noswap tz=localtime initrd (loop)/boot/isolinux/minirt.gz loopback --delete loop } fi

a1ive commented 4 years ago

I can't even boot the ISO directly in the vm. 深度截图_选择区域_20200406143542

wimbrts commented 4 years ago

Yes it is not so easy to boot Knoppix Runtime Live CD, but the asterisk in bootfrom=/dev/*$iso_path solved the issue

Knoppix is interesting since it is a small size more technically oriented Linux ISO

steve6375 commented 4 years ago

When using VBox 5 it works OK for MBR\Legacy. UEFI64 boots OK for me - I just can't see it!!! The audio works and I can hear it say 'Initiating startup sequence' when it gets to the Desktop or when you do a Ctrl-Alt-Del and it shuts down. image image

steve6375 commented 4 years ago

UEFI64 is OK on real system (except no usb kbd/mouse!)

wimbrts commented 4 years ago

kbd/mouse for Knoppix runtimelivece are OK in my case when booting in UEFI 64 Secure Or BIOS mode

a1ive commented 4 years ago

UEFI64 boots OK for me - I just can't see it!!! The audio works and I can hear it say 'Initiating startup sequence' when it gets to the Desktop or when you do a Ctrl-Alt-Del and it shuts down.

I encountered the same situation. The linux kernel should setup video display automatically, strange.

wimbrts commented 4 years ago

In Grub2 Live ISO Multiboot as Added to SuperUEFIinSecure Boot Disk I see in efi\grub\glim\main.cfg some video settings that might be helpful to you

`# GLIM USB GRUB2 Configuration insmod regexp

Required for GUI and to prevent "No video mode set" error

insmod all_video

Keep the same graphic mode for kernel booting (passed as vga=)

other values are "text" or any gfxmode value

set gfxpayload=keep

Enable GUI

terminal_output gfxterm

loadfont unicode

insmod png set theme=${prefix}/themes/invader/theme.txt

set isopath=/EFI/iso export isopath probe --set rootuuid --fs-uuid $root

Required to have these available in other configfile files

export theme export isopath export rootuuid set prefix=($root)/EFI/grub ` Somehow all comment in code section above is getting Header Text Format. Sorry but I cannot avoid it (yet) ....

On the other hand in my case booting straight with grub2 without gfxmode , I do not need any of these settings in my boot\grub\grub.cfg file for booting Knoppix Runtime Live CD and using grub_Linux.cfg as configfile.

Both ways:

  1. Grub2 Live Iso Multiboot glim booting in gfxmode using efi\grub\glim\main.cfg
  2. my grub2 mode booting straight without gfxmode using boot\grub\grub.cfg can be used and are OK for booting Knoppic Runtime Live CD ISO in BIOS and in UEFI Secure mode.
a1ive commented 4 years ago

set gfxpayload=keep set gfxpayload=text set gfxpayload=auto or vga=791 don't work...

wimbrts commented 4 years ago

insmod all_video

does that has effect ?

bootfrom=/dev/*$iso_path the asteriks I know is critical for booting Knoppix Runtime Live CD I think it is missing in your grub2 entry ....

Your knoppix.sh set vmlinuz_img="(loop)/boot/isolinux/linux"; set initrd_img="(loop)/boot/isolinux/minirt.gz"; set kcmdline="ramdisk_size=100000 lang=en apm=power-off nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime"; linux $vmlinuz_img $kcmdline $linux_extra; initrd $initrd_img;

a1ive commented 4 years ago

https://github.com/a1ive/grub2-filemanager/commit/c98e8b58b36b0e852ed7d432ac19259146ae4a87 https://github.com/a1ive/grub2-filemanager/blob/1009f880306f7d31fca674d7856d2fed2f7b51e8/boot/grubfm/rules/iso/loop_detect.sh#L342 I think this is the same as bootfrom=/dev/*$iso_path

wimbrts commented 4 years ago

Ok, so the Knoppix boot problem is solved ? Or do you still have some problem with the video in UEFI mode ?

a1ive commented 4 years ago

Or do you still have some problem with the video in UEFI mode ?

yes.

wimbrts commented 4 years ago

I have no idea how to solve it, but as described above in my two ways of booting Knoppix ISO there is no such video problem.

wimbrts commented 4 years ago

In a1ive Grub2 File Manager there is Option F4 - Disable graphics mode. Can this be used to overcome the Knoppix video problem ?

a1ive commented 4 years ago

In a1ive Grub2 File Manager there is Option F4 - Disable graphics mode. Can this be used to overcome the Knoppix video problem ?

I've tried. no.

a1ive commented 4 years ago

@wimbrts Please try if it works on your computer. grubfm.tar.gz

wimbrts commented 4 years ago

New version of grubfm was tested for booting Knoppix Runtime Live CD in BIOS and in UEFI mode each for 3 methods of booting. UEFI mode - 3x Failure (always) BIOS mode - From ISO fails (always) BIOS mode - map is booting but stops at Waiting USB - dev not found BIOS mode - partnew is booting OK BIOS mode - map after partnew is booting OK

The video problem in case of boot from ISO is still present in BIOS and UEFI mode dev Not found problem during booting is still present

a1ive commented 4 years ago

grub2-filemanager.tar.gz BIOS mode should work. (use linux16 command instead of linux command) But doesn't work under UEFI.

wimbrts commented 4 years ago

runtimelivecd.iso located in \efi\iso\knoppix folder BIOS mode Boot From ISO and map method fail - dev Not found UEFI mode Boot from ISO fail and video problem still exists

runtimelivecd.iso located in \images folder UEFI Secure and BIOS mode Boot From ISO - is booting OK - dev found UEFI Secure and BIOS mode map ISO fail

In my working menu I am using linux command and not linux16 BTW: the Grub2 File Manager has for me unreadable Chinese Chars

a1ive commented 4 years ago

Strange. For me, BIOS Boot from ISO -- OK, UEFI fail (video problem).

wimbrts commented 4 years ago

The path is critical, but for simple path then both UEFI Secure and BIOS mode are booting OK in case of Boot From ISO, but fail in case of map ISO.

It is not the pathlength: ISO located in \images\iso\knoppix is booting OK in BIOS and UEFI mode. I think video problem is solved as soon as knoppix start booting.

a1ive commented 4 years ago

grub2-filemanager.tar.gz now BIOS OK and UEFI OK. (path: /extra/livecd/knoppix/iso/runtimelivecd.iso) But the kernel still has video problem before X11 starts under UEFI.

but fail in case of map ISO.

"map ISO" is for Windows PE or other ISOs, not for Linux.

wimbrts commented 4 years ago

Boot From ISO tested: UEFI and BIOS Fail - path: /EFI/iso/knoppix/runtimelivecd.iso UEFI and BIOS OK - path: /images/runtimelivecd.iso

a1ive commented 4 years ago

It's kernel and init scripts have bugs.

wimbrts commented 4 years ago

OK, but booting straight with Grub2 and Grub4dos menu entries is working OK and very fast in all cases. Also Grub2 Live Multiboot that uses path: /EFI/iso/knoppix/runtimelivecd.iso is booting OK in BIOS and UEFI mode.

a1ive commented 4 years ago

rename 'EFI' to 'efi'

wimbrts commented 4 years ago

It works OK 🥇 EFI is generated by bcdboot.exe of Windows 10x64 in making bootable drive. Renaming to efi solves the Knoppix Boot problem. I will take care in my programs to Rename EFI in efi Thanks for your help to solve the problem 👍 May be better to move iso directory to root of USB drive.

YES, I have decided to Move iso directory to root of USB Boot Drive. Your latest version is booting Knoppix runtimelivecd.iso in UEFI Secure and in BIOS mode OK 🥇 Problem is solved 👍 (but v7-beta4 version still fails, I hope you make new official Release)

wimbrts commented 4 years ago

Thanks for new Release v7.0.0 🥇

Everything is working OK now 👍 and I will add this v7 version to USB_FORMAT and UEFI_MULTI in the addon-glim-agFM files