|
This section provides reference information for the following voice VLAN commands:
The interface range command allows you to configure multiple interfaces with the same configuration parameters. By using this command, you enter range configuration mode. While you are in this mode, the command parameters that you enter are attributed to all interfaces within the range specified.
interface range {{ethernet | fastethernet} slot/interface - interface}
[, {{ethernet | fastethernet} slot/interface - interface}]
The space before the dash is required. You can enter up to five comma-separated ranges. You are not required to enter spaces before or after the comma.
If you enter multiple configuration commands while you are in interface range mode, each command is executed as it is entered. If you exit interface range configuration mode while the commands are being executed, some commands may not be executed on all interfaces in the range. Wait until the command prompt reappears before exiting interface range configuration mode.
The following example shows how to select the Fast Ethernet interfaces 5/1 to 5/5:
Use the interface vlan configuration command to configure an interface type, create a switch virtual interface to be used as the routed VLAN interface, and to enter interface configuration mode.
Valid VLAN IDs are from 1 to 1005. Do not enter leading zeroes.
The default management VLAN interface is VLAN 1.
To enable inter-VLAN routing, configure an interface VLAN with a VLAN number.
The following example shows how to enter configuration mode for vlan 3:
Use the monitor session configuration command to set a port session.
monitor session number destination_interface
monitor session number source_interface
You can span only selected interfaces. You cannot span VLANs.
The following example shows how to set up a port monitor session. For this example, we configure two sessions in global configuration mode.
In session 1, int Fas 5/2 will mirror all of its packets to 5/9:
In session 2, int fas 5/3 will mirror all of its packets to 5/13:
You can sees what is being mirrored by entering the show monitor session command in privileged EXEC mode:
Use the spanning-tree global configuration command to enable Spanning Tree Protocol (STP) on a VLAN. Use the no form of the command to disable STP on a VLAN.
no spanning-tree [vlan stp-list]
(Optional) List of spanning-tree instances. Each spanning-tree instance is associated with a VLAN ID. Valid IDs are from 1 to 1005. Enter each VLAN ID separated by a space. Do not enter leading zeroes. Ranges are not supported.
Disabling STP causes the VLAN or list of VLANs to stop participating in STP. Ports that are administratively down remain down. Received Bridge Protocol Data Units (BPDUs) are forwarded like other multicast frames. The VLAN does not detect and prevent loops when STP is disabled.
You can disable STP on a VLAN that is not currently active, and verify the change by using the privileged EXEC show running-config or the show spanning-tree vlan stp-list command. The setting takes effect when the VLAN is activated.
If the variable stp-list is omitted, the command applies to the STP instance associated with VLAN 1.
You can enable STP on a VLAN that has no ports assigned to it.
The following example shows how to disable STP on VLAN 5:
You can verify the previous command by entering the show spanning-tree command in privileged EXEC mode. In this instance, VLAN 5 does not appear in the list.
Use the spanning-tree portfast interface configuration command to enable the Port Fast feature on a port in all its associated VLANs. When the Port Fast feature is enabled, the port changes directly from a blocking state to a forwarding state without making the intermediate STP status changes. Use the no form of this command to return the port to default operation.
This command has no keywords or arguments.
The Port Fast feature is disabled; however, it is automatically enabled on dynamic-access ports.
This feature should be used only on ports that connect to end stations. It affects all VLANs on the port.
A port with the Port Fast feature enabled is moved directly to the spanning-tree forwarding state.
The following example shows how to enable the Port Fast feature on fixed port 2.
You can verify the previous command by entering the show running-config in privilege EXEC mode.
Use the switchport access interface configuration command to configure a port as a static-access port. The port operates as a member of the configured VLAN.
Use the no form of this command to reset the access mode to the default VLAN for the switch.
switchport access vlan vlan-id
no switchport access vlan vlan-id
ID of the VLAN. Valid IDs are from 1 to 1005. Do not enter leading zeroes.
All ports are in static-access mode in VLAN 1.
An access port can be assigned to only one VLAN.
When the no switchport access vlan form is used, the access mode is reset to static access on VLAN 1.
The following example shows how to assign a port to VLAN 2 (instead of the default VLAN 1):
You can verify the previous command by entering the show interface interface-id switchport command in privileged EXEC mode and examining information in the Administrative Mode and Operational Mode rows.
Use the switchport voice vlan interface configuration command to configure the voice VLAN on the port. Use the no form of this command to return the setting to its default.
switchport voice vlan {vlan-id | dot1p | none | untagged}
VLAN used for voice traffic. Valid IDs are from 1 to 1001 (IDs 1002 to 4095 are not supported on Catalyst 4224 switches).
The telephone uses priority tagging and uses an 802.1Q VLAN ID of 0.
The telephone is not instructed through the CLI about the voice VLAN.
The telephone uses the configuration from the telephone key pad.
The telephone does not tag frames. The switch port can be an access port or an 802.1Q trunk port.
The switch default is not to configure the telephone automatically (none).
The Cisco 7960 IP Phone default is to generate an 802.1Q/802.1P frame.
Ports that are not configured as trunk ports but have a configured voice VLAN are access ports with a voice VLAN ID (VVID).
The following example shows how to configure VLAN 2 as the voice VLAN:
You can verify the previous command by entering the show interface interface-id switchport command in privileged EXEC mode.
Posted: Sat Apr 5 04:04:17 PST 2003
All contents are Copyright © 1992--2002 Cisco Systems, Inc. All rights reserved.
Important Notices and Privacy Statement.