Forum Discussion
iControl get Active/Standby State and Sync Status
I have two F5 LDM devices in an active-standby HA device group called datasync-global-dg. I want to add local traffic components to the active, then force a sync.
My F5 sw version is 11.6.1.
How do I query the active? I can display the group like this:
curl -sk -u admin:admin -H "Content-Type: application/json" -X GET
But I can't get the status.
curl -sk -u admin:admin -H "Content-Type: application/json" -X GET
{"code":404,"message":"Object not found - /Common/datasync-global-dg","errorStack":[]}
I know that I can force a sync via utilCmdArgs.
curl -sk -u admin:admin -H "Content-Type: application/json" -X POST -d '{"command":"run","utilCmdArgs":"config-sync to-group datasync-global-dg"}'
So maybe there's a way to run the "show /sys failover" as a utilCmdArgs?
- Neihls_298286
Nimbostratus
This works, to execute from bash.
gba2saas02-57> curl -sk -u 'admin:admin' -H 'Content-Type: application/json' -X POST -d '{"command":"run","utilCmdArgs":"-c \"tmsh show /sys failover\""}' {"kind":"tm:util:bash:runstate","command":"run","utilCmdArgs":"-c \"tmsh show /sys failover\"","commandResult":"Failover active for 15d 15:05:30\n"}
(What is the URL path to execute a tmsh command directly, instead of executing "tmsh" from bash?)
Recent Discussions
Related Content
* 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