diff --git a/xCAT-server/share/xcat/rollupdate/LL_setup b/xCAT-server/share/xcat/rollupdate/LL_setup new file mode 100644 index 000000000..126410b7d --- /dev/null +++ b/xCAT-server/share/xcat/rollupdate/LL_setup @@ -0,0 +1,37 @@ +#!/bin/sh +# Sample postscript to be added to /install/postscripts and in the +# in the postscripts table, will setup the node with LL on install +# Setup for LL config and execution +master=$MASTER + + +# set LoadLeveler paths in /etc/profile +if ! grep "xCAT Customizations" /etc/profile > /dev/null 2>&1 ; then + echo "" >> /etc/profile + echo "# xCAT Customizations " >> /etc/profile + echo "export PATH=\$PATH:/usr/lpp/LoadL/full/bin " >> /etc/profile + echo "export MANPATH=\$MANPATH:/usr/lpp/LoadL/full/man " >> /etc/profile +# set a few other things while we're at it + echo "set -o vi" >> /etc/profile + echo "export HOST=`hostname`" >> /etc/profile + echo "export ENV=/.kshrc" >> /etc/profile + echo "export SECONDS=\"\$(date '+3600*%H+60*%M+%S')\"" >> /etc/profile + echo "typeset -Z2 _h _m _s" >> /etc/profile + echo "_hh=\"(SECONDS/3600)%24\" _mm=\"(SECONDS/60)%60\" _ss=\"SECONDS%60\"" >> /etc/profile + echo "_time='\${_x[((_m=_mm)==(_h=_hh))==(_s=_ss)]}\$_h:\$_m:\$_s'" >> /etc/profile + echo "PS1=\"(\$_time) \`hostname -s\`\"' # '" >> /etc/profile +fi + +if ! grep 'loadl' /etc/inittab ; then + echo "loadl:2:once:/usr/lpp/LoadL/full/bin/llctl start > /dev/console 2>&1" >> /etc/inittab + +/usr/bin/errupdate -f /usr/lpp/LoadL/full/include/loadl_err.S +/usr/bin/mkdir -p /tmp/var/loadl +/usr/bin/chown -R loadl:loadl /tmp/var/loadl +/usr/bin/su - loadl "-c /usr/lpp/LoadL/full/bin/llinit -local /tmp/var/loadl -release /usr/lpp/LoadL/full -cm $MASTER" +/usr/lpp/LoadL/full/bin/llctl start +fi + +logger -t xCAT "LoadL setup" +exit 0 +