LTM: Interface Failsafe
Nathan McMahon and Kirk Bauer bring us another slick solution for a couple of common requirements in high performance environments: To fail over immediately when a single physical network connection ...
Published Mar 05, 2008
Version 1.0Deb_Allen_18
Historic F5 Account
Joined September 25, 2004
Deb_Allen_18
Historic F5 Account
Joined September 25, 2004
Omnix_TIMS_4122
Nimbostratus
Jan 11, 2015Dears,
Can some one assist me to understand what the script below exactly did:
shift
shift
interfaces="$*"
interfaces="1/2.2 2/2.2"
b interface show > /tmp/b_interface_show
for i in $interfaces ; do
status=`grep "^ *$i " /tmp/b_interface_show | awk '{print $2}'`
logger -p local0.notice "interface $i is parced and status is $status"
if [ "$status" = "DN" ] ; then
logger -p local0.notice "$MON_TMPL_NAME: interface $i is DOWN (status: $status)"
for f in $interfaces ; do
logger -p local0.notice "$MON_TMPL_NAME: bring down other interfaces"
if [ $f != $i ] ; then
b interface $f disable
fi
done
echo "failed" > /tmp/int_fail_state
exit 1
fi
if [ "$status" = "UP" ] ; then
state=`cat /tmp/int_fail_state`
if [ "$state" = "failed" ] ; then
logger -p local0.notice "$MON_TMPL_NAME: interface $i is back UP (status: $status)"
for f in $interfaces ; do
logger -p local0.notice "$MON_TMPL_NAME: bring UP interface $f in group ($interfaces)"
b interface $f enable
done
echo "ok" > /tmp/int_fail_state
fi
fi
done
All specified interfaces are up...
echo "up"
exit 0
I have Active F5a and Standby F5b and need to do fail safe interface between them.
Once I apply it on F5a (active) and interfaces 1/2.1 and 2/2.2 still up; F5a changed to standby and another F5 didn't go active.
I have other monitor for interface fail safe for interfaces 1/2.1 1/2.3 2/2.1.
Please I need to understand this script very clearly to know the reason that made F5a goes to standby.
Thanks.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)