welcome: please sign in
location: Kickstart

Moved to Confluence: https://osmium.morningside.edu/confluence/display/OPS/Kickstart

Kickstart

Kickstart is a method to install RHEL or CentOS based operating systems via the network with an "answer file".

These answer files along with the install medium are stored in frank.morningside.edu:/tank/kickstart.

Kickstart files

Updating OS install files

From time to time (Usually when a new version of the OS is released), I will add this revision to our kickstart server.

To add a new revision, download and extract the main installation files from the DVD1 iso into the ./dvds/[centos|rhel]/x.y/[arch] directory. For example, CentOS 6.0 64-bit would be installed into ./dvds/centos/6.0/x86_64/

There are a couple of programs in kickstart/bin to help with this. To deploy a new image:

  1. Create the empty repositories for the version: bin/new_dist.sh

    •     root@frank:/tank/kickstart/bin# ./new_dist.sh 6.5
          Creating directories under /tank/kickstart/dvds/centos//6.5
  2. Copy over the ISO files and mount them so we can copy the data.1

    •     $ scp CentOS-6.5-*-bin* kickstart:/tank/kickstart/
          CentOS-6.5-i386-bin-DVD1.iso
          CentOS-6.5-x86_64-bin-DVD1.iso
  3. Copy (or mount) the ISO images for network access.
    •     # bin/mount_image.sh ./CentOS-6.5-x86_64-bin-DVD1.iso /mnt/
          # cp /mnt/* dvds/centos/6.5/x86_64
          # umount /mnt

Update PXE server to allow installations from new dvds

  1. Copy the images/pxeboot from the dvd to the pxe server under /tftpboot/images/CentOS-<version>-<arch> directory.

    •     # scp -r dvds/centos/6.5/x86_64/images/pxeboot pixy:/tftpboot/images/CentOS-6.5-x86_64/
  2. Update the pxe boot menu in /tftpboot/pxelinux.cfg/default

    •     LABEL CentOS-6.5-x86_64 NetInstall
          kernel images/CentOS-6.5-x86_64/vmlinuz
          append initrd=images/CentOS-6.5-x86_64/initrd.img ks=http://kickstart/changeme.cfg devfs=nomount

Update the generic KS files

Next, a kickstart.cfg file must be made to point to it. Typically, this is done by copying an older kickstart file and modifying it appropriately. I keep an i386.cfg and x86_64.cfg which always point to the latest release we are running in production. To use an older release, 5.5-i386.cfg would be appropriate for version 5.5 (centos implied).

Since RHEL is in the minority, all versions imply centos unless rhel is specifically specified (eg, rhel-6.0-x86_64.cfg)

Lastly, the url's appear as http://kickstart/i386.cfg and the dvds (which are non-browsable) appear at http://kickstart/dvds/[dist]/[version]/[cpu]/

How to install a VM

Create your Virtual Machine normally and attach the "Netinstall" cd for the appropriate version (revision and processor architecture.)

For 6.0 based systems, at the grub prompt edit the install field and add "ks=<ks_url>". For 5.x based systems, at the LINUX prompt enter "linux ks=<ks_url>"

Choose network boot (VMWare defaults to this on a new VM), and select the appropriate CentOS version. After the installed loads you will be prompted for the kickstart file URL (good starting points are x86_64.cfg and i386.cfg)


CategoryCheatSheets

  1. Alternatively, we could mount the ISO image to the data directory. (1)

Kickstart (last edited 2017-08-07 13:12:16 by meyersh)