这里是python的新手,请耐心等待。我正在创建一个必须对各种设备执行备份的脚本。我有以下代码:
def getOS():
if platform.system().upper() == 'JUNOS' :
os = "junos"
elif platform.system().upper() == "WIN32"
os = "windows"
elif platform.system().upper() == "DARWIN"
os = "mac"
return os
如何测试Big-IP?另外,在platform.system()的潜在结果中是否有列表?
答案 0 :(得分:0)
platform.system()
返回uname
系统调用。没有明确的回报,它100%依赖于操作系统。
有关uname
的更多信息您最好的做法可能是在Big-IP操作系统上运行platform.system()
。
答案 1 :(得分:0)
要查看TMOS版本,您可以运行 tmsh show sys软件。
root@(ltm3)(cfg-sync Standalone)(Active)(/Common)(tmos)# show sys software
--------------------------------------------------
Sys::Software Status
Volume Product Version Build Active Status
--------------------------------------------------
HD1.1 BIG-IP 13.1.0.5 0.0.5 yes complete
HD1.2 BIG-IP 12.1.3.3 0.0.1 no complete
HD1.3 none none none no complete