Bugzilla will be upgraded to version 5.0 on a still to be determined date in the near future. The original upgrade date has been delayed.
Bug 228533 - in kickstart %post install does not evaluate %include properly
in kickstart %post install does not evaluate %include properly
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: anaconda (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Chris Lumens
Depends On:
  Show dependency treegraph
Reported: 2007-02-13 12:12 EST by Andrew Boyce-Lewis
Modified: 2007-11-16 20:14 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2007-02-27 10:59:06 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Andrew Boyce-Lewis 2007-02-13 12:12:26 EST
Description of problem:

When evaluating %include, anaconda apparently expands %include directives and
places them at the top of the %post section before any other lines (taking the
%included portions out of context).  This becomes a problem when order of
execution of %post install scripts matters. 

For example, a %post install section of a kickstart file:

%include /mnt/ksroot/1.ks
echo 2
%include /mnt/ksroot/3.ks
echo 4

The includes contain "echo 1" and "echo 3" respectively.

The expected output would be:


The actual result is however:


How reproducible: Always

Steps to Reproduce:
1. Create kickstart file with %includes as well as other lines in the %post
2. Install system using the kickstart file.
3. Observe kickstart output during %post.
Actual results:

%included lines are run first, followed by other lines. 

Expected results:

Per documentation, "Use the %include /path/to/file command to include the
contents of another file in the kickstart file as though the contents were at
the location of the %include  command in the kickstart file."

(documentation quoted from
Comment 1 Chris Lumens 2007-02-27 10:59:06 EST
This is fixed in RHEL5 which uses a completely different kickstart backend that
doesn't have such weird problems as this one.  If you require this fix in a
RHEL4 update, please talk to your support representative who will raise the
issue through the appropriate channels for consideration.  Thanks for the bug

Note You need to log in before you can comment on or make changes to this bug.