[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Re: Post Install Script questions
- From: Philip Rowlands <phr doc ic ac uk>
- To: "'kickstart-list redhat com'" <kickstart-list redhat com>
- Subject: Re: Post Install Script questions
- Date: Thu, 1 May 2003 09:33:37 +0100 (BST)
On Wed, 30 Apr 2003, Robert Denton wrote:
>I am working ona post install script and half seems to work the other half
>doesn't. Here are the items I am having trouble with:
>
>%post --nochroot
Why --nochroot? You only work outside /mnt/sysimage for one line.
Suggest you split the %post into two; one --nochroot, the second
chrooted.
%post --nochroot
>cat /proc/mdstat >> /mnt/sysimage/root/ks-install.txt
%post
>echo "Kickstarted RH9: `date`" > /mnt/sysimage/root/ks-install.txt
>
>wget http://10.101.10.3/httpd.conf -o /root/wget.log
>/mnt/sysimage/sbin/chkconfig --level 345 httpd on
>service httpd start
>service httpd status >> /root/ks-install.txt
>
>echo "MAILADDR netadmin hs com" >> /mnt/sysimage/etc/mdadm.conf
>echo "mdadm -Fs --delay=6000 &" >> /mnt/sysimage/etc/rc.d/rc.local
Or activate the "mdmonitor" script in /etc/init.d
># Add user and set password
>useradd -G root phantom
>echo "menace" | passwd phantom --stdin
># this line will work just fine when you are logged in as root
># but it doesn't seem to work in %post
It's working on your nochroot /etc files
># Notify me with install log:
># as above, works from command line, not in post.
>mail robert hs com -s "`hostname` is ready." <
>/root/ks-install.txt
Again, no need for this to run nochrooted.
Hope this helps,
Phil
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]