DHCP Commands
show ip dhcp global statistics
show ip dhcp global statistics
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 ip dhcp global statistics",
"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)
{
"pkts_processed": 0,
"pkts_recvd_through_cfsoe": 0,
"pkts_fwded": 0,
"pkts_cfsoe_fwded": 0,
"pkts_dropped": 0,
"pkts_dropped_from_untrusted_ports": 0,
"pkts_dropped_src_mac_chk_fail": 0,
"pkts_dropped_opt82_ins_fail": 0,
"pkts_dropped_unknown_op_intf": 0,
"pkts_dropped_unknown_pkt": 0,
"pkts_dropped_no_trust_inf": 0,
"pkts_dropped_relay_disable": 0,
"pkts_dropped_no_binding_entry": 0,
"pkts_dropped_interface_error": 0,
"pkts_dropped_max_hops_exceeded": 0,
"pkts_dropped_queue_full": 0
}
switch# show ip dhcp global statistics | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ip>
<dhcp>
<global>
<statistics>
<__XML__OPT_Cmd_show_dhcp_stats___readonly__>
<__readonly__>
<pkts_processed>0</pkts_processed>
<pkts_recvd_through_cfsoe>0</pkts_recvd_through_cfsoe>
<pkts_fwded>0</pkts_fwded>
<pkts_cfsoe_fwded>0</pkts_cfsoe_fwded>
<pkts_dropped>0</pkts_dropped>
<pkts_dropped_from_untrusted_ports>0</pkts_dropped_from_untrusted_ports
>
<pkts_dropped_src_mac_chk_fail>0</pkts_dropped_src_mac_chk_fail>
<pkts_dropped_opt82_ins_fail>0</pkts_dropped_opt82_ins_fail>
<pkts_dropped_unknown_op_intf>0</pkts_dropped_unknown_op_intf>
<pkts_dropped_unknown_pkt>0</pkts_dropped_unknown_pkt>
<pkts_dropped_no_trust_inf>0</pkts_dropped_no_trust_inf>
<pkts_dropped_relay_disable>0</pkts_dropped_relay_disable>
<pkts_dropped_no_binding_entry>0</pkts_dropped_no_binding_entry>
<pkts_dropped_interface_error>0</pkts_dropped_interface_error>
<pkts_dropped_max_hops_exceeded>0</pkts_dropped_max_hops_exceeded>
<pkts_dropped_queue_full>0</pkts_dropped_queue_full>
</__readonly__>
</__XML__OPT_Cmd_show_dhcp_stats___readonly__>
</statistics>
</global>
</dhcp>
</ip>
</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 ip dhcp relay
show ip dhcp relay
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 ip dhcp relay",
"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)
{
"relay_service_enable": "enabled",
"relay_opt82_enable": "disabled",
"relay_subopt_VPN_enable": "disabled",
"relay_subopt_type_cisco_enable": "disabled",
"global_smart-relay_enable": "disabled",
"global_relay_trusted_enable": "disabled",
"relay_trusted_port_enable": "disabled",
"global_src_addr_hsrp_enable": "disabled",
"smart_relay_intfs_hdr": 0,
"subnet_bcast_intfs_hdr": 0,
"trusted_port_intfs_hdr": 0,
"relay_src_addr_hsrp_hdr": 0,
"relay_address_hdr": 0,
"TABLE_intf": {
"ROW_intf": {
"intf": "Ethernet5/3",
"relay_address": "3.3.3.1",
"vrf_name": null
}
}
}
switch# show ip dhcp relay | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ip>
<dhcp>
<relay>
<__XML__OPT_Cmd_show_dhcp_relay___readonly__>
<__readonly__>
<relay_service_enable>enabled</relay_service_enable>
<relay_opt82_enable>disabled</relay_opt82_enable>
<relay_subopt_VPN_enable>disabled</relay_subopt_VPN_enable>
<relay_subopt_type_cisco_enable>disabled</relay_subopt_type_cisco_enable
>
<global_smart-relay_enable>disabled</global_smart-relay_enable>
<global_relay_trusted_enable>disabled</global_relay_trusted_enable>
<relay_trusted_port_enable>disabled</relay_trusted_port_enable>
<global_src_addr_hsrp_enable>disabled</global_src_addr_hsrp_enable>
<smart_relay_intfs_hdr>0</smart_relay_intfs_hdr>
<subnet_bcast_intfs_hdr>0</subnet_bcast_intfs_hdr>
<trusted_port_intfs_hdr>0</trusted_port_intfs_hdr>
<relay_src_addr_hsrp_hdr>0</relay_src_addr_hsrp_hdr>
<relay_address_hdr>0</relay_address_hdr>
<TABLE_intf>
<ROW_intf>
<intf>Ethernet5/3</intf>
<relay_address>3.3.3.1</relay_address>
<vrf_name> </vrf_name>
</ROW_intf>
</TABLE_intf>
</__readonly__>
</__XML__OPT_Cmd_show_dhcp_relay___readonly__>
</relay>
</dhcp>
</ip>
</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 ip dhcp relay address [interface ]
show ip dhcp relay address [interface <intf-range>]
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 ip dhcp relay address",
"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)
{
"intf_header": 0,
"TABLE_intf": {
"ROW_intf": {
"intf2": "Ethernet5/3",
"relay_address": "3.3.3.1",
"vrf_name": null
}
}
}
switch# show ip dhcp relay address | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ip>
<dhcp>
<relay>
<address>
<__XML__OPT_Cmd_show_ip_dhcp_relay_address_intf_interface>
<__XML__OPT_Cmd_show_ip_dhcp_relay_address_intf___readonly__>
<__readonly__>
<intf_header>0</intf_header>
<TABLE_intf>
<ROW_intf>
<intf2>Ethernet5/3</intf2>
<relay_address>3.3.3.1</relay_address>
<vrf_name> </vrf_name>
</ROW_intf>
</TABLE_intf>
</__readonly__>
</__XML__OPT_Cmd_show_ip_dhcp_relay_address_intf___readonly__>
</__XML__OPT_Cmd_show_ip_dhcp_relay_address_intf_interface>
</address>
</relay>
</dhcp>
</ip>
</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 ip dhcp relay information trusted-sources
show ip dhcp relay information trusted-sources
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 ip dhcp relay information trusted-sources",
"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)
{
"header": 3
}
switch# show ip dhcp relay information trusted-sources | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ip>
<dhcp>
<relay>
<information>
<trusted-sources>
<__XML__OPT_Cmd_show_dhcp_relay_trusted_sources___readonly__>
<__readonly__>
<header>3</header>
</__readonly__>
</__XML__OPT_Cmd_show_dhcp_relay_trusted_sources___readonly__>
</trusted-sources>
</information>
</relay>
</dhcp>
</ip>
</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 ip dhcp relay statistics [ interface | {interface serverip [use-vrf ]} ]
show ip dhcp relay statistics [ interface <intf> | {interface <intf> serverip <ip-addr-val> [use-vrf <vrf-name>]} ]
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 ip dhcp relay statistics",
"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)
{
"msg_stats_hdr": 0,
"msg_type_str": "Discover",
"rx_pkts": 0,
"tx_pkts": 0,
"drops": 0,
"msg_type_str_offer": "Offer",
"offer_rx_pkts": 0,
"offer_tx_pkts": 0,
"offer_drops": 0,
"msg_type_str_request": "Request(*)",
"request_rx_pkts": 0,
"request_tx_pkts": 0,
"request_drops": 0,
"msg_type_str_ack": "Ack",
"ack_rx_pkts": 0,
"ack_tx_pkts": 0,
"ack_drops": 0,
"msg_type_str_release": "Release(*)",
"release_rx_pkts": 0,
"release_tx_pkts": 0,
"release_drops": 0,
"msg_type_str_decline": "Decline",
"decline_rx_pkts": 0,
"decline_tx_pkts": 0,
"decline_drops": 0,
"msg_type_str_inform": "Inform(*)",
"inform_rx_pkts": 0,
"inform_tx_pkts": 0,
"inform_drops": 0,
"msg_type_str_nack": "Nack",
"nack_rx_pkts": 0,
"nack_tx_pkts": 0,
"nack_drops": 0,
"line": 0,
"msg_type_str_total": 1635020628,
"total_rx_pkts": 0,
"total_tx_pkts": 0,
"total_drops": 0,
"line_x": 0,
"l3_fwd_hdr": 0,
"l3_fwd_rx_pkts": 0,
"l3_fwd_tx_pkts": 0,
"l3_fwd_drops": 0,
"non_dhcp_hdr": 0,
"non_dhcp_rx_pkts": 0,
"non_dhcp_tx_pkts": 0,
"non_dhcp_drops": 0,
"drop_hdr": 0,
"drop_validation_fail": 0,
"drop_relay_disable": 0,
"drop_invalid_msg_type": 0,
"drop_intf_err": 0,
"drop_tx_sock_err": 0,
"drop_tx_fail_client_intf": 0,
"drop_unknown_op_intf": 0,
"drop_l3_unknown_op_intf": 0,
"drop_max_hops": 0,
"drop_opt82_insert_fail": 0,
"drop_malformed": 0,
"drop_untrusted_relay_intf": 0,
"footer": 0
}
switch# show ip dhcp relay statistics | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ip>
<dhcp>
<relay>
<statistics>
<__XML__OPT_Cmd_show_dhcp_relay_stats_interface>
<__XML__OPT_Cmd_show_dhcp_relay_stats___readonly__>
<__readonly__>
<msg_stats_hdr>0</msg_stats_hdr>
<msg_type_str>Discover</msg_type_str>
<rx_pkts>0</rx_pkts>
<tx_pkts>0</tx_pkts>
<drops>0</drops>
<msg_type_str_offer>Offer</msg_type_str_offer>
<offer_rx_pkts>0</offer_rx_pkts>
<offer_tx_pkts>0</offer_tx_pkts>
<offer_drops>0</offer_drops>
<msg_type_str_request>Request(*)</msg_type_str_request>
<request_rx_pkts>0</request_rx_pkts>
<request_tx_pkts>0</request_tx_pkts>
<request_drops>0</request_drops>
<msg_type_str_ack>Ack</msg_type_str_ack>
<ack_rx_pkts>0</ack_rx_pkts>
<ack_tx_pkts>0</ack_tx_pkts>
<ack_drops>0</ack_drops>
<msg_type_str_release>Release(*)</msg_type_str_release>
<release_rx_pkts>0</release_rx_pkts>
<release_tx_pkts>0</release_tx_pkts>
<release_drops>0</release_drops>
<msg_type_str_decline>Decline</msg_type_str_decline>
<decline_rx_pkts>0</decline_rx_pkts>
<decline_tx_pkts>0</decline_tx_pkts>
<decline_drops>0</decline_drops>
<msg_type_str_inform>Inform(*)</msg_type_str_inform>
<inform_rx_pkts>0</inform_rx_pkts>
<inform_tx_pkts>0</inform_tx_pkts>
<inform_drops>0</inform_drops>
<msg_type_str_nack>Nack</msg_type_str_nack>
<nack_rx_pkts>0</nack_rx_pkts>
<nack_tx_pkts>0</nack_tx_pkts>
<nack_drops>0</nack_drops>
<line>0</line>
<msg_type_str_total>1635020628</msg_type_str_total>
<total_rx_pkts>0</total_rx_pkts>
<total_tx_pkts>0</total_tx_pkts>
<total_drops>0</total_drops>
<line_x>0</line_x>
<l3_fwd_hdr>0</l3_fwd_hdr>
<l3_fwd_rx_pkts>0</l3_fwd_rx_pkts>
<l3_fwd_tx_pkts>0</l3_fwd_tx_pkts>
<l3_fwd_drops>0</l3_fwd_drops>
<non_dhcp_hdr>0</non_dhcp_hdr>
<non_dhcp_rx_pkts>0</non_dhcp_rx_pkts>
<non_dhcp_tx_pkts>0</non_dhcp_tx_pkts>
<non_dhcp_drops>0</non_dhcp_drops>
<drop_hdr>0</drop_hdr>
<drop_validation_fail>0</drop_validation_fail>
<drop_relay_disable>0</drop_relay_disable>
<drop_invalid_msg_type>0</drop_invalid_msg_type>
<drop_intf_err>0</drop_intf_err>
<drop_tx_sock_err>0</drop_tx_sock_err>
<drop_tx_fail_client_intf>0</drop_tx_fail_client_intf>
<drop_unknown_op_intf>0</drop_unknown_op_intf>
<drop_l3_unknown_op_intf>0</drop_l3_unknown_op_intf>
<drop_max_hops>0</drop_max_hops>
<drop_opt82_insert_fail>0</drop_opt82_insert_fail>
<drop_malformed>0</drop_malformed>
<drop_untrusted_relay_intf>0</drop_untrusted_relay_intf>
<footer>0</footer>
</__readonly__>
</__XML__OPT_Cmd_show_dhcp_relay_stats___readonly__>
</__XML__OPT_Cmd_show_dhcp_relay_stats_interface>
</statistics>
</relay>
</dhcp>
</ip>
</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 |
---|
|
Message Type Rx Tx Drops
Discover 0 0 0 Offer 0 0 0 Request() 0 0 0 Ack 0 0 0 Release() 0 0 0 Decline 0 0 0 Inform(*) 0 0 0 Nack 0 0 0
Total 0 0 0
DHCP L3 FWD: Total Packets Received : 0 Total Packets Forwarded : 0 Total Packets Dropped : 0 Non DHCP: Total Packets Received : 0 Total Packets Forwarded : 0 Total Packets Dropped : 0 DROP: DHCP Relay not enabled : 0 Invalid DHCP message type : 0 Interface error : 0 Tx failure towards server : 0 Tx failure towards client : 0 Unknown output interface : 0 Unknown vrf or interface for server : 0 Max hops exceeded : 0 Option 82 validation failed : 0 Packet Malformed : 0 Relay Trusted port not configured : 0
- These counters will show correct value when switch
receives DHCP request packet with destination ip as broadcast
address. If request is unicast it will be HW switched
- These counters will show correct value when switch
receives DHCP request packet with destination ip as broadcast
address. If request is unicast it will be HW switched
show ip dhcp snooping
show ip dhcp snooping
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 ip dhcp snooping",
"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)
{
"snoop_gbl_enable": "enabled",
"snoop_vlan_enable": null,
"snoop_oper_vlan_enable": null,
"snoop_opt82_enable": "disabled",
"snoop_hwaddr_verify_enable": "enabled",
"snoop_hdr": 0,
"TABLE_intf_entry": {
"ROW_intf_entry": {
"intf_entry_if_index": "Ethernet5/35",
"intf_entry_trust_dhcp": "trusted",
"intf_entry_pkt_limit": 0
}
}
}
switch# show ip dhcp snooping | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ip>
<dhcp>
<snooping>
<__XML__OPT_Cmd_show_dhcp_snooping___readonly__>
<__readonly__>
<snoop_gbl_enable>enabled</snoop_gbl_enable>
<snoop_vlan_enable></snoop_vlan_enable>
<snoop_oper_vlan_enable></snoop_oper_vlan_enable>
<snoop_opt82_enable>disabled</snoop_opt82_enable>
<snoop_hwaddr_verify_enable>enabled</snoop_hwaddr_verify_enable>
<snoop_hdr>0</snoop_hdr>
<TABLE_intf_entry>
<ROW_intf_entry>
<intf_entry_if_index>Ethernet5/35</intf_entry_if_index>
<intf_entry_trust_dhcp>trusted</intf_entry_trust_dhcp>
<intf_entry_pkt_limit>0</intf_entry_pkt_limit>
</ROW_intf_entry>
</TABLE_intf_entry>
</__readonly__>
</__XML__OPT_Cmd_show_dhcp_snooping___readonly__>
</snooping>
</dhcp>
</ip>
</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 ip dhcp snooping binding [ | | vlan | interface ]+ [dynamic | static]
show ip dhcp snooping binding [<ip> | <mac> | vlan <vlan-range> | interface <intf>]+ [dynamic | static]
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 ip dhcp snooping binding",
"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)
{
"bind_hdr": 3
}
switch# show ip dhcp snooping binding | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ip>
<dhcp>
<snooping>
<binding>
<__XML__OPT_Cmd_show_dhcp_binding_ip>
<__XML__OPT_Cmd_show_dhcp_binding_dynamic>
<__XML__OPT_Cmd_show_dhcp_binding___readonly__>
<__readonly__>
<bind_hdr>3</bind_hdr>
</__readonly__>
</__XML__OPT_Cmd_show_dhcp_binding___readonly__>
</__XML__OPT_Cmd_show_dhcp_binding_dynamic>
</__XML__OPT_Cmd_show_dhcp_binding_ip>
</binding>
</snooping>
</dhcp>
</ip>
</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 ip dhcp snooping statistics [ {vlan interface } | vlan ]
show ip dhcp snooping statistics [ {vlan <vlan-id> interface <intf>} | vlan <vlan-id> ]
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 ip dhcp snooping statistics",
"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)
{
"msg_stats_hdr": 0,
"TABLE_message": {
"ROW_message": [
{
"msg_type_str": "Discover",
"rx_pkts": 0,
"tx_pkts": 0,
"drops": 0
},
{
"msg_type_str": "Offer",
"rx_pkts": 0,
"tx_pkts": 0,
"drops": 0
},
{
"msg_type_str": "Request",
"rx_pkts": 0,
"tx_pkts": 0,
"drops": 0
},
{
"msg_type_str": "Ack",
"rx_pkts": 0,
"tx_pkts": 0,
"drops": 0
},
{
"msg_type_str": "Release",
"rx_pkts": 0,
"tx_pkts": 0,
"drops": 0
},
{
"msg_type_str": "Decline",
"rx_pkts": 0,
"tx_pkts": 0,
"drops": 0
},
{
"msg_type_str": "Inform",
"rx_pkts": 0,
"tx_pkts": 0,
"drops": 0
},
{
"msg_type_str": "Nack",
"rx_pkts": 0,
"tx_pkts": 0,
"drops": 0
}
]
},
"line": 0,
"msg_type_str_total": 1635020628,
"total_rx_pkts": 0,
"total_tx_pkts": 0,
"total_drops": 0,
"line1": 0,
"l2_fwd_hdr": 0,
"l2_fwd_rx_pkts": 0,
"l2_fwd_tx_pkts": 0,
"l2_fwd_drops": 0,
"non_dhcp_hdr": 0,
"non_dhcp_rx_pkts": 0,
"non_dhcp_tx_pkts": 0,
"non_dhcp_drops": 0,
"drop_hdr": 0,
"drop_untrust": 0,
"drop_validation_fail": 0,
"drop_unknown": 0,
"drop_src_mac_chk_fail": 0,
"drop_nobinding": 0,
"drop_invalid_msg_type": 0,
"drop_invalid_dhcp_discover_with_ip": 0,
"drop_intf_err": 0,
"drop_tx_trusted_port_fail": 0,
"drop_no_trusted_port": 0,
"drop_vlan_validation_fail": 0,
"drop_opt82_insert_fail": 0,
"drop_malformed": 0
}
switch# show ip dhcp snooping statistics | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ip>
<dhcp>
<snooping>
<statistics>
<__XML__OPT_Cmd_show_dhcp_snoop_stats_vlan>
<__XML__OPT_Cmd_show_dhcp_snoop_stats___readonly__>
<__readonly__>
<msg_stats_hdr>0</msg_stats_hdr>
<TABLE_message>
<ROW_message>
<msg_type_str>Discover</msg_type_str>
<rx_pkts>0</rx_pkts>
<tx_pkts>0</tx_pkts>
<drops>0</drops>
</ROW_message>
<ROW_message>
<msg_type_str>Offer</msg_type_str>
<rx_pkts>0</rx_pkts>
<tx_pkts>0</tx_pkts>
<drops>0</drops>
</ROW_message>
<ROW_message>
<msg_type_str>Request</msg_type_str>
<rx_pkts>0</rx_pkts>
<tx_pkts>0</tx_pkts>
<drops>0</drops>
</ROW_message>
<ROW_message>
<msg_type_str>Ack</msg_type_str>
<rx_pkts>0</rx_pkts>
<tx_pkts>0</tx_pkts>
<drops>0</drops>
</ROW_message>
<ROW_message>
<msg_type_str>Release</msg_type_str>
<rx_pkts>0</rx_pkts>
<tx_pkts>0</tx_pkts>
<drops>0</drops>
</ROW_message>
<ROW_message>
<msg_type_str>Decline</msg_type_str>
<rx_pkts>0</rx_pkts>
<tx_pkts>0</tx_pkts>
<drops>0</drops>
</ROW_message>
<ROW_message>
<msg_type_str>Inform</msg_type_str>
<rx_pkts>0</rx_pkts>
<tx_pkts>0</tx_pkts>
<drops>0</drops>
</ROW_message>
<ROW_message>
<msg_type_str>Nack</msg_type_str>
<rx_pkts>0</rx_pkts>
<tx_pkts>0</tx_pkts>
<drops>0</drops>
</ROW_message>
</TABLE_message>
<line>0</line>
<msg_type_str_total>1635020628</msg_type_str_total>
<total_rx_pkts>0</total_rx_pkts>
<total_tx_pkts>0</total_tx_pkts>
<total_drops>0</total_drops>
<line1>0</line1>
<l2_fwd_hdr>0</l2_fwd_hdr>
<l2_fwd_rx_pkts>0</l2_fwd_rx_pkts>
<l2_fwd_tx_pkts>0</l2_fwd_tx_pkts>
<l2_fwd_drops>0</l2_fwd_drops>
<non_dhcp_hdr>0</non_dhcp_hdr>
<non_dhcp_rx_pkts>0</non_dhcp_rx_pkts>
<non_dhcp_tx_pkts>0</non_dhcp_tx_pkts>
<non_dhcp_drops>0</non_dhcp_drops>
<drop_hdr>0</drop_hdr>
<drop_untrust>0</drop_untrust>
<drop_validation_fail>0</drop_validation_fail>
<drop_unknown>0</drop_unknown>
<drop_src_mac_chk_fail>0</drop_src_mac_chk_fail>
<drop_nobinding>0</drop_nobinding>
<drop_invalid_msg_type>0</drop_invalid_msg_type>
<drop_invalid_dhcp_discover_with_ip>0</drop_invalid_dhcp_discover_with
_ip>
<drop_intf_err>0</drop_intf_err>
<drop_tx_trusted_port_fail>0</drop_tx_trusted_port_fail>
<drop_no_trusted_port>0</drop_no_trusted_port>
<drop_vlan_validation_fail>0</drop_vlan_validation_fail>
<drop_opt82_insert_fail>0</drop_opt82_insert_fail>
<drop_malformed>0</drop_malformed>
</__readonly__>
</__XML__OPT_Cmd_show_dhcp_snoop_stats___readonly__>
</__XML__OPT_Cmd_show_dhcp_snoop_stats_vlan>
</statistics>
</snooping>
</dhcp>
</ip>
</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 |
---|
|
Message Type Rx Tx Drops
Discover 0 0 0 Offer 0 0 0 Request 0 0 0 Ack 0 0 0 Release 0 0 0 Decline 0 0 0 Inform 0 0 0 Nack 0 0 0
DHCP L2 Forwarding: Total Packets Received : 0 Total Packets Forwarded : 0 Total Packets Dropped : 0 Non DHCP: Total Packets Received : 0 Total Packets Forwarded : 0 Total Packets Dropped : 0 DROP: Received on untrusted port : 0 Unknown Failure : 0 Source mac validation failed : 0 Binding entry validation Failed : 0 Invalid DHCP message type : 0 Interface error : 0 Tx over trusted port failed : 0 Trust port not configured : 0 Vlan validation failure : 0 Insertion of option 82 failed : 0 Packet Malformed : 0
show ip dhcp status
show ip dhcp status
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 ip dhcp status",
"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)
{
"current_cli_op": "show ip dhcp status",
"last_cli_op": "ip dhcp snooping trust: Interface Ethernet5/35",
"last_cli_stat": 0
}
switch# show ip dhcp status | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ip>
<dhcp>
<status>
<__XML__OPT_Cmd_show_ip_dhcp_status___readonly__>
<__readonly__>
<current_cli_op>show ip dhcp status</current_cli_op>
<last_cli_op>ip dhcp snooping trust: Interface Ethernet5/35</last_cli_op
>
<last_cli_stat>0</last_cli_stat>
</__readonly__>
</__XML__OPT_Cmd_show_ip_dhcp_status___readonly__>
</status>
</dhcp>
</ip>
</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 ip udp relay
show ip udp relay
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 ip udp relay",
"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)
{
"udp_relay_service_enable": "disabled",
"udp_relay_hdr": 0,
"TABLE_default_ports": {
"ROW_default_ports": [
{
"port_name": 37,
"udp_relay_port_enable": "enabled"
},
{
"port_name": 42,
"udp_relay_port_enable": "enabled"
},
{
"port_name": 49,
"udp_relay_port_enable": "enabled"
},
{
"port_name": 53,
"udp_relay_port_enable": "enabled"
},
{
"port_name": 69,
"udp_relay_port_enable": "enabled"
},
{
"port_name": 137,
"udp_relay_port_enable": "enabled"
},
{
"port_name": 138,
"udp_relay_port_enable": "enabled"
}
]
},
"udp_ports_hdr": 0,
"udp_intf_hdr": 0
}
switch# show ip udp relay | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ip>
<udp>
<relay>
<__XML__OPT_Cmd_show_udp_relay___readonly__>
<__readonly__>
<udp_relay_service_enable>disabled</udp_relay_service_enable>
<udp_relay_hdr>0</udp_relay_hdr>
<TABLE_default_ports>
<ROW_default_ports>
<port_name>37</port_name>
<udp_relay_port_enable>enabled</udp_relay_port_enable>
</ROW_default_ports>
<ROW_default_ports>
<port_name>42</port_name>
<udp_relay_port_enable>enabled</udp_relay_port_enable>
</ROW_default_ports>
<ROW_default_ports>
<port_name>49</port_name>
<udp_relay_port_enable>enabled</udp_relay_port_enable>
</ROW_default_ports>
<ROW_default_ports>
<port_name>53</port_name>
<udp_relay_port_enable>enabled</udp_relay_port_enable>
</ROW_default_ports>
<ROW_default_ports>
<port_name>69</port_name>
<udp_relay_port_enable>enabled</udp_relay_port_enable>
</ROW_default_ports>
<ROW_default_ports>
<port_name>137</port_name>
<udp_relay_port_enable>enabled</udp_relay_port_enable>
</ROW_default_ports>
<ROW_default_ports>
<port_name>138</port_name>
<udp_relay_port_enable>enabled</udp_relay_port_enable>
</ROW_default_ports>
</TABLE_default_ports>
<udp_ports_hdr>0</udp_ports_hdr>
<udp_intf_hdr>0</udp_intf_hdr>
</__readonly__>
</__XML__OPT_Cmd_show_udp_relay___readonly__>
</relay>
</udp>
</ip>
</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 |
---|
|
UDP relay service is DISABLED
UDP relay on default UDP ports:
Default UDP Ports Status
------------------ -------
Time service (port 37 ) enabled IEN-116 Name Service (port 42 ) enabled TACACS service (port 49 ) enabled Domain Naming System (port 53 ) enabled Trivial File Transfer Protocol (port 69 ) enabled NetBIOS Name Server (port 137) enabled NetBIOS Datagram Server (port 138) enabled
Non-default UDP ports:
----------------------
Interfaces and subnet-broadcast:
Interface Subnet-broadcast Object-group
show ip udp relay interface []
show ip udp relay interface [<intf_range>]
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 ip udp relay interface",
"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)
{
"udp_intf_hdr": 0,
"TABLE_intf": {
"ROW_intf": {
"udp_intf_idx": "Ethernet5/35",
"udp_sub_bcast": "disabled",
"udp_objgrp": "abc"
}
}
}
switch# show ip udp relay interface | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ip>
<udp>
<relay>
<interface>
<__XML__OPT_Cmd_show_udp_relay_intf_intf_range>
<__XML__OPT_Cmd_show_udp_relay_intf___readonly__>
<__readonly__>
<udp_intf_hdr>0</udp_intf_hdr>
<TABLE_intf>
<ROW_intf>
<udp_intf_idx>Ethernet5/35</udp_intf_idx>
<udp_sub_bcast>disabled</udp_sub_bcast>
<udp_objgrp>abc</udp_objgrp>
</ROW_intf>
</TABLE_intf>
</__readonly__>
</__XML__OPT_Cmd_show_udp_relay_intf___readonly__>
</__XML__OPT_Cmd_show_udp_relay_intf_intf_range>
</interface>
</relay>
</udp>
</ip>
</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 ip udp relay object-group []
show ip udp relay object-group [<obj-grp-name>]
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 ip udp relay object-group",
"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_objgrp_list": {
"ROW_objgrp_list": {
"udp_objgrp": "abc",
"TABLE_objgrp": {
"ROW_objgrp": {
"net_addr": "2.2.2.0",
"net_mask": "255.255.255.0"
}
},
"udp_intf_hdr": 0,
"TABLE_intf": {
"ROW_intf": {
"udp_intf_idx": "Ethernet5/35"
}
}
}
}
}
switch# show ip udp relay object-group | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ip>
<udp>
<relay>
<object-group>
<__XML__OPT_Cmd_show_udp_relay_objgrp_obj-grp-name>
<__XML__OPT_Cmd_show_udp_relay_objgrp___readonly__>
<__readonly__>
<TABLE_objgrp_list>
<ROW_objgrp_list>
<udp_objgrp>abc</udp_objgrp>
<TABLE_objgrp>
<ROW_objgrp>
<net_addr>2.2.2.0</net_addr>
<net_mask>255.255.255.0</net_mask>
</ROW_objgrp>
</TABLE_objgrp>
<udp_intf_hdr>0</udp_intf_hdr>
<TABLE_intf>
<ROW_intf>
<udp_intf_idx>Ethernet5/35</udp_intf_idx>
</ROW_intf>
</TABLE_intf>
</ROW_objgrp_list>
</TABLE_objgrp_list>
</__readonly__>
</__XML__OPT_Cmd_show_udp_relay_objgrp___readonly__>
</__XML__OPT_Cmd_show_udp_relay_objgrp_obj-grp-name>
</object-group>
</relay>
</udp>
</ip>
</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 ip verify source [ interface ]
show ip verify source [ interface <intf6> ]
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 ip verify source",
"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)
{
"verify_ipsg_enable_intfs": "Ethernet5/12",
"verify_hdr": 0,
"TABLE_verify_entry": {
"ROW_verify_entry": {
"verify_intf": "Ethernet5/12",
"verify_filter_mode": 2
}
}
}
switch# show ip verify source | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ip>
<verify>
<source>
<__XML__OPT_Cmd_show_ipsg_verify_interface>
<__XML__OPT_Cmd_show_ipsg_verify___readonly__>
<__readonly__>
<verify_ipsg_enable_intfs> Ethernet5/12
</verify_ipsg_enable_intfs>
<verify_hdr>0</verify_hdr>
<TABLE_verify_entry>
<ROW_verify_entry>
<verify_intf>Ethernet5/12</verify_intf>
<verify_filter_mode>2</verify_filter_mode>
</ROW_verify_entry>
</TABLE_verify_entry>
</__readonly__>
</__XML__OPT_Cmd_show_ipsg_verify___readonly__>
</__XML__OPT_Cmd_show_ipsg_verify_interface>
</source>
</verify>
</ip>
</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 |
---|
|
Ethernet5/12
IP source guard operational entries:
Interface Filter-mode IP-address Mac-address Vlan
Ethernet5/12 inactive-no-snoop-vlan
show ipv6 dhcp relay [interface ]
show ipv6 dhcp relay [interface <intf-range>]
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": "sshow ipv6 dhcp relay",
"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)
{
"relay_service_enable": "enabled",
"relay_vpn_enable": "disabled",
"relay_cisco_option_enable": "disabled",
"TABLE_intf": {
"ROW_intf": {
"interface-name": "Ethernet5/3",
"intf_header": 0,
"TABLE_addr": {
"ROW_addr": {
"relay_address": "2000::1",
"dst_intf": null,
"vrf_name": null
}
}
}
}
}
switch# show ipv6 dhcp relay | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ipv6>
<dhcp>
<relay>
<__XML__OPT_Cmd_show_ipv6_dhcp_relay_intf_interface>
<__XML__OPT_Cmd_show_ipv6_dhcp_relay_intf___readonly__>
<__readonly__>
<relay_service_enable>enabled</relay_service_enable>
<relay_vpn_enable>disabled</relay_vpn_enable>
<relay_cisco_option_enable>disabled</relay_cisco_option_enable>
<TABLE_intf>
<ROW_intf>
<interface-name>Ethernet5/3</interface-name>
<intf_header>0</intf_header>
<TABLE_addr>
<ROW_addr>
<relay_address>2000::1</relay_address>
<dst_intf></dst_intf>
<vrf_name> </vrf_name>
</ROW_addr>
</TABLE_addr>
</ROW_intf>
</TABLE_intf>
</__readonly__>
</__XML__OPT_Cmd_show_ipv6_dhcp_relay_intf___readonly__>
</__XML__OPT_Cmd_show_ipv6_dhcp_relay_intf_interface>
</relay>
</dhcp>
</ipv6>
</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 ipv6 dhcp relay statistics [ interface [[server-ip [use-vrf ] [interface ]] | [server-ip [interface ] [use-vrf ]]]]
show ipv6 dhcp relay statistics [ interface <intf> [[server-ip <ip-addr-val> [use-vrf <vrf-name>] [interface <dest-interface>]] | [server-ip <ip-addr-val> [interface <dest-interface>] [use-vrf <vrf-name>]]]]
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 ipv6 dhcp relay statistics",
"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)
{
"msg_stats_hdr": 0,
"msg_type_str": "SOLICIT",
"rx_pkts": 0,
"tx_pkts": 0,
"drops": 0,
"msg_type_str_advertise": "ADVERTISE",
"rx_pkts_advertise": 0,
"tx_pkts_advertise": 0,
"drops_advertise": 0,
"msg_type_str_request": "REQUEST",
"rx_pkts_request": 0,
"tx_pkts_request": 0,
"drops_request": 0,
"msg_type_str_confirm": "CONFIRM",
"rx_pkts_confirm": 0,
"tx_pkts_confirm": 0,
"drops_confirm": 0,
"msg_type_str_renew": "RENEW",
"rx_pkts_renew": 0,
"tx_pkts_renew": 0,
"drops_renew": 0,
"msg_type_str_rebind": "REBIND",
"rx_pkts_rebind": 0,
"tx_pkts_rebind": 0,
"drops_rebind": 0,
"msg_type_str_reply": "REPLY",
"rx_pkts_reply": 0,
"tx_pkts_reply": 0,
"drops_reply": 0,
"msg_type_str_release": "RELEASE",
"rx_pkts_release": 0,
"tx_pkts_release": 0,
"drops_release": 0,
"msg_type_str_decline": "DECLINE",
"rx_pkts_decline": 0,
"tx_pkts_decline": 0,
"drops_decline": 0,
"msg_type_str_reconfigure": "RECONFIGURE",
"rx_pkts_reconfigure": 0,
"tx_pkts_reconfigure": 0,
"drops_reconfigure": 0,
"msg_type_str_inforeq": "INFORMATION_REQUEST",
"rx_pkts_inforeq": 0,
"tx_pkts_inforeq": 0,
"drops_inforeq": 0,
"msg_type_str_relay_fwd": "RELAY_FWD",
"rx_pkts_relay_fwd": 0,
"tx_pkts_relay_fwd": 0,
"drops_relay_fwd": 0,
"msg_type_str_relay_reply": "RELAY_REPLY",
"rx_pkts_relay_reply": 0,
"tx_pkts_relay_reply": 0,
"drops_relay_reply": 0,
"msg_type_str_unknown": "UNKNOWN",
"rx_pkts_unknown": 0,
"tx_pkts_unknown": 0,
"drops_unknown": 0,
"msg_type_str_total": 0,
"drop_hdr": 0,
"drop_relay_disable": 0,
"drop_max_hops": 0,
"drop_validation_fails": 0,
"drop_unknown_op_intf": 0,
"drop_bad_context": 0,
"drop_opt_insert_fail": 0,
"drop_server_direct_reply": 0,
"drop_no_ipv6_addr": 0,
"drop_intf_error": 0,
"drop_vpn_disabled": 0,
"drop_ipv6_extn_hdrs_presence": 0
}
switch# show ipv6 dhcp relay statistics | xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<nf:rpc-reply xmlns="http://www.cisco.com/nxos:1.0:dhcp_snoop" xmlns:nf="urn:iet
f:params:xml:ns:netconf:base:1.0">
<nf:data>
<show>
<ipv6>
<dhcp>
<relay>
<statistics>
<__XML__OPT_Cmd_show_ipv6_dhcp_relay_stats_interface>
<__XML__OPT_Cmd_show_ipv6_dhcp_relay_stats___readonly__>
<__readonly__>
<msg_stats_hdr>0</msg_stats_hdr>
<msg_type_str>SOLICIT</msg_type_str>
<rx_pkts>0</rx_pkts>
<tx_pkts>0</tx_pkts>
<drops>0</drops>
<msg_type_str_advertise>ADVERTISE</msg_type_str_advertise>
<rx_pkts_advertise>0</rx_pkts_advertise>
<tx_pkts_advertise>0</tx_pkts_advertise>
<drops_advertise>0</drops_advertise>
<msg_type_str_request>REQUEST</msg_type_str_request>
<rx_pkts_request>0</rx_pkts_request>
<tx_pkts_request>0</tx_pkts_request>
<drops_request>0</drops_request>
<msg_type_str_confirm>CONFIRM</msg_type_str_confirm>
<rx_pkts_confirm>0</rx_pkts_confirm>
<tx_pkts_confirm>0</tx_pkts_confirm>
<drops_confirm>0</drops_confirm>
<msg_type_str_renew>RENEW</msg_type_str_renew>
<rx_pkts_renew>0</rx_pkts_renew>
<tx_pkts_renew>0</tx_pkts_renew>
<drops_renew>0</drops_renew>
<msg_type_str_rebind>REBIND</msg_type_str_rebind>
<rx_pkts_rebind>0</rx_pkts_rebind>
<tx_pkts_rebind>0</tx_pkts_rebind>
<drops_rebind>0</drops_rebind>
<msg_type_str_reply>REPLY</msg_type_str_reply>
<rx_pkts_reply>0</rx_pkts_reply>
<tx_pkts_reply>0</tx_pkts_reply>
<drops_reply>0</drops_reply>
<msg_type_str_release>RELEASE</msg_type_str_release>
<rx_pkts_release>0</rx_pkts_release>
<tx_pkts_release>0</tx_pkts_release>
<drops_release>0</drops_release>
<msg_type_str_decline>DECLINE</msg_type_str_decline>
<rx_pkts_decline>0</rx_pkts_decline>
<tx_pkts_decline>0</tx_pkts_decline>
<drops_decline>0</drops_decline>
<msg_type_str_reconfigure>RECONFIGURE</msg_type_str_reconfigure>
<rx_pkts_reconfigure>0</rx_pkts_reconfigure>
<tx_pkts_reconfigure>0</tx_pkts_reconfigure>
<drops_reconfigure>0</drops_reconfigure>
<msg_type_str_inforeq>INFORMATION_REQUEST</msg_type_str_inforeq>
<rx_pkts_inforeq>0</rx_pkts_inforeq>
<tx_pkts_inforeq>0</tx_pkts_inforeq>
<drops_inforeq>0</drops_inforeq>
<msg_type_str_relay_fwd>RELAY_FWD</msg_type_str_relay_fwd>
<rx_pkts_relay_fwd>0</rx_pkts_relay_fwd>
<tx_pkts_relay_fwd>0</tx_pkts_relay_fwd>
<drops_relay_fwd>0</drops_relay_fwd>
<msg_type_str_relay_reply>RELAY_REPLY</msg_type_str_relay_reply>
<rx_pkts_relay_reply>0</rx_pkts_relay_reply>
<tx_pkts_relay_reply>0</tx_pkts_relay_reply>
<drops_relay_reply>0</drops_relay_reply>
<msg_type_str_unknown>UNKNOWN</msg_type_str_unknown>
<rx_pkts_unknown>0</rx_pkts_unknown>
<tx_pkts_unknown>0</tx_pkts_unknown>
<drops_unknown>0</drops_unknown>
<msg_type_str_total>0</msg_type_str_total>
<drop_hdr>0</drop_hdr>
<drop_relay_disable>0</drop_relay_disable>
<drop_max_hops>0</drop_max_hops>
<drop_validation_fails>0</drop_validation_fails>
<drop_unknown_op_intf>0</drop_unknown_op_intf>
<drop_bad_context>0</drop_bad_context>
<drop_opt_insert_fail>0</drop_opt_insert_fail>
<drop_server_direct_reply>0</drop_server_direct_reply>
<drop_no_ipv6_addr>0</drop_no_ipv6_addr>
<drop_intf_error>0</drop_intf_error>
<drop_vpn_disabled>0</drop_vpn_disabled>
<drop_ipv6_extn_hdrs_presence>0</drop_ipv6_extn_hdrs_presence>
</__readonly__>
</__XML__OPT_Cmd_show_ipv6_dhcp_relay_stats___readonly__>
</__XML__OPT_Cmd_show_ipv6_dhcp_relay_stats_interface>
</statistics>
</relay>
</dhcp>
</ipv6>
</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 |
---|
|
Message Type Rx Tx Drops
SOLICIT 0 0 0 ADVERTISE 0 0 0 REQUEST 0 0 0 CONFIRM 0 0 0 RENEW 0 0 0 REBIND 0 0 0 REPLY 0 0 0 RELEASE 0 0 0 DECLINE 0 0 0 RECONFIGURE 0 0 0 INFORMATION_REQUEST 0 0 0 RELAY_FWD 0 0 0 RELAY_REPLY 0 0 0 UNKNOWN 0 0 0
Total 0 0 0
DROPS:
DHCPv6 Relay is disabled : 0 Max hops exceeded : 0 Packet validation fails : 0 Unknown output interface : 0 Invalid VRF : 0 Option insertion failed : 0 Direct Replies (Recnfg/Adv/Reply) from server: 0 IPv6 addr not configured : 0 Interface error : 0 VPN Option Disabled : 0 IPv6 extn headers present : 0