Auto Install for Mandrake Linux | ||
---|---|---|
Prev | Next |
If you were curious and pressed the F1 and/or the F2 keys during a Manual install, you would have noticed a few features that you may find useful; the text on the screens indicate that you can type the indicated keywords in response to the boot prompt. You can also add them to the Section append line(s) as additional SPACE separated parameters.
WARNING: Please be careful when adding additional parameters to the append line(s) that you DO NOT exceed the 256 character limit. Use the Method Parameter Aliases to reduce the line length. If this is still not enough, determine what you can live with or, find an alternative approach.
The following are a selection of interesting / exotic / useful features that I felt needed to be highlighted.
Just a couple for now. NOTE: you can only provide parameters to the kernel for 'compiled' in capabilities. You can not pass parameters to 'modules' using the append line.
quiet – has the dubious benefit of making the kernel less verbose while it is going though its boot up process. Mostly it is for those who complain about all the 'noise' on the screen at start up, which they can not read, do not understand or care about.
mem=nopentium – this is needed for Athlon based computers until a kernel upgrade is released which resolves AMD's 'not a bug' issue. This one is critical.
Until this point, I have always indicated that the configuration file is always called 'auto_inst.cfg' and that it is always located on the floppy diskette. Most people find this to be the easiest and most portable method and, it is better to use a consistent presentation in a document (less confusion).
However DrakX is not that limited. In fact it supports a number of different methods for specifying where the file is located and what its name is. The following provide an illustration of most approaches.
This is the primary location for the 'auto_inst.cfg' file and it is generally specified using 'kickstart=floppy'. You may also use 'auto_install=floppy'. In either case, when the floppy keyword is used, DrakX expects the file to be called 'auto_inst.cfg'or, 'auto_inst.cfg.pl'.
As an alternative to the floppy diskette, DrakX provides a capability that allows you to specify the name and location of the configuration file on the source media (where the install file set is). You can use this feature with any of the Network Services methods as well as the CD-ROM method.
Basically, you use either the kickstart= or auto_install= parameter to specify a file relative to the location of the install file set using the following general form:
auto_install=<path>/<name>
<path>/ - is the directory path, optional, to the file (<name>) relative to the directory that you specified with the 'directory:' parameter and,
<name> - is the name of a unique file which contains the installation selections (see the section Anatomy of the 'auto_inst.cfg' File).
Here is a simple example:
append auto_install=cfgs/test.cfg automatic=met:nfs, |
ser:fileserver,dir:/mnt/mass/Mandrake/mandrake/8.2, |
netw:static,ip:192.168.5.202,netm:255.255.255.0, |
gat:192.168.5.253,dns:192.168.5.253, |
ramdisk_size=32000 initrd=network.rdz root=/dev/ram3 vga=788 |
Can you imagine the possibilities? Especially (the people building clusters) if you combine this with the postInstall and postInstallNonRooted options? NOTE: DrakX mounts the NFS exported directory on the server as Read Only, and if you are using ftp or http it is a bit more troublesome, so ...
The CD-ROM method can be used too, but it requires that you create new CD-ROMs containing the configuration file(s) (see the section Creating an Updated Installation Set).
All the fore going require that you use a boot floppy, for those of you who are really into customization and the ultimate in CD-ROM automated installs, try modifying the images/cdrom.img file on the new CD-ROMs that you need to create. It works great if you only want one kind of install configuration. Warning: this will affect the replay_install.img that the Mandrake Control Center tool uses to generate Replay Installation disks so make sure that you correct that image using the postInstall options.
DHCP servers can, in addition to supplying an IP address and other network information, provide the name of a file to any or all client machine(s) that request an IP. When used with the Stage 1 install program, this file can be the name of a generic or a machine specific 'auto_inst.cfg' file.
This new feature of the Stage 1 install program is enabled when you specify network:dhcp. It is a bit exotic and definitely not for the faint of heart. However, it works well and has the benefit of not requiring you to waste characters on the 'append' line. It does require that you have access to the configuration files for the DHCP server and, optionally, that you know the Type and Hardware Address (link layer address) for each of the Network Interface Cards (NICs) that you plan to use this feature with. Working knowledge for configuring a DHCP server is mandatory.
There are four (4) method available; a simple one that can be used with any/all computers and three which allow you to customize for specific computers and requires specific parameter settings on the append line as well as changes to the DHCP server's configuration file. The following are a brief description of each.
If you are going to use the same configuration file with all computers, then adding an entry similar to the following in the Global Section of the dhcp.conf file will be adequate:
filename “my_cfgs/auto_inst.cfg”;
The 'syslinux.cfg' files' append line should be similar to the following:
append automatic=method:nfs,server:fileserver, |
directory:/mnt/mass/Mandrake/mandrake/8.2,network:dhcp |
ramdisk_size=32000 initrd=network.rdz root=/dev/ram3 vga=788 |
If you want specific configuration filenames given to specific computers, then you need to create host declarations which identify each of the client hardware addresses and the filenames to be served; similar to the following:
host tommy {
hardware ethernet 00:20:78:11:F9:A2;
filename “my_cfg/tommy.cfg”;
}
host johnny {
hardware ethernet 00:60:05:37:69:C8;
filename “my_cfg/johnny.cfg”;
}
The 'syslinux.cfg' files' append line should be similar to the following:
append automatic=method:nfs,server:fileserver, |
directory:/mnt/mass/Mandrake/mandrake/8.2,network:dhcp |
ramdisk_size=32000 initrd=network.rdz root=/dev/ram3 vga=788 |
If you are using Dynamic DNS and want to specify the host name for the computer, then use something similar to the following:
host tommy {
option dhcp-client-identifier 1:00:20:78:11:F9:A2;
filename “my_cfg/tommy.cfg”;
}
host johnny {
option dhcp-client-identifier 1:00:60:05:37:69:C8;
filename “my_cfg/johnny.cfg”;
}
The 'syslinux.cfg' files' append line should be similar to the following:
append automatic=method:nfs,server:fileserver, |
directory:/mnt/mass/Mandrake/mandrake/8.2,network:dhcp, |
hostname:tommy |
ramdisk_size=32000 initrd=network.rdz root=/dev/ram3 vga=788 |
This is a simple variation of Method 3 where you want or need to specify the domain name as well, then use something similar to the following:
host tommy {
option dhcp-client-identifier “tommy.eastcott.net”;
filename “my_cfg/tommy.cfg”;
}
host johnny {
option dhcp-client-identifier “johnny.eastcott.net”;
filename “my_cfg/johnny.cfg”;
}
The 'syslinux.cfg' files' append line should be similar to the following:
append automatic=method:nfs,server:fileserver, |
directory:/mnt/mass/Mandrake/mandrake/8.2,network:dhcp, |
hostname:tommy,domain:eastcott.net |
ramdisk_size=32000 initrd=network.rdz root=/dev/ram3 vga=788 |
Note: the fore going examples assume the use of an ISC DHCP server: dhcp-server-3.0-0rc12.1mdk or later (earlier versions should work too).
A bit of advice for those of you contemplating setting up a DHCP server in an environment where there is one already, don't. At least not with out coordinating with the people responsible for administering the network so that it is set up correctly and does not interfere with existing operations. If you do, do not be surprised if they invite you for a picnic by the river and there is a 25kg bag of cement in the basket (hehehe).
My favorite for Network Service installs. Have you ever been stuck trying to find a keyboard and display to install on a headless server? Well if you enter display=<display machine name or IP>:<display> (eg. display=linux1:0) at the boot prompt and you use the command xhost + on the target display machine, then lo and behold all the Stage 2 information that would have been displayed on the local console will show up on the target display machine that you specified. NOTE: currently this only works when you are using a full GUI install (gtk), the newt or text modes do not support this.
If you create a boot diskette using the MandrakeSoft supplied network.img image, modify the 'syslinux.cfg' files' append line similar to the following:
append display=linux1:0 automatic=method:nfs, |
server:fileserver,directory:/mnt/mass/Mandrake/mandrake/8.2, |
network:static,ip:192.168.5.202,netmask:255.255.255.0, |
gateway:192.168.5.253,dns:192.168.5.253, |
ramdisk_size=32000 initrd=network.rdz root=/dev/ram3 vga=788 |
You can now do a remote Manual install on a headless machine too. (GC claims this has been available forrreverrrrrrr, hmmm). Only the Stage 2 portion of the install is actually displayed on the remote machine, all Stage 1 information is still presented on the local display (so if you made a mistake, you will never see the Stage 2 graphics stuff on the remote machines' display).
For the auto install crowd, there are three things you will have to do:
a) use the command xhost + on the target display computer. For the more security conscious, xhost + <IP or name> for the machine being installed. eg. xhost +192.168.5.202 or xhost +linux2.eastcott.net.
b) add the option 'interactive' => 'gtk', to your auto_inst.cfg file.
c) adjust your syslinux.cfg file to added the display= parameter.
d) Just to keep things from getting too confusing, you might want to start a second X session using the startx -- :1 command, then adjusting the 'display=' parameter so that it references this new session for the display.
One final note (hehehe), if you use the 'display=' parameter, the specified machine must have an X server running on it.
Prev | Home | Next |
Replay Install | Scratch Built Auto Install Diskette |