
2011/4/28 Erico Mendonça <erico.mendonca@gmail.com>:
2011/4/27 Tim Kirby <trk@cray.com>:
On 4/27/11 1:54 PM, "Erico Mendonça" <erico.mendonca@gmail.com> wrote:
I need to run some scripts after the partitions are formatted on SLES 11SP1. I tried "chroot-scripts", but it's not being executed at all.
Is there a known limitation for SLES11 SP1? The other types of scripts are being executed just fine (pre, post, init scripts).
I have chroot-scripts in production with SP1 and they are working just fine for me, FWIW.
That is weird. I've checked and rechecked my XML files, and the tags appears to be correct, but they're not executed at all.
According to the official docs, this should be it, under the main profile tag: <scripts> <chroot-scripts config:type="list"> <script> <filename>test.sh</filename> <interpreter>shell</interpreter> <source> <![CDATA[ echo "blah" ]]> </source> </script> </chroot-scripts> </scripts>
And indeed the AutoinstScripts.ycp module checks and should execute them as well. In the logs, I see pre/post/init scripts being executed, but I see no mention of chroot-scripts at all.
Could you send me one of your working examples (with chroot-scripts, that is) ?
I'm not sure if it's true for SLES11, but in openSUSE 11.4 you have the following situation: chroot = after the first installation has finished but before the bootloader will be installed postpartitioning = after the partitions are formatted, just before the first package will be installed (but after the installation of the new "deploy images" (lzma.... packages) I use the postpartitioning script to copy some additional stuff from my installation medium to the new system, e.g. <postpartitioning-scripts config:type="list"> <script> <filename>postpart2.sh</filename> <interpreter>shell</interpreter> <debug config:type="boolean">false</debug> <feedback config:type="boolean">true</feedback> <source><![CDATA[ #!/bin/bash mkdir /mnt/config InstMode=$(grep Cmdline /etc/install.inf | cut -d "=" -f2- | cut -d " " -f1 ) FULLURL=$(grep Zypp /etc/install.inf | awk 'BEGIN { FS = "//" } ; {print $2}' ) URL=$(echo $FULLURL | cut -d "/" -f1 ) URLPATH=$(echo $FULLURL | cut -d "/" -f2- ) if [ "$InstMode" = "nfs" ]; then mount -o nolock -t nfs $URL:/$URLPATH /download else mount /dev/sr0 /download fi cp -a /download/add-on/s4e /mnt/opt umount /download ]]> </source> </script> </postpartitioning-scripts> -- Best regards, Matthias -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org