staging.inyokaproject.org

Hippo und grub

Status: Ungelöst | Ubuntu-Version: Ubuntu 21.04 (Hirsute Hippo)
Antworten |

black_tencate

Avatar von black_tencate

Anmeldungsdatum:
27. März 2007

Beiträge: 11349

Hej,

Anlaß für diesen thread ist die Untersuchung der Umstände in diesem thread → https://forum.ubuntuusers.de/topic/mehrfache-boot-eintraege-im-bios-f8/

Ich habe eine Testumgebung geschaffen mit

hippo@hippo-VB:~$ sudo parted -l
Modell: ATA VBOX HARDDISK (scsi)
Festplatte  /dev/sda:  53,7GB
Sektorgröße (logisch/physisch): 512B/512B
Partitionstabelle: gpt
Disk-Flags: 

Nummer  Anfang  Ende    Größe   Dateisystem  Name                          Flags
 1      1049kB  1075MB  1074MB  fat32        T1-Win-iso                    msftdata
 2      1075MB  7517MB  6442MB  ntfs         T2-Win-iso                    msftdata
 3      7517MB  7622MB  105MB   fat32        EFI system partition          boot, esp
 4      7622MB  7639MB  16,8MB               Microsoft reserved partition  msftres
 5      7640MB  24,8GB  17,2GB  ntfs         Win10                         msftdata
 7      24,8GB  34,3GB  9437MB  ext4         Fossa
 8      34,3GB  43,7GB  9437MB  ext4         Gorilla
 9      43,7GB  53,1GB  9453MB  ext4         für_hippo
 6      53,1GB  53,7GB  538MB   ntfs                                       versteckt, diag
10      53,7GB  53,7GB  1049kB                                             bios_grub


hippo@hippo-VB:~$ 
  • zunächst ein Windows (auf GPT), dann Fossa, gefolgt vom Gorilla

    • da alles im EFI Modus, ist also der letzt installierte Gorilla grub-technisch federführend.

  • die Installation von Hippo erfolgte bewußt im "legacy" Modus

    • (Nebenbemerkung: Hippo kommt nur noch mit grub, syslinux ist wohl "out")

    • die für eine "legacy" Installation auf GPT notwendige bios_grub wurde "angemeckert", habe die dann eingerichtet und Hippo im "legacy" Modus installiert. Grub ist "auf /dev/sda" →

      hippo@hippo-VB:~$ sudo fdisk -l 2>/dev/null | egrep "Disk /|/dev/" | sed "s#^/dev/#Part /dev/#" | awk '{print $2}' | sed 's/://' | xargs -n1 -IX sudo sh -c "hexdump -v -s 0x80 -n  2 -e '2/1 \"%x\" \"\\n\"' X | xargs -n1 -IY sh -c \"case  \"Y\" in '48b4') echo X: GRUB 2 v1.96 ;; 'aa75' | '5272') echo X: GRUB Legacy ;; '7c3c') echo X: GRUB 2 v1.97 oder v1.98 ;; '020') echo X: GRUB 2 v1.99 ;; *) echo X: Kein GRUB Y ;; esac\"" 
      xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
      [sudo] Passwort für hippo: 
      xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
      /dev/sda: GRUB 2 v1.99
      xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
      /dev/sda1: Kein GRUB 6f74
      xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
      /dev/sda2: Kein GRUB 6f6f
      xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
      /dev/sda3: Kein GRUB f6c1
      xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
      /dev/sda4: Kein GRUB 00
      xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
      /dev/sda5: Kein GRUB 55aa
      xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
      /dev/sda6: Kein GRUB 55aa
      xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
      /dev/sda7: Kein GRUB 00
      xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
      /dev/sda8: Kein GRUB 00
      xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
      /dev/sda9: Kein GRUB 00
      xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
      /dev/sda10: Kein GRUB 31d2
      hippo@hippo-VB:~$ 
    • der Boot (im "legacy" Modus) ist erfolgreich.

Das große Erstaunen kam dann aber nach Umschalten in den EFI Modus und reboot. Ich hatte erwartet, daß im grub Menü (wie vor der "legacy" Installation vom Hippo) nach wie vor der grub von Gorilla federführend sei. Das ist aber nicht der Fall. An erster Stelle im grub Menü steht Ubuntu (==Hippo). In der ESP gibt es die entsprechende Veränderung, obwohl ja nur im "legacy" Modus installiert wurde.

hippo@hippo-VB:~$ lsblk -f
NAME    FSTYPE FSVER LABEL UUID                                 FSAVAIL FSUSE% MOUNTPOINT
sda                                                                            
├─sda1  vfat   FAT32       B456-27D0                                           
├─sda2  ntfs               30BE32384A0773B4                                    
├─sda3  vfat   FAT32       6630-4A9A                              63,2M    34% /mnt
├─sda4                                                                         
├─sda5  ntfs               D6E839A1E83980B3                                    
├─sda6  ntfs               BC56F82556F7DE58                                    
├─sda7  ext4   1.0         9f457d48-c2fe-430b-a4a8-ffdebdc74e7d                
├─sda8  ext4   1.0         28872a5b-de2a-49fe-841a-6f9388046d3b                
├─sda9  ext4   1.0         8c22a434-0092-4c4b-ad3e-b675071d1331    3,5G    53% /
└─sda10                                                                        
sr0                                                                            
hippo@hippo-VB:~$hippo@hippo-VB:~$ sudo mount /dev/sda3 /mnt
[sudo] Passwort für hippo: 
hippo@hippo-VB:~$ sudo ls /mnt/EFI/ubuntu
BOOTX64.CSV  grub.cfg  grubx64.efi  mmx64.efi  shimx64.efi
hippo@hippo-VB:~$ sudo cat /mnt/EFI/ubuntu/grub.cfg
search.fs_uuid 8c22a434-0092-4c4b-ad3e-b675071d1331 root hd0,gpt9 
set prefix=($root)'/boot/grub'
configfile $prefix/grub.cfg
hippo@hippo-VB:~$

Booten tut der Eintrag allerdings nicht, bleibt hängen.

EDIT.: Nun, beim 2. Startversuch (im EFI, nach einem "legacy" boot) will das Nilpferd wohl doch, oh,oh!

Stellt sich für mich die Frage, warum bei einer "legacy" Installation ubiquity dennoch (zusätzlich) grub in die ESP installiert wird?

Es ist (mir) klar, daß, wenn jetzt auf "EFI only" umgestellt werden soll, in Gorilla ein GRUB 2 von BIOS nach EFI umstellen passieren muß.

Gruß black tencate

Lidux

Anmeldungsdatum:
18. April 2007

Beiträge: 16801

Hallo black_tencate,

Hab dazu leider auch keine Erklärung .....

Mich würde aber mal interessieren welchen Inhalt die:

10      53,7GB  53,7GB  1049kB                                             bios_grub

hat und ob dort auch eine .cfg ist und deren Inhalt.

Gruss Lidux

black_tencate

(Themenstarter)
Avatar von black_tencate

Anmeldungsdatum:
27. März 2007

Beiträge: 11349

Hej Lidux

Lidux schrieb:

...Inhalt … bios_grub

ist immer die core.img

Gruß black tencate

Bilder

ChickenLipsRfun2eat Team-Icon

Anmeldungsdatum:
6. Dezember 2009

Beiträge: 12067

black_tencate schrieb:

Stellt sich für mich die Frage, warum bei einer "legacy" Installation ubiquity dennoch (zusätzlich) grub in die ESP installiert wird?

Ich rate mal, da ich es nicht weiß. Es gibt an sich keine Systeme mehr mit BIOS im x64-Bereich. Da die Nutzer das aber noch nicht alle mitbekommen haben, ist die Wahrscheinlichkeit es falsch zu installieren groß. Also wird parallel zum „klassischen Bootsektor“ geprüft, ob es eine EFI-Partition gibt und wenn ja, werden dort vorsichtshalber die nötigen Dateien angelegt. So ist gewährleistet, dass Ubuntu auch bei einem „BIOS Reset“ oder Umstellung noch startet.

Und „legacy“ ist ja auch nicht BIOS, sondern ein Kompatibilitätsmodus. Da ist beides auch irgendwie logisch.

Taomon Team-Icon

Supporter
Avatar von Taomon

Anmeldungsdatum:
30. Januar 2011

Beiträge: 8463

das Problem ist, das an nur Bios system ebenfalls eine fehlende efi Partition angemahnt wird und nicht nur einmal mehrmals, trotzdem das das Live-system nachweislich im bios mode gestartet wurde.

Zum schluß wird man noch mit Fehlermeldung grub-install in /dev/sd* gescheitert ist und dies ein kritischer Fehler sei beglückt.

Bei der Installation von groovy, ich habe geflucht wie ein droschken kutscher.

Gruß Taomon

black_tencate

(Themenstarter)
Avatar von black_tencate

Anmeldungsdatum:
27. März 2007

Beiträge: 11349

Hej ChickenLipsRfun2eat,

ChickenLipsRfun2eat schrieb:

...[...]

klingt plausibel

Und „legacy“ ist ja auch nicht BIOS, sondern ein Kompatibilitätsmodus. Da ist beides auch irgendwie logisch.

was auch immer das ist, was man in VBox bekommt, wenn EFI nicht aktiviert wird (also der Normalfall).

Ich denke auch mal

  1. Hippo ist noch nicht freigegeben

  2. ubiquity (das ist es ja immer noch) legt auf einer neuen *.vdi eine GPT an! Habe ich bemerkt an "Gemecker", daß da keine bios_grub sei, die gebraucht würde

Gruß black tencate

black_tencate

(Themenstarter)
Avatar von black_tencate

Anmeldungsdatum:
27. März 2007

Beiträge: 11349

Hej Taomon,

Taomon schrieb:

... Zum schluß wird man noch mit Fehlermeldung grub-install in /dev/sd* gescheitert ist und dies ein kritischer Fehler sei beglückt.

das jedenfalls (ich kenne das auch, waren ja auch einige threads hier) passierte eben bei einer Hippo Installation auf einer "msdos" MBR Platte mit vorgegebener ESP und "/" nicht, dafür steht aber eine komplette grub Installation in der ESP, und schon auch noch – wie man es erwartet – im MBR von /dev/sda

h@hh-VB:~$ sudo mount /dev/sda1 /mnt
[sudo] Passwort für hh: 
hh@hh-VB:~$ sudo ls -R /mnt
/mnt:
EFI

/mnt/EFI:
BOOT  ubuntu

/mnt/EFI/BOOT:
BOOTX64.EFI  fbx64.efi	mmx64.efi

/mnt/EFI/ubuntu:
BOOTX64.CSV  grub.cfg  grubx64.efi  mmx64.efi  shimx64.efi
hh@hh-VB:~$ sudo fdisk -l 2>/dev/null | egrep "Disk /|/dev/" | sed "s#^/dev/#Part /dev/#" | awk '{print $2}' | sed 's/://' | xargs -n1 -IX sudo sh -c "hexdump -v -s 0x80 -n  2 -e '2/1 \"%x\" \"\\n\"' X | xargs -n1 -IY sh -c \"case  \"Y\" in '48b4') echo X: GRUB 2 v1.96 ;; 'aa75' | '5272') echo X: GRUB Legacy ;; '7c3c') echo X: GRUB 2 v1.97 oder v1.98 ;; '020') echo X: GRUB 2 v1.99 ;; *) echo X: Kein GRUB Y ;; esac\"" 
xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
/dev/loop0: Kein GRUB 15d
xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
/dev/loop1: Kein GRUB bd5d
xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
/dev/loop2: Kein GRUB 785d
xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
/dev/loop3: Kein GRUB 85d
xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
/dev/loop4: Kein GRUB ff5d
xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
/dev/sda: GRUB 2 v1.99
xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
/dev/sda1: Kein GRUB 6f74
xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
/dev/sda2: Kein GRUB 00
xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value
/dev/sda5: Kein GRUB 00
hh@hh-VB:~$ 

Gruß black tencate

Tuemmler

Anmeldungsdatum:
26. März 2007

Beiträge: 8075

Moin Moin,

Taomon schrieb:

... Zum schluß wird man noch mit Fehlermeldung grub-install in /dev/sd* gescheitert ist und dies ein kritischer Fehler sei beglückt.

Lies einmal hier

Gruß

ChickenLipsRfun2eat Team-Icon

Anmeldungsdatum:
6. Dezember 2009

Beiträge: 12067

black_tencate schrieb:

…was auch immer das ist, was man in VBox bekommt, wenn EFI nicht aktiviert wird (also der Normalfall).

Das weiß ich leider nicht. Bei QEMU gibt es seabios, wenn man sich keins der vorhandenen EFI-Pakete wie OVMF installiert.

Antworten |