Forum Discussion
Preyansh_247983
Feb 06, 2018Historic F5 Account
How do I retrieve all the BIG-IP version details using F5-SDK?
session = create_rest_session('10.192.70.16')
print session.tmos_version
This gives me the version currently running on the bigip. But what if i want all the details mentioned in the icontrol rest api https://10.192.70.16/mgmt/tm/sys/version. I want to get all the details given in the response of this rest api like build, product, edition, project, title, version etc using f5-sdk.
1 Reply
- Satoshi_Toyosa1Ret. Employee
If you are after the output of
(or iControl REST endpointtmsh show sys version
), the feature became available from the latest version. See F5Networks/f5-common-python Github./mgmt/tm/sys/version
[root@centos ~] grep version /usr/lib/python2.7/site-packages/f5/__init__.py __version__ = '3.0.10' [root@centos python] python Python 2.7.5 (default, Jun 24 2015, 00:41:19) [GCC 4.8.3 20140911 (Red Hat 4.8.3-9)] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> from f5.bigip import ManagementRoot >>> mgmt = ManagementRoot('xx.xx.xx.xx', 'admin', 'xxx') >>> ver = mgmt.tm.sys.version.load() >>> print ver.raw {u'kind': u'tm:sys:version:versionstats', '_meta_data': {'container': , 'minimum_additional_parameters': set([]), 'exclusive_attributes': [], 'allowed_commands': [], 'uri': 'https://192.168.226.131:443/mgmt/tm/sys/version/', 'required_json_kind': 'tm:sys:version:versionstats', 'bigip': , 'icontrol_version': '', 'required_command_parameters': set([]), 'icr_session': , 'required_load_parameters': set([]), 'object_has_stats': True, 'minimum_version': '11.5.0'}, u'selfLink': u'https://localhost/mgmt/tm/sys/version?ver=13.0.0', u'entries': {u'https://localhost/mgmt/tm/sys/version/0': {u'nestedStats': {u'entries': {u'Product': {u'description': u'BIG-IP'}, u'Title': {u'description': u'Main Package'}, u'Edition': {u'description': u'Final'}, u'Version': {u'description': u'13.0.0'}, u'Build': {u'description': u'0.0.1645'}, u'Date': {u'description': u'Tue Jan 31 16:59:50 PST 2017'}}}}}}
Recent Discussions
Related Content
DevCentral Quicklinks
* 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
Discover DevCentral Connects