Skip to content

Monitoring

Amy Buck edited this page Dec 21, 2016 · 17 revisions

OPX supports network monitoring features such as sFlow and port mirroring which monitor and capture network traffic in the system. It also provides tools to collect port and VLAN statistics, and port media information.

Port mirroring

Mirroring copies packets from a mirroring source port to a mirroring destination port. In local port mirroring, packets are forwarded from a source port to a destination port on the same system.

In remote port mirroring, mirrored packets are forwarded using a dedicated L2 VLAN.

User application can provision mirroring capabilities using the CPS API:

  • Create a mirroring session
  • Update a mirroring session
  • Delete a mirroring session

See Programming examples for information on how to program port mirroring using the CPS API.

NOTE: OPX does not support Linux modeling of port mirroring.

SFlow

sFlow monitors network traffic by sampling incoming and outgoing packets on physical ports. User applications can provision sFlow functionality using the CPS API:

  • Enable packet sampling on a physical port
  • Disable packet sampling on a physical port
  • Set the sampling interval rate
  • Forward the sampled packet to an IP address/port

See Programming examples for information on how to program sFlow using the CPS API.

NOTE: OPX does not support Linux modeling of sFlow.

Statistics

Use the base-show-stats and base-ethtool commands to display statistical information about ports/VLANs, and installed transceivers.

Command Description
base-show-stats if_stat [_iface_name_] {filter_list} Displays port statistics for all (or a specified) Linux interfaces which map to physical ports. Enter a filter_list value.
base-show-stats vlan_stat [_vlan_ifname_] {filter_list} Displays statistics from all (or a specified) VLANs. Enter a filter_list value to display specified statistics.
base-show-stats clear [_iface_name_] Deletes port statistics for all (or a specified) Linux interfaces. The base-show-stats command does not support deleting VLAN statistics.
`base-ethtool [-v -e

View statistics for Linux interface e101-001-0

$ base-show-stats if_stat e101-001-0

Key:
base-stats/interface/ip/in-discards = 0
base-stats/interface/ether-octets = 13442942147
base-stats/interface/ether-out/pkts-64-octets = 0
base-stats/interface/ether-collisions = 0
...
base-stats/interface/if-in-multicast-pkts = 0
base-stats/interface/ether-in/pkts-64-octets = 0
base-stats/interface/ether-in/pkts-512-to-1023-octets = 0

View statistics for VLAN Linux bridge interface Br1

$ base-show-stats vlan_stat br1

Key:
base-stats/vlan/time-stamp:  1455586573
base-stats/vlan/in-octets:  16381983058
base-stats/vlan/in-pkts:  16101053
base-stats/vlan/out-octets:  55146334258
base-stats/vlan/out-pkts:  67419926

Delete statistics for port that maps to e101-001-0

$ base-show-stats clear e101-001-0
Success

View port statistics

$ base-ethtool -S e101-001-0
Statistics for interface e101-001-0
  Ether statistics:
    rx_bytes: 9185614848
    rx_no_errors: 0
    tx_no_errors: 9003181
    tx_total_collision: 0
    rx_undersize_packets: 0
    rx_jabbers: 0
    rx_fragments: 0
    rx_align_errors: 0
    rx_discards: 0
    rx_mcast_packets: 35445

View media (transceiver) statistics for e101-001-0

$ base-ethtool -e e101-001-0
Show media info for e101-001-0
if_index is 17

Key: 2.19.1245389.1245248.1245249.1245250.
base-pas/media/rate-identifier = 0
base-pas/media/oper-status = 0
base-pas/media/category = 3
base-pas/media/voltage-state = 1
base-pas/media/bias-low-warning-threshold =
base-pas/media/vendor-pn = 568400002
base-pas/media/current-temperature = ??
base-pas/media/insertion-cnt = 0
base-pas/media/voltage-low-warning-threshold =
base-pas/media/cc_ext = 162
base-pas/media/length-om2 = 0
base-pas/media/length-om3 = 0
base-pas/media/rx-power-low-alarm-threshold =
base-pas/media/length-om1 = 0

base-pas/media/vendor-id = AP
base-pas/media/media-category/sfp-plus/br-max = 0
base-pas/media/connector = 33
base-pas/media/ext-transceiver = 0
base-pas/media/vendor-Specific =
ffffffffffffff00000000000000000000000000000000000000000000000000
base-pas/media/media-category/sfp-plus/br-min = 0
base-pas/media/encoding = 0
base-pas/media/tx-power-high-warning-threshold =
base-pas/media/vendor-name = Amphenol
base-pas/media/rx-power-low-warning-threshold =
base-pas/media/slot = 1
base-pas/media/port = 1
base-pas/media/vendor-rev = 4700
base-pas/media/slot = 1
base-pas/media/port = 1
base-pas/media/tx-power-low-alarm-threshold =
base-pas/media/bias-low-alarm-threshold =
base-pas/media/capability = 6
base-pas/media/media-category/sfp-plus/sff-8472-compliance = 0
base-pas/media/diag-mon-type = 0
base-pas/media/temp-state = 1
base-pas/media/type = 43
base-pas/media/media-category/qsfp-plus/wavelength-tolerance = 0
base-pas/media/ext-identifier = 0
base-pas/media/temp-low-warning-threshold =
base-pas/media/voltage-high-warning-threshold =
base-pas/media/temp-high-alarm-threshold =
base-pas/media/length-sfm = 0
base-pas/media/rate-select-state = 0
base-pas/media/rx-power-measurement-type = 0
base-pas/media/wavelength = 0
base-pas/media/cc_base = 54
base-pas/media/temp-low-alarm-threshold =
base-pas/media/tx-power-low-warning-threshold =
base-pas/media/insertion-timestamp = 0
base-pas/media/current-voltage =
base-pas/media/bias-high-alarm-threshold =
base-pas/media/high-power-mode = 1
base-pas/media/br-nominal = 0
base-pas/media/options = 0
base-pas/media/rx-power-high-warning-threshold =
base-pas/media/date-code = 3131303632322000
base-pas/media/present = 1
base-pas/media/transceiver = 0000000000000000205c
base-pas/media/length-cable = 2
base-pas/media/voltage-high-alarm-threshold =
base-pas/media/identifier = 12
base-pas/media/voltage-low-alarm-threshold =
base-pas/media/dell-qualified = 0
base-pas/media/length-sfm-km = 0
base-pas/media/rx-power-high-alarm-threshold =
base-pas/media/admin-status = 0
base-pas/media/serial-number = APF11240020140
base-pas/media/tx-power-high-alarm-threshold =
base-pas/media/temp-high-warning-threshold =
base-pas/media/bias-high-warning-threshold =
base-pas/media/enhanced-options = 0
base-pas/media/media-category/qsfp-plus/max-case-temp = 70
Clone this wiki locally