[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: A thread on grub-bug could need attention
From: |
Thomas Schmitt |
Subject: |
Re: A thread on grub-bug could need attention |
Date: |
Tue, 30 Jan 2018 20:15:02 +0100 |
Hi,
Daniel Kiper wrote:
> IIRC you see blank screen after installing some distros. Right?
It also does not work when booting the ISO images which shall install
the systems.
E.g. debian-9.3.0-amd64-netinst.iso :
mount debian-9.3.0-amd64-netinst.iso /mnt/iso
mount /mnt/iso/boot/grub/efi.img /mnt/fat
At the end of the binary /mnt/fat/efi/boot/bootx64.efi, "strings" sees:
search --file --set=root /.disk/info
set prefix=($root)/boot/grub
source $prefix/x86_64-efi/grub.cfg
(memdisk)/boot/grub
The search leads to the ISO 9660 filesystem.
/mnt/iso/boot/grub/x86_64-efi/grub.cfg has
insmod part_acorn
insmod part_amiga
insmod part_apple
insmod part_bsd
insmod part_dfly
insmod part_dvh
insmod part_gpt
insmod part_msdos
insmod part_plan
insmod part_sun
insmod part_sunpc
source /boot/grub/grub.cfg
/mnt/iso/boot/grub/grub.cfg has
if loadfont $prefix/font.pf2 ; then
set gfxmode=800x600
insmod efi_gop
insmod efi_uga
insmod video_bochs
insmod video_cirrus
insmod gfxterm
insmod png
terminal_output gfxterm
fi
if background_image /isolinux/splash.png; then
set color_normal=light-gray/black
set color_highlight=white/black
else
set menu_color_normal=cyan/blue
set menu_color_highlight=white/blue
fi
insmod play
play 960 440 1 0 4 440 1
set theme=/boot/grub/theme/1
menuentry --hotkey=g 'Graphical install' {
set background_color=black
linux /install.amd/vmlinuz vga=788 --- quiet
initrd /install.amd/gtk/initrd.gz
}
menuentry --hotkey=i 'Install' {
set background_color=black
linux /install.amd/vmlinuz vga=788 --- quiet
initrd /install.amd/initrd.gz
}
submenu --hotkey=a 'Advanced options ...' {
set menu_color_normal=cyan/blue
set menu_color_highlight=white/blue
set theme=/boot/grub/theme/1-1
menuentry '... Graphical expert install' {
set background_color=black
linux /install.amd/vmlinuz priority=low vga=788 ---
initrd /install.amd/gtk/initrd.gz
}
menuentry '... Graphical rescue mode' {
set background_color=black
linux /install.amd/vmlinuz vga=788 rescue/enable=true --- quiet
initrd /install.amd/gtk/initrd.gz
}
menuentry '... Graphical automated install' {
set background_color=black
linux /install.amd/vmlinuz auto=true priority=critical vga=788 ---
quiet
initrd /install.amd/gtk/initrd.gz
}
menuentry --hotkey=x '... Expert install' {
set background_color=black
linux /install.amd/vmlinuz priority=low vga=788 ---
initrd /install.amd/initrd.gz
}
menuentry --hotkey=r '... Rescue mode' {
set background_color=black
linux /install.amd/vmlinuz vga=788 rescue/enable=true --- quiet
initrd /install.amd/initrd.gz
}
menuentry --hotkey=a '... Automated install' {
set background_color=black
linux /install.amd/vmlinuz auto=true priority=critical vga=788 ---
quiet
initrd /install.amd/initrd.gz
}
submenu --hotkey=s '... Speech-enabled advanced options ...' {
set menu_color_normal=cyan/blue
set menu_color_highlight=white/blue
set theme=/boot/grub/theme/1-1-1
menuentry --hotkey=x '... Expert speech install' {
set background_color=black
linux /install.amd/vmlinuz priority=low vga=788
speakup.synth=soft ---
initrd /install.amd/gtk/initrd.gz
}
menuentry --hotkey=r '... Rescue speech mode' {
set background_color=black
linux /install.amd/vmlinuz vga=788 rescue/enable=true
speakup.synth=soft --- quiet
initrd /install.amd/gtk/initrd.gz
}
menuentry --hotkey=a '... Automated speech install' {
set background_color=black
linux /install.amd/vmlinuz auto=true priority=critical vga=788
speakup.synth=soft --- quiet
initrd /install.amd/gtk/initrd.gz
}
}
}
menuentry --hotkey=s 'Install with speech synthesis' {
set background_color=black
linux /install.amd/vmlinuz vga=788 speakup.synth=soft --- quiet
initrd /install.amd/gtk/initrd.gz
}
--------------------------------------------------------------------
Well, my MBR versus GPT theory fades away by Daniel Kiper's above question.
The next step would have been to build a grub-mkrescue image with
a partition layout like Knoppix 8.1. You'd take script
xorriso-1.4.8/frontend/grub-mkrescue-sed.sh
from a GNU xorriso source installation or from
https://dev.lovelyhq.com/libburnia/libisoburn/raw/master/frontend/grub-mkrescue-sed.sh
and use it as "xorriso" for the grub-mkrescue run.
It re-arranges the options for the xorriso run to achieve other partition
layouts and/or positions of the EFI System Partition.
Default is mode "mbr_only", which puts the EFI partition image after
the ISO 9660 partition and marks both partitions by MBR rather than GPT.
Best with xorrisofs option "-partition_offset 16", which lets the ISO
partition start at byte 32768 with an own superblock and directory tree,
while the overall ISO filesystem starts at byte 0 and claims the whole
image size including the EFI partition as its filesystem size.
grub-mkrescue -o output.iso minimal \
--xorriso=...path.../grub-mkrescue-sed.sh \
-partition_offset 16
If xorriso-1.4.8 is installed, you should afterwards get told by
xorriso -indev output.iso -report_system_area plain
something like:
System area summary: MBR grub2-mbr cyl-align-off
ISO image size/512 : 33864
Partition offset : 16
MBR heads per cyl : 64
MBR secs per head : 32
MBR partition table: N Status Type Start Blocks
MBR partition : 1 0x80 0x00 64 28040
MBR partition : 2 0x00 0xef 28104 5760
after this harmless warning:
libisofs: WARNING : Found hidden El-Torito image. Its size could not be
figured out, so image modify or boot image patching may lead to bad results.
(I will have to improve the multi-session capabilities with boot images
which are not reachable as files of the ISO 9660 filesystem.)
Have a nice day :)
Thomas
- Re: A thread on grub-bug could need attention, Daniel Kiper, 2018/01/08
- Re: A thread on grub-bug could need attention, Michel Bouissou, 2018/01/08
- Re: A thread on grub-bug could need attention, Daniel Kiper, 2018/01/29
- Re: A thread on grub-bug could need attention, Michel Bouissou, 2018/01/29
- Re: A thread on grub-bug could need attention, Michel Bouissou, 2018/01/29
- Re: A thread on grub-bug could need attention, Thomas Schmitt, 2018/01/29
- Re: A thread on grub-bug could need attention, Michel Bouissou, 2018/01/30
- Re: A thread on grub-bug could need attention, Thomas Schmitt, 2018/01/30
- Re: A thread on grub-bug could need attention, Michel Bouissou, 2018/01/30
- Re: A thread on grub-bug could need attention, Daniel Kiper, 2018/01/30
- Re: A thread on grub-bug could need attention,
Thomas Schmitt <=
- Re: A thread on grub-bug could need attention, Michel Bouissou, 2018/01/31
- Re: A thread on grub-bug could need attention, Thomas Schmitt, 2018/01/31
- Re: A thread on grub-bug could need attention, Michel Bouissou, 2018/01/31
- Re: A thread on grub-bug could need attention, Thomas Schmitt, 2018/01/31
- Re: A thread on grub-bug could need attention, Thomas Schmitt, 2018/01/31
- Re: A thread on grub-bug could need attention, Michel Bouissou, 2018/01/31
- Re: A thread on grub-bug could need attention, Thomas Schmitt, 2018/01/31
- Re: A thread on grub-bug could need attention, Daniel Kiper, 2018/01/31