100% network (remote) install -- No direct machine access?

Tom Diehl tdiehl at rogueind.com
Sun Jan 2 21:17:16 UTC 2005


On Sun, 2 Jan 2005, S. W. Davison wrote:

> 
> 
> 
> I'm a kickstart beginner, but it seems to me that this ought
> to be possible.  Maybe someone can point me at the right
> documentation...
> 
> We have many sites which are geographically distant from
> each other.  At each site there are 10-20 machines running
> an old version of Linux.
> 
> We would like to upgrade all the machines to RHEL 3, but we
> would like to make the upgrades entirely remotely controlled
> and entirely automated.  Specifically, we don't want to be
> in the situation where personnel at each site must visit
> each machine for any purpose.  We are trying to avoid:
> o  Any use of floppies or CDs.
> o  Any use of console output from the machines.  (Many of
>     them do not have consoles, unless you plug one in
>     especially.)
> o  Any keyboard activity on the machine.  (Many of them do
>     not have keyboards attached in their normal service
>     configuration.)
> o  Any need to go into the machine's BIOS setup to enable
>     network booting or PXE.  (As far as I know, you can do
>     that only with a local keyboard and console.)
> 
> Reading the kickstart documentation, it looks as if one way
> to accomplish a kickstart install is to put a kickstart file
> (ks.cfg) on an ext2 partition of the machine to be upgraded.
> The ks.cfg file would specify an NFS host where the
> installation tree was available.  Then you boot from a
> boot/install floppy, and at the boot prompt you enter:
>      linux ks=hd:sda3:/mydir/ks.cfg
> 
> OK.  If I can do that, it seems to me that it ought to be
> possible to build the necessary vmlinuz, intitrd, and
> whatever else I needed (the stuff that would ordinarily
> be on the boot/install floppy), put them into /boot on the
> machine to be upgraded, and then change lilo's default boot
> command to:  "linux ks=hd:sda3:/mydir/ks.cfg"
> 
> Then, if I do a "shutdown -r" over a network connection, the
> target system should reboot and go straight into the
> kickstart installation, just as if it had booted from the
> floppy disk.
> 
> Is that possible?  Can anyone point me at documentation for
> setting up the necessary boot files?

That should work, but another thing you could do is put your 
ks.cfg file on a web server, then copy the kernel and initrd
file from the images/pxe directory on the first install disk
to something like /boot/pxe. Add an entry to lilo/grub.conf that 
looks something like the following:
linux ks=http://www.mydomain.com/kickstart/ks.cfg ksdevice=link\
ramdisk=-32768

If you have a properly built ks.cfg it should work just fine.
If you want to keep an eye on the progress of the installation
simply add a vnc line to your ks.cfg file pointed to a machine
you have access too. I have done this many times. It takes a
fair amount of fiddeling to get the ks.cfg correct but it can be
done. You can also set up a yum repository and use a combiination
of kickstart and yum to get the machines installed remotely.
Using yum in the %post of the ksconfig along with the yumgroups
stuff allows you to basically have the same ks.cfg for multiple
machines and just vary the yumgroups.xml file based on the hostname
for a particular machine. Again getting this setup initally requires
some fiddeling but in the end you end up with a machine that is fully
updated on the first boot, without having to build a custom distro.


HTH,

Tom




More information about the Kickstart-list mailing list