Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'd like to make a dual-boot machine that can be rebooted into either OS remotely.

The only idea I have is to make the grub configuration live on a FAT partition so that it can be edited by either OS. The user would manually change the default OS in menu.lst. (Maybe this would only work with grub 1, but I think that's all that's in CentOS right now.)

Will this work, or is there a more elegant way to handle this?

share|improve this question

migrated from May 6 '11 at 13:43

This question came from our site for system and network administrators.

Does anyone know why this might be getting votes to close? – Jim Hunziker May 6 '11 at 4:15
Thanks, @Zoredache. I just flagged myself. I saw it as a server problem because the machine is remote and used by multiple people, but because the decision of booting will be made out-of-band, you're right that it's more of a remote workstation. – Jim Hunziker May 6 '11 at 13:25
up vote 3 down vote accepted

It is a small utility that works both in Windows and Linux.

share|improve this answer

If the system can boot from its network card, and if you have an accessible DHCP server you can remotely configure:

  • Make separate partitions for Linux and Windows (practically goes without saying, but just in case).

  • Configure the DHCP server to offer a Linux PXE boot that mounts the Linux root filesystem when you want Linux, and to offer nothing at all when you want Windows.

  • Configure the dual-boot system's boot order to try the NIC first, and if it can't boot from the NIC, it falls back to the internal hard drive.

That's what we do to have one set of PCs be a regular Windows lab during the day and evenings, and be a small Linux cluster overnights and on weekends.

share|improve this answer

How about a single-port, IP-based KVM. When you need to reboot, connect to the KVM, restart and select your boot option? I like it because it is not complicated to set up.

If it is an HP server you could use the ILO for this. Other servers have similar tools.

share|improve this answer

Quick and dirty solution, but it should work: install Windows on the first partition with the default configuration, install Linux in the second one and put its boot loader in the partition's boot sector (instead of overwriting the MBR), then from each O.S. you can change the active partition on the disk (using diskpart in Windows and fdisk in Linux) and reboot the computer, thus forcing the next boot into the other one.

With this solution, you will not have any boot menu to select the O.S. you want to boot; but if you only need to change this setting remotely, this should not be a problem (and you can of course change the active partition from inside any O.S., you just need for it to finish booting if you're just starting the computer and want to boot the one that is currently not active).

share|improve this answer

What OS is currently on the machines in question?

If it's Windows, my first instinct would be to use Norton Ghost. There is an agent that comes with some of the later versions that you can install on a machine to remotely image it, provided that there is infrastructure in place on the machine's network to serve the image files.

The main issue with this is that you'd overwrite the Windows OS that is currently on the machine.

share|improve this answer
afaik Norton Ghost will only allow to build the machine (remotely) but won't allow to select which OS to boot remotely. – laurent May 5 '11 at 22:29
The initial settings would be in the grub configuration, pre-imaging. – Hyppy May 5 '11 at 22:31

If possible, I would prefer booting in one OS and installing the other (less used one) in a virtual machine so it can be started after boot.

I'm not convinced changing grub frequently is a very easy or secure solution, mainly remotely. Anyways, when grub updates to 2 this will not work anymore I think.

share|improve this answer
Both operating systems need to connect to a special PCI card that cannot be emulated. – Jim Hunziker May 6 '11 at 4:12

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .