Possible to log %post when using chroot?

Pat patchu1 at yahoo.com
Wed Aug 13 21:40:44 UTC 2008


Quote from the site http://kbase.redhat.com/faq/FAQ_42_10490.shtm:
============
%post nochroot --log=/tmp/post.log
//post scripts and commands go here

The logfiles will be saved in the temporary installation environment. In order to make them available when the installation is complete, they need to be copied to the installation environment in the %post section as show below. Note that this can not be done in a chrooted environment; the "nochroot" option must be used. 
============

so when executing a chrooted %post script, it is not possible to log the activity? Is that right?

For example, I have a chrooted post section like this:

%post --log=/root/post.log
//do stuff 

I tried that but the commands and resulting error messages (if any) were not logged with one exception. Within that post section, I did create a run once script which runs after the first reboot. The output from that script when it ran after the first reboot was recorded to the post.log which I don't quite understand. I'm glad I can see the output however I would like to see the results of the other post commands as well which were done after the OS install and before the first reboot.

BTW I'm using CentOS 5.0 and Redhat 5.2. Thanks for any help!





      




More information about the Kickstart-list mailing list