From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Thomas Schmitt" Subject: Re: ISO installer image: GPT versus MBR partitions Date: Thu, 25 Apr 2019 17:09:05 +0200 Message-ID: <23526677701293855388@scdbackup.webframe.org> References: <20190425114943.el4reqk5364zpuok@pelzflorian.localdomain> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([209.51.188.92]:34248) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hJgCS-0001TK-4P for guix-devel@gnu.org; Thu, 25 Apr 2019 11:22:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hJfxR-00087t-8l for guix-devel@gnu.org; Thu, 25 Apr 2019 11:06:42 -0400 In-Reply-To: <20190425114943.el4reqk5364zpuok@pelzflorian.localdomain> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: bug-xorriso@gnu.org Cc: guix-devel@gnu.org Hi, Florian Pelz wrote: > I do not know and did not try yet how to configure GRUB to produce > both 32-bit and 64-bit EFI. As Debian user i am in the comfortable position to install the three binary packages for BIOS, x86 EFI 32 bit, and x86 EFI 64 bit. Then grub-mkrescue knows what to do. Some digging in the source of grub-mkrescue and util/grub-install-common.c reveils that it is about the existence of $cpu-$firmware directories with lots of .mod files in them: $ ls /usr/lib/grub grub-mkconfig_lib i386-efi i386-pc x86_64-efi The binary Debian packages nearly entirely consist of one of these directories, each: https://packages.debian.org/sid/amd64/grub-efi-amd64-bin/filelist https://packages.debian.org/sid/amd64/grub-efi-ia32-bin/filelist https://packages.debian.org/sid/amd64/grub-pc-bin/filelist But i don't know the tool which is to be used for creating those directories and for filling them with .mod files. Maybe you find some GRUB tool usage in the Guix ISO production which uses parameters like "x86_64" "efi". Or the name "grub-mkconfig_lib" gives a hint ? man grub-mkconfig and info chapter are quite sparse. > (Would putting both 32-bit and 64-bit > bootefi files in EFI/Boot/ be a good idea for Guix ISOs in general, or > could this lead to problems with 64-bit machines or lead to confusing > boot selection screens?) It should be perfectly ok to combine several EFI start programs in one EFI partition. The firmware is supposed to pick what it deems suitable. UEFI 2.4 3.4.1.1 "Removable Media Boot Behavior": "[...] the system firmware will attempt to boot from a removable media FilePathList[0] by adding a default file name in the form \EFI\BOOT\BOOT{machine type short-name}.EFI. Each file only contains one UEFI image type, and a system may support booting from one or more images types." You could even combine "IA32", "X64", "ARM", and "AA64" programs if you manage to keep all CPU specific files apart in the course of the further operating system run. > The Lenovo Ideapad 100S=E2=80=99s owner tried a USB drive prepared with = a > purely 32-bit GRUB [...] > export MKRESCUE_SED_MODE=3Dmbr_hfs > export MKRESCUE_SED_IN_EFI_NO_PT=3Dyes > grub-mkrescue --xorriso=3D./grub-mkrescue-sed.sh \ > -iso_mbr_part_type 0x83 -partition_offset 16 \ > and it boots fine. So that's not the mad EFI which hates all MBR partitions except one 0xef. > a DVD with an untreated Guix > git master could not be booted but very likely due to an error with my > external DVD drive (it often does not work) We could start a separate endeavor in private for diagnosing that. (My other sport besides ISO 9660 is burning flat round things.) > I will try a current git master Guix iso built for 32-bit next. If it > does not work (guixsd-install-0.15.0.i686-linux.iso did not work), I > will try the same with > dd if=3D/dev/zero bs=3D1 count=3D16 seek=3D446 of=3D/dev/sdc2 Was the machine similarly stuck as the Macbook ? That would probably be the partition problem, indeed. But failure when GRUB or a Linux kernel have taken over would be a different problem. The minimal grub-mkrescue ISO would then possibly work because it prompts the user before the problem can occur. Or maybe because it has a .mod file that is needed for that machine ? Have a nice day :) Thomas