issue with cobbler snippet not working since we started using OEL and RHEL 5.7

Edward Bailey eds.mailing.list.account at gmail.com
Tue Dec 13 15:05:29 UTC 2011


We have a very simple snippet that helps cobbler partition our servers
during a kickstart. This was working with no issues for 4.8 and 5.4 till we
recently starting moving our systems to 5.7. Now we get the same error with
every kickstart. Any advice or suggestions for  better options are more
than welcome. I am stuck.

Thanks

Ed

I see the following printed to the screen during a kickstart

File "/usr/lib/python2.4/site-packages/pykickstart/parser.py", line 1128,
in readKickstart fh = open(file)
IOError: [Errno 2] No such file or directory: '/tmp/partitions' install
existed abnormally [1/1]

Below is the snippet

%include /tmp/partitions

%pre

LIST=/tmp/drives
cmd="list-harddrives"
$cmd > $LIST
cchk=`awk '/^cciss/ {print $1}' $LIST|head -1`
schk=`awk '/^sda/ {print $1}' $LIST|head -1`
if [ -z "$schk" -a -z "$cchk" ]; then
 echo "No HP or SAN attached disks found; exiting."

exit 1
fi
if [ -n "$cchk" ]; then
 REST="$cchk"
else
 REST="$schk"
fi
if [ -n "$schk" ]; then
 BOOT="$schk"
else
 BOOT="$cchk"
fi
#export BOOT REST
cat << EOP > /tmp/partitions
bootloader --location=mbr
clearpart --all --initlabel
part / --fstype=ext3 --size=6144 --ondisk=$BOOT
part /opt --fstype=ext3 --size=1 --grow --ondisk=$REST
part /var --fstype=ext3 --size=2048 --ondisk=$BOOT
part /tmp --fstype=ext3 --size=1024 --ondisk=$REST
part swap --size=2048 --ondisk=$REST
EOP
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://fedorahosted.org/pipermail/cobbler/attachments/20111213/8f4941ab/attachment.html 


More information about the cobbler mailing list