grub-install error on GPT partition table
# grub-install /dev/sda
/usr/sbin/grub-setup: warn: This GPT partition label has no BIOS Boot Partition; embedding won't be possible!.
/usr/sbin/grub-setup: warn: Embedding is not possible. GRUB can only be installed in this setup by using blocklists. However, blocklists are UNRELIABLE and their use is discouraged..
/usr/sbin/grub-setup: error: will not proceed with blocklists.
The problem is because I set the wrong flags for bios_grub partition:
# parted /dev/sda unit s print
Model: ATA QEMU HARDDISK (scsi)
Disk /dev/sda: 20971520s
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Number Start End Size File system Name Flags
1 34s 97656s 97623s ext2 bios_grub boot
2 98304s 20969471s 20871168s ext4 rootfs
Flags need set to bios_grub instead of boot:
# parted /dev/sda set 1 bios_grub on
Information: You may need to update /etc/fstab.
# partprobe
# parted /dev/sda unit s print
Model: ATA QEMU HARDDISK (scsi)
Disk /dev/sda: 20971520s
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Number Start End Size File system Name Flags
1 34s 97656s 97623s ext2 bios_grub bios_grub
2 98304s 20969471s 20871168s ext4 rootfs
# grub-install /dev/sda
Installation finished. No error reported.
阅读(1340) | 评论(0) | 转发(0) |