zoukankan      html  css  js  c++  java
  • 安装windows7和ubuntu双系统后引导项设置

    win7系统,U盘安装ubuntu,在选择【安装启动引导器的设备】时,
    1.如果你选择的是/dev/sda,即整个硬盘,他会将启动引导器使用grub进行系统引导,而不再使用windows loader,即这样安装完双系统,默认只能进入ubuntu系统.
    这时候,你要从ubuntu引导win7,增加启动项,只需要
    sudo update-grub
    这一句,它会自动查找windows7 loader 并将其写入/boot/grub/grub.cfg中
    增加一条 menuentry记录,重启应该就会看到win7启动项了(你可以查看grub.cfg是否自动修改了启动项)

    我的系统是14.04.1 STL,运行该命令后文件中增加了如下内容:

    ### BEGIN /etc/grub.d/30_os-prober ###
    menuentry 'Windows 7 (loader) (on /dev/sda1)' --class windows --class os $menuentry_id_option 'osprober-chain-848A4A888A4A76A8' {
        insmod part_msdos
        insmod ntfs
        set root='hd0,msdos1'
        if [ x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  848A4A888A4A76A8
        else
          search --no-floppy --fs-uuid --set=root 848A4A888A4A76A8
        fi
        parttool ${root} hidden-
        chainloader +1
    }
    set timeout_style=menu
    if [ "${timeout}" = 0 ]; then
      set timeout=10
    fi
    ### END /etc/grub.d/30_os-prober ###


    2.如果你选择的是 安装ubutu时挂载的/boot对应的设备号,比如/dev/sda5,则说明ubuntu是独立的引导项,重启系统时,看不到ubuntu启动项,默认进入win7系统.这时候,你要从win7引导ubuntu,需要
    安装easybcd,增加一条启动项记录,具体使用方法自己查吧.
    应该注意的一点,增加记录时,(不确定)选好启动项对应的设备,如/dev/sda5

  • 相关阅读:
    浅谈c#中使用lock的是与非
    C#设计模式学习笔记单例模式
    ArrayList c.toArray might (incorrectly) not return Object[] (see 6260652)
    java.lang.Object 之 clone() 使用

    把以前的补齐 张
    String的方法 张
    随便写写 张
    集合框架 张
    java 张
  • 原文地址:https://www.cnblogs.com/cotton/p/3970731.html
Copyright © 2011-2022 走看看