解决Linux安装过程中不能安装Grub的问题

在grub-install的时候,具体问题如下:

sh-4.3# grub-install /dev/sdb
Installing for i386-pc platform.
grub-install: warning: this GPT partition label contains no BIOS Boot Partition; embedding won't be possible.
grub-install: error: embedding is not possible, but this is required for cross-disk install.

有一个不是办法的办法,就是不用Grub呗,可以使用syslinux,不过我不想用。具体方法在这里:

https://wiki.archlinux.org/index.php/Syslinux#Automatic_Install

解决Grub的方法:

就是在分区前面加上一个2MB大小的分区,设定它的标志为“bios_grub”。

如果你是Arch,那么可以在安装过程中下载:

sh4.3# pacman -S parted

好像还有一个软件要安装,具体没有注意,系统会有提示的,我一会再看看是什么,补充上来。

然后执行:

parted /dev/sdb set 1 bios_grub on

这里的“1”就是那个2MB大小的分区

具体执行过程如下:

sh-4.3# parted /dev/sdb set 1 bios_grub on
Information: You may need to update /etc/fstab.                           
 
sh-4.3# parted /dev/sdb print
Model: ATA WDC WD20EZRX-00D (scsi)
Disk /dev/sdb: 2000GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
 
Number  Start   End     Size    File system  Name  Flags
 1      17.4kB  3049kB  3032kB  ext4               bios_grub
sh-4.3# grub-install /dev/sdb
Installing for i386-pc platform.
Installation finished. No error reported.

这样就可以正常安装Grub了。


希望你喜欢!

参考链接:

https://blog.hostonnet.com/grub-install-warning-this-gpt-partition-label-contains-no-bios-boot-partition-embedding-wont-be-possible


转载于:https://my.oschina.net/u/1444992/blog/601355

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值