show port-channel compatibility-parameters

show port-channel compatibility-parameters

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 port-channel compatibility-parameters ",
  "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)


{
  "ins_api": {
    "type": "cli_show",
    "version": "1.0",
    "sid": "eoc",
    "outputs": {
      "output": {
        "input": "show port-channel compatibility-parameters ",
        "msg": "Success",
        "code": "200",
        "body": {
          "TABLE_compatibility": {
            "ROW_compatibility": [
              {
                "parameter": "port mode",
                "description": "Members must have the same port mode configured, either E,F or AUTO. If \nthey are configured in AUTO port mode, they have to negotiate E or F mode \nwhen they come up. If a member negotiates a different mode, it will be \nsuspended."
              },
              {
                "parameter": "speed",
                "description": "Members must have the same speed configured. If they are configured in AUTO \nspeed, they have to negotiate the same speed when they come up. If a member \nnegotiates a different speed, it will be suspended."
              },
              {
                "parameter": "MTU",
                "description": "Members have to have the same MTU configured. This only applies to ethernet \nport-channel."
              },
              {
                "parameter": "MEDIUM",
                "description": "Members have to have the same medium type configured. This only applies to \nethernet port-channel."
              },
              {
                "parameter": "Span mode",
                "description": "Members must have the same span mode."
              },
              {
                "parameter": "load interval",
                "description": "Member must have same load interval configured."
              },
              {
                "parameter": "port Voice VLAN",
                "description": "Members must not have voice vlan configured."
              },
              {
                "parameter": "VLAN translation mapping list",
                "description": "Members must have the same VLAN translation list."
              },
              {
                "parameter": "sub interfaces",
                "description": "Members must not have sub-interfaces."
              },
              {
                "parameter": "Duplex Mode",
                "description": "Members must have same Duplex Mode configured."
              },
              {
                "parameter": "Ethernet Layer",
                "description": "Members must have same Ethernet Layer (switchport/no-switchport) configured."
              },
              {
                "parameter": "Span Port",
                "description": "Members cannot be SPAN ports."
              },
              {
                "parameter": "Storm Control",
                "description": "Members must have same storm-control configured."
              },
              {
                "parameter": "Switchport Block",
                "description": "Members must have same switchport block configured."
              },
              {
                "parameter": "Switchport Isolated",
                "description": "Members must have same switchport isolated configured."
              },
              {
                "parameter": "Flow Control",
                "description": "Members must have same flowctrl configured."
              },
              {
                "parameter": "Capabilities",
                "description": "Members must have common capabilities."
              },
              {
                "parameter": "Capabilities speed",
                "description": "Members must have common speed capabilities."
              },
              {
                "parameter": "Capabilities duplex",
                "description": "Members must have common speed duplex capabilities."
              },
              {
                "parameter": "Port has PVLAN config",
                "description": "Members must have same pvlan configuration"
              },
              {
                "parameter": "rate mode",
                "description": "Members must have the same rate mode configured."
              },
              {
                "parameter": "Capabilities FabricPath",
                "description": "Members must have common fabricpath capability."
              },
              {
                "parameter": "1G port is not capable of acting as peer-link",
                "description": "Members must be 10G to become part of a vPC peer-link."
              },
              {
                "parameter": "EthType",
                "description": "Members must have same EthType configured."
              },
              {
                "parameter": "shared interface",
                "description": "Members can not be shared-interfaces."
              },
              {
                "parameter": "Capabilities SpanDest",
                "description": "Members must be capable of span destination configuration"
              },
              {
                "parameter": "Module Type Incompatible",
                "description": "Module type for interfaces is not compatible."
              },
              {
                "parameter": "Port Mode Fabricpath Incompatible",
                "description": "Members are Fabricpath Enforce locked, not compatible."
              },
              {
                "parameter": "Buffer boost",
                "description": "Members must have same buffer-boost configuration."
              },
              {
                "parameter": "vmtracker enable mismatch",
                "description": "Members have vmtracker enable mismatch"
              },
              {
                "parameter": "Port Type",
                "description": "Members must be all server or all fabric facing ports."
              },
              {
                "parameter": "Sflow enabled port",
                "description": "Members cannot be Sflow enabled ports"
              },
              {
                "parameter": "Switchport Mac-learn",
                "description": "Members must have same switchport mac-learn configured."
              },
              {
                "parameter": "switchport virtual-ethernet-bridge enabled port",
                "description": "Members must have same switchport virtual-ethernet-bridge configured."
              },
              {
                "parameter": "port-type fabric",
                "description": "Members must have same port-type configured."
              },
              {
                "parameter": "port",
                "description": "Members port VLAN info."
              },
              {
                "parameter": "port",
                "description": "Members port does not exist."
              },
              {
                "parameter": "switching port",
                "description": "Members must be switching port, Layer 2."
              },
              {
                "parameter": "port access VLAN",
                "description": "Members must have the same port access VLAN."
              },
              {
                "parameter": "port native VLAN",
                "description": "Members must have the same port native VLAN."
              },
              {
                "parameter": "port allowed VLAN list",
                "description": "Members must have the same port allowed VLAN list."
              },
              {
                "parameter": "controller interface",
                "description": "The interface is assigned to controller"
              },
              {
                "parameter": "port MULTI-TAG",
                "description": "Members must have allow-multi-tag configured."
              },
              {
                "parameter": "Members should have same fex config",
                "description": "Members must have same FEX configuration."
              },
              {
                "parameter": "FEX pinning max-links not one",
                "description": "FEX pinning max-links config is not one."
              },
              {
                "parameter": "Multiple port-channels with same Fex-id",
                "description": "Multiple port-channels to same FEX not allowed."
              },
              {
                "parameter": "Pinning Params",
                "description": "Members must have the same pinning parameters."
              },
              {
                "parameter": "All HIF member ports not in same pinning group",
                "description": "All HIF member ports not in same pinning group"
              },
              {
                "parameter": "Slot in host vpc mode",
                "description": "Cannot add cfged slot member to fabric po vpc."
              },
              {
                "parameter": "Members in multiple FEX",
                "description": "Members must belong to same FEX."
              },
              {
                "parameter": "Members are of different type",
                "description": "Members must of same interface type."
              },
              {
                "parameter": "port egress queuing policy",
                "description": "10G port-channel members must have the same egress queuing policy as the \nport-channel."
              },
              {
                "parameter": "port channel egress queuing policy",
                "description": "port channel egress queuing policy with fex interface memberun-supported \npolicy"
              },
              {
                "parameter": "Port Security policy",
                "description": "Members must have the same port-security enable status as port-channel"
              },
              {
                "parameter": "Port priority-flow-control",
                "description": "PFC config should be the same for all the members"
              },
              {
                "parameter": "Dot1x policy",
                "description": "Members must have host mode as multi-host with no mab configuration. Dot1X \ncannot be enabled on members when Port Security is configured on port \nchannel"
              },
              {
                "parameter": "PVLAN port config",
                "description": "Members must have same PVLAN port configuration."
              },
              {
                "parameter": "VFC bound to member port of port channel.",
                "description": "Fail to add additional interface to port channel"
              },
              {
                "parameter": "Fex ports for span",
                "description": "Port-Channel is already a SPAN source. Cannot add FEX ports connected \nthrough                         Ricard to this PC"
              },
              {
                "parameter": "VNSEG VSI configured under port channel member",
                "description": "Port Channel members cannot have VNSEG VSI configured under them"
              },
              {
                "parameter": "Speed auto-negotiation",
                "description": "Members must be configured to have the same auto-negotiation rules"
              },
              {
                "parameter": "shut lan",
                "description": "Members cannot have shut lan configured"
              },
              {
                "parameter": "MACSEC compat check",
                "description": "Members cannot have macsec enabled before adding to PO with macsec"
              }
            ]
          }
        }
      }
    }
  }
}

The CLI output example below corresponds to the payload example in the code pane on the right. For more information about the show port-channel compatibility-parameters command, see the CLI command reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

Note: This example was added in Cisco NX-OS Release 9.2(1).

CLI Output
Switch# show port-channel compatibility-parameters 

 port mode

Members must have the same port mode configured, either E,F or AUTO. If 
they are configured in AUTO port mode, they have to negotiate E or F mode 
when they come up. If a member negotiates a different mode, it will be 
suspended.

 speed

Members must have the same speed configured. If they are configured in AUTO 
speed, they have to negotiate the same speed when they come up. If a member 
negotiates a different speed, it will be suspended.

 MTU

Members have to have the same MTU configured. This only applies to ethernet 
port-channel.

 MEDIUM

Members have to have the same medium type configured. This only applies to 
ethernet port-channel.

 Span mode

Members must have the same span mode.

 load interval

Member must have same load interval configured.

 port Voice VLAN 

Members must not have voice vlan configured.

 VLAN translation mapping list

Members must have the same VLAN translation list.

 sub interfaces

Members must not have sub-interfaces.

 Duplex Mode

Members must have same Duplex Mode configured.

 Ethernet Layer

Members must have same Ethernet Layer (switchport/no-switchport) configured.

 Span Port

Members cannot be SPAN ports.

 Storm Control

Members must have same storm-control configured.

 Switchport Block

Members must have same switchport block configured.

 Switchport Isolated

Members must have same switchport isolated configured.

 Flow Control

Members must have same flowctrl configured.

 Capabilities

Members must have common capabilities.

 Capabilities speed

Members must have common speed capabilities.

 Capabilities duplex

Members must have common speed duplex capabilities.

 Port has PVLAN config

Members must have same pvlan configuration

 rate mode

Members must have the same rate mode configured.

 Capabilities FabricPath

Members must have common fabricpath capability.

 1G port is not capable of acting as peer-link

Members must be 10G to become part of a vPC peer-link.

 EthType

Members must have same EthType configured.

 shared interface

Members can not be shared-interfaces.

 Capabilities SpanDest

Members must be capable of span destination configuration

 Module Type Incompatible

Module type for interfaces is not compatible.

 Port Mode Fabricpath Incompatible

Members are Fabricpath Enforce locked, not compatible.

 Buffer boost

Members must have same buffer-boost configuration.

 vmtracker enable mismatch

Members have vmtracker enable mismatch

 Port Type

Members must be all server or all fabric facing ports.

 Sflow enabled port

Members cannot be Sflow enabled ports

 Switchport Mac-learn

Members must have same switchport mac-learn configured.

 switchport virtual-ethernet-bridge enabled port

Members must have same switchport virtual-ethernet-bridge configured.

 port-type fabric

Members must have same port-type configured.

 port

Members port VLAN info.

 port

Members port does not exist.

 switching port

Members must be switching port, Layer 2.

 port access VLAN

Members must have the same port access VLAN.

 port native VLAN

Members must have the same port native VLAN.

 port allowed VLAN list

Members must have the same port allowed VLAN list.

 controller interface

The interface is assigned to controller

 port MULTI-TAG

Members must have allow-multi-tag configured.

 Members should have same fex config

Members must have same FEX configuration.

 FEX pinning max-links not one

FEX pinning max-links config is not one.

 Multiple port-channels with same Fex-id

Multiple port-channels to same FEX not allowed.

 Pinning Params

Members must have the same pinning parameters.

 All HIF member ports not in same pinning group

All HIF member ports not in same pinning group

 Slot in host vpc mode

Cannot add cfged slot member to fabric po vpc.

 Members in multiple FEX

Members must belong to same FEX.

 Members are of different type

Members must of same interface type.

 port egress queuing policy

10G port-channel members must have the same egress queuing policy as the 
port-channel.

 port channel egress queuing policy

port channel egress queuing policy with fex interface memberun-supported 
policy

 Port Security policy 

Members must have the same port-security enable status as port-channel

 Port priority-flow-control

PFC config should be the same for all the members

 Dot1x policy

Members must have host mode as multi-host with no mab configuration. Dot1X 
cannot be enabled on members when Port Security is configured on port 
channel

 PVLAN port config

Members must have same PVLAN port configuration.

 VFC bound to member port of port channel.

 Fail to add additional interface to port channel

 Fex ports for span

Port-Channel is already a SPAN source. Cannot add FEX ports connected 
through                         Ricard to this PC

 VNSEG VSI configured under port channel member

Port Channel members cannot have VNSEG VSI configured under them

 Speed auto-negotiation

Members must be configured to have the same auto-negotiation rules 

 shut lan

Members cannot have shut lan configured

* MACSEC compat check

Members cannot have macsec enabled before adding to PO with macsec

show port-channel database interface po50

show port-channel database interface po50

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 port-channel database interface po50 ",
  "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)


{
  "ins_api": {
    "type": "cli_show",
    "version": "1.0",
    "sid": "eoc",
    "outputs": {
      "output": {
        "input": "show port-channel database interface po50 ",
        "msg": "Success",
        "code": "200",
        "body": {
          "TABLE_interface": {
            "ROW_interface": {
              "interface": "port-channel50",
              "last-membership-update": "successful",
              "total-ports": "2",
              "total-up-ports": "2",
              "first_operational-port": "Ethernet1/12",
              "age-of-channel": "0d:06h:24m:39s",
              "time-since-last-bundle": "0d:06h:24m:48s",
              "last-bundled-member": "Ethernet1/11",
              "TABLE_member": {
                "ROW_member": [
                  {
                    "port": "Ethernet1/11",
                    "mode": "active",
                    "port-status": "up"
                  },
                  {
                    "port": "Ethernet1/12",
                    "mode": "active",
                    "port-status": "up"
                  }
                ]
              }
            }
          }
        }
      }
    }
  }
}

The CLI output example below corresponds to the payload example in the code pane on the right. For more information about the show port-channel database interface po50 command, see the CLI command reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

Note: This example was added in Cisco NX-OS Release 9.2(1).

CLI Output
Switch# show port-channel database interface po50 
port-channel50
    Last membership update is successful
    2 ports in total, 2 ports up
    First operational port is Ethernet1/12
    Age of the port-channel is 0d:06h:24m:39s
    Time since last bundle is 0d:06h:24m:48s
    Last bundled member is Ethernet1/11
    Ports:   Ethernet1/11    [active ] [up]
             Ethernet1/12    [active ] [up] *

show port-channel summary

show port-channel summary

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 port-channel summary ",
  "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)


{
  "ins_api": {
    "type": "cli_show",
    "version": "1.0",
    "sid": "eoc",
    "outputs": {
      "output": {
        "input": "show port-channel summary ",
        "msg": "Success",
        "code": "200",
        "body": {
          "TABLE_channel": {
            "ROW_channel": [
              {
                "group": "1",
                "port-channel": "port-channel1",
                "layer": "S",
                "status": "U",
                "type": "Eth",
                "prtcl": "LACP",
                "TABLE_member": {
                  "ROW_member": {
                    "port": "Ethernet1/31",
                    "port-status": "P"
                  }
                }
              },
              {
                "group": "2",
                "port-channel": "port-channel2",
                "layer": "S",
                "status": "U",
                "type": "Eth",
                "prtcl": "LACP",
                "TABLE_member": {
                  "ROW_member": [
                    {
                      "port": "Ethernet1/39",
                      "port-status": "P"
                    },
                    {
                      "port": "Ethernet1/41",
                      "port-status": "P"
                    }
                  ]
                }
              }
            ]
          }
        }
      }
    }
  }
}

The CLI output example below corresponds to the payload example in the code pane on the right. For more information about the show port-channel summary command, see the CLI command reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

Note: This example was added in Cisco NX-OS Release 9.2(1).

CLI Output
Switch# show port-channel summary 

Flags:  D - Down        P - Up in port-channel (members)
        I - Individual  H - Hot-standby (LACP only)
        s - Suspended   r - Module-removed
        b - BFD Session Wait
        S - Switched    R - Routed
        U - Up (port-channel)
        p - Up in delay-lacp mode (member)
        M - Not in use. Min-links not met
--------------------------------------------------------------------------------
Group Port-       Type     Protocol  Member Ports
      Channel
--------------------------------------------------------------------------------
1     Po1(SU)     Eth      LACP      Eth1/31(P)
2 Po2(SU) Eth LACP Eth1/39(P) Eth1/41(P)

show port-channel traffic

show port-channel traffic

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 port-channel traffic  ",
  "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)


{
  "ins_api": {
    "type": "cli_show",
    "version": "1.0",
    "sid": "eoc",
    "outputs": {
      "output": {
        "input": "show port-channel traffic  ",
        "msg": "Success",
        "code": "200",
        "body": {
          "TABLE_channel": {
            "ROW_channel": [
              {
                "chanId": "1",
                "port": "Ethernet1/31",
                "rx-ucst": "100.00",
                "tx-ucst": "100.00",
                "rx-mcst": "100.00",
                "tx-mcst": "100.00",
                "rx-bcst": "0.0",
                "tx-bcst": "100.00"
              },
              {
                "chanId": "2",
                "port": "Ethernet1/39",
                "rx-ucst": "0.0",
                "tx-ucst": "99.99",
                "rx-mcst": "49.93",
                "tx-mcst": "99.02",
                "rx-bcst": "0.0",
                "tx-bcst": "99.99"
              },
              {
                "chanId": "2",
                "port": "Ethernet1/41",
                "rx-ucst": "100.00",
                "tx-ucst": "0.00",
                "rx-mcst": "50.06",
                "tx-mcst": "0.97",
                "rx-bcst": "0.0",
                "tx-bcst": "0.00"
              }
            ]
          }
        }
      }
    }
  }
}

The CLI output example below corresponds to the payload example in the code pane on the right. For more information about the show port-channel traffic command, see the CLI command reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

Note: This example was added in Cisco NX-OS Release 9.2(1).

CLI Output
Switch# show port-channel traffic
NOTE: Clear the port-channel member counters to get accurate statistics ChanId Port Rx-Ucst Tx-Ucst Rx-Mcst Tx-Mcst Rx-Bcst Tx-Bcst ------ --------- ------- ------- ------- ------- ------- ------- 1 Eth1/31 100.00% 100.00% 100.00% 100.00% 0.0% 100.00% ------ --------- ------- ------- ------- ------- ------- ------- 2 Eth1/39 0.0% 99.99% 49.93% 99.02% 0.0% 99.99% 2 Eth1/41 100.00% 0.00% 50.06% 0.97% 0.0% 0.00%