Forum Discussion
Kevin_106976
Nimbostratus
May 31, 2009List nodes that are down
Hi,
Bit of a newbie with this whole iControl API. I want to use Perl + iControl to simply list the nodes that are currently down. I took a look at the codeshare section and did not find it (or maybe its already there but I was not searching correctly).
In addition, I would like to send myself a notification when a node goes down.
If someone can point it in the right direction, it would be really appreciated.
Thanks !
-Kevin.
1 Reply
- L4L7_53191
Nimbostratus
Kevin: while I don't have a perl script handy to paste, hopefully this will help get you off to a good start or give you an extra idea or two.
-- Point SOAP::Lite at LocalLB.NodeAddress
-- Use the get_object_status call, which will return two useful bits of data for you: availability_status, and enabled_status
-- Other calls of interest (depending on your goals) may be get_availability_status and get_monitor_status
You can fetch a list of node addresses with get_list, stuff them into an array, then pass that entire array into one of the calls above. With the results, create a hash with the node address as the key, and the results of one of the 'status' calls above as the value. Then you'll have something solid to work with and you'll be able to do pretty much whatever you're after.
Regarding emails when a node goes down, you may want to have BigIP itself handle this via SNMP traps. Refer to the manual for your version on how to do this - a pool member or node address going offline should be already included on box, so it's a matter of setting it up.
-Matt
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects
