grub2 não pode ver o sistema de arquivos na partição / boot alternativa

1

Eu tenho 2 (em breve mais) sistemas operacionais independentes. No momento, ele é apenas o CentOS 6.6 e 7, mas adicionará vários outros.

Eu posso inicializar o CentOS 7 de forma limpa, mas o 6.6 não inicializa. O erro é:

error: no such device (long UUID here)
error: unknown filesystem

FYI, o disco é GPT, particionado com gdisk / parted. Há um /boot para 7 em /dev/sda2 e outro para 6,6 em /dev/sda9 . Ambos têm o diretório /boot/grub2/ completo (não que isso deva importar) e grub2.cfg idêntico.

O 7 um trabalho ( sda2 ) está formatado xfs . O malsucedido 6.6 um ( sda9 ) falha com ext2 , ext4 ou xfs .

Entrando na linha de comando do grub, tento listar as partições. Ele vê todas as partições, mas não pode ver um sistema de arquivos em nada, exceto sda2 :

grub> ls (hd0,2)
      Partition hd0,2: Filesystem type xfs, UUID 97df.... - Partition start at 2048 KiB - Total size 512000 KiB
grub> ls (hd0,9)
      Partition hd0,9: No known filesystem detected - Partition start at 279393720 KiB - Total size 495616 KiB

Inicializando em 7, posso montar sda9 diretamente, tudo parece bom.

Tabela de partições do parted:

(parted) p
Model: DELL PERC H730 Mini (scsi)
Disk /dev/sda: 8397GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags:

Number  Start   End     Size    File system  Name            Flags
 1      1049kB  2097kB  1049kB                               bios_grub
 2      2097kB  526MB   524MB   xfs
 3      526MB   537GB   537GB                                lvm
 4      537GB   1074GB  537GB                                lvm
 5      1074GB  1504GB  430GB                                lvm
 6      1504GB  1933GB  430GB                                lvm
 7      1933GB  2324GB  391GB                                lvm
 8      2324GB  2861GB  537GB                Linux LVM       lvm
 9      2861GB  2861GB  508MB   xfs          centos_66_boot
10      2861GB  2961GB  99.5GB               centos_66_root  lvm
11      2961GB  2971GB  9999MB               smart_data1
12      2971GB  3071GB  100GB                smart_data2

(nada nas partições smart_ *, para ser usado em aplicativos alternativos).

Se você preferir do gdisk:

Disk /dev/sda: 16401301504 sectors, 7.6 TiB
Logical sector size: 512 bytes
Disk identifier (GUID): 5B41D43E-6D17-4E34-9068-E66BD3753D70
Partition table holds up to 128 entries
First usable sector is 34, last usable sector is 16401301470
Partitions will be aligned on 2048-sector boundaries
Total free space is 10403256253 sectors (4.8 TiB)

Number  Start (sector)    End (sector)  Size       Code  Name
   1            2048            4095   1024.0 KiB  EF02
   2            4096         1028095   500.0 MiB   0700
   3         1028096      1049612287   500.0 GiB   8E00
   4      1049612288      2098196479   500.0 GiB   8E00
   5      2098196480      2937065471   400.0 GiB   8E00
   6      2937065472      3775934463   400.0 GiB   8E00
   7      3775934464      4539299839   364.0 GiB   8E00
   8      4539299840      5587875839   500.0 GiB   8E00  Linux LVM
   9      5587875840      5588867071   484.0 MiB   0700  centos_66_boot
  10      5588867072      5783203839   92.7 GiB    8E00  centos_66_root
  11      5783203840      5802733567   9.3 GiB     0700  smart_boot
  12      5802733568      5998047231   93.1 GiB    BF00  smart_data

Partes relevantes de /boot/grub2/grub.cfg :

menuentry 'CentOS Linux 7 (Core), with Linux 3.10.0-229.14.1.el7.x86_64' --class rhel fedora --class gnu-linux --class gnu --class os --unrestricted $menuentry_id_option 'gnulinux-3.10.0-229.14.1.el7.x86_64-advanced-d171cb6d-c39b-45d5-b09a-33f641c3f397' {
        load_video
        set gfxpayload=keep
        insmod gzio
        insmod part_gpt
        insmod xfs
        set root='hd0,gpt2'
        if [ x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt2 --hint-efi=hd0,gpt2 --hint-baremetal=ahci0,gpt2 --hint='hd0,gpt2'  97dfd142-3423-459a-a39e-9a6099b3e5fc
        else
          search --no-floppy --fs-uuid --set=root 97dfd142-3423-459a-a39e-9a6099b3e5fc
        fi
        linux16 /vmlinuz-3.10.0-229.14.1.el7.x86_64 root=/dev/mapper/root-lv_root ro rd.lvm.lv=root/lv_root rd.lvm.lv=centos/swap crashkernel=auto rhgb quiet
        initrd16 /initramfs-3.10.0-229.14.1.el7.x86_64.img
}
    menuentry 'CentOS release 6.6 (Final) (on /dev/mapper/vg_centos6-lv_centos6_root)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-simple-b5002a5f-a521-423c-bae5-82e0aefe5e17' {
        insmod part_gpt
        insmod xfs
        set root='hd0,gpt9'
        if [ x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt9 --hint-efi=hd0,gpt9 --hint-baremetal=ahci0,gpt9 --hint='hd0,gpt9'  5715cdc8-9d49-49c3-814f-eb887d69b7d4
        else
          search --no-floppy --fs-uuid --set=root 5715cdc8-9d49-49c3-814f-eb887d69b7d4
        fi
        linux /vmlinuz-2.6.32-504.el6.x86_64 root=/dev/dm-5
        initrd /initramfs-2.6.32-504.el6.x86_64.img
}

Eu também tentei códigos de partição alternativos para sda9 , nada funciona. O que estou perdendo?

Por que vale a pena, versão grub2:

# rpm -qi grub2
Name        : grub2
Epoch       : 1
Version     : 2.02
Release     : 0.17.0.1.el7.centos.4
Architecture: x86_64
Install Date: Mon 26 Oct 2015 05:48:42 PM IST
Group       : System Environment/Base
Size        : 7394739
License     : GPLv3+
Signature   : RSA/SHA256, Wed 23 Sep 2015 07:13:19 PM IDT, Key ID 24c6a8a7f4a80eb5
Source RPM  : grub2-2.02-0.17.0.1.el7.centos.4.src.rpm
Build Date  : Wed 23 Sep 2015 05:51:07 PM IDT
Build Host  : kbuilder.dev.centos.org
Relocations : (not relocatable)
URL         : http://www.gnu.org/software/grub/
Summary     : Bootloader with support for Linux, Multiboot and more

A pedido do comentador, saída:

# file -s /dev/sda9
/dev/sda9: SGI XFS filesystem data (blksz 4096, inosz 256, v2 dirs)
# file -s /dev/sda2
/dev/sda2: SGI XFS filesystem data (blksz 4096, inosz 256, v2 dirs)

E grub2-probe parece satisfeito com os dois:

# grub2-probe --device /dev/sda2
xfs
# grub2-probe --device /dev/sda9
xfs

grub2-fstest também parece retornar corretamente para essas partições:

# grub2-fstest -vvv -r /dev/sda2 /dev/sda ls -- -l
Device proc: Filesystem type procfs - Sector size 512B - Total size 0KiB
Device loop0: No known filesystem detected - Sector size 512B - Total size 8200650752KiB
    Partition loop0,gpt12: No known filesystem detected - Partition start at 2901366784KiB - Total size 97656832KiB
    Partition loop0,gpt11: No known filesystem detected - Partition start at 2891601920KiB - Total size 9764864KiB
    Partition loop0,gpt10: No known filesystem detected - Partition start at 2794433536KiB - Total size 97168384KiB
    Partition loop0,gpt9: Filesystem type xfs, UUID b5c911d7-4f55-46da-80fd-d956bad72234 - Partition start at 2793937920KiB - Total size 495616KiB
    Partition loop0,gpt8: No known filesystem detected - Partition start at 2269649920KiB - Total size 524288000KiB
    Partition loop0,gpt7: No known filesystem detected - Partition start at 1887967232KiB - Total size 381682688KiB
    Partition loop0,gpt6: No known filesystem detected - Partition start at 1468532736KiB - Total size 419434496KiB
    Partition loop0,gpt5: No known filesystem detected - Partition start at 1049098240KiB - Total size 419434496KiB
    Partition loop0,gpt4: No known filesystem detected - Partition start at 524806144KiB - Total size 524292096KiB
    Partition loop0,gpt3: No known filesystem detected - Partition start at 514048KiB - Total size 524292096KiB
    Partition loop0,gpt2: Filesystem type xfs, UUID 97dfd142-3423-459a-a39e-9a6099b3e5fc - Partition start at 2048KiB - Total size 512000KiB
    Partition loop0,gpt1: No known filesystem detected - Partition start at 1024KiB - Total size 1024KiB

Ajuda?

    
por deitch 26.11.2015 / 13:28

0 respostas