Enabling Broadcom FCoE

Following on from my previous post on the topic on BL460c Gen8 and the missing HBA, I thought I’d provide a quick script to automate the required installation of rpms and associated config changes, so here you go;


echo "Installing Pre-Reqs for FCoE on Broadcom NICs..."

yum install -y lldpad lldpad-libs fcoe-utils

echo "Configuring FCoE..."

cd /etc/fcoe

DEVICES="eth2 eth3"
COUNT=0

for i in $DEVICES; do
cp cfg-ethx cfg-$i
sed -i 's/DCB_REQUIRED="yes"/DCB_REQUIRED="no"/g' cfg-$i
done

echo "Starting lldpad service..."

/sbin/chkconfig lldpad on
/sbin/service lldpad start

for i in $DEVICES; do
lldptool set-lldp -i $i adminStatus=disabled
COUNT=$[COUNT+1]
done

ADMINSETCOUNT=`grep adminStatus /var/lib/lldpad/lldpad.conf | wc -l`

if [ $ADMINSETCOUNT == $COUNT ]; then
echo "adminStatus appears to have been set correctly"
else
echo adminStatus has not been set correctly, you should investigate this further!"
echo "Useful URL - http://h20564.www2.hp.com/hpsc/doc/public/display?docId=mmr_kc-0115755-3"
fi

echo "Restarting services after changes made"
/sbin/service lldpad restart
/sbin/service fcoe restart

echo "Setting FCoE service to start on boot..."
/sbin/chkconfig fcoe on

echo "Enable Ethernet interfaces to start on boot"

for i in $DEVICES; do
sed -i 's/ONBOOT=no/ONBOOT=yes/g' ifcfg-$i
done

The above does make the assumption that you are using eth2 and eth3 for FCoE.

Leave a Reply