Maintenance Mode Commands
show maintenance on-reload reset-reasons
show maintenance on-reload reset-reasons
import requests
import json
"""
Modify these please
"""
url='http://<IP_Address>/ins'
switchuser='<User_ID>'
switchpassword='<Password>'
myheaders={'content-type':'application/json'}
payload={
"ins_api":{
"version": "1.0",
"type": "cli_show",
"chunk": "0",
"sid": "1",
"input": "show maintenance on-reload reset-reasons",
"output_format": "json"
}
response = requests.post(url,data=json.dumps(payload), headers=myheaders,auth=(switchuser,switchpassword)).json()
output = json.dumps(response, indent=4, sort_keys=True)
{
"rr_bitmap": "0x0"
}
switch# show maintenance on-reload reset-reasons | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:8.3.1.:mmode" xmlns:nf="urn:ietf:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<maintenance>
<on-reload>
<reset-reasons>
<__readonly__>
<rr_bitmap>0x0</rr_bitmap>
</__readonly__>
</reset-reasons>
</on-reload>
</maintenance>
</show>
</nf:data>
</nf:rpc-reply>
]]>]]>
For command descriptions, see the Cisco Nexus 7000 Series Switches Command References.
Note: This sample output is generated for Cisco Nexus 7000 Series NX-OS Release 8.3(1).
| CLI Output |
|---|
|
(not configured)
bitmap = 0x0
show maintenance profile
show maintenance profile
import requests
import json
"""
Modify these please
"""
url='http://<IP_Address>/ins'
switchuser='<User_ID>'
switchpassword='<Password>'
myheaders={'content-type':'application/json'}
payload={
"ins_api":{
"version": "1.0",
"type": "cli_show",
"chunk": "0",
"sid": "1",
"input": "show maintenance profile",
"output_format": "json"
}
response = requests.post(url,data=json.dumps(payload), headers=myheaders,auth=(switchuser,switchpassword)).json()
output = json.dumps(response, indent=4, sort_keys=True)
{
"TABLE_profile": {
"ROW_profile": [
{
"name": "Normal Mode"
},
{
"name": "Maintenance Mode"
}
]
}
}
switch# show maintenance profile | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:8.3.1.:mmode" xmlns:nf="urn:ietf:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<maintenance>
<profile>
<__readonly__>
<TABLE_profile>
<ROW_profile>
<name>Normal Mode</name>
</ROW_profile>
<ROW_profile>
<name>Maintenance Mode</name>
</ROW_profile>
</TABLE_profile>
</__readonly__>
</profile>
</maintenance>
</show>
</nf:data>
</nf:rpc-reply>
]]>]]>
For command descriptions, see the Cisco Nexus 7000 Series Switches Command References.
Note: This sample output is generated for Cisco Nexus 7000 Series NX-OS Release 8.3(1).
| CLI Output |
|---|
|
show maintenance profile maintenance-mode
show maintenance profile maintenance-mode
import requests
import json
"""
Modify these please
"""
url='http://<IP_Address>/ins'
switchuser='<User_ID>'
switchpassword='<Password>'
myheaders={'content-type':'application/json'}
payload={
"ins_api":{
"version": "1.0",
"type": "cli_show",
"chunk": "0",
"sid": "1",
"input": "show maintenance profile maintenance-mode",
"output_format": "json"
}
response = requests.post(url,data=json.dumps(payload), headers=myheaders,auth=(switchuser,switchpassword)).json()
output = json.dumps(response, indent=4, sort_keys=True)
{
"TABLE_profile": {
"ROW_profile": {
"name": "Maintenance Mode"
}
}
}
switch# show maintenance profile maintenance-mode | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:8.3.1.:mmode" xmlns:nf="urn:ietf:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<maintenance>
<profile>
<__XML__PARAM__mode>
<__XML__value>maintenance-mode</__XML__value>
<__readonly__>
<TABLE_profile>
<ROW_profile>
<name>Maintenance Mode</name>
</ROW_profile>
</TABLE_profile>
</__readonly__>
</__XML__PARAM__mode>
</profile>
</maintenance>
</show>
</nf:data>
</nf:rpc-reply>
]]>]]>
For command descriptions, see the Cisco Nexus 7000 Series Switches Command References.
Note: This sample output is generated for Cisco Nexus 7000 Series NX-OS Release 8.3(1).
| CLI Output |
|---|
|
show maintenance profile normal-mode
show maintenance profile normal-mode
import requests
import json
"""
Modify these please
"""
url='http://<IP_Address>/ins'
switchuser='<User_ID>'
switchpassword='<Password>'
myheaders={'content-type':'application/json'}
payload={
"ins_api":{
"version": "1.0",
"type": "cli_show",
"chunk": "0",
"sid": "1",
"input": "show maintenance profile normal-mode",
"output_format": "json"
}
response = requests.post(url,data=json.dumps(payload), headers=myheaders,auth=(switchuser,switchpassword)).json()
output = json.dumps(response, indent=4, sort_keys=True)
{
"TABLE_profile": {
"ROW_profile": {
"name": "Normal Mode"
}
}
}
switch# show maintenance profile normal-mode | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:8.3.1.:mmode" xmlns:nf="urn:ietf:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<maintenance>
<profile>
<__XML__PARAM__mode>
<__XML__value>normal-mode</__XML__value>
<__readonly__>
<TABLE_profile>
<ROW_profile>
<name>Normal Mode</name>
</ROW_profile>
</TABLE_profile>
</__readonly__>
</__XML__PARAM__mode>
</profile>
</maintenance>
</show>
</nf:data>
</nf:rpc-reply>
]]>]]>
For command descriptions, see the Cisco Nexus 7000 Series Switches Command References.
Note: This sample output is generated for Cisco Nexus 7000 Series NX-OS Release 8.3(1).
| CLI Output |
|---|
|
show maintenance snapshot-delay
show maintenance snapshot-delay
import requests
import json
"""
Modify these please
"""
url='http://<IP_Address>/ins'
switchuser='<User_ID>'
switchpassword='<Password>'
myheaders={'content-type':'application/json'}
payload={
"ins_api":{
"version": "1.0",
"type": "cli_show",
"chunk": "0",
"sid": "1",
"input": "show maintenance snapshot-delay",
"output_format": "json"
}
response = requests.post(url,data=json.dumps(payload), headers=myheaders,auth=(switchuser,switchpassword)).json()
output = json.dumps(response, indent=4, sort_keys=True)
{
"delay": "120"
}
switch# show maintenance snapshot-delay | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:8.3.1.:mmode" xmlns:nf="urn:ietf:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<maintenance>
<snapshot-delay>
<__readonly__>
<delay>120</delay>
</__readonly__>
</snapshot-delay>
</maintenance>
</show>
</nf:data>
</nf:rpc-reply>
]]>]]>
For command descriptions, see the Cisco Nexus 7000 Series Switches Command References.
Note: This sample output is generated for Cisco Nexus 7000 Series NX-OS Release 8.3(1).
| CLI Output |
|---|
|
show maintenance timeout
show maintenance timeout
import requests
import json
"""
Modify these please
"""
url='http://<IP_Address>/ins'
switchuser='<User_ID>'
switchpassword='<Password>'
myheaders={'content-type':'application/json'}
payload={
"ins_api":{
"version": "1.0",
"type": "cli_show",
"chunk": "0",
"sid": "1",
"input": "show maintenance timeout",
"output_format": "json"
}
response = requests.post(url,data=json.dumps(payload), headers=myheaders,auth=(switchuser,switchpassword)).json()
output = json.dumps(response, indent=4, sort_keys=True)
{
"timeout": "0"
}
switch# show maintenance timeout | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:8.3.1.:mmode" xmlns:nf="urn:ietf:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<maintenance>
<timeout>
<__readonly__>
<timeout>0</timeout>
</__readonly__>
</timeout>
</maintenance>
</show>
</nf:data>
</nf:rpc-reply>
]]>]]>
For command descriptions, see the Cisco Nexus 7000 Series Switches Command References.
Note: This sample output is generated for Cisco Nexus 7000 Series NX-OS Release 8.3(1).
| CLI Output |
|---|
|
show system mode
show system mode
import requests
import json
"""
Modify these please
"""
url='http://<IP_Address>/ins'
switchuser='<User_ID>'
switchpassword='<Password>'
myheaders={'content-type':'application/json'}
payload={
"ins_api":{
"version": "1.0",
"type": "cli_show",
"chunk": "0",
"sid": "1",
"input": "show system mode",
"output_format": "json"
}
response = requests.post(url,data=json.dumps(payload), headers=myheaders,auth=(switchuser,switchpassword)).json()
output = json.dumps(response, indent=4, sort_keys=True)
{
"system_mode": "Normal"
}
switch# show system mode | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:8.3.1.:mmode" xmlns:nf="urn:ietf:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<system>
<mode>
<__readonly__>
<system_mode>Normal</system_mode>
</__readonly__>
</mode>
</system>
</show>
</nf:data>
</nf:rpc-reply>
]]>]]>
For command descriptions, see the Cisco Nexus 7000 Series Switches Command References.
Note: This sample output is generated for Cisco Nexus 7000 Series NX-OS Release 8.3(1).
| CLI Output |
|---|
|