grub.cfg

grub2启动项里面找不到Windows的情况,这时候就需要自己去配置grub.cfg

### BEGIN /etc/grub.d/30_os-prober ###
menuentry 'Windows Boot Manager (on /dev/sda2)' --class windows --class os $menuentry_id_option  'osprober-
efi-6E35-E6D3' { #查看分区UUID  ls -l /dev/disk/by-uuid/  找到并填入对应启动分区的UUID
    insmod part_gpt
    insmod fat
    set root='hd0,gpt2' #对应sda2,根据自己硬盘修改
    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  6E35-E6D3 #修改UUID
    else
      search --no-floppy --fs-uuid --set=root 6E35-E6D3  #修改UUID
    fi
    chainloader /efi/Microsoft/Boot/bootmgfw.efi
}
### END /etc/grub.d/30_os-prober ###

 https://www.jianshu.com/p/2d5958bed095

猜你喜欢

转载自www.cnblogs.com/liuzhenbo/p/10810282.html
cfg
今日推荐