Forum Discussion
Ken_Edwards_106
Nimbostratus
Jun 05, 2007Is it possible to create and disable node groups?
Is it possible to place nodes into a group and disable the groups as needed? I have a need to disable 20 nodes at a time. The server/application teams are complaining it takes too long to mark each node down with the monitor page. Looking for ideas and other best practices...
Thanks,
Ken
9 Replies
- Sure is. All our iControl methods are bulk enabled, meaning you can pass 1-n items in on each call. You'll likely want the LocalLB PoolMember::set_monitor_state() and/or set_session_enabled_state() methods. Each method allows you to pass in as many pool members as you wish. You might also want to look at the LocalLB NodeAddress interface if you want an easy way to disable all pool members based on just the ip address of the node.
Using iControl, you can do this with Java,.Net,Perl,PowerShell,... and any other runtime language that supports web services.
-Joe - Ken_Edwards_106
Nimbostratus
Since I am new to iControl, could you post a sample of the code that would be necessary to pass these parameters including the command to send to the F5.
Thanks - I don't know if I have something that exactly fits your bill. Can you be very detailed as to what you want accomplished?
o All members disabled for a given pool
o Disable a specified list of Pool members for a given pool
o All Node Addresses disabled?
o Disable a specified list of Node Addresses
o Language choice? (Perl, .Net, PowerShell, Java)
Each of those if fairly simple to put a little script together. The hard part is guessing on your requirements. Let me know what you need and if it's not too entailed, I'll whip up a Codeshare sample to get you started.
Also, keep in mind that each language choice has a corresponding client environment that you will need to configure.
-Joe - Giuseppe_Casabl
Nimbostratus
Hi I'm new to IControl, and I'm trying to to disable a node . How can I do that in java? Have you an example ? I wrote a method setState but I don't know how to pass the Object EnabledState ? could you help me ??
public void setState(String[] node_address, iControl.CommonEnabledState[] states)throws Exception
{
m_nodeAddress.set_session_enabled_state(node_address,states);
} - Your code looks good to me. What exactly are you having problems with? EnabledState is an enum which should be defined by the WSDL converter (or if you are using the iControl Java Library from DevCentral Labs, it's baked in).
As for node groups, I'm not sure what you are getting at with that either. iControl can do what's in the GUI and I don't believe there is a concept of a Node Group within the BIG-IP configuration. You can group node:port groups together as members of a Pool. So, is that what you are getting at? If so, Look at the LocalLB.Pool and LocalLB.PoolMember interfaces in the SDK.
-Joe - Claudio_16539
Nimbostratus
Hi,
I'd like to display the status of all virtusl servers with Java, but I can't find a method for getting the EnabledState.
There is a method for setting the state:
new iControlIntermediary.VirtualNode(name, pwd, addr).setEnableState(servername, true);
But neither this classes nor iControl.LocalLBVirtualServer, iControl.CommonVirtualServerDefinition, iControl.LocalLBNodeAddress provide methods for getting the state.
In previous posts a class named iControl.LocalLBNode was mentioned, but i can't find this class. - Don_MacVittie_1Historic F5 AccountOops. That smiley face should be a colon followed by the letter p.
Don. - Claudio_16539
Nimbostratus
Thank you Don, now i've got it working... - Don_MacVittie_1Historic F5 AccountGlad to hear it! I hope it was not too painful.
Don.
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
