- New and Changed Information
- Preface
- Overview
- Configuring CFS
- Configuring NTP
- Configuring PTP
- Configuring CDP
- Configuring System Message Logging
- Configuring Smart Call Home
- Configuring Rollback
- Configuring Session Manager
- Configuring the Scheduler
- Configuring SNMP
- Configuring RMON
- Configuring Online Diagnostics
- Configuring the Embedded Event Manager
- Configuring Onboard Failure Logging
- Configuring SPAN
- Configuring ERSPAN
- Configuring LLDP
- Configuring NetFlow
- Supported RFCs
- EEM Events and Examples
- Configuration Limits for Cisco NX-OS System Management
Configuring ERSPAN
This chapter describes how to configure an encapsulated remote switched port analyzer (ERSPAN) to transport mirrored traffic in an IP network on Cisco NX-OS devices.
Information About ERSPAN
ERSPAN transports mirrored traffic over an IP network. The traffic is encapsulated at the source router and is transferred across the network. The packet is decapsulated at the destination router and then sent to the destination interface.
ERSPAN consists of an ERSPAN source session, routable ERSPAN generic routing encapsulation (GRE)-encapsulated traffic, and an ERSPAN destination session. You separately configure ERSPAN source sessions and destination sessions on different switches.
This section includes the following topics:
- ERSPAN Sources
- ERSPAN Destinations
- ERSPAN Sessions
- Multiple ERSPAN Sessions
- High Availability
- Virtualization Support
ERSPAN Sources
The interfaces from which traffic can be monitored are called ERSPAN sources. Sources designate the traffic to monitor and whether to copy ingress, egress, or both directions of traffic. ERSPAN sources include the following:
- Ethernet ports and port channels
- The inband interface to the control plane CPU—You can monitor the inband interface only from the default VDC. Inband traffic from all VDCs is monitored.
- VLANs—When a VLAN is specified as an ERSPAN source, all supported interfaces in the VLAN are ERSPAN sources.
- Fabric port channels connected to the Cisco Nexus 2000 Series Fabric Extender
- Satellite ports and host interface port channels on the Cisco Nexus 2000 Series Fabric Extender—
These interfaces are supported in Layer 2 access mode, Layer 2 trunk mode, and Layer 3 mode.
Note
Layer 3 subinterfaces are not supported.
Note
A single ERSPAN session can include mixed sources in any combination of the above.
ERSPAN Destinations
Destination ports receive the copied traffic from ERSPAN sources.
ERSPAN destination ports have the following characteristics:
- Destinations for an ERSPAN session include Ethernet ports or port-channel interfaces in either access or trunk mode.
- A port configured as a destination port cannot also be configured as a source port.
- A destination port can be configured in only one ERSPAN session at a time.
- Destination ports do not participate in any spanning tree instance or any Layer 3 protocols.
- Ingress and ingress learning options are not supported on monitor destination ports.
- F1 Series module core ports, Fabric Extender HIF ports, HIF port channels, and Fabric PO ports are not supported as SPAN destination ports.
ERSPAN Sessions
You can create ERSPAN sessions that designate sources and destinations to monitor.
Note
Only two ERSPAN or SPAN source sessions can run simultaneously across all VDCs. Only 23 ERSPAN destination sessions can run simultaneously across all VDCs.
Figure 19-1 shows an ERSPAN configuration.
Figure 19-1 ERSPAN Configuration
Multiple ERSPAN Sessions
Although you can define up to 48 ERSPAN sessions, only two ERSPAN or SPAN sessions can be running simultaneously. You can shut down an unused ERSPAN session.
For information about shutting down ERSPAN sessions, see the “Shutting Down or Activating an ERSPAN Session” section.
High Availability
The ERSPAN feature supports stateless and stateful restarts. After a reboot or supervisor switchover, the running configuration is applied.
For more information on high availability, see the Cisco Nexus 7000 Series NX-OS High Availability and Redundancy Guide, Release 5.x.
Virtualization Support
A virtual device context (VDC) is a logical representation of a set of system resources. ERSPAN applies only to the VDC where the commands are entered.
Note
You can monitor the inband interface only from the default VDC. Inband traffic from all VDCs is monitored.
For information about configuring VDCs, see the Cisco Nexus 7000 Series NX-OS Virtual Device Context Configuration Guide, Release 5.x.
Licensing Requirements for ERSPAN
The following table shows the licensing requirements for this feature:
Prerequisites for ERSPAN
Guidelines and Limitations
ERSPAN has the following configuration guidelines and limitations:
- For ERSPAN session limits, see the Cisco Nexus 7000 Series NX-OS Verified Scalability Guide.
- All ERSPAN replication is performed in the hardware. The supervisor CPU is not involved.
- ERSPAN and ERSPAN ACLs are not supported on F1 Series modules.
- The encapsulation or decapsulation of generic routing encapsulation (GRE) or ERSPAN packets received on an F1 Series module is not supported.
- ERSPAN and ERSPAN ACLs are not supported for packets generated by the supervisor.
- ERSPAN and ERSPAN ACL sessions are terminated identically at the destination router.
- ERSPAN is not supported for management ports.
- A destination port can be configured in only one ERSPAN session at a time.
- You cannot configure a port as both a source and destination port.
- A single ERSPAN session can include mixed sources in any combination of the following:
–
Ethernet ports or port channels but not subinterfaces
–
VLANs or port channels, which can be assigned to port channel subinterfaces
–
The inband interface or port channels to the control plane CPU
Note
ERSPAN does not monitor any packets that are generated by the supervisor, regardless of their source.
- Destination ports do not participate in any spanning tree instance or Layer 3 protocols.
- When an ERSPAN session contains source ports that are monitored in the transmit or transmit and receive direction, packets that these ports receive may be replicated to the ERSPAN destination port even though the packets are not actually transmitted on the source ports. Some examples of this behavior on source ports include:
–
Traffic that results from flooding
–
Broadcast and multicast traffic
- For VLAN ERSPAN sessions with both ingress and egress configured, two packets (one from ingress and one from egress) are forwarded from the destination port if the packets get switched on the same VLAN.
- VLAN ERSPAN monitors only the traffic that leaves or enters Layer 2 ports in the VLAN.
- You can monitor the inband interface only from the default VDC. Inband traffic from all VDCs is monitored.
- Beginning with Cisco NX-OS Release 5.2, the Cisco Nexus 2000 Series Fabric Extender interfaces and the fabric port channels connected to the Cisco Nexus 2000 Series Fabric Extender can be configured as ERSPAN sources. However, they cannot be configured as ERSPAN destinations.
Note
ERSPAN on Fabric Extender interfaces and fabric port channels is supported on the 32-port, 10-Gigabit M1 and M1 XL modules (N7K-M132XP-12 and N7K-M132XP-12L). ERSPAN runs on the Cisco Nexus 7000 Series device, not on the Fabric Extender.
- ERSPAN is supported on Fabric Extender interfaces in Layer 2 access mode, Layer 2 trunk mode, and Layer 3 mode. Layer 3 subinterfaces are not supported.
- Multicast best effort mode applies only to M1 Series modules.
- If ERSPAN is enabled on a vPC and ERSPAN packets need to be routed to the destination through the vPC, packets coming through the vPC peer-link cannot be captured.
- ERSPAN ACLs are not supported for use with OTV.
Default Settings
Table 19-1 lists the default settings for ERSPAN parameters.
|
|
|
|---|---|
Configuring ERSPAN
This section includes the following topics:
- Configuring an ERSPAN Source Session
- Configuring an ERSPAN Destination Session
- Shutting Down or Activating an ERSPAN Session
- Configuring the Multicast Best Effort Mode for an ERSPAN Session
Configuring an ERSPAN Source Session
You can configure an ERSPAN session on the local device only. By default, ERSPAN sessions are created in the shut state.
For sources, you can specify Ethernet ports, port channels, the supervisor inband interface, and VLANs. A single ERSPAN session can include mixed sources in any combination of Ethernet ports, VLANs, or the inband interface to the control plane CPU.
Note
ERSPAN does not monitor any packets that are generated by the supervisor, regardless of their source.
BEFORE YOU BEGIN
Ensure that you are in the correct VDC. To switch VDCs, use the switchto vdc command. For more information, see the Cisco Nexus 7000 Series NX-OS Virtual Device Context Configuration Guide, Release 5.x.
SUMMARY STEPS
2.
monitor erspan origin ip-address ip-address global
3.
no monitor session { session-number | all }
4.
monitor session { session-number | all } type erspan-source
6.
source {[ interface [ type slot / port [- port ][, type slot / port [- port ]]] [ port-channel channel-number ] | [ vlan { number | range }]} [ rx | tx | both ]
7.
(Optional) Repeat Step 6 to configure all ERSPAN sources.
8.
(Optional) filter vlan { number | range }
9.
(Optional) Repeat Step 8 to configure all source VLANs to filter.
10.
(Optional) filter access-group acl-filter
14.
(Optional) ip ttl ttl-number
15.
(Optional) ip dscp dscp-number
17.
(Optional) show monitor session { all | session-number | range session-range }
18.
(Optional) show running-config monitor
DETAILED STEPS
Configuring an ERSPAN Destination Session
You can configure an ERSPAN destination session to copy packets from a source IP address to destination ports on the local device. By default, ERSPAN destination sessions are created in the shut state.
BEFORE YOU BEGIN
Ensure that you are in the correct VDC (or use the switchto vdc command).
Ensure that you have already configured the destination ports in monitor mode. For more information, see the Cisco Nexus 7000 Series NX-OS Interfaces Configuration Guide, Release 5.x.
SUMMARY STEPS
2.
interface ethernet slot / port [- port ]
4.
switchport mode [access | trunk]
6.
(Optional) Repeat Steps 2 to 5 to configure monitoring on additional ERSPAN destinations.
7.
no monitor session { session-number | all }
8.
monitor session { session-number | all } type erspan-destination
11.
destination {[ interface [ type slot / port [- port ][, type slot / port [- port ]]] | [ port-channel channel-number] ]}
12.
(Optional) Repeat Step 11 to configure all ERSPAN destination ports.
16.
(Optional) show monitor session { all | session-number | range session-range }
17.
(Optional) show running-config monitor
DETAILED STEPS
Shutting Down or Activating an ERSPAN Session
You can shut down ERSPAN sessions to discontinue the copying of packets from sources to destinations. Because only two ERSPAN sessions can be running simultaneously, you can shut down one session in order to free hardware resources to enable another session. By default, ERSPAN sessions are created in the shut state.
You can enable ERSPAN sessions to activate the copying of packets from sources to destinations. To enable an ERSPAN session that is already enabled but operationally down, you must first shut it down and then enable it. You can shut down and enable the ERSPAN session states with either a global or monitor configuration mode command.
BEFORE YOU BEGIN
Ensure that you are in the correct VDC (or use the switchto vdc command).
SUMMARY STEPS
2.
monitor session { session-range | all } shut
3.
no monitor session { session-range | all } shut
4.
monitor session session-number type erspan-source
5.
monitor session session-number type erspan-destination
8.
(Optional) show monitor session all
9.
(Optional) show running-config monitor
DETAILED STEPS
Configuring the Multicast Best Effort Mode for an ERSPAN Session
You can configure the multicast best effort mode for any ERSPAN session. By default, ERSPAN replication occurs on both the ingress and egress line card. When you enable the multicast best effort mode, ERSPAN replication occurs only on the ingress line card for multicast traffic or on the egress line card for packets egressing out of Layer 3 interfaces (that is, on the egress line card, packets egressing out of Layer 2 interfaces are not replicated for ERSPAN).
BEFORE YOU BEGIN
Ensure that you are in the correct VDC (or use the switchto vdc command).
SUMMARY STEPS
2.
monitor session session-number
DETAILED STEPS
Verifying the ERSPAN Configuration
To display the ERSPAN configuration, perform one of the following tasks:
|
|
|
|---|---|
show monitor session { all | session-number | range session-range } |
|
For detailed information about the fields in the output from these commands, see the Cisco Nexus 7000 Series NX-OS System Management Command Reference.
Configuration Examples for ERSPAN
This section includes the following topics:
- Configuration Example for an ERSPAN Source Session
- Configuration Example for an ERSPAN Destination Session
- Configuration Example for an ERSPAN ACL
- Configuration Example for ERSPAN Using the Multicast Best Effort Mode
Configuration Example for an ERSPAN Source Session
This example shows how to configure an ERSPAN source session:
Configuration Example for an ERSPAN Destination Session
This example shows how to configure an ERSPAN destination session:
Configuration Example for an ERSPAN ACL
This example shows how to configure an ERSPAN ACL:
Configuration Example for ERSPAN Using the Multicast Best Effort Mode
This example shows how to configure the multicast best effort mode for an ERSPAN session:
Additional References
For additional information related to implementing ERSPAN, see the following sections:
Related Documents
Standards
|
|
|
|---|---|
No new or modified standards are supported by this feature, and support for existing standards has not been modified by this feature. |
Feature History for ERSPAN
Table 19-2 lists the release history for this feature.
Feedback