Auto Install for Mandrakelinux | ||
---|---|---|
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, in the 'syslinux.cfg' file, to the Section 'append' line(s) as additional SPACE separated parameters. All kernel parameters are normally placed at the end of the 'append' line so that the 256 character limit can be fully used for parameters passed to the Stage1 installer.
|
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.
|
You can only provide parameters to the kernel for 'compiled' in capabilities. You can not pass parameters to 'modules' using the append line in the 'syslinux.cfg' file. |
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. This option has become the default used in the 'lilo.conf' file. |
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:/Mandrake/10.0, |
netw:static,ip:192.168.5.202,netm:255.255.255.0, |
gat:192.168.5.253,dns:192.168.5.253 ramdisk_size=128000 |
initrd=network.rdz root=/dev/ram3 acpi=ht vga=788 |
|
All the text starting with append through 788 are on ONE line. |
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 IP-based File Naming feature will aid those of you wanting to manage all the configuration files from the NFS server and create a boot floppy set (not machine customized). It works this way:
On the file server, create each machine's configuration file using the following form:
<name>-<IP Address> |
|
<IP Address> |
is expressed as a combined hexidecimal value for each component of the IP address (the letters must be Upper Case). eg. 192.168.5.225 would be C0A805E1 |
then set the 'auto_install=' parameter in the 'syslinux.cfg' file as follows:
auto_install=<path>/<name>-IP or
auto_install=<path>/<name>-IP.pl
Now when the 'auto_install=' parameter is processed, the 'IP' portion is replaced by the IP Address for the machine, and the resultant file is accessed on the server. The following is a simple example:
On the server, create the auto install file 'cfgs/test-C0A805E1' and in the 'syslinux.cfg' file, set the append parameter as follows:
append auto_install=cfgs/test-IP automatic=met:nfs, |
ser:fileserver,dir:/Mandrake/10.0, |
netw:static,ip:192.168.5.202,netm:255.255.255.0, |
gat:192.168.5.253,dns:192.168.5.253 ramdisk_size=128000 |
initrd=network.rdz root=/dev/ram3 acpi=ht vga=788 |
|
All the text starting with append through 788 are on ONE line. |
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 CD Set). The configuration files are placed on the CD-ROM in a manner similar to the one described above on an NFS server.
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. Better yet, check out the Boot CD-ROM and Auto Install Diskette section.
|
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 capability of the Stage 1 install program is available when you specify network:dhcp, but you must explicitly tell the installer to use the DHCP supplied file by adding netauto as well. 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.
|
If you are planning to use the IP-based File Naming, then you must have the DCHP server provide fixed IPs rather than a random one from the pool. |
There are five (5) methods 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 fifth, IP-based File Naming, can substantially reduce the work required to maintain and manage the configuration files. The following are a brief general 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 dhcpd.conf file will be adequate:
filename "my_cfgs/auto_inst.cfg";
The 'syslinux.cfg' files' append line should be similar to the following:
append netauto automatic=met:nfs, |
ser:fileserver,dir:/Mandrake/10.0, |
netw:dhcp, ramdisk_size=128000 |
initrd=network.rdz root=/dev/ram3 acpi=ht vga=788 |
|
All the text starting with append through 788 are on ONE line. |
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 netauto automatic=met:nfs, |
ser:fileserver,dir:/Mandrake/10.0, |
netw:dhcp, ramdisk_size=128000 |
initrd=network.rdz root=/dev/ram3 acpi=ht vga=788 |
|
All the text starting with append through 788 are on ONE line. |
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 netauto automatic=met:nfs, |
ser:fileserver,dir:/Mandrake/10.0, |
netw:dhcp,hos:tommy, ramdisk_size=128000 |
initrd=network.rdz root=/dev/ram3 acpi=ht vga=788 |
|
All the text starting with append through 788 are on ONE line. |
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 "\000tommy.eastcott.net"; |
filename "my_cfg/tommy.cfg"; |
} |
|
host johnny { |
option dhcp-client-identifier "\000johnny.eastcott.net"; |
filename "my_cfg/johnny.cfg"; |
} |
The 'syslinux.cfg' files' append line should be similar to the following:
append netauto automatic=met:nfs, |
ser:fileserver,dir:/Mandrake/10.0, |
netw:dhcp,hos:tommy,dom:eastcott.net ramdisk_size=128000 |
initrd=network.rdz root=/dev/ram3 acpi=ht vga=788 |
|
All the text starting with append through 788 are on ONE line. |
This example illustrates the IP-based File Naming.
|
This can only be used if the DHCP server provides fixed IP address to the computer being installed. |
Add an entry similar to the following in the Global Section of the dhcpd.conf file:
filename "my_cfgs/auto_inst-IP";
Add a host declaration similar to the following:
host tommy { |
option dhcp-client-identifier 1:00:20:78:11:F9:A2; |
fixed-address "192.168.5.149"; |
} |
Create the computer specific installation file with a filename formed by substituting the hexidecimal representation of the fixed-address for the 'IP' portion of the generic name declared with the filename option. For this example, the filename should be: auto_inst-C0A80595 in the directory my_cfgs.
The 'syslinux.cfg' files' append line should be similar to the following:
append netauto auto_install=my_cfgs/auto_inst-IP automatic=met:nfs, |
ser:fileserver,dir:/Mandrake/10.0, |
netw:dhcp,hos:tommy ramdisk_size=128000 |
initrd=network.rdz root=/dev/ram3 acpi=ht vga=788 |
|
All the text starting with append through 788 are on ONE line. |
|
The fore going
examples assume the use of an ISC DHCP server:
|
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.
|
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 Network Auto Install Diskette Set using the MandrakeSoft supplied network.img and network_driver.img images, modify the 'syslinux.cfg' files' append line similar to the following:
append display=linux1:0 automatic=method:nfs, |
server:fileserver,directory:/Mandrake/10.0, |
network:static,ip:192.168.5.202,netmask:255.255.255.0, |
gateway:192.168.5.253,dns:192.168.5.253 ramdisk_size=128000 |
initrd=network.rdz root=/dev/ram3 acpi=ht vga=788 |
|
All the text starting with append through 788 are on ONE line. |
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 four 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 |
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 |