Red Hat Bugzilla – Bug 97571
kickstart %pre poorly documented
Last modified: 2007-11-30 17:06:53 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.3.1) Gecko/20030425
Description of problem:
Use of the %pre directive is poorly documented, especially with regard to how it
interacts with the rest of the install process. The %include directive in more
recent versions of anaconda fixes this shortcoming, but it doesn't really help
when working with the current version of AS.
Specifically, documenting how a %pre script can (if it can) modify the kickstart
file. An example would be determining the hardware type (with dmidecode), and
loading the appropriate driver (such as a scsi controller driver that was
unsupported when AS 2.1 initially shipped).
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Search for %pre information in places such as the mailing list, google, etc.
2. Find hardly anything.
You can't do this in 2.1 (it's why the %include directive was added).
Assigning to Tammy to double-check what's currently there for the next release.
The latest step of docs for kickstart show how to use the %pre section to
determine information and then include it later in the kickstart file. Like
Jeremy said, the %include directive was added after RHEL 2.1. Is this the type
of example you are looking for?
In the kickstart-mailing list there have been reports of regenerating an entire
kickstart file in the %pre section, and writing it to /tmp/ks.cfg so that the
new version will be reread after %pre. grep'ing through /usr/lib/anaconda does
not find that string, but I did find /tmp/anaconda-ks.cfg. So I tried writing to
both of these locations in %pre but without success. Is regenerating the entire
kickstart file in %pre possible in AS 2.1?
The next version will include %include, and the next version of the docs will
include an example of how to use %pre to create a file and include it with %include.