F5Networks / f5-common-python

Python SDK for configuration and monitoring of F5® BIG-IP® devices via the iControl® REST API.
https://f5-sdk.readthedocs.org
Apache License 2.0
262 stars 133 forks source link

the node's "downInternval" and "interval" values are not changing and stay on default values #1617

Open shariaty59 opened 9 months ago

shariaty59 commented 9 months ago

Hi, I am trying to update the node's "downInternval" and "interval" while I'm adding it to the pool but those values are not changing and stay at default. This is the simple code I am testing. as you see I also tried updating these values after the node is created, but still no luck. Please advise. Thank you.

`from f5.bigip import ManagementRoot mgmt = ManagementRoot('ip', 'user', 'pass') pool = mgmt.tm.ltm.pools.pool.load(partition='Common', name='my-pool')

server_name = "my-server" app_port = "440"

socket_name = f"{server_name}:{app_port}" address = f"{server_name}.github.com" fqdn = {"autopopulate": "enabled", "downInternval": 6, "interval": 300, "tmName": address}

member_add = pool.members_s.members.create( partition='Common', name=socket_name, fqdn=fqdn )

node = mgmt.tm.ltm.nodes.node.load(partition='Common', name=server_name)

node.fqdn['downInterval'] = 10 node.fqdn['interval'] = 350

print (node.raw)`

f5-rahm commented 9 months ago

hi @shariaty59 did you do a node.update() after setting the fqdn attributes? Setting them locally doesn't automatically update the object on BIG-IP, it just updates the local python object until you call the update() method.