Upgrading A Headless Server? 28
Paul Bristow writes "I've been using a Headless Linux server at home for years and years, but I always find myself putting off doing a distro upgrade. It always means digging out the old graphics card, keyboard and monitor, dusting them off and plugging them in, just so I can have a console to upgrade on. Are there any linux distributions that will allow remote upgrades? You know, log in as root viua ssh, webmin, whatever, run upgrade prog, remotely reboot, off we go. ;-) I know I'm not the only one running a headless server, and I *know* how stable it is, but occasionally RedHat (in my case) come out with a nice new feature that I might want to upgrade for. Also, with just one server it might just be possible, but how do you upgrade a headless server farm?"
Nik posted this relevant article back in March about the PC Weasel, which sounds like a good way to do this, at the cost of a small hardware investment per box. Are there better ones?
A KVM (Score:1)
Try Debian (Score:3)
apt-get update
apt-get upgrade
done.
you want debian
apt-get update && apt-get -u -y upgrade (Score:2)
My modified Slackware can do this. (Score:4)
Unfortunately, this isn't helpful for your existing Redhat system. But it shows some ideas for things that can be done.
Debian can do it out of the box (Score:2)
One "apt-get dist-upgrade" and you're away!
Easy enough under *BSD (Score:3)
Serial console? (Score:2)
Reboot = no (Score:1)
Re:Reboot = no (Score:3)
Debian & serial-console (Score:1)
I have done this with Debian - but Why? (Score:2)
Debian can do this, as others have said, and I have actually DONE this with Debian (slink to potato) over ssh. You must remember to have _at least_ two ssh sessions open as root, I kept three just in case. The sshd upgrade was what scared me, but it handed off just fine. Of course, I had other problems...
I guess you could also create a Kickstart disk for Redhat and have it automatically install the newer Redhat.
I also have to ask: Why do you want to upgrade your headless box? It works, right?
-Percival
Re:Easy enough under *BSD (Score:1)
We routinely upgrade our remote headless FreeBSD boxen without any problems whatsoever.
fezbox (Score:2)
Essentially, once you've used fezbox to create a kickstart install script, all you have to do is put the cd and a floppy disk with the config files in the pc, reboot it, and it just gets done. Again, I don't know if a PC will boot with no video/keyboard/etc, but there might be some way to disable this in the BIOS. worth a try...
btw, cheap linux cdz from cheapbytes.com, linuxmall.com, in case ur like me and don't have broadband
Re:Reboot = no (Score:1)
You can use RPM to do a LIVE upgrade ... (Score:4)
Have done this several times myself.
Just run rpm -Fhv *.rpm in your newer distro's RPM directory (e.g., /mnt/cdrom/RedHat/RPMS) and it will only upgrade those componenets that are install.
Heck, sometimes you don't even need to reboot! (although expect a few library issues until you do)
-- Bryan "TheBS" Smith
Re:Reboot = no (Score:2)
---
Off with your head (Score:2)
As long as your computer can boot by itself, i.e. no booting problems and it brings up the network you're golden.
Your RPMs are easy to upgrade - just 'rpm -Uvh pkgname'. No need to reboot, but I do say damn the uptime and reboot if you've seriously just changed every piece of code in the box
Kernel can be a bit trickier. Telnet in, and patch it first thing (Oh wait, you've got a stock redhat kernel? You could rpm -Uvh it, but i've got a certain fondness for going to ftp.kernel.org and grabbing the newest stable kernel(2.2.16 I believe). Then you can just patch it and recompile whenever you want - no icky redhatness to deal with.) After it's patched - either login through an X terminal and 'make xconfig'. If you're using telnet 'make menuconfig'.
I'm hoping you know what to do after that, but if you don't - drop by the linux document project. They've got a mirror at www.linuxhq.com. There's a Kernel-Upgrading HOWTO which pretty much says everything i've said - and more
Re:Serial console? (Score:3)
Re:A KVM (Score:1)
Since you did bring it up and I'm sure there are others out there who are thinking the same thing I'll toss in my two cents on the monitor/keyboar/mouse switches: get something powered. For example the black box stuff we use at work is great and it can handle sun (read 13w3) and PC (read SVGA) interchangly on the same box (you can program the switch with what type is plugged into it and what it needs to output). I thought I'd get a similar effect when I got a monitor/keyboard/mouse switch that was not powered - it works fine on systems where I used a 14" monitor, but for every video card/17" or greater monitor combo I tried I got some signal degradation (read fuzzyness) most likely due to the length of signal cable (and signal drop at the box itself). I tried loading the cable with ferites as well. If anyone has suggestions with my problem speak away - but if this is the case that the orig. questioner posed I don't see this as a cheap/benefitial option since he seems quite happy with his lack of head, sorry, headless system.
Re:Try Debian (Score:1)
please don't degrade debian by trolling about how great apt is.
Re:Try Debian (Score:1)
Debian GNU/Linux (Score:1)
Here is what you will want to do once you've got Debian GNU/Linux installed:
edit
apt-get clean (to purge already downloaded and probably outdated files)
apt-get update (to update the packages list)
apt-get -f upgrade (to upgrade most packages, skipping things like major libs - the -f tells apt it should try to fix dependancies)
apt-get -f dist-upgrade (to do a full system-wide upgrade of all packages)
logout, login. done! (unless you upgraded the kernel, then you'll have to reboot).
Enjoy!
*BSD Console (Score:1)
Re:You can use RPM to do a LIVE upgrade ... (Score:1)
Re:I have done this with Debian - but Why? (Score:1)
Re:Off with your head (Score:1)
Thanks for the suggestions (Score:1)
Re:Off with your head (Score:2)
Ahh, grasshopper. It is time to reveal the secret of uptime.
init 1
init 4