Making the Kickstart File Available


A kickstart file must be placed in one of two locations:

  • On a boot diskette

  • On a network

Normally a kickstart file is copied to the boot diskette, or made available on the network. The network-based approach is most commonly used, as most kickstart installations tend to be performed on networked computers. Let us take a more in-depth look at where the kickstart file may be placed.

Creating a Kickstart Boot Diskette

To perform a diskette-based kickstart installation, the kickstart file must be named ks.cfg and must be located in the boot diskette’s top-level directory. Note that the Red Hat Linux boot diskettes are in MS-DOS format, so it is easy to copy the kickstart file under Linux using the mcopy command:

mcopy ks.cfg a:

Alternatively, you can use Windows to copy the file. You can also mount the MS-DOS boot diskette and cp the file over.

Making the Kickstart File Available on the Network

Network installations using kickstart are quite common, because system administrators can easily automate the installation on many networked computers quickly and painlessly. In general, the approach most commonly used is for the administrator to have both a BOOTP/DHCP server and an NFS server on the local network. The BOOTP/DHCP server is used to give the client system its networking information, while the actual files used during the installation are served by the NFS server. Often, these two servers run on the same physical machine, but they are not required to.

To perform a network-based kickstart installation, you must have a BOOTP/DHCP server on your network, and it must include configuration information for the machine on which you are attempting to install Red Hat Linux. The BOOTP/DHCP server will provide the client with its networking information as well as the location of the kickstart file.

If a kickstart file is specified by the BOOTP/DHCP server, the client system will attempt an NFS mount of the file’s path, and will copy the specified file to the client, using it as the kickstart file. The exact settings required vary depending on the BOOTP/DHCP server you use. Here is an example of a line from the dhcpd.conf file for the DHCP server shipped with Red Hat Linux:

filename "/usr/new-machine/kickstart/"; next-server blarg.redhat.com;

Note that you should replace the value after filename with the name of the kickstart file (or the directory in which the kickstart file resides) and the value after next-server with the NFS server name.

If the file name returned by the BOOTP/DHCP server ends with a slash (/), then it is interpreted as a path only. In this case, the client system mounts that path using NFS, and searches for a particular file. The file name the client searches for is:

<ip-addr> -kickstart

The ip-addr section of the file name should be replaced with the client’s IP address in dotted decimal notation. For example, the file name for a computer with an IP address of 10.10.0.1 would be 10.10.0.1-kickstart. Note that if you do not specify a server name, then the client system will attempt to use the server that answered the BOOTP/DHCP request as its NFS server. If you do not specify a path or file name, the client system will try to mount /kickstart from the BOOTP/DHCP server and will try to find the kickstart file using the same ip-addr -kickstart file name as described above.

Making the Installation Tree Available

The kickstart installation needs to access an installation tree. An installation tree is a copy of the binary Red Hat Linux CD-ROMs with the same directory structure. If you are performing a CD-based installation, insert the Red Hat Linux CD-ROM #1 into the computer before starting the kickstart installation. If you are performing a hard-drive installation, make sure the ISO images of the binary Red Hat Linux CD-ROMs are on a hard drive in the computer. If you are performing a network-based (NFS, FTP, or HTTP) installation, you must make the installation tree available over the network. Refer to the “Preparing for a Network Installation” section of Appendix A for details.

Starting a Kickstart Installation

To begin a kickstart installation, you must boot the system from a Red Hat Linux boot diskette or the CD-ROM and enter a special boot command at the boot prompt. If the kickstart file is located on a boot diskette that was created from the boot.img or bootnet.img image file, the correct boot command would be:

boot: linux ks=floppy

The linux ks=floppy command also works if the ks.cfg file is located on a vfat or ext2 file system on a floppy diskette and you boot from the Red Hat Linux CD-ROM. An alternate boot command for booting off the Red Hat Linux CD-ROM and having the kickstart file on a vfat or ext2 file system on a floppy diskette is:

boot: linux ks=hd:fd0/ks.cfg

If you need to use a driver disk with kickstart, you can still have the kickstart file on a floppy disk:

boot: linux ks=floppy dd

The Red Hat Linux installation program looks for a kickstart file if the ks command-line argument is passed to the kernel. The command-line argument can take a number of forms.

ks=nfs: <server> :/ <path>

The installation program will look for the kickstart file on the NFS server as file path. The installation program will use DHCP to configure the Ethernet card. For example, if your NFS server is server.example.com and the kickstart file is in the NFS share /mydir/ks.cfg, the correct boot command would be:

ks=nfs:server.example.com:/mydir/ks.cfg.

ks=http:// server / path

The installation program will look for the kickstart file on the HTTP server, as file path. The installation program will use DHCP to configure the Ethernet card. For example, if your HTTP server is server.example.com and the kickstart file is in the HTTP directory /mydir/ks.cfg, the correct boot command would be:

ks=http://server.example.com/mydir/ks.cfg.

ks=floppy

The installation program looks for the file ks.cfg on a vfat or ext2 file system on the floppy in drive /dev/fd0.

ks=hd: <device> / <file>

The installation program will mount the file system on <device> (which must be vfat or ext2), and look for the kickstart configuration file as a file in that file system (for example, ks=hd:sda3/mydir/ks.cfg).

ks=file:/ <file>

The installation program will try to read the file from the file system; no mounts will be done. This is normally used if the kickstart file is already on the initrd image.

ks=cdrom:/ <path>

The installation program will look for the kickstart file on CD-ROM, as file path.

ks

If ks is used alone, the installation program will configure the Ethernet card in the system using DHCP. The system will use the bootServer from the DHCP response as an NFS server to read the kickstart file from (by default, this is the same as the DHCP server).

The kickstart file will be identified in one of the following ways:

  • If DHCP is specified and the bootfile begins with a /, the bootfile provided by DHCP is looked for on the NFS server.

  • If DHCP is specified and the bootfile begins with something other than a /, the bootfile provided by DHCP is looked for in the /kickstart directory on the NFS server.

  • If DHCP did not specify a bootfile, then the installation program tries to read the file /kickstart/1.2.3.4-kickstart, where 1.2.3.4 is the numeric IP address of the machine being installed.

ksdevice= <device>

The installation program will use this network device to connect to the network. For example, to start a kickstart installation with the kickstart file on an NFS server that is connected to the system through the eth1 device, use the command

ks=nfs: <server> :/ <path>  ksdevice=eth1

at the boot: prompt.




Official Red Hat Linux Administrator's Guide
Official Red Hat Linux Administrators Guide
ISBN: 0764516957
EAN: 2147483647
Year: 2002
Pages: 278
Authors: Red Hat Inc

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net