Forum Discussion
uisomdc_95191
Nimbostratus
Aug 08, 2008qualifying node IP's to hostname
anyone know of a way to get this done inside the API? I'm going to need actual hostnames of my nodes displayed to people I'd like to avoid doing any nslookups within my code, but i can every hour and store them if need be.
LocalLB_NodeAddress. looked promising but I couldn't seem to get anything decent.
- You can give user friendly names to NodeAddresses so you can easily accomplish the same thing by setting that property to the hostname of the node address. The problem is that this is only available in the NodeAddress interface, not the PoolMember.
http://devcentral.f5.com/Default.aspx?tabid=63&articleType=ArticleView&articleId=191
- RichKL_77280
Nimbostratus
This is how I did it in Java:LocalLBPoolMemberBindingStub f5_pm_obj = (LocalLBPoolMemberBindingStub) new LocalLBPoolMemberLocator().getLocalLBPoolMemberPort(new URL(f5_address)); LocalLBNodeAddressBindingStub f5_na_obj = (LocalLBNodeAddressBindingStub) new LocalLBNodeAddressLocator().getLocalLBNodeAddressPort(new URL(f5_address)); LocalLBPoolMemberMemberSessionStatus[] serverStatuses = f5_pm_obj.get_session_status(new String[] {"pool_name"})[ 0 ]; nodeIndex = 0; String nodeAddress = serverStatuses[nodeIndex].getMember().getAddress(); String hostname = f5_na_obj.get_screen_name(new String[] {nodeAddress})[ 0 ];
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