How to set up port spanning on HP devices
From Netmon
Contents |
Port Spanning on HP 2500 series Switches
You must use the following configuration sequence to configure port spanning in the CLI:
- Assign a span (mirror) port.
- Designate the port(s) and/or a VLAN to monitor.
Displaying the Port Monitoring Configuration.
This command lists the port assigned to receive monitored traffic and the ports being monitored.
show mirror-port
Configuring the Monitor Port.
This command assigns or removes a monitoring port, and must be executed from the global configuration level. Removing the monitor port disables port monitoring and resets the monitoring parameters to factory default.
[no] mirror-port [<port-num>]
For example, to assign port 12 as the monitoring port:
HP2512(config)# mirror-port 12
To turn off port monitoring:
HP2512(config)# no mirror-port
Selecting or Removing Ports or VLANs As Monitoring Sources.
After you configure a monitor port you can use either the global configuration level or the interface context level to select ports or VLANs as monitoring sources. You can also use either level to remove monitoring sources.
[no] monitor [vlan <vlan-id> | interface ethernet <port-list>]
For example, with a monitoring port configured as above, you could select ports 1 and 2 for monitoring:
HP2512(config)# int e 1,2 monitor
Alternately, you could select a VLAN to monitor:
HP2512(config)# vlan 1 monitor
To turn off monitoring for a particular port without turning off monitoring altogether:
HP2512(config)# no int e 1,2 monitor
Navigation
