如何从 Ubuntu 和 Windows 7 远程切换,反之亦然?

Ero*_*oft 5 boot grub2 dual-boot windows-7

如何在远程工作时从 Ubuntu 和 Windows 7(反之亦然)切换?

实际上,我在 MBR 上使用 Windows 加载程序 (BCD),我有两个选择:

如果我在 Windows 7 上工作并想启动到 Ubuntu,这很容易,因为我将 Ubuntu 设置为默认值。所以在重新启动时,系统直接进入GRUB(超时设置为“0”)并且 Ubuntu 在那里。

但是我怎么能再次回到 Windows 呢?有机会吗?

在打字时,我想知道是否可以解决这个问题,将 Windows 加载程序强制安装到 Ubuntu 并让 GRUB2 从不同的系统中进行选择。

它可以工作吗?

Vol*_*gel 6

很好,你已经解决了从 Windows 切换到 Linux 的部分。另一个方向并不难:


有一个命令grub-reboot可以满足您的需求 - 请参阅下面的详细信息:

如果您grub要启动的系统的菜单项是“Windows”,您只需执行以下操作:

$ grub-reboot Windows


如果您将硬件配置为在断电后启动,我认为计算机没有理由不能继续运行。

但如果没有,应该可以通过网络唤醒 (WOL) 将其唤醒,启动您在关机前配置的系统。WOL 与无法路由到本地网络之外的“特殊”网络包一起使用,因此该网络中需要一个设备,例如某些 DSL 路由器或任何计算机。



来自man 8 grub-reboot

 GRUB-REBOOT(8)     System Administration Utilities      GRUB-REBOOT(8)


 NAME
        grub-reboot - set the default boot entry for GRUB, for the next
        boot only

 SYNOPSIS
        grub-reboot [OPTION] MENU_ENTRY

 DESCRIPTION
        Set the default boot menu entry for GRUB,  for  the  next  boot
        only.

        [  ...  ]
        --boot-directory=DIR
               expect  GRUB images under the directory DIR/grub instead
               of the /boot/grub directory

        MENU_ENTRY is a number, a menu item title or a menu item  iden?
        tifier. Please note that menu items in submenus or sub-submenus
        require specifying the submenu components  and  then  the  menu
        item  component.  The  titles  should  be  separated  using the
        greater-than character (>) with no extra spaces.  Depending  on
        your  shell some characters including > may need escaping. More
        information about this is available in the GRUB Manual  in  the
        section about the 'default' command.
        [  ...  ]
Run Code Online (Sandbox Code Playgroud)


运行man -k grub相关命令列表 - 例如。grub-set-default也可以帮到你。