Remote control (via ethernet) a computer from boot for Grub choices. (On Linux)

9,479

Solution 1

Unfortunately, you can't do it using Ethernet out-of-box (unless you have a Linux-based BIOS in your PC).

But you can use Ethernet-to-Serial adapter (Serial Network Interface, SNI) and tune your GRUB to use serial console as terminal. I can't tell you how to tune GRUB for it, but for LILO, you just add one line to /etc/lilo.conf :

serial=0,115200n8

Then you can completely remove monitor, keyboard and mouse from your PC (except for adjusting BIOS setting).

Also, some BIOS's let you redirect even BIOS messages to serial port! :-)

Solution 2

It should be possible. Read this document about remote booting. The basic idea is that you "install" your linux distro on your main computer (use a virtual machine or something) on a partition (maybe on an external harddisk).

Then you can configure your second PC to boot remotely and configure your main PC to serve the distribution you want (so the PC always boots the "same" system and you edit the config of the boot server to make the switch).

Alternatively, you can set the default which GRUB will use for the next boot but for that, you need the test PC running for that.

[EDIT] Check the GRUB manual: Booting GRUB from the network

If you use this approach, you can put the GRUB menu.lst on your main PC and edit there. During boot, only those file need to be present and you can do you test install on the second PC as usual. As soon as the boot has finished, your main computer is no longer necessary.

Share:
9,479

Related videos on Youtube

Dom
Author by

Dom

I was home educated most of my life, I've always been interested in science particularly physics. I went to college for A'levels, then between that and University I did a year-long full time circus course specialising in Acrobatics and Aerial. I did my undergraduate degree at Sheffield, and a summer Nuffield research project on scalar hairy black holes. Now I'm doing a PhD in Quantum Information Theory in Curved Spacetimes. I have a lovely wife, Sascha, we got married May 2010. We like going out, walking, cycling or for a meal and the cinema.

Updated on September 17, 2022

Comments

  • Dom
    Dom almost 2 years

    I have a computer that I use for practically everything. In the same room I have a second computer that I use purely for trialing Linux distributions, It currently has Debian, gNewSense and Kubuntu on it with Grub to choose between. This computer has no keyboard / mouse / monitor, but it has directly wired ethernet to the home network.

    Is there any way I can set it to be remotely controlled from before / during grub so I can choose from the other computer which to run? I realise I can just crawl behind the desk and unplug the keyboard / mouse / monitor, but I don't particularly want to every time I reboot into a different distro.

    I also realise that remote access during boot is a security risk so is there a way of allowing only one MAC address to do the controlling?

  • Dom
    Dom almost 14 years
    When you say "install" the linux distro on the remote computer, do you mean just put a link to the different installations on the local computer. I would still want to be able to boot the local computer independently if necessary.
  • dingzhihu
    dingzhihu almost 14 years
    By install, I mean that you need to setup a boot server on your main computer. This server must be running while the second PC boots. But I might have found a much better solution.
  • Dom
    Dom almost 14 years
    Thank you, I'll have a go at that at the weekend. It looks like the sort of solution I was looking for.