NBAR show Commands

The show ip nbar protocol-discovery command displays the statistics gathered by the NBAR Protocol Discovery feature. By default, statistics for all interfaces on which Protocol Discovery is enabled are displayed. The default output includes bit rate, byte count, packet count, and protocol name. Protocol Discovery monitors ingress and egress traffic and can optionally be applied with a service policy.

Egress traffic statistics are gathered before policing features (such as QoS, access lists, or queue drops) at the interface. Therefore, the egress counters might be higher than the actual traffic being forwarded by the interface.

Some of the more detailed show ip nbar command options are as follows:

  • router# show ip nbar [filter | pdlm | port-map | protocol-discovery | resources | trace | unclassified-port-stats | version]

    displays a variety of statistics based on the keyword used:

    - filter displays the current NBAR's filter criteria.

    - pdlm displays the currently installed PDLMs.

    - port-map displays the TCP/UDP port numbers NBAR uses to classify a given protocol.

    - protocol-discovery displays the statistics for all interfaces on which Protocol Discovery is enabled.

    - resources displays the memory configuration for tracking stateful sessions.

    - unclassified-port-stats displays NBAR's port statistics for unclassified packets.

    - version displays currently installed PDL Module Version Info.

The more complex commands are explained specifically:

  • router(config)# show ip nbar protocol-discovery [interface interface-spec] [stats {byte-count | bit-rate | packet-count | max-bit-rate}][{protocol protocol-name | top-n number}]

    displays the statistics gathered by the NBAR Protocol Discovery feature. The parameter details are as follows:

    - interface-spec specifies an interface to display.

    - stats specifies that the byte count, bit rate, or packet count is to be displayed:

    byte-count specifies that the byte count is to be displayed.

    bit-rate specifies that the bit rate is to be displayed.

    packet-count specifies that the packet count is to be displayed.

    max-bit-rate specifies that the maximum bit rate is to be displayed.

    - protocol specifies that statistics for a specific protocol (defined by protocol-name) are to be displayed.

    - top-n number specifies that a Top-N (number) of most active protocols is displayed. For instance, if top-n 3 is entered, the three most active NBAR supported protocols are displayed.

  • router# show ip nbar port-map [protocol-name] [tcp | udp] port-number

    displays the current protocol-to-port mappings in use by NBAR.

  • router# show ip nbar unclassified-port-stats [number of top talkers] [ip {starting protocol number | top-n talkers}] [tcp {starting tcp port number | bottom-talkers | top-talkers}] [udp {starting udp port number | bottom-talkers | top-talkers}]

    displays NBAR port statistics for unclassified packets.



Part II: Implementations on the Cisco Devices