Possible to install Linux on a headless machine?

Man of Honour
Joined
19 Oct 2002
Posts
29,751
Location
Surrey
I have a slightly annoying problem. I have bought one of the HP N40L Microservers that everyone is raving about in the Server forum. My intention was to run it headless after an install of either Ubuntu Server LTS or CentOS. It only has a standard VGA output on it and due to its tiny size I couldn't fit my spare graphics card in it anyway.

Sadly my main machine only has a DVI input on the TFT so I could not use that for the install. So I was intending to use a spare old TFT I had lying in the loft for years. The spare TFT has a VGA input so it would have been fine. However I've just realised I disposed of that TFT a few months ago. So I'm now stuck with a microserver that won't plug into any of my screens and I don't have a spare low profile gfx card to put into it. I therefore have three options:

1) Buy a cheap used TFT for the install and then sell it.
2) Buy a cheap low profile gfx card for the install and sell it.
3) Try to install the OS headless.

Before I go and buy any extra hardware I'd like to try to install the OS headless. Is this possible? e.g. boot into an OS off a DVD or USB key and ssh or remote desktop into the OS from my main machine.

Has anyone done this or can they offer any suggestions on how to? Any advise appreciated. Thanks.


EDIT: Just thought of another option: (4) I have a spare external USB hard drive. Maybe I could install an OS onto there using my main machine. Then enable remote desktop and try to book the microserver from it?
 
Last edited:
you could set linux up on another system then clone the partition to the microserver drive.

unlike windows linux is pretty much hardware discovery on boot and it did work fine when i upgraded my linux server.
 
With CentOS it should be possible to have the DVD automatically install by re-authoring the DVD with an edited isolinux.cfg to edit the startup menu to tell it to automatically call a Kickstart file on the DVD which will then install the system as you want. (Haven't tried this personally as I normally just call the Kickstart file manually off of a HTTP server by editing the boot command from the menu)

Alternatively, as Kickstart files are not necessarily easy to create, if you have a DHCP server on the network then you should be able to edit the isolinux.cfg (or equivalent) and pass the VNC option to run a VNC server during the install which can then be used to perform a manual graphical install, (you'd need to look at your DHCP leases or do a lot of pinging to find the address of the VNC server).

for more information see: here and here.
 
Thanks. The hard drive in main machine look the easiest to start with. If that doesnt work I will look at the vnc option.
 
What about LTSP ?

Install that on a server and PXE boot all your clients from it. It's actually not as difficult as it sounds - apt-get install ltsp-server && build client - very simple - not at all like what it was like in the old days
 
What about LTSP ?

Install that on a server and PXE boot all your clients from it. It's actually not as difficult as it sounds - apt-get install ltsp-server && build client - very simple - not at all like what it was like in the old days

THabks, I'll take a look if all else fails.

Old 15" LCDs go for pennies now, I'm sure you could get hold of one for <£20, saves a lot of hassle. It's always handy to have one spare anyway!

I had an old 19" but got rid of it when the wife moaned it wss taking up space in the loft :D
 
I thought I'd revisit this thread and give a quick update. Firstly thanks all for the suggestions. I think that I will eventually grab a cheap TFT from somewhere as it will be much easier long term. However I did get it running and managed to do it without one.

As suggested I set it up by simply putting the servers hard drive in my main machine and installing it there. However I did hit a problem. The server appeared to boot ok but I couldn't connect to it remotely. Diagnosing it was tricky due to the lack of a screen. I could see from my router that the server wasn't being assigned an IP. So by swapping the drive back into my main machine and reading the logs there I could see that it couldn't see the network card and therefore wasn't attempting to connect. A quick google showed that Ubuntu server is stricter than the desktop distro and deliberately won't setup the NIC automatically if you change it. Clearly I'd changed the NIC because it was now running in a different machine.

I considered just installing the desktop version insrtead, because that will configure the NIC automatically. But I didn't want all the bloat that comes with it. This is a low powered machine (AMD Neo) so lack of bloat is important. However the solution was simple. All I had to do was remove the old rules file and on reboot it then setup the NIC. So I obviously dropped the drive back into my main machine and removed it:

Code:
sudo rm etc/udev/rules.d/70-persistent-net.rules

And now it boots fine and connects to the network. Apparently this is a common issue when cloning Ubuntu server in a VM environment.

I now have a login prompt and can start setting it up properly :)
 
Last edited:
I was going to suggest using a serial connection, but depends on how HP set up the BIOSs/console redirects to tty from the factory.

I'm guessing they build them with a WHS user in mind, but that would have been one of my avenues of attempt!
 
Right it's been a few days now and I have to say that doing everything at a command prompt and headless is a fantastic way of learning your way arounf Linux. I've had several issues which I've managed to negotiate my way around and every time it has taught me something new. Being unable to simply turn on a screen and drop into a GUI means you need to search for possible fixes and navigate your way around config files and other command line tools.

I've just taught myself how to test network performance and diagnose why it wasn't running at gigabit. Another one I've worked my way around is exporting and re-importing virtualbox appliances (guest VM's) which get very confused when you suddenly switch the network card on them and then refuse to talk to you (I'm building the VM's on my main machine and then importing them into the headless server).

In general I'm also having to tiptoe my way around, and pre-test any dangerous commands beforehand on an identically setup VM. The last thing I need is to lose connectivity or somehow kill the server and have to start again. It's slowing things down quite a bit but I'm actually really enjoying all the learning I'm doing. It's definitely improving my knowledge!
 
How did you install in the end? I know the Debian alternate installer works over a serial port.

It was actually quite simple:

1) Take the hdd out of the server and put it in my main PC (also remove all other drives from my main PC).

2) Install Ubuntu Server as normal onto the servers hdd using the main PC.

3) Install sshd so I can connect to the server later.

4) Change the network config to use a static IP instead of DHCP, so I can find the server later :)

5) Swap the hdd back into the server.

6) Press the start button, wait around 20 secs and then ssh into it.
 
Back
Top Bottom