Skip to main content

SPAN/Port Mirror Configuration Reference


Cisco​

IOS / IOS XE​

  1. Enter Configuration Mode:

    Switch# configure terminal
  2. Define the Monitor Session Number and Input (Source):

    Switch(config)# monitor session <SESSION_NUMBER> source [interface <INTERFACE_NAME> | vlan <VLAN_ID>] both
  3. Specify the Output (Destination) Interface:

    Switch(config)# monitor session <SESSION_NUMBER> destination interface <INTERFACE_NAME>
  4. Save the Configuration:

    Switch(config)# end
    Switch# copy running-config startup-config

NX-OS​

  1. Enter Configuration Mode:

    switch# configure terminal
  2. Define the Monitor Session Number and Input (Source):

    switch(config)# monitor session <SESSION_NUMBER> type local
    switch(config-monitor)# source [interface <INTERFACE_NAME> | vlan <VLAN_ID>] <INTERFACE_NAME> both
  3. Specify the Output (Destination) Interface:

    switch(config-monitor)# destination interface <INTERFACE_NAME>
  4. Save the Configuration:

    switch(config-monitor)# no shut
    switch(config-monitor)# exit
    switch(config)# exit
    switch# copy running-config startup-config

Juniper​

Junos OS​

  1. Enter Configuration Mode:

    user@device> configure
  2. Define the Analyzer Name and Input (Source):

    user@device# set forwarding-options analyzer <ANALYZER_NAME> input ingress interface [<INTERFACE_NAME> | vlan.<VLAN_ID>]
    user@device# set forwarding-options analyzer <ANALYZER_NAME> input egress interface [<INTERFACE_NAME> | vlan.<VLAN_ID>]
  3. Specify the Output (Destination) Interface:

    user@device# set forwarding-options analyzer <ANALYZER_NAME> output interface <INTERFACE_NAME>
  4. Commit the Configuration:

    user@device# commit

Dell​

Dell Networking OS (DNOS)​

  1. Enter Configuration Mode:

    switch# configure
  2. Create the SPAN Session:

    switch(config)# monitor session <SESSION_NUMBER>
    switch(config-mon)# source interface <INTERFACE_NAME> both
  3. Specify the Destination Port:

    switch(config-mon)# destination interface <INTERFACE_NAME>
  4. Activate the Session (if necessary):

    switch(config-mon)# no shutdown
  5. Exit and Save Configuration:

    switch(config-mon)# end
    switch# write memory

Dell PowerConnect OS​

  1. Enter Configuration Mode:

    switch# configure
  2. Define the Source Port:

    switch(config)# mirror <SOURCE_INTERFACE>
  3. Define the Destination Port:

    switch(config)# ethernet <DESTINATION_INTERFACE>
    switch(config-if)# port monitor <SOURCE_INTERFACE>
  4. Save the Configuration:

    switch(config)# exit
    switch# write memory

Dell EMC OS10​

  1. Enter Configuration Mode:

    switch# configure terminal
  2. Create the SPAN Session:

    switch(config)# monitor session <SESSION_NUMBER> type local
    switch(config-monitor)# source [interface <INTERFACE_NAME> | vlan <VLAN_ID>] both
  3. Specify the Destination Port:

    switch(config-monitor)# destination interface <INTERFACE_NAME>
  4. Activate the Session (if necessary):

    switch(config-monitor)# no shutdown
  5. Exit and Save Configuration:

    switch(config-monitor)# end
    switch# write memory

HP​

HP ProVision (ArubaOS-Switch)​

  1. Enter Configuration Mode:

    switch# configure terminal
  2. Define the Source Port:

    switch(config)# mirror-port <SOURCE_INTERFACE>
  3. Define the Destination Port:

    switch(config)# interface <DESTINATION_INTERFACE>
    switch(eth-<DESTINATION_INTERFACE>)# monitor
  4. Save the Configuration:

    switch(config)# write memory

HP Comware​

  1. Enter System View:

    <HP> system-view
  2. Create a Local Mirroring Group:

    [HP] mirroring-group <GROUP_NUMBER> local
  3. Add Sources to the Mirroring Group:

    • Interfaces:

      [HP] interface <SOURCE_INTERFACE>
      [HP-if] port-mirroring to interface <DESTINATION_INTERFACE> both
    • VLANs:

      [HP] mirroring-group <GROUP_NUMBER> vlan <VLAN_ID> both
  4. Specify the Mirroring Group's Destination Port:

    [HP] mirroring-group <GROUP_NUMBER> mirroring-port <DESTINATION_INTERFACE>
  5. Save the Configuration:

    [HP] save