Forum Discussion

Mark_Bell_98620's avatar
Mark_Bell_98620
Icon for Nimbostratus rankNimbostratus
Jun 22, 2009

GTM status changer

Hi,

 

 

I have been looking at the C repository however cant seem to find many examples for this through the forums and the site. Would anyone have any idea how to implement a GTM status changer similar to how the example "LTM Pool Manager Example" works at http://devcentral.f5.com/Default.aspx?tabid=63&articleType=ArticleView&articleId=87.

 

 

Anyone have any ideas?

 

 

Thanks

 

5 Replies

  • What exactly do you want to do with GTM programatically. The article you referenced shows how to toggle pool member enabled states. If you are looking into managing GTM pool members, then you'll want to look at the GlobalLB.PoolMember.get/set_enabled_state methods.

     

     

    -Joe
  • Hi,

     

     

    We have a list of WideIP's on the GTM that we change on a regular basis if we need to switch data centres. I was looking to try and modify the example in the link to do a similar job only for GTM wide IPs, so instead of getting the member list from the LTM, get the wide IP list for the GTM's and then modify the ratio etc.

     

  • The link above is not working.. I am hoping to do something along the lines of what is stated above.... would like to control the status of a wide ip pool member.

     

     

    Thanks.
  • Yeah, just really looking for what code would need to be changed or added for this so that we can get the Wide IP's back from the GTM and then be able to change the ratio like changing the pool member status in the example given from that url.

     

     

    Would be grateful if someone can point me in the right direction regarding this.

     

     

    Thanks
  • A couple things...the wideIP's are pulled with the GlobalLB.WideIP.get_list method. Pool members are not under the wideip, they are under the pool, which is assigned to a wideip. The pools/pool members are GlobalLB.Pool and GlobalLB.PoolMember. Joe had a tutorial on writing a C application on LocalLB.Pool and LocalLB.PoolMember. All you should need to do is migrate from one interface to the other, all the code should be similar. The tutorial is here:

     

     

    http://devcentral.f5.com/Default.aspx?tabid=63&articleType=ArticleView&articleId=87 Click here