Forum Discussion

Justin_Kitagawa's avatar
Justin_Kitagawa
Icon for Nimbostratus rankNimbostratus
Sep 18, 2007

Help! Java iControl API puts F5 in an unknown state.

Hi.

 

 

We are trying to initiate F5 objects in particular VLANs, SelfIPs, Nodes, Pools, and Virtual Servers via the F5 BIG-IP iControl SOAP API. We are coding this solution in Java.

 

 

We authenticate properly and are successful in calling the appropriate create methods:

 

 

For example for Self IPs, we are successfully executing the following abbreviated code:

 

 

NetworkingSelfIPBindingStub networkingSelfIPBindingStub = (NetworkingSelfIPBindingStub)new NetworkingSelfIPLocator().getNetworkingSelfIPPort(url);

 

...

 

networkingSelfIPBindingStub.create(selfIPs,vlanNames,netmasks,unitIDs,floatingStateList);

 

 

 

The API returns without throwing exceptions. The problem is two fold, though.

 

 

Problem 1

 

Some of these newly created objects do not show up in the BIG-IP's admin console.

 

 

Problem 2

 

Changes are not reflected in the /config dir of the BIG-IP. We verify this by sshing into the load balancer, changing directories to /config and grepping for the objects we have created. (e/g creating a selfip 123.123.123.123 and grepping for 123 in /config).

 

 

If we create the same object through the BIG-IP's admin console with the same parameters, the objects appear in the UI and in the /config directory.

 

 

Any help would be greatly appreciated.

 

 

 

 

 

3 Replies

  • Problem 1: Not sure why created objects would not show up in the GUI. The only reason I could think for this would be that you are not passing all the required parameters and the iControl portal isn't flagging it as an error correctly. If you can get me a trace of the connection (SOAP Request/Response), I can check it out.

     

     

    Problem 2: This one is easy. iControl methods will only change the running config. To persist the changes you've made, you'll have to make an explicit call to System.ConfigSync.save_configuration() to flush the config changes to disk. The Admin GUI does this implicitly with every page submission, but due to the overhead of the save command, and the possibly large number of consecutive iControl methods in a usage scenario, we decided to leave this as a manual step one must take. I guess we need to document this a little better.

     

     

    Hope this helps...

     

     

    -Joe
  • You do not need to specify a filename for SAVE_BASE_LEVEL_CONFIG or SAVE_HIGH_LEVEL_CONFIG as they are saved to /config/bigip_base.conf and /config/bigip.conf respectively. This iControl method essentually executes the following bigpipe commands

     

     

    SAVE_BASE_LEVEL_CONFIG -> "bigpipe base save"

     

    SAVE_HIGH_LEVEL_CONFIG -> "bigpipe save"

     

     

     

    If the return from the above bigpipe commands reports an error, the "Error saving configuration" soap fault is returned.

     

     

    I'd try to login to a ssh session and try to execute those commands manually and see if they work. I'm not sure why executing them from the CLI would be any different than from within the iControl portal though. Could be to do with user permissions so if you aren't using an admin account, you might try your iControl connection with different credentials to see if that makes a difference.

     

     

    -Joe
  • Don_MacVittie_1's avatar
    Don_MacVittie_1
    Historic F5 Account
    Just to throw another idea out there, with problem 1, have you tried querying the objects from iControl to see if they respond? If they're not showing up in the UI, checking that iControl can access them after create is a good next step (if you haven't already).

     

     

    Don.