PatrickSF_14757
Sep 15, 2014Nimbostratus
tmsh to bigsuds - virtual server - associate a vlan and assign a persistence profile
Hi all
I've successfully ported tmsh LTM Pool creation statements to bigsuds, but partly succeeded for virtuals
I'm working with different bippipe versions but have only tested the following code on v10.2.4...
['BIG-IP_v10.2.4'] ['BIG-IP_v10.2.2'] ['BIG-IP_v11.2.1']
So, after a successful Virtual creation on all these bigpipe versions (has the expected pool member), I still cannot
- assign/associate to an existing vlan
- assign an existing persistence profile as default (no failback)
- create a SNAT pool (how?)
Example tmsh statements I'm working to port to icontrol/bigsuds
1.
tmsh create /ltm virtual MY_VIRTUAL { destination 1.2.3.4:https pool MYPOOL vlans add { External Internal } vlans-enabled profiles add { tcp } persist replace-all-with { source_addr } fallback-persistence none }
- corresponding code:
obj.LocalLB.VirtualServer.create(
definitions = [{'name': [virtualname], 'address': [address], 'port': [port], 'protocol': 'PROTOCOL_TCP'}],
wildmasks = ['255.255.255.255'],
resources = [{'type': 'RESOURCE_TYPE_POOL', 'default_pool_name': [member_pool]}],
profiles = [[{'profile_context': 'PROFILE_CONTEXT_TYPE_ALL', 'profile_name': 'tcp'}]])
** set_vlan: does not work
obj.LocalLB.VirtualServer.set_vlan( virtual_servers = [virtualname], vlans = [vlans] )
errors with
"Internal" is not a valid value for Common.VLANFilterList, expecting: state, vlans
** persistence: does not work:
b.LocalLB.VirtualServer.add_persistence_profile( virtual_servers = [virtualname], profiles = [[ {'profile_name': 'source_addr_SR', 'default_profile': 'true'} ]] )
- At a loss for SNAT pool creation (on terms of where to start)
tmsh create /ltm snat MY_SNAT_POOL translation 1.2.3.4 origins add { 5.6.7.8/32 } vlans-enabled vlans add { Internal }
tmsh modify /ltm snat-translation 1.2.3.4 { tcp-idle-timeout 300 udp-idle-timeout 300 ip-idle-timeout 300 }
Digging into this work is great and rewarding but sadly I'm getting dry...
Any help is greatly appreciated THks
Patrick