Cisco ConfiguratioGuide SW4500 IOS
Cisco ConfiguratioGuide SW4500 IOS
Corporate Headquarters
Cisco Systems, Inc.
170 West Tasman Drive
San Jose, CA 95134-1706
USA
http://www.cisco.com
Tel: 408 526-4000
800 553-NETS (6387)
Fax: 408 526-4100
THE SPECIFICATIONS AND INFORMATION REGARDING THE PRODUCTS IN THIS MANUAL ARE SUBJECT TO CHANGE WITHOUT NOTICE. ALL
STATEMENTS, INFORMATION, AND RECOMMENDATIONS IN THIS MANUAL ARE BELIEVED TO BE ACCURATE BUT ARE PRESENTED WITHOUT
WARRANTY OF ANY KIND, EXPRESS OR IMPLIED. USERS MUST TAKE FULL RESPONSIBILITY FOR THEIR APPLICATION OF ANY PRODUCTS.
THE SOFTWARE LICENSE AND LIMITED WARRANTY FOR THE ACCOMPANYING PRODUCT ARE SET FORTH IN THE INFORMATION PACKET THAT
SHIPPED WITH THE PRODUCT AND ARE INCORPORATED HEREIN BY THIS REFERENCE. IF YOU ARE UNABLE TO LOCATE THE SOFTWARE LICENSE
OR LIMITED WARRANTY, CONTACT YOUR CISCO REPRESENTATIVE FOR A COPY.
The Cisco implementation of TCP header compression is an adaptation of a program developed by the University of California, Berkeley (UCB) as part of UCBs public
domain version of the UNIX operating system. All rights reserved. Copyright 1981, Regents of the University of California.
NOTWITHSTANDING ANY OTHER WARRANTY HEREIN, ALL DOCUMENT FILES AND SOFTWARE OF THESE SUPPLIERS ARE PROVIDED AS IS WITH
ALL FAULTS. CISCO AND THE ABOVE-NAMED SUPPLIERS DISCLAIM ALL WARRANTIES, EXPRESSED OR IMPLIED, INCLUDING, WITHOUT
LIMITATION, THOSE OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OR ARISING FROM A COURSE OF
DEALING, USAGE, OR TRADE PRACTICE.
IN NO EVENT SHALL CISCO OR ITS SUPPLIERS BE LIABLE FOR ANY INDIRECT, SPECIAL, CONSEQUENTIAL, OR INCIDENTAL DAMAGES, INCLUDING,
WITHOUT LIMITATION, LOST PROFITS OR LOSS OR DAMAGE TO DATA ARISING OUT OF THE USE OR INABILITY TO USE THIS MANUAL, EVEN IF CISCO
OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
CCSP, the Cisco Square Bridge logo, Follow Me Browsing, and StackWise are trademarks of Cisco Systems, Inc.; Changing the Way We Work, Live, Play, and Learn, and
iQuick Study are service marks of Cisco Systems, Inc.; and Access Registrar, Aironet, ASIST, BPX, Catalyst, CCDA, CCDP, CCIE, CCIP, CCNA, CCNP, Cisco, the Cisco
Certified Internetwork Expert logo, Cisco IOS, Cisco Press, Cisco Systems, Cisco Systems Capital, the Cisco Systems logo, Cisco Unity, Empowering the Internet Generation,
Enterprise/Solver, EtherChannel, EtherFast, EtherSwitch, Fast Step, FormShare, GigaDrive, GigaStack, HomeLink, Internet Quotient, IOS, IP/TV, iQ Expertise, the iQ logo,
iQ Net Readiness Scorecard, LightStream, Linksys, MeetingPlace, MGX, the Networkers logo, Networking Academy, Network Registrar, Packet, PIX, Post-Routing,
Pre-Routing, ProConnect, RateMUX, ScriptShare, SlideCast, SMARTnet, StrataView Plus, SwitchProbe, TeleRouter, The Fastest Way to Increase Your Internet Quotient,
TransPath, and VCO are registered trademarks of Cisco Systems, Inc. and/or its affiliates in the United States and certain other countries.
All other trademarks mentioned in this document or Website are the property of their respective owners. The use of the word partner does not imply a partnership relationship
between Cisco and any other company. (0411R)
Catalyst 4500 Series Switch Cisco IOS Software Configuration Guide
Copyright 19992004 Cisco Systems, Inc. All rights reserved.
C O N T E N T S
Preface
xxi
Audience
xxi
Organization
xxi
Related Documentation
xxiii
Conventions xxiv
Commands in Task Tables
xxv
xxvi
CHAPTER
Product Overview
xxvii
1-1
1-2
1-6
iii
Contents
HSRP 1-6
IP Routing Protocols 1-6
Multicast Services 1-9
Network Security with ACLs 1-9
Policy-Based Routing 1-10
Unidirectional Link Routing 1-10
VRF-lite 1-10
QoS Features
1-10
CHAPTER
Command-Line Interfaces
1-11
2-1
2-3
2-3
CHAPTER
2-4
2-5
2-6
2-1
3-1
3-1
3-2
3-10
iv
OL-6696-01
Contents
3-15
3-18
CHAPTER
Configuring Interfaces
4-1
4-1
4-2
4-4
4-5
4-7
4-13
CHAPTER
5-1
5-1
5-2
5-3
5-3
5-4
5-4
5-5
Software Configuration GuideRelease 12.2(25)EW
OL-6696-01
Contents
Running Ping
5-6
5-7
CHAPTER
5-10
6-1
6-2
6-3
6-7
6-10
6-11
6-12
CHAPTER
6-14
7-1
7-2
7-4
vi
OL-6696-01
Contents
CHAPTER
CHAPTER
7-15
8-3
9-1
9-13
CHAPTER
10
10-1
10-1
10-4
vii
Contents
CHAPTER
11
11-1
CHAPTER
12
11-9
12-1
12-1
12-4
12-5
CHAPTER
13
13-1
13-1
CHAPTER
14
13-8
14-1
viii
OL-6696-01
Contents
14-6
CHAPTER
15
15-1
15-2
15-2
Overview of PortFast
15-3
15-4
15-5
Overview of BackboneFast
Enabling Root Guard
15-8
15-9
Enabling PortFast
15-6
15-11
15-12
15-4
15-12
15-14
Enabling BackboneFast
15-15
ix
Contents
CHAPTER
16
16-1
16-8
CHAPTER
17
17-1
17-2
17-5
CHAPTER
18
18-1
18-4
OL-6696-01
Contents
CHAPTER
19
18-19
18-20
18-15
19-1
19-1
19-7
CHAPTER
20
20-1
Configuring CDP
20-2
19-12
20-1
xi
Contents
CHAPTER
21
Configuring UDLD
Overview of UDLD
21-1
21-1
21-2
CHAPTER
CHAPTER
22
23
22-1
22-1
22-1
23-1
23-3
CHAPTER
24
23-4
24-1
23-3
24-2
24-3
24-6
xii
OL-6696-01
Contents
24-7
CHAPTER
25
25-1
25-4
25-13
CHAPTER
26
26-1
26-3
26-5
xiii
Contents
CHAPTER
27
26-6
27-1
27-5
27-5
CHAPTER
28
Configuring VRF-lite
28-1
Understanding VRF-lite
28-2
28-3
28-4
28-5
28-5
28-6
CHAPTER
29
Configuring QoS
28-11
29-1
xiv
OL-6696-01
Contents
29-15
CHAPTER
30
30-1
30-1
CHAPTER
31
30-2
30-2
30-3
30-4
31-1
31-1
xv
Contents
CHAPTER
32
31-22
32-1
32-1
32-3
32-3
CHAPTER
33
32-4
32-7
33-1
33-2
33-3
xvi
OL-6696-01
Contents
33-10
34
33-12
33-13
CHAPTER
33-10
33-14
34-1
CHAPTER
35
35-1
35-2
35-5
35-6
35-8
xvii
Contents
35-8
35-11
35-11
35-19
35-20
CHAPTER
36
35-26
36-1
36-2
CHAPTER
37
37-1
37-1
xviii
OL-6696-01
Contents
CHAPTER
38
38-1
38-3
38-4
38-4
CHAPTER
39
38-7
39-1
39-10
Encapsulation Configuration
Ingress Packets
39-12
39-12
39-14
39-15
xix
Contents
CHAPTER
40
39-19
39-24
40-1
Acronyms
40-9
40-11
APPENDIX
40-5
40-14
A-1
INDEX
xx
OL-6696-01
Preface
This preface describes who should read this document, how it is organized, and its conventions. The
preface also tells you how to obtain Cisco documents, as well as how to obtain technical assistance.
Audience
This guide is for experienced network administrators who are responsible for configuring and
maintaining Catalyst 4500 series switches.
Organization
This guide is organized into the following chapters:
Chapter
Title
Description
Chapter 1
Product Overview
Chapter 2
Command-Line Interfaces
Chapter 3
Chapter 4
Configuring Interfaces
Chapter 5
Chapter 6
Chapter 7
Chapter 8
Chapter 9
xxi
Preface
Organization
Chapter
Title
Description
Chapter 10
Chapter 11
Chapter 12
Chapter 13
Chapter 14
Understanding and
Configuring STP
Chapter 15
Chapter 16
Chapter 17
Chapter 18
Chapter 19
Chapter 20
Chapter 21
Configuring UDLD
Chapter 22
Configuring Unidirectional
Ethernet
Chapter 23
Chapter 24
Chapter 25
Chapter 26
Configuring Policy-Based
Routing
Chapter 27
Chapter 28
Configuring VRF-lite
Chapter 29
Configuring QoS
Chapter 30
xxii
OL-6696-01
Preface
Related Documentation
Chapter
Title
Description
Chapter 31
Chapter 32
Chapter 33
Configuring DHCP Snooping and Describes how to configure DHCP snooping and IP
IP Source Guard
Source Guard
Chapter 34
Chapter 35
Chapter 36
Chapter 37
Chapter 38
Chapter 39
Chapter 40
Appendix A Acronyms
Related Documentation
The following publications are available for the Catalyst 4500 series switches:
Cisco IOS configuration guides and command referencesUse these publications to help you
configure Cisco IOS software features not described in the preceding publications:
Configuration Fundamentals Configuration Guide
Configuration Fundamentals Command Reference
Interface Configuration Guide
Interface Command Reference
Network Protocols Configuration Guide, Part 1, 2, and 3
Network Protocols Command Reference, Part 1, 2, and 3
Security Configuration Guide
Security Command Reference
xxiii
Preface
Conventions
Conventions
This document uses the following typographical conventions:
Convention
Description
boldface font
italic font
[ ]
{x|y|z}
[x|y|z]
string
A nonquoted set of characters. Do not use quotation marks around the string
because the string will include the quotation marks.
screen
font
boldface screen
screen
font.
font
italic screen
font
Arguments for which you supply values are in italic screen font.
This pointer highlights an important line of text in an example.
< >
Note
Means reader take note. Notes contain helpful suggestions or references to material not covered in the
publication.
xxiv
OL-6696-01
Preface
Obtaining Documentation
Caution
Means reader be careful. In this situation, you might do something that could result in equipment
damage or loss of data.
Obtaining Documentation
Cisco documentation and additional literature are available on Cisco.com. Cisco also provides several
ways to obtain technical assistance and other technical resources. These sections explain how to obtain
technical information from Cisco Systems.
Cisco.com
You can access the most current Cisco documentation at this URL:
http://www.cisco.com/univercd/home/home.htm
You can access the Cisco website at this URL:
http://www.cisco.com
You can access international Cisco websites at this URL:
http://www.cisco.com/public/countries_languages.shtml
Ordering Documentation
You can find instructions for ordering documentation at this URL:
http://www.cisco.com/univercd/cc/td/doc/es_inpck/pdi.htm
You can order Cisco documentation in these ways:
Registered Cisco.com users (Cisco direct customers) can order Cisco product documentation from
the Ordering tool:
http://www.cisco.com/en/US/partner/ordering/index.shtml
Nonregistered Cisco.com users can order documentation through a local account representative by
calling Cisco Systems Corporate Headquarters (California, USA) at 408 526-7208 or, elsewhere in
North America, by calling 1 800 553-NETS (6387).
xxv
Preface
Documentation Feedback
Documentation Feedback
You can send comments about technical documentation to [email protected].
You can submit comments by using the response card (if present) behind the front cover of your
document or by writing to the following address:
Cisco Systems
Attn: Customer Document Ordering
170 West Tasman Drive
San Jose, CA 95134-9883
We appreciate your comments.
Note
Use the Cisco Product Identification (CPI) tool to locate your product serial number before submitting
a web or phone request for service. You can access the CPI tool from the Cisco Technical Support
Website by clicking the Tools & Resources link under Documentation & Tools. Choose Cisco Product
Identification Tool from the Alphabetical Index drop-down list, or click the Cisco Product
Identification Tool link under Alerts & RMAs. The CPI tool offers three search options: by product ID
or model name; by tree view; or for certain products, by copying and pasting show command output.
Search results show an illustration of your product with the serial number label location highlighted.
Locate the serial number label on your product and record the information before placing a service call.
xxvi
OL-6696-01
Preface
Obtaining Additional Publications and Information
Cisco Marketplace provides a variety of Cisco books, reference guides, and logo merchandise. Visit
Cisco Marketplace, the company store, at this URL:
http://www.cisco.com/go/marketplace/
The Cisco Product Catalog describes the networking products offered by Cisco Systems, as well as
ordering and customer support services. Access the Cisco Product Catalog at this URL:
http://cisco.com/univercd/cc/td/doc/pcat/
xxvii
Preface
Obtaining Additional Publications and Information
Cisco Press publishes a wide range of general networking, training and certification titles. Both new
and experienced users will benefit from these publications. For current Cisco Press titles and other
information, go to Cisco Press at this URL:
http://www.ciscopress.com
Packet magazine is the Cisco Systems technical user magazine for maximizing Internet and
networking investments. Each quarter, Packet delivers coverage of the latest industry trends,
technology breakthroughs, and Cisco products and solutions, as well as network deployment and
troubleshooting tips, configuration examples, customer case studies, certification and training
information, and links to scores of in-depth online resources. You can access Packet magazine at
this URL:
http://www.cisco.com/packet
iQ Magazine is the quarterly publication from Cisco Systems designed to help growing companies
learn how they can use technology to increase revenue, streamline their business, and expand
services. The publication identifies the challenges facing these companies and the technologies to
help solve them, using real-world case studies and business strategies to help readers make sound
technology investment decisions. You can access iQ Magazine at this URL:
http://www.cisco.com/go/iqmagazine
Internet Protocol Journal is a quarterly journal published by Cisco Systems for engineering
professionals involved in designing, developing, and operating public and private internets and
intranets. You can access the Internet Protocol Journal at this URL:
http://www.cisco.com/ipj
World-class networking training is available from Cisco. You can view current offerings at
this URL:
http://www.cisco.com/en/US/learning/index.html
xxviii
OL-6696-01
C H A P T E R
Product Overview
This chapter provides an overview of Catalyst 4500 series switches and includes the following major
sections:
Note
For more information about the chassis, modules, and software features supported by the
Catalyst 4500 series switch, refer to the Release Notes for the Catalyst 4500 Series Switch, Cisco IOS
Release 12.2(25)EW at http://www.cisco.com/univercd/cc/td/doc/product/lan/cat4000/relnotes/
1-1
Chapter 1
Product Overview
Storm Control
Broadcast suppression is used to prevent LANs from being disrupted by a broadcast storm on one or
more switch ports. A LAN broadcast storm occurs when broadcast packets flood the LAN, creating
excessive traffic and degrading network performance. Errors in the protocol-stack implementation or in
the network configuration can cause a broadcast storm. Multicast and broadcast suppression measures
how much broadcast traffic is passing through a port and compares the broadcast traffic with some
configurable threshold value within a specific time interval. If the amount of broadcast traffic reaches
the threshold during this interval, broadcast frames are dropped, and optionally the port is shut down.
For information on configuring broadcast suppression, see Chapter 38, Configuring Port-Based Traffic
Control.
CDP
The Cisco Discovery Protocol (CDP) is a device-discovery protocol that is both media- and
protocol-independent. CDP is available on all Cisco products, including routers, switches, bridges, and
access servers. Using CDP, a device can advertise its existence to other devices and receive information
about other devices on the same LAN. CDP enables Cisco switches and routers to exchange information,
such as their MAC addresses, IP addresses, and outgoing interfaces. CDP runs over the data-link layer
only, allowing two systems that support different network-layer protocols to learn about each other. Each
device configured for CDP sends periodic messages to a multicast address. Each device advertises at
least one address at which it can receive Simple Network Management Protocol (SNMP) messages.
For information on configuring CDP, see Chapter 20, Understanding and Configuring CDP.
DHCP Snooping
Dynamic Host Configuration Protocol (DHCP) snooping is a security feature that is a component of a
DHCP server. DHCP snooping provides security by intercepting untrusted DHCP messages and by
building and maintaining a DHCP snooping binding table. An untrusted message is a message that is
received from outside the network or firewall that can cause traffic attacks within your network.
1-2
OL-6696-01
Chapter 1
Product Overview
Layer 2 Software Features
DHCP snooping acts like a firewall between untrusted hosts and DHCP servers. It also provides a way
to differentiate between untrusted interfaces connected to the end-user and trusted interfaces connected
to the DHCP server or another switch.
For DHCP server configuration information, refer to the chapter, Configuring DHCP, in the Cisco IOS
IP and IP Routing Configuration Guide at the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/ip_c/ipcprt1/1cddhcp.htm
For information on configuring DHCP snooping, see Chapter 33, Configuring DHCP Snooping and IP
Source Guard.
EtherChannel Bundles
EtherChannel port bundles allow you to create high-bandwidth connections between two switches by
grouping multiple ports into a single logical transmission path.
For information on configuring EtherChannel, see Chapter 17, Understanding and Configuring
EtherChannel.
IP Source Guard
Similar to DHCP snooping, this feature is enabled on an untrusted 12 port that is configured for DHCP
snooping. Initially all IP traffic on the port is blocked except for the DHCP packets, which are captured
by the DHCP snooping process. When a client receives a valid IP address from the DHCP server, a
PVACL is installed on the port, which restricts the client IP traffic only to clients with assigned IP
addresses, so any IP traffic with source IP addresses other than those assigned by the DHCP server will
be filtered out. This filtering prevents a malicious host from attacking a network by hijacking neighbor
host's IP address.
For information on configuring IP Source Guard, see Chapter 33, Configuring DHCP Snooping and IP
Source Guard.
Jumbo Frames
The jumbo frames feature allows the switch to forward packets as large as 9216 bytes (larger than the
IEEE Ethernet MTU), rather than declare those frames oversize and discard them. This feature is
typically used for large data transfers. The jumbo feature can be configured on a per-port basis on
Layer 2 and Layer 3 interfaces and is supported only on non-blocking GB front ports.
For information on Jumbo Frames, see Chapter 4, Configuring Interfaces.
Layer 2 Traceroute
The Layer 2 traceroute feature allows the switch to identify the physical path that a packet takes from a
source device to a destination device. Layer 2 traceroute supports only unicast source and destination
MAC addresses.
For information about Layer 2 Traceroute, see Chapter 5, Checking Port Status and Connectivity.
1-3
Chapter 1
Product Overview
MST
IEEE 802.1s Multiple Spanning Tree (MST) allows for multiple spanning tree instances within a single
802.1Q or Inter-Switch Link (ISL) VLAN trunk. MST extends the IEEE 802.1w Rapid Spanning Tree
(RST) algorithm to multiple spanning trees. This extension provides both rapid convergence and load
balancing within a VLAN environment.
MST allows you to build multiple spanning trees over trunks. You can group and associate VLANs to
spanning tree instances. Each instance can have a topology independent of other spanning tree instances.
This new architecture provides multiple forwarding paths for data traffic and enables load balancing.
Network fault tolerance is improved because a failure in one instance (forwarding path) does not affect
other instances (forwarding paths).
For information on configuring MST, see Chapter 16, Understanding and Configuring Multiple
Spanning Trees.
PVRST+
Per-VLAN Rapid Spanning Tree (PVRST+) is the implementation of 802.1w on a per-VLAN basis. It is
the same as PVST+ with respect to STP mode and runs RSTP protocol based on 802.1w.
For information on configuring PVRST+, see Chapter 14, Understanding and Configuring STP.
Spanning tree PortFastPortFast allows a port with a directly attached host to transition to the
forwarding state directly, bypassing the listening and learning states.
Spanning tree BackboneFastBackboneFast reduces the time needed for the spanning tree to
converge after a topology change caused by an indirect link failure. BackboneFast decreases
spanning-tree convergence time for any switch that experiences an indirect link failure.
Spanning tree root guardRoot guard forces a port to become a designated port so that no switch
on the other end of the link can become a root switch.
For information on the STP enhancements, see Chapter 15, Configuring STP Features.
1-4
OL-6696-01
Chapter 1
Product Overview
Layer 2 Software Features
UDLD
The UniDirectional Link Detection (UDLD) protocol allows devices connected through fiber-optic or
copper Ethernet cables to monitor the physical configuration of the cables and detect a unidirectional
link.
For information about UDLD, see Chapter 21, Configuring UDLD.
Unidirectional Ethernet
Unidirectional Ethernet uses only one strand of fiber for either transmitting or receiving one-way traffic
for the Gigaport, instead of two strands of fiber for a full-duplex Gigaport Ethernet.
For information about Unidirectional Ethernet, see Chapter 22, Configuring Unidirectional Ethernet.
VLANs
A VLAN configures switches and routers according to logical, rather than physical, topologies. Using
VLANs, a network administrator can combine any collection of LAN segments within an internetwork
into an autonomous user group, such that the segments appear as a single LAN in the network. VLANs
logically segment the network into different broadcast domains so that packets are switched only
between ports within the VLAN. Typically, a VLAN corresponds to a particular subnet, although not
necessarily.
For more information about VLANs, see Chapter 10, Understanding and Configuring VLANs.
The following VLAN-related features are also supported.
VLAN Trunking Protocol (VTP)VTP maintains VLAN naming consistency and connectivity
between all devices in the VTP management domain. You can have redundancy in a domain by using
multiple VTP servers, through which you can maintain and modify the global VLAN information.
Only a few VTP servers are required in a large network.
For more information about VTP, see Chapter 27, Understanding and Configuring VTP.
Private VLANsPrivate VLANs are sets of ports that have the features of normal VLANs and also
provide some Layer 2 isolation from other ports on the switch.
For information about private VLANs, see Chapter 36, Configuring Private VLANs.
Private VLAN Trunk PortsPrivate VLAN trunk ports allow a secondary port on a private VLAN
to carry multiple secondary VLANs.
Dynamic VLAN MembershipDynamic VLAN Membership allows you to assign switch ports to
VLANs dynamically, based on the source Media Access Control (MAC) address of the device
connected to the port. When you move a host from a port on one switch in the network to a port on
another switch in the network, that switch dynamically assigns the new port to the proper VLAN for
that host. With the VMPS Client feature, you can convert a dynamic access port to a VMPS client.
VMPS clients can use VQP queries to communicate with the VMPS server to obtain a VLAN
assignment for the port based on the MAC address of the host attached to that port. For more
information about Dynamic VLAN Membership, see Chapter 11, Configuring Dynamic VLAN
Membership.
1-5
Chapter 1
Product Overview
CEF
Cisco Express Forwarding (CEF) is an advanced Layer 3 IP-switching technology. CEF optimizes
network performance and scalability in networks with large and dynamic traffic patterns, such as the
Internet, and on networks that use intensive web-based applications or interactive sessions. Although
you can use CEF in any part of a network, it is designed for high-performance, highly resilient Layer 3
IP-backbone switching.
For information on configuring CEF, see Chapter 24, Configuring Cisco Express Forwarding.
HSRP
The Hot Standby Router Protocol (HSRP) provides high network availability by routing IP traffic from
hosts on Ethernet networks without relying on the availability of any single Layer 3 switch. This feature
is particularly useful for hosts that do not support a router discovery protocol and do not have the
functionality to switch to a new router when their selected router reloads or loses power.
For information on configuring HSRP, refer to the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/ip_c/ipcprt1/1cdip.htm
IP Routing Protocols
The following routing protocols are supported on the Catalyst 4500 series switch:
RIP
OSPF
IS-IS
1-6
OL-6696-01
Chapter 1
Product Overview
Layer 3 Software Features
IGRP
EIGRP
BGP
RIP
The Routing Information Protocol (RIP) is a distance-vector, intradomain routing protocol. RIP works
well in small, homogeneous networks. In large, complex internetworks, it has many limitations, such as
a maximum hop count of 15, lack of support for variable-length subnet masks (VLSMs), inefficient use
of bandwidth, and slow convergence. RIP II does support VLSMs.
OSPF
The Open Shortest Path First (OSPF) protocol is a standards-based IP routing protocol designed to
overcome the limitations of RIP. Because OSPF is a link-state routing protocol, it sends link-state
advertisements (LSAs) to all other routers within the same hierarchical area. Information on the attached
interfaces and their metrics is used in OSPF LSAs. As routers accumulate link-state information, they
use the shortest path first (SPF) algorithm to calculate the shortest path to each node. Additional OSPF
features include equal-cost multipath routing and routing based on the upper-layer type of service (ToS)
requests.
OSPF employs the concept of an area, which is a group of contiguous OSPF networks and hosts. OSPF
areas are logical subdivisions of OSPF autonomous systems in which the internal topology is hidden
from routers outside the area. Areas allow an additional level of hierarchy different from that provided
by IP network classes, and they can be used to aggregate routing information and mask the details of a
network. These features make OSPF particularly scalable for large networks.
IS-IS
The Intermediate System-to-Intermediate System Protocol (IS-IS Protocol) uses a link-state routing
algorithm. It closely follows the Open Shortest Path First (OSPF) routing protocol used within the
TCP/IP environment. The operation of ISO IS-IS Protocol requires each router to maintain a full
topology map of the network (that is, which intermediate systems and end systems are connected to
which other intermediate systems and end systems). Periodically, the router runs an algorithm over its
map to calculate the shortest path to all possible destinations.
The IS-IS Protocol uses a two-level hierarchy. Intermediate Systems (or routers) are classified as Level
1 and Level 2. Level 1 intermediate systems deal with a single routing area. Traffic is relayed only within
that area. Any other internetwork traffic is sent to the nearest Level 2 intermediate systems, which also
acts as a Level 1 intermediate systems. Level 2 intermediate systems move traffic between different
routing areas within the same domain.
An IS-IS with multi-area support allows multiple Level 1 areas within in a single intermediate system,
thus allowing an intermediate system to be in multiple areas. A single Level 2 area is used as backbone
for inter-area traffic.
Only Ethernet frames are supported. The IS-IS Protocol does not support IPX.
1-7
Chapter 1
Product Overview
IGRP
The Interior Gateway Routing Protocol (IGRP) is a robust distance-vector Interior Gateway Protocol
(IGP) developed by Cisco to provide for routing within an autonomous system (AS). Distance vector
routing protocols request that a switch send all or a portion of its routing table data in a routing update
message at regular intervals to each of its neighboring routers. As routing information proliferates
through the network, routers can calculate distances to all nodes within the internetwork. IGRP uses a
combination of metrics: internetwork delay, bandwidth, reliability, and load are all factored into the
routing decision.
EIGRP
The Enhanced Interior Gateway Routing Protocol (EIGRP) is a version of IGRP that combines the
advantages of link-state protocols with distance-vector protocols. EIGRP incorporates the Diffusing
Update Algorithm (DUAL). EIGRP includes fast convergence, variable-length subnet masks, partially
bounded updates, and multiple network-layer support. When a network topology change occurs, EIGRP
checks its topology table for a suitable new route to the destination. If such a route exists in the table,
EIGRP updates the routing table instantly. You can use the fast convergence and partial updates that
EIGRP provides to route Internetwork Packet Exchange (IPX) packets.
EIGRP saves bandwidth by sending routing updates only when routing information changes. The
updates contain information only about the link that changed, not the entire routing table. EIGRP also
takes into consideration the available bandwidth when determining the rate at which it transmits updates.
Note
Layer 3 switching does not support the Next Hop Resolution Protocol (NHRP).
BGP
The Border Gateway Protocol (BGP) is an exterior gateway protocol that allows you to set up an
interdomain routing system to automatically guarantee the loop-free exchange of routing information
between autonomous systems. In BGP, each route consists of a network number, a list of autonomous
systems that information has passed through (called the autonomous system path), and a list of other path
attributes.
The Catalyst 4500 series switch supports BGP version 4, including classless interdomain routing
(CIDR). CIDR lets you reduce the size of your routing tables by creating aggregate routes, resulting in
supernets. CIDR eliminates the concept of network classes within BGP and supports the advertising of
IP prefixes. CIDR routes can be carried by OSPF, EIGRP, and RIP.
For BGP configuration information, refer to the chapter Configuring BGP in the Cisco IOS IP and IP
Routing Configuration Guide at the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/ip_c/ipcprt2/1cdbgp.htm
For a complete description of the BGP commands, refer to the chapter BGP Commands in the
Cisco IOS IP and IP Routing Command Reference at the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/ip_r/iprprt2/1rdbgp.htm
1-8
OL-6696-01
Chapter 1
Product Overview
Layer 3 Software Features
Multicast Services
Multicast services save bandwidth by forcing the network to replicate packets only when necessary and
by allowing hosts to join and leave groups dynamically. The following multicast services are supported:
Cisco Group Management Protocol (CGMP) serverCGMP server manages multicast traffic.
Multicast traffic is forwarded only to ports with attached hosts that request the multicast traffic.
MAC address filtering, which enables you to block unicast traffic for a MAC address on a VLAN
interface.
Port ACLs, which enable you to apply ACLs to Layer 2 interfaces on a switch for inbound traffic.
For information on ACLs, MACLs, VLAN maps, MAC address filtering, and Port ACLs, see
Chapter 35, Configuring Network Security with ACLs.
1-9
Chapter 1
Product Overview
QoS Features
Policy-Based Routing
Traditional IP forwarding decisions are based purely on the destination IP address of the packet being
forwarded. Policy Based Routing (PBR) enables forwarding based upon other information associated
with a packet, such as the source interface, IP source address, Layer 4 ports, and so on. This feature
allows network managers more flexibility in how they configure and design their networks.
For more information on policy-based routing, see Chapter 26, Configuring Policy-Based Routing.
VRF-lite
VPN routing and forwarding (VRF-lite) is an extension of IP routing that provides multiple routing instances.
Along with BGP, it enables the creation of a Layer 3 VPN service by keeping separate IP routing and
forwarding tables for each VPN customer. VRF-lite uses input interfaces to distinguish routes for different
VPNs. It forms virtual packet-forwarding tables by associating one or more Layer 3 interfaces with each VRF,
allowing the creation of multiple Layer 3 VPNs on a single switch. Interfaces in a VRF could be either
physical, such as an Ethernet port, or logical, such as a VLAN switch virtual interface (SVI). However,
interfaces cannot belong to more than one VRF at any time.
For information on VRF-lite, see Chapter 28, Configuring VRF-lite.
QoS Features
The quality of service (QoS) features prevent congestion by selecting network traffic and prioritizing it
according to its relative importance. Implementing QoS in your network makes network performance
more predictable and bandwidth use more effective.
The Catalyst 4500 series switch supports the following QoS features:
Catalyst 4500 series switch supports trusted boundary, which uses the Cisco Discovery Protocol (CDP)
to detect the presence of a Cisco IP phone (such as the Cisco IP Phone 7910, 7935, 7940, and 7960) on
a switch port. If the telephone is not detected, the trusted boundary feature disables the trusted setting
on the switch port and prevents misuse of a high-priority queue.
The Catalyst 4500 series switch also supports QoS Automation (Auto QoS), which simplifies the
deployment of existing QoS features through automatic configuration.
For information on QoS and Auto QoS, see Chapter 29, Configuring QoS.
1-10
OL-6696-01
Chapter 1
Product Overview
Management and Security Features
Stateful switchover (SSO)This feature propagates configuration and state information from the
active to the redundant supervisor engine so that sub-second interruptions in Layer 2 traffic occur
when the active supervisor engine switches over to the redundant supervisor engine.
Stateful IGMP Snooping
This feature propagates the IGMP data learned by the active supervisor engine to the redundant
supervisor engine so that when a switchover occurs, the newly active supervisor engine is aware
of the multicast group membership, which alleviates a disruption to multicast traffic during a
switchover.
Stateful DHCP Snooping
This feature propagates the DHCP-snooped data from the active supervisor engine to the
redundant supervisor engine so that when a switchover occurs, the newly active supervisor
engine is aware of the DHCP data that was already snooped, and the security benefits continue
uninterrupted.
802.1X protocolThis feature provides a means for a host that is connected to a switch port to be
authenticated before it is given access to the switch services.
802.1X with VLAN assignmentThis feature allows you to enable non-802.1X-capable hosts to
access networks that use 802.1X authentication.
802.1X authentication for guest VLANsThis feature allows you to use VLAN assignment to limit
network access for certain users.
802.1X RADIUS accountingThis feature allows you to track the usage of network devices.
802.1X with Voice VLANThis feature allows you to use 802.1X security on a port while enabling
it to be used by both Cisco IP phones and devices with 802.1X supplicant support.
Dynamic ARP inspectionThis feature intercepts all ARP requests, replies on untrusted ports, and
verifies each intercepted packet for valid IP to MAC bindings. Dynamic ARP Inspection helps to
prevent attacks on a network by not relaying invalid ARP replies out to other ports in the same
VLAN. Denied ARP packets are logged by the switch for auditing.
Flood BlockingThis feature enables users to disable the flooding of unicast and multicast packets
on a per-port basis. Occasionally, unknown unicast or multicast traffic from an unprotected port is
flooded to a protected port because a MAC address has timed out or has not been learned by the
switch.
Port SecurityThis feature restricts traffic on a port based upon the MAC address of the workstation
that accesses the port.
1-11
Chapter 1
Product Overview
Local Authentication, Remote Authentication Dial-In User Service (RADIUS), and Terminal
Access Controller Access Control System Plus (TACACS+) authenticationThese authentication
methods control access to the switch. For additional information, refer to the chapter
Authentication, Authorization, and Accounting (AAA), in Cisco IOS Security Configuration
Guide, Release 12.1, at the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/secur_c/scprt1/index.htm
Visual port status informationThe switch LEDs provide visual management of port- and
switch-level status.
Auto 10/100/1000 negotiationThis feature allows you to configure a port to limit the speed at
which it will autonegotiate to a speed lower than the physically maximum speed. This method of
reducing the throughput incurs much less overhead than using an ACL.
Secure ShellSecure Shell (SSH) is a program that enables you to log into another computer over
a network, to execute commands remotely, and to move files from one machine to another. The
switch may not initiate SSH connections: SSH will be limited to providing a remote login session
to the switch and will only function as a server.
NetFlow statisticsThis feature is a global traffic monitoring feature that allows flow-level
monitoring of all IPv4-routed traffic through the switch.
User Based Rate Limiting (UBRL)This feature adopts microflow policing to dynamically learn
traffic flows and rate limit each unique flow to an individual rate. UBRL is available only on the
Supervisor Engine V-10GE with the built-in NetFlow support.
Switched Port Analyzer (SPAN)SPAN allows you to monitor traffic on any port for analysis by a
network analyzer or Remote Monitoring (RMON) probe. You also can do the following:
Configure ACLs on SPAN sessions.
Allow incoming traffic on SPAN destination ports to be switched normally.
Explicitly configure the encapsulation type of packets that are spanned out of a destination port.
Restrict ingress sniffing depending on whether the packet is unicast, multicast, or broadcast, and
purposes.
For information on SPAN, see Chapter 39, Configuring SPAN and RSPAN.
Remote SPAN (RSPAN)RSPAN is an extension of SPAN, where source ports and destination
ports are distributed across multiple switches, allowing remote monitoring of multiple switches
across the network. The traffic for each RSPAN session is carried over a user-specified RSPAN
VLAN that is dedicated for that RSPAN session on all participating switches.
For information on RSPAN, see Chapter 39, Configuring SPAN and RSPAN.
1-12
OL-6696-01
Chapter 1
Product Overview
Management and Security Features
For information on SNMP, refer to the Cisco IOS Configuration Fundamentals Configuration Guide
and Cisco IOS Configuration Fundamentals Command Reference at the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios121/121cgcr/index.htm
Dynamic Host Control Protocol serverThe Cisco IOS DHCP server feature is a full DHCP server
implementation that assigns and manages IP addresses from specified address pools within the
router to DHCP clients. If the Cisco IOS DHCP server cannot satisfy a DHCP request from its own
database, it can forward the request to one or more secondary DHCP servers defined by the network
administrator.
With DHCP-based autoconfiguration, your switch (the DHCP client) is automatically configured at
startup with IP address information and a configuration file.
For more information on configuring the DHCP server, refer to the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122newft/122t/
122t1/easyip2.htm
Debugging featuresThe Catalyst 4500 series switch has several commands to help you debug
your initial setup. These commands include the following groups:
platform
debug platform
For more information, refer to the Catalyst 4500 Series Switch Cisco IOS Command Reference.
1-13
Chapter 1
Product Overview
1-14
OL-6696-01
C H A P T E R
Command-Line Interfaces
This chapter describes the CLIs you use to configure the Catalyst 4500 series switch. This chapter
includes the following major sections:
Note
For complete syntax and usage information for the commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm
Accessing the CLI Using the EIA/TIA-232 Console Interface, page 2-1
EIA/TIA-232 was known as recommended standard 232 (RS-232) before its acceptance as a standard by
the Electronic Industries Alliance (EIA) and Telecommunications Industry Association (TIA).
Perform the initial switch configuration over a connection to the EIA/TIA-232 console interface. Refer
to the Catalyst 4500 Series Switch Module Installation Guide for console interface cable connection
procedures.
2-1
Chapter 2
Command-Line Interfaces
To access the switch through the console interface, perform this task:
Command
Purpose
Step 1
Switch> enable
Step 2
Password: password
Switch#
Step 3
Switch# quit
After accessing the switch through the EIA/TIA-232 interface, you see this display:
Press Return for Console prompt
Switch> enable
Password:< >
Switch#
Before you make a Telnet connection to the switch, you must set the IP address for the switch. See the
Configuring Physical Layer 3 Interfaces section on page 23-4.
The switch supports up to eight simultaneous Telnet sessions. Telnet sessions disconnect automatically
after remaining idle for the period specified by the exec-timeout command.
To make a Telnet connection to the switch, perform this task:
Command
Purpose
Step 1
From the remote host, enter the telnet command and the
name or IP address of the switch you want to access.
Step 2
Password: password
Switch#
Step 3
Step 4
2-2
OL-6696-01
Chapter 2
Command-Line Interfaces
Performing Command-Line Processing
Keyboard Shortcuts
Keystrokes
Result
Press Ctrl-B or
press the Left Arrow key 1
Press Ctrl-F or
press the Right Arrow key1
Press Ctrl-A
Press Ctrl-E
Press Esc-B
Press Esc-F
Command
Purpose
2-3
Chapter 2
Command-Line Interfaces
Table 2-2
Command
Ctrl-N or the Down Arrow key
Purpose
1
For complete information about Cisco IOS command modes, refer to the Cisco IOS Configuration
Fundamentals Configuration Guide and the Cisco IOS Configuration Fundamentals Command
Reference at: http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm
The Cisco IOS user interface has many different modes: user EXEC, privileged EXEC (enable), global
configuration, interface, subinterface, and protocol-specific. The commands available to you depend on
which mode you are in. To get a list of the commands in a given mode, enter a question mark (?) at the
system prompt. See the Getting a List of Commands and Syntax section on page 2-5 for more
information.
When you start a session on the switch, you begin in user mode, also called user EXEC mode. Only a
small subset of commands are available in EXEC mode. To have access to all commands, you must enter
privileged EXEC mode, also called enable mode. To access the privileged EXEC mode, you must enter
a password. When you are in the privileged EXEC mode, you can enter any EXEC command or access
global configuration mode. Most EXEC commands are one-time commands, such as show commands,
which display the current configuration status, and clear commands, which reset counters or interfaces.
The EXEC commands are not saved when the switch is rebooted.
The configuration modes allow you to make changes to the running configuration. If you save the
configuration, these commands are stored when you reboot the switch. You must start in global
configuration mode. From global configuration mode, you can enter interface configuration mode,
subinterface configuration mode, and a variety of protocol-specific modes.
You would use a separate mode called ROMMON when the switch cannot boot up properly. For example,
the switch might enter ROMMON mode if it does not find a valid system image when it is booting, or if
its configuration file is corrupted. For more information, see the ROMMOM Command-Line Interface
section on page 2-6.
Table 2-3 lists and describes frequently used Cisco IOS modes.
2-4
OL-6696-01
Chapter 2
Command-Line Interfaces
Getting a List of Commands and Syntax
Table 2-3
Mode
How to Access
Prompt
User EXEC
Log in.
Switch>
Switch#
Switch(config)#
Interface configuration
Switch(config-if)#
Console configuration
Switch(config-line)#
The Cisco IOS command interpreter, called the EXEC, interprets and runs the commands you enter. You
can abbreviate commands and keywords by entering just enough characters to make the command unique
from other commands. For example, you can abbreviate the show command to sh and the configure
terminal command to config t.
When you type exit, the switch backs out one level. To exit configuration mode completely and return
to privileged EXEC mode, press Ctrl-Z.
To obtain a list of commands that begin with a particular character sequence, enter those characters
followed by the question mark (?). Do not include a space before the question mark. This form of help
is called word help, because it completes a word for you.
2-5
Chapter 2
Command-Line Interfaces
To list keywords or arguments, enter a question mark in place of a keyword or argument. Include a space
before the question mark. This form of help is called command syntax help, because it reminds you
which keywords or arguments are applicable based on the command, keywords, and arguments you have
already entered.
Switch# configure ?
memory
network
overwrite-network
terminal
<cr>
Configure
Configure
Overwrite
Configure
from NV memory
from a TFTP network host
NV memory from TFTP network host
from the terminal
To redisplay a command you previously entered, press the Up Arrow key or Ctrl-P. You can continue
to press the Up Arrow key to see the last 20 commands you entered.
Tip
If you are having trouble entering a command, check the system prompt and enter the question mark (?)
for a list of available commands. You might be in the wrong command mode or using incorrect syntax.
Type exit to return to the previous mode. Press Ctrl-Z or enter the end command in any mode to
immediately return to privileged EXEC mode.
Note
Ctrl-C is always enabled for 60 seconds after you reboot the switch, even if Ctrl-C is configured to be
off in the configuration register settings.
When you enter ROMMON mode, the prompt changes to rommon 1>. Use the ? command to see the
available ROMMON commands.
For more information about the ROMMON commands, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference.
2-6
OL-6696-01
C H A P T E R
Cisco IOS Configuration Fundamentals Configuration Guide, Release 12.2, at this URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/fun_c/index.htm
Cisco IOS Configuration Fundamentals Configuration Command Reference, Release 12.2, at this
URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/fun_r/index.htm
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm
Feature
Default Settings
Administrative connection
Normal mode
System clock
3-1
Chapter 3
Table 3-1
Feature
Default Settings
Passwords
Switch prompt
Switch>
Interfaces
If your DHCP server is a Cisco device, or if you are configuring the switch as a DHCP server, refer to
the IP Addressing and Services section in the Cisco IOS IP and IP Routing Configuration Guide for
Cisco IOS Release 12.1 for additional information about configuring DHCP.
Starting with Release 12.2(20)EW, you can enable DHCP AutoConfiguration by issuing the write erase
command. This command clears the startup-config in NVRAM. In images prior to Release 12.2(20)EW,
this command will not enable autoconfiguration.
DHCP provides configuration information to Internet hosts and internetworking devices. This protocol
consists of two components: one component for delivering configuration parameters from a DHCP
server to a device and another component that is a mechanism for allocating network addresses to
devices. DHCP is built on a client-server model, in which designated DHCP servers allocate network
addresses and deliver configuration parameters to dynamically configured devices. The switch can act
as both a DHCP client and a DHCP server.
With DHCP-based autoconfiguration, no DHCP client-side configuration is needed on your switch
because your switch (the DHCP client) is automatically configured at startup with IP address
information and a configuration file. However, you need to configure the DHCP server or the DHCP
server feature on your switch for various lease options associated with IP addresses. If you are using
DHCP to relay the configuration file location on the network, you might also need to configure a Trivial
File Transfer Protocol (TFTP) server and a Domain Name System (DNS) server.
DHCP-based autoconfiguration replaces the BOOTP client functionality on your switch.
3-2
OL-6696-01
Chapter 3
DHCPDISCOVER (broadcast)
Switch A
DHCPOFFER (unicast)
DHCP server
DHCPACK (unicast)
51807
DHCPREQUEST (broadcast)
The client, Switch A, broadcasts a DHCPDISCOVER message to locate a DHCP server. The DHCP
server offers configuration parameters (such as an IP address, subnet mask, gateway IP address, DNS IP
address, lease for the IP address, and so forth) to the client in a DHCPOFFER unicast message.
In a DHCPREQUEST broadcast message, the client returns a formal request for the offered
configuration information to the DHCP server. The formal request is broadcast so that all other DHCP
servers that received the DHCPDISCOVER broadcast message from the client can reclaim the IP
addresses that they offered to the client.
The DHCP server confirms that the IP address has been allocated to the client by returning a DHCPACK
unicast message to the client. With this message, the client and server are bound, and the client uses the
configuration information that it received from the server. The amount of information the switch receives
depends on how you configure the DHCP server. For more information, see the Configuring the DHCP
Server section on page 3-3.
If the configuration parameters sent to the client in the DHCPOFFER unicast message are invalid (if
configuration error exists), the client returns a DHCPDECLINE broadcast message to the DHCP server.
The DHCP server sends the client a DHCPNAK denial broadcast message, which means that the offered
configuration parameters have not been assigned, that an error has occurred during the negotiation of the
parameters, or that the client has been slow in responding to the DHCPOFFER message. (The DHCP
server might have assigned the parameters to another client.)
A DHCP client might receive offers from multiple DHCP servers and can accept any of them; however,
the client usually accepts the first offer it receives. The offer from the DHCP server is not a guarantee
that the IP address will be allocated to the client; however, the server usually reserves the address until
the client has had a chance to formally request the address.
3-3
Chapter 3
If you want the switch to receive IP address information, you must configure the DHCP server with these
lease options:
Note
The router IP address is the default gateway address for the switch.
If you want the switch to receive the configuration file from a TFTP server, you must configure the
DHCP server with these lease options:
Boot filename (the name of the configuration file that the client needs) (recommended)
Depending on the settings of the DHCP server or the DHCP server feature running on your switch, the
switch can receive IP address information, the configuration file, or both.
If you do not configure the DHCP server, or the DHCP server feature running on your switch, with the
lease options described earlier, the switch replies to client requests with only those parameters that are
configured. If the IP address and subnet mask are not in the reply, the switch is not configured. If the
router IP address or TFTP server name (or IP address) are not found, the switch might send broadcast,
instead of unicast, TFTP requests. Unavailability of other lease options does not impact
autoconfiguration.
The DHCP server, or the DHCP server feature running on your switch, can be on the same LAN or on a
different LAN than the switch. If the DHCP server is running on a different LAN, you should configure
a DHCP relay, which forwards broadcast traffic between two directly connected LANs. A router does
not forward broadcast packets, but it forwards packets based on the destination IP address in the received
packet. For more information on relay devices, see the Configuring the Relay Device section on
page 3-5.
3-4
OL-6696-01
Chapter 3
For the switch to successfully download a configuration file, the TFTP server must contain one or more
configuration files in its base directory. The files can include the following:
The configuration file named in the DHCP reply (the actual switch configuration file).
The network-confg or the cisconet.cfg file (known as the default configuration files).
The router-confg or the ciscortr.cfg file. (These files contain commands common to all switches.
Normally, if the DHCP and TFTP servers are properly configured, these files are not accessed.)
If you specify the TFTP server name in the DHCP server-lease database, you must also configure the
TFTP server name-to-IP-address mapping in the DNS-server database.
If the TFTP server you plan to use is on a different LAN from the switch, or if it is to be accessed by the
switch through the broadcast address (which occurs if the DHCP server response does not contain all the
required information described earlier), a relay must be configured to forward the TFTP packets to the
TFTP server. For more information, see the Configuring the Relay Device section on page 3-5. The
preferred solution is to configure either the DHCP server or the DHCP server feature running on your
switch with all the required information.
On interface 20.0.0.1
router(config-if)# ip helper-address 10.0.0.1
3-5
Chapter 3
Figure 3-2
Switch
(DHCP client)
Cisco router
(Relay)
10.0.0.2
10.0.0.1
DHCP server
20.0.0.3
TFTP server
20.0.0.4
DNS server
49068
20.0.0.2
20.0.0.1
The IP address and the configuration filename are reserved for the switch and provided in the DHCP
reply (one-file read method).
The switch receives its IP address, subnet mask, TFTP server address, and the configuration
filename from either the DHCP server or the DHCP server feature running on your switch. The
switch sends a unicast message to the TFTP server to retrieve the named configuration file from the
base directory of the server, and upon receipt, completes its boot-up process.
The IP address and the configuration filename is reserved for the switch, but the TFTP server
address is not provided in the DHCP reply (one-file read method).
The switch receives its IP address, subnet mask, and the configuration filename from either the
DHCP server or the DHCP server feature running on your switch. The switch sends a broadcast
message to a TFTP server to retrieve the named configuration file from the base directory of the
server, and upon receipt, completes its boot-up process.
Only the IP address is reserved for the switch and provided in the DHCP reply. The configuration
filename is not provided (two-file read method).
The switch receives its IP address, subnet mask, and the TFTP server address from either the DHCP
server or the DHCP server feature running on your switch. The switch sends a unicast message to
the TFTP server to retrieve the network-confg or cisconet.cfg default configuration file. (If the
network-confg file cannot be read, the switch reads the cisconet.cfg file.)
The default configuration file contains the host names-to-IP-address mapping for the switch. The
switch fills its host table with the information in the file and obtains its host name. If the host name
is not found in the file, the switch uses the host name in the DHCP reply. If the host name is not
specified in the DHCP reply, the switch uses the default Switch as its host name.
After obtaining its host name from the default configuration file or the DHCP reply, the switch reads
the configuration file that has the same name as its host name (hostname-confg or hostname.cfg,
depending on whether or not the network-confg file or the cisconet.cfg file was read earlier) from
the TFTP server. If the cisconet.cfg file is read, the filename of the host is truncated to eight
characters.
3-6
OL-6696-01
Chapter 3
If the switch cannot read the network-confg, cisconet.cfg, or the hostname file, it reads the
router-confg file. If the switch cannot read the router-confg file, it reads the ciscortr.cfg file.
Note
The switch broadcasts TFTP server requests provided that one of these conditions is met: 1) the TFTP
server is not obtained from the DHCP replies; 2) all attempts to read the configuration file through
unicast transmissions fail, or 3) the TFTP server name cannot be resolved to an IP address.
Example Configuration
Figure 3-3 shows a sample network for retrieving IP information using DHCP-based autoconfiguration.
Figure 3-3
Switch 1
Switch 2
Switch 3
Switch 4
00e0.9f1e.2001 00e0.9f1e.2002 00e0.9f1e.2003 00e0.9f1e.2004
Cisco router
10.0.0.10
DHCP server
10.0.0.2
DNS server
10.0.0.3
TFTP server
(maritsu)
49066
10.0.0.1
Table 3-2 shows the configuration of the reserved leases on either the DHCP server or the DHCP server
feature running on your switch.
Table 3-2
Switch 1
Switch 2
Switch 3
Switch 4
Binding key
(hardware address)
00e0.9f1e.2001
00e0.9f1e.2002
00e0.9f1e.2003
00e0.9f1e.2004
IP address
10.0.0.21
10.0.0.22
10.0.0.23
10.0.0.24
Subnet mask
255.255.255.0
255.255.255.0
255.255.255.0
255.255.255.0
Router address
10.0.0.10
10.0.0.10
10.0.0.10
10.0.0.10
10.0.0.2
10.0.0.2
10.0.0.2
10.0.0.2
maritsu or 10.0.0.3
maritsu or 10.0.0.3
maritsu or 10.0.0.3
maritsu or 10.0.0.3
Boot filename
(configuration file)
(optional)
switch1-confg
switch2-confg
switch3-confg
switch4-confg
switch1
switch2
switch3
switch4
3-7
Chapter 3
If no configuration filename is given in the DHCP server reply, Switch 1 reads the network-confg
file from the base directory of the TFTP server.
Switch 1 adds the contents of the network-confg file to its host table.
Switch 1 reads its host table by indexing its IP address 10.0.0.21 to its host name (switch1).
Switch 1 reads the configuration file that corresponds to its host name; for example, it reads
switch1-confg from the TFTP server.
Switches 2 through 4 retrieve their configuration files and IP addresses in the same way.
Saving the Running Configuration Settings to Your Start-up File, page 3-10
3-8
OL-6696-01
Chapter 3
Step 2
After a few seconds, you will see the user EXEC prompt (Switch>). Now, you may want to enter
privileged EXEC mode, also known as enable mode. Type enable to enter enable mode:
Switch> enable
Note
Step 3
At the enable prompt (#), enter the configure terminal command to enter global configuration mode:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#
Step 4
At the global configuration mode prompt, enter the interface type slot/interface command to enter
interface configuration mode:
Switch(config)# interface fastethernet 5/1
Switch(config-if)#
Step 5
Step 6
Step 7
Save your settings. (See the Saving the Running Configuration Settings to Your Start-up File section
on page 3-10.)
Your switch is now minimally configured and can boot with the configuration you entered. To see a list
of the configuration commands, enter ? at the prompt or press the help key in configuration mode.
3-9
Chapter 3
hostname Switch
<...output truncated...>
!
line con 0
transport input none
line vty 0 4
exec-timeout 0 0
password lab
login
transport input lat pad dsipcon mop telnet rlogin udptn nasi
!
end
Switch#
This command saves the configuration settings that you created in configuration mode. If you fail to do
this step, your configuration will be lost the next time you reload the system.
To store the configuration, changes to the configuration, or changes to the startup configuration in
NVRAM, enter the copy running-config startup-config command at the enable prompt (#), as follows:
Switch# copy running-config startup-config
3-10
OL-6696-01
Chapter 3
<...output truncated...>
!
line con 0
exec-timeout 0 0
transport input none
line vty 0 4
exec-timeout 0 0
password lab
login
transport input lat pad dsipcon mop telnet rlogin udptn nasi
!
end
Switch#
The switch uses the default gateway only when it is not configured with a routing protocol.
Configure a default gateway to send data to subnets other than its own when the switch is not configured
with a routing protocol. The default gateway must be the IP address of an interface on a router that is
directly connected to the switch.
To configure a default gateway, perform this task:
Command
Purpose
Step 1
Step 2
This example shows how to configure a default gateway and how to verify the configuration:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# ip default-gateway 172.20.52.35
Switch(config)# end
3d17h: %SYS-5-CONFIG_I: Configured from console by console
Switch# show ip route
Default gateway is 172.20.52.35
Host
Gateway
ICMP redirect cache is empty
Switch#
Last Use
Total Uses
Interface
3-11
Chapter 3
Purpose
Step 1
Step 2
This example shows how to use the ip route command to configure a static route to a workstation at IP
address 171.10.5.10 on the switch with a subnet mask and IP address 172.20.3.35 of the forwarding
router:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# ip route 171.10.5.10 255.255.255.255 172.20.3.35
Switch(config)# end
Switch#
This example shows how to use the show running-config command to confirm the configuration of the
static route:
Switch# show running-config
Building configuration...
.
<...output truncated...>
.
ip default-gateway 172.20.52.35
ip classless
ip route 171.10.5.10 255.255.255.255 172.20.3.35
no ip http server
!
line con 0
transport input none
line vty 0 4
exec-timeout 0 0
password lab
login
transport input lat pad dsipcon mop telnet rlogin udptn nasi
!
end
Switch#
This example shows how to use the ip route command to configure the static route IP address 171.20.5.3
with subnet mask and connected over VLAN 1 to a workstation on the switch:
Switch# configure terminal
Switch(config)# ip route 171.20.5.3 255.255.255.255 vlan 1
Switch(config)# end
Switch#
This example shows how to use the show running-config command to confirm the configuration of the
static route:
Switch# show running-config
Building configuration...
.
<...output truncated...>
.
3-12
OL-6696-01
Chapter 3
ip default-gateway 172.20.52.35
ip classless
ip route 171.20.5.3 255.255.255.255 Vlan1
no ip http server
!
!
x25 host z
!
line con 0
transport input none
line vty 0 4
exec-timeout 0 0
password lab
login
transport input lat pad dsipcon mop telnet rlogin udptn nasi
!
end
Switch#
Using the enable password and enable secret Commands, page 3-14
Setting TACACS+ Password Protection for Privileged EXEC Mode, page 3-15
Purpose
This example shows how to configure an enable password as lab at the privileged EXEC mode:
Switch# configure terminal
Switch(config)# enable password lab
Switch(config)#
For instructions on how to display the password or access level configuration, see the Displaying the
Password, Access Level, and Privilege Level Configuration section on page 3-17.
3-13
Chapter 3
Purpose
When you enter either of these password commands with the level option, you define a password for a
specific privilege level. After you specify the level and set a password, give the password only to users
who need to have access at this level. Use the privilege level configuration command to specify
commands accessible at various levels.
If you enable the service password-encryption command, the password you enter is encrypted. When
you display the password with the more system:running-config command, the password displays the
password in encrypted form.
If you specify an encryption type, you must provide an encrypted passwordan encrypted password you
copy from another Catalyst 4500 series switch configuration.
Note
You cannot recover a lost encrypted password. You must clear NVRAM and set a new password. See the
Recovering a Lost Enable Password section on page 3-18 for more information.
For information on how to display the password or access level configuration, see the Displaying the
Password, Access Level, and Privilege Level Configuration section on page 3-17.
Purpose
3-14
OL-6696-01
Chapter 3
For information on how to display the password or access level configuration, see the Displaying the
Password, Access Level, and Privilege Level Configuration section on page 3-17.
The Authentication, Authorization, and Accounting (AAA) chapter in the Cisco IOS Security
Configuration Guide, Release 12.2, at the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/secur_c/scprt1/index.htm
Cisco IOS Security Command Reference, Release 12.2, at the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/secur_r/index.htm
To set the TACACS+ protocol to determine whether or not a user can access the privileged EXEC mode,
perform this task:
Command
Purpose
When you set TACACS password protection at the privileged EXEC mode, the enable EXEC command
prompts you for a new username and a new password. This information is then passed to the TACACS+
server for authentication.
If you use extended TACACS, another extension to the older TACACS protocol that provides additional
functionality, it also passes any existing UNIX user identification code to the TACACS+ server.
Extended TACACS provides information about protocol translator and router use. This information is
used in UNIX auditing trails and accounting files.
Note
When used without extended TACACS, the enable use-tacacs command allows anyone with a valid
username and password to access the privileged EXEC mode, creating a potential security risk. This
problem occurs because the query resulting from entering the enable command is indistinguishable from
an attempt to log in without extended TACACS.
Encrypting Passwords
Because protocol analyzers can examine packets (and read passwords), you can increase access security
by configuring the Cisco IOS software to encrypt passwords. Encryption prevents the password from
being readable in the configuration file.
To configure the Cisco IOS software to encrypt passwords, perform this task:
Command
Purpose
Encrypts a password.
3-15
Chapter 3
Encryption occurs when the current configuration is written or when a password is configured. Password
encryption is applied to all passwords, including authentication key passwords, the privileged command
password, console and virtual terminal line access passwords, and Border Gateway Protocol (BGP)
neighbor passwords. The service password-encryption command keeps unauthorized individuals from
viewing your password in your configuration file.
Caution
The service password-encryption command does not provide a high level of network security. If you
use this command, you should also take additional network security measures.
Although you cannot recover a lost encrypted password (that is, you cannot get the original password
back), you can regain control of the switch after having lost or forgotten the encrypted password. See
the Recovering a Lost Enable Password section on page 3-18 for more information.
For information on how to display the password or access level configuration, see the Displaying the
Password, Access Level, and Privilege Level Configuration section on page 3-17.
Displaying the Password, Access Level, and Privilege Level Configuration, page 3-17
Purpose
Step 1
Step 2
For information on how to display the password or access level configuration, see the Displaying the
Password, Access Level, and Privilege Level Configuration section on page 3-17.
3-16
OL-6696-01
Chapter 3
Purpose
For information on how to display the password or access level configuration, see the Displaying the
Password, Access Level, and Privilege Level Configuration section on page 3-17.
Purpose
Purpose
Purpose
Step 1
Step 2
This example shows how to display the password and access level configuration:
Switch# show running-config
Building configuration...
Current configuration:
!
version 12.0
service timestamps debug datetime localtime
service timestamps log datetime localtime
no service password-encryption
!
hostname Switch
!
boot system flash sup-bootflash
enable password lab
!
<...output truncated...>
3-17
Chapter 3
For more information on the configuration register which is preconfigured in NVRAM, see Configuring
the Software Configuration Register section on page 3-19.
Perform these steps to recover a lost enable password:
Step 1
Step 2
Stop the boot sequence and enter ROM monitor by pressing Ctrl-C during the first 5 seconds of bootup.
Step 3
Configure the switch to boot-up without reading the configuration memory (NVRAM).
Step 4
Step 5
Access enable mode (this can be done without a password if a password has not been configured).
Step 6
Step 7
Reconfigure the switch to boot-up and read the NVRAM as it normally does.
Step 8
3-18
OL-6696-01
Chapter 3
Note
Ctrl-C is always enabled for five seconds after you reboot the switch, regardless of whether the
configuration-register setting has Ctrl-C disabled.
The ROM monitor has these features:
Hardware initialization
Caution
To manually boot the system using the boot command at the bootstrap program prompt
To force an automatic bootup from the system bootstrap software (boot image) or from a default
system image in onboard Flash memory, and read any boot system commands that are stored in the
configuration file in NVRAM
To avoid possibly halting the Catalyst 4500 series switch switch, remember that valid configuration
register settings might be combinations of settings and not just the individual settings listed in Table 3-3.
For example, the factory default value of 0x2101 is a combination of settings.
Table 3-3 lists the meaning of each of the software configuration memory bits. Table 3-4 defines the boot
field.
3-19
Chapter 3
Table 3-3
Meaning
00 to 03
04
0x0010
Unused
05
0x0020
06
0x0040
07
0x0080
08
0x0100
Unused
09
0x0200
Unused
10
0x0400
11 to 12
0x0800 to 0x1000 Bits one and zero of Console line speed (default is 9600 baud)
13
0x2000
14
0x4000
1. The factory default value for the configuration register is 0x2101. This value is a combination of the following: binary bit 13,
bit 8 = 0x0100 and binary bits 00 through 03 = 0x0001. (See Table 3-4.)
2. OEM = original equipment manufacturer.
Table 3-4
01
02 to 0F
Autoboots using image(s) specified by the BOOT environment variable. If more than one
image is specified, the switch attempts to boot the first image specified in the BOOT
variable. As long as the switch can successfully boot from this image, the same image will
be used on a reboot. If the switch fails to boot from the image specified in the BOOT
variable, the switch will try to boot from the next image listed in the BOOT variable. If the
end of the BOOT variable is reached without the switch booting successfully, the switch
attempts the boot from the beginning of the BOOT variable. The autoboot continues until
the switch successfully boots from one of the images specified in the BOOT variable.
Note
The factory default configuration register setting for systems and spares is 0x2101. However, the
recommended value is 0x0102.
3-20
OL-6696-01
Chapter 3
When the boot field is set to either 00 or 01 (0-0-0-0 or 0-0-0-1), the system ignores any boot instructions
in the system configuration file and the following occurs:
Caution
When the boot field is set to 00, you must boot up the operating system manually by issuing the boot
command at the system bootstrap or ROMMON prompt.
When the boot field is set to 01, the system boots the first image in the bootflash single in-line
memory module (SIMM).
When the entire boot field equals a value between 0-0-1-0 and 1-1-1-1, the switch loads the system
image specified by boot system commands in the startup configuration file.
If you set bootfield to a value between 0-0-1-0 and 1-1-1-1, you must specify a value in the boot system
command, else the switch cannot boot up and will remain stuck in ROMMON.
You can enter the boot command only or enter the command and include additional boot instructions,
such as the name of a file stored in Flash memory, or a file that you specify for booting from a network
server. If you use the boot command without specifying a file or any other boot instructions, the system
boots from the default Flash image (the first image in onboard Flash memory). Otherwise, you can
instruct the system to boot up from a specific Flash image (using the boot system flash filename
command).
You can also use the boot command to boot up images stored in the compact Flash cards located in slot 0
on the supervisor engine.
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config)# end
Step 5
Switch# reload
To modify the configuration register while the switch is running Cisco IOS software, follow these steps:
Step 1
Enter the enable command and your password to enter privileged level, as follows:
Switch> enable
Password:
Switch#
3-21
Chapter 3
Step 2
Enter the configure terminal command at the EXEC mode prompt (#), as follows:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#
Step 3
Set the contents of the configuration register by specifying the value command variable, where value is
a hexadecimal number preceded by 0x (see Table 3-3 on page 3-20).
Step 4
Enter the end command to exit configuration mode. The new value settings are saved to memory;
however, the new settings do not take effect until the system is rebooted.
Step 5
Enter the show version EXEC command to display the configuration register value currently in effect;
it will be used at the next reload. The value is displayed on the last line of the screen display, as shown
in this sample output:
Configuration register is 0x141 (will be 0x102 at next reload)
Step 6
Save your settings. (See the Saving the Running Configuration Settings to Your Start-up File section
on page 3-10. Note that configuration register changes take effect only after the system reloads, such as
when you enter a reload command from the console.)
Step 7
Reboot the system. The new configuration register value takes effect with the next system boot up.
Purpose
In this example, the show version command indicates that the current configuration register is set so that
the switch does not automatically load an operating system image. Instead, it enters ROMMON mode
and waits for you to enter ROM monitor commands.
Switch#show version
Cisco Internetwork Operating System Software
IOS (tm) Catalyst 4000 L3 Switch Software (cat4000-IS-M), Experimental
Version 12.1(20010828:211314) [cisco 105]
Copyright (c) 1986-2001 by cisco Systems, Inc.
Compiled Thu 06-Sep-01 15:40 by
Image text-base:0x00000000, data-base:0x00ADF444
ROM:1.15
Switch uptime is 10 minutes
System returned to ROM by reload
Running default software
3-22
OL-6696-01
Chapter 3
Copy the Flash memory image to a network server using TFTP or RCP
Remotely load multiple system software images through TFTP or RCP transfers (one transfer for
each file loaded)
Boot a switch manually or automatically from a system software image stored in Flash memory (you
can also boot directly from ROM)
Security Precautions
Note the following security precaution when loading from Flash memory:
Caution
You can only change the system image stored in Flash memory from privileged EXEC level on the
console terminal.
3-23
Chapter 3
Copy a system image to Flash memory using TFTP or other protocols. Refer to the Cisco IOS File
Management and Loading and Maintaining System Images chapters in the Cisco IOS Configuration
Fundamentals Configuration Guide, Release 12.2, at the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/fun_c/fcprt2/fcd203.htm
Step 2
Configure the system to boot automatically from the desired file in Flash memory. You might need to
change the configuration register value. See the Modifying the Boot Field and Using the boot
Command section on page 3-20, for more information on modifying the configuration register.
Step 3
Step 4
Power cycle and reboot your system to verify that all is working as expected.
Note
When you use the boot system and boot bootldr global configuration commands, you affect only the
running configuration. To save the configuration for future use, you must save the environment variable
settings to your startup configuration, which places the information under ROM monitor control. Enter
the copy system:running-config nvram:startup-config command to save the environment variables
from your running configuration to your startup configuration.
You can view the contents of the BOOT and BOOTLDR variables using the show bootvar command.
This command displays the settings for these variables as they exist in the startup configuration and in
the running configuration if a running configuration setting differs from a startup configuration setting.
This example shows how to check the BOOT and BOOTLDR variables on the switch:
Switch# show bootvar
BOOTLDR variable = bootflash:cat4000-is-mz,1;
Configuration register is 0x0
Switch#
3-24
OL-6696-01
C H A P T E R
Configuring Interfaces
This chapter describes how to configure interfaces for the Catalyst 4500 series switches. It also provides
guidelines, procedures, and configuration examples.
This chapter includes the following major sections:
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Interface type:
Fast Ethernet (use the fastethernet keyword)
Gigabit Ethernet (use the gigabitethernet keyword)
10-Gigabit Ethernet (use the tengigabitethernet keyword)
4-1
Chapter 4
Configuring Interfaces
Slot numberThe slot in which the interface module is installed. Slots are numbered starting
with 1, from top to bottom.
Interface numberThe interface number on the module. The interface numbers always begin with 1.
When you are facing the front of the switch, the interfaces are numbered from left to right.
You can identify interfaces by physically checking the slot/interface location on the switch. You can also
use the Cisco IOS show commands to display information about a specific interface or all the interfaces.
At the privileged EXEC prompt, enter the configure terminal command to enter global configuration
mode:
Switch# configure terminal
Enter configuration commands, one per line.
Switch(config)#
Step 2
In global configuration mode, enter the interface command. Identify the interface type and the number
of the connector on the interface card. The following example shows how to select Fast Ethernet, slot 5,
interface 1:
Switch(config)# interface fastethernet 5/1
Switch(config-if)#
Step 3
Interface numbers are assigned at the factory at the time of installation or when modules are added to a
system. Enter the show interfaces EXEC command to see a list of all interfaces installed on your switch.
A report is provided for each interface that your switch supports, as shown in this display:
Switch(config-if)#Ctrl-Z
Switch#show interfaces
Vlan1 is up, line protocol is down
Hardware is Ethernet SVI, address is 0004.dd46.7aff (bia 0004.dd46.7aff)
MTU 1500 bytes, BW 1000000 Kbit, DLY 10 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation ARPA, loopback not set
ARP type: ARPA, ARP Timeout 04:00:00
Last input never, output never, output hang never
Last clearing of "show interface" counters never
Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
Queueing strategy: fifo
Output queue: 0/40 (size/max)
5 minute input rate 0 bits/sec, 0 packets/sec
5 minute output rate 0 bits/sec, 0 packets/sec
0 packets input, 0 bytes, 0 no buffer
Received 0 broadcasts, 0 runts, 0 giants, 0 throttles
0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
0 packets output, 0 bytes, 0 underruns
0 output errors, 0 interface resets
0 output buffer failures, 0 output buffers swapped out
GigabitEthernet1/1 is up, line protocol is down
Hardware is Gigabit Ethernet Port, address is 0004.dd46.7700 (bia 0004.dd46.7700)
MTU 1500 bytes, BW 1000000 Kbit, DLY 10 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation ARPA, loopback not set
Keepalive set (10 sec)
Auto-duplex, Auto-speed
ARP type: ARPA, ARP Timeout 04:00:00
4-2
OL-6696-01
Chapter 4
Configuring Interfaces
Using the interface Command
Step 4
To begin configuring Fast Ethernet interface 5/5, as shown in the following example, enter the interface
keyword, interface type, slot number, and interface number in global configuration mode:
Switch# configure terminal
Enter configuration commands, one per line.
Switch(config)# interface fastethernet 5/5
Switch(config-if)#
Note
You do not need to add a space between the interface type and interface number. For example,
in the preceding line you can specify either fastethernet 5/5 or fastethernet5/5.
4-3
Chapter 4
Configuring Interfaces
Step 5
Follow each interface command with the interface configuration commands your particular interface
requires. The commands you enter define the protocols and applications that will run on the interface.
The commands are collected and applied to the interface command until you enter another interface
command or press Ctrl-Z to exit interface configuration mode and return to privileged EXEC mode.
Step 6
After you configure an interface, check its status by using the EXEC show commands listed in
Monitoring and Maintaining the Interface section on page 4-13.
Purpose
Note
When you use the interface range command, you must add a space between the vlan, fastethernet,
gigabitethernet, tengigabitethernet, or macro keyword and the dash. For example, the command
interface range fastethernet 5/1 - 5 specifies a valid range; the command
interface range fastethernet 1-5 does not contain a valid range command.
Note
The interface range command works only with VLAN interfaces that have been configured with the
interface vlan command (the show running-configuration command displays the configured VLAN
interfaces). VLAN interfaces that are not displayed by the show running-configuration command
cannot be used with the interface range command.
4-4
OL-6696-01
Chapter 4
Configuring Interfaces
Defining and Using Interface-Range Macros
This example shows how to reenable all Fast Ethernet interfaces 5/1 to 5/5:
Switch(config)# interface range fastethernet 5/1 - 5
Switch(config-if-range)# no shutdown
Switch(config-if-range)#
*Oct 6 08:24:35: %LINK-3-UPDOWN: Interface FastEthernet5/1, changed state to up
*Oct 6 08:24:35: %LINK-3-UPDOWN: Interface FastEthernet5/2, changed state to up
*Oct 6 08:24:35: %LINK-3-UPDOWN: Interface FastEthernet5/3, changed state to up
*Oct 6 08:24:35: %LINK-3-UPDOWN: Interface FastEthernet5/4, changed state to up
*Oct 6 08:24:35: %LINK-3-UPDOWN: Interface FastEthernet5/5, changed state to up
*Oct 6 08:24:36: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet5/
5, changed state to up
*Oct 6 08:24:36: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet5/
3, changed state to up
*Oct 6 08:24:36: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet5/
4, changed state to up
Switch(config-if)#
This example shows how to use a comma to add different interface type strings to the range to reenable
all Fast Ethernet interfaces in the range 5/1 to 5/5 and both Gigabit Ethernet interfaces 1/1 and 1/2:
Switch(config-if)# interface range fastethernet 5/1 - 5, gigabitethernet 1/1 - 2
Switch(config-if)# no shutdown
Switch(config-if)#
*Oct 6 08:29:28: %LINK-3-UPDOWN: Interface FastEthernet5/1, changed state to up
*Oct 6 08:29:28: %LINK-3-UPDOWN: Interface FastEthernet5/2, changed state to up
*Oct 6 08:29:28: %LINK-3-UPDOWN: Interface FastEthernet5/3, changed state to up
*Oct 6 08:29:28: %LINK-3-UPDOWN: Interface FastEthernet5/4, changed state to up
*Oct 6 08:29:28: %LINK-3-UPDOWN: Interface FastEthernet5/5, changed state to up
*Oct 6 08:29:28: %LINK-3-UPDOWN: Interface GigabitEthernet1/1, changed state to
up
*Oct 6 08:29:28: %LINK-3-UPDOWN: Interface GigabitEthernet1/2, changed state to
up
*Oct 6 08:29:29: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet5/
5, changed state to up
*Oct 6 08:29:29: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet5/
3, changed state to up
*Oct 6 08:29:29: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet5/
4, changed state to up
Switch(config-if)#
If you enter multiple configuration commands while you are in interface-range configuration mode, each
command is run as it is entered (they are not batched together and run after you exit interface-range
configuration mode). If you exit interface-range configuration mode while the commands are being run,
some commands might not be run on all interfaces in the range. Wait until the command prompt is
displayed before exiting interface-range configuration mode.
4-5
Chapter 4
Configuring Interfaces
Purpose
This example shows how to define an interface-range macro named enet_list to select Fast Ethernet
interfaces 5/1 through 5/4:
Switch(config)# define interface-range enet_list fastethernet 5/1 - 4
Purpose
This example shows how to display the defined interface-range macro named enet_list:
Switch# show running-config | include define
define interface-range enet_list FastEthernet5/1 - 4
Switch#
To use an interface-range macro in the interface range command, perform this task:
Command
Purpose
This example shows how to change to the interface-range configuration mode using the interface-range
macro enet_list:
Switch(config)# interface range macro enet_list
Switch(config-if)#
4-6
OL-6696-01
Chapter 4
Configuring Interfaces
Configuring Optional Interface Features
Displaying the Interface Speed and Duplex Mode Configuration, page 4-9
You do not configure the client device for autonegotiation. Rather, you configure the switch with the
speed, or range of speeds, that you want to autonegotiate.
You can configure the interface speed and duplex mode parameters to auto and allow the Catalyst 4500
series switch to negotiate the interface speed and duplex mode between interfaces. If you decide to
configure the interface speed and duplex commands manually, consider the following:
Caution
If you enter the no speed command, the switch automatically configures both interface speed and
duplex to auto.
When you set the interface speed to 1000 (Mbps) or auto 1000, the duplex mode is full duplex. You
cannot change the duplex mode.
If the interface speed is set to 10 or 100, the duplex mode is set to half duplex by default unless you
explicitly configure it.
Changing the interface speed and duplex mode configuration might shut down and restart the interface
during the reconfiguration.
Purpose
Step 1
Step 2
This example shows how to set the interface speed to 100 Mbps on the Fast Ethernet interface 5/4:
Switch(config)# interface fastethernet 5/4
Switch(config-if)# speed 100
4-7
Chapter 4
Configuring Interfaces
This example shows how to allow Fast Ethernet interface 5/4 to autonegotiate the speed and duplex
mode:
Switch(config)# interface fastethernet 5/4
Switch(config-if)# speed auto
Note
This example shows how to limit speed negotiation to 100 Mbps on the Gigabit Ethernet interface 1/1:
Switch(config)# interface gigabitethernet 1/1
Switch(config-if)# speed auto 100
Note
Turning off autonegotiation on a Gigabit Ethernet interface will result in the port being forced into
1000 Mbps and full-duplex mode.
To turn off the port speed autonegotiation for Gigabit Ethernet interface 1/1, perform this task:
Command
Purpose
Step 1
Step 2
To restore autonegotiation, enter the no speed nonegotiate command in the interface configuration
mode.
Note
For the blocking ports on the WS-X4416 module, do not set the speed to autonegotiate.
When the interface is set to 1000 Mbps, you cannot change the duplex mode from full duplex to half
duplex.
To set the duplex mode of a Fast Ethernet interface, perform this task:
Command
Purpose
Step 1
Step 2
This example shows how to set the interface duplex mode to full on Fast Ethernet interface 5/4:
Switch(config)# interface fastethernet 5/4
Switch(config-if)# duplex full
4-8
OL-6696-01
Chapter 4
Configuring Interfaces
Configuring Optional Interface Features
Purpose
This example shows how to display the interface speed and duplex mode of Fast Ethernet interface 6/1:
Switch# show interface fastethernet 6/1
FastEthernet6/1 is up, line protocol is up
Hardware is Fast Ethernet Port, address is 0050.547a.dee0 (bia 0050.547a.dee0)
MTU 1500 bytes, BW 100000 Kbit, DLY 100 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation ARPA, loopback not set
Keepalive set (10 sec)
Full-duplex, 100Mb/s
ARP type: ARPA, ARP Timeout 04:00:00
Last input 00:00:54, output never, output hang never
Last clearing of "show interface" counters never
Input queue: 50/2000/0/0 (size/max/drops/flushes); Total output drops: 0
Queueing strategy: fifo
Output queue: 0/40 (size/max)
5 minute input rate 0 bits/sec, 0 packets/sec
5 minute output rate 0 bits/sec, 0 packets/sec
50 packets input, 11300 bytes, 0 no buffer
Received 50 broadcasts, 0 runts, 0 giants, 0 throttles
0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
0 input packets with dribble condition detected
1456 packets output, 111609 bytes, 0 underruns
0 output errors, 0 collisions, 0 interface resets
0 babbles, 0 late collision, 0 deferred
1 lost carrier, 0 no carrier
0 output buffer failures, 0 output buffers swapped out
Switch#
Purpose
This example shows how to add a description on Fast Ethernet interface 5/5:
Switch(config)# interface fastethernet 5/5
Switch(config-if)# description Channel-group to "Marketing"
4-9
Chapter 4
Configuring Interfaces
Note
4-10
OL-6696-01
Chapter 4
Configuring Interfaces
Configuring Optional Interface Features
Note
Jumbo frame support is only configured per interface; jumbo frame support cannot be configured
globally.
Ethernet Ports
These sections describe configuring nondefault MTU sizes on Ethernet ports:
With Cisco IOS Release 12.2(25)EW, configuring a nondefault MTU size on certain Ethernet ports
limits the size of ingress packets. The MTU does not impact the egress packets.
With releases earlier than Cisco IOS Release 12.1(13)EW, you can configure the MTU size only on
Gigabit Ethernet.
Layer 3 and Layer 2 EtherChannels
With Release Cisco IOS Release 12.2(25)EW and later releases, you can configure all the interfaces in
an EtherChannel provided that they have the same MTU. Changing the MTU of an EtherChannel
changes the MTU of all member ports. If the MTU of a member port cannot be changed to the new value,
that port is suspended (administratively shut down). A port cannot join an EtherChannel if the port has
a different MTU. If a member port of an EtherChannel changes MTU, the member port is suspended.
VLAN Interfaces
If switch ports reside in the same VLAN, either configure all of the switch ports to handle jumbo frames
and support the same MTU size, or configure none of them. However, such uniformity of MTU size in
the same VLAN is not enforced.
When a VLAN has switch ports with different MTU size, packets received from a port with a larger MTU
might be dropped when they are forwarded to a port with a smaller MTU.
If the switch ports in a VLAN have jumbo frames enabled, the corresponding SVI can have jumbo frames
enabled. The MTU of an SVI should always be smaller than the smallest MTU among all the switch ports
in the VLAN, but this condition is not enforced.
The MTU of a packet is not checked on the ingress side for an SVI; it is checked on the egress side of
an SVI. If the MTU of a packet is larger than the MTU of the egress SVI, the packet will be sent to the
CPU for fragmentation processing. If the do not fragment bit is not set, the packet is fragmented.
Otherwise, the packet is dropped.
4-11
Chapter 4
Configuring Interfaces
Purpose
Step 1
Step 2
Switch(config-if)# no mtu
Step 3
Switch(config-if)# end
Step 4
1.
Note
When configuring the MTU size for VLAN interfaces and Layer 3 and Layer 2 Ethernet ports, note that
the supported MTU values are from 1500 to 9198 bytes.
This example shows how to configure the MTU size on Gigabit Ethernet port 1/1:
switch# conf t
switch(config)# int gi1/1
switch(config-if)# mtu 9198
switch(config-if)# end
4-12
OL-6696-01
Chapter 4
Configuring Interfaces
Understanding Online Insertion and Removal
Purpose
Step 1
Step 2
Step 3
Step 4
4-13
Chapter 4
Configuring Interfaces
This example shows how to display the status of Fast Ethernet interface 5/5:
Switch# show protocols fastethernet 5/5
FastEthernet5/5 is up, line protocol is up
Switch#
Purpose
This example shows how to clear and reset the counters on Fast Ethernet interface 5/5:
Switch# clear counters fastethernet 5/5
Clear "show interface" counters on this interface [confirm] y
Switch#
*Sep 30 08:42:55: %CLEAR-5-COUNTERS: Clear counter on interface FastEthernet5/5
by vty1 (171.69.115.10)
Switch#
The clear counters command (without any arguments) clears all the current interface counters from all
interfaces.
Note
The clear counters command does not clear counters retrieved with SNMP; it clears only those counters
displayed with the EXEC show interfaces command.
Purpose
Step 1
Step 2
Switch(config-if)# shutdown
Step 3
Switch(config-if)# no shutdown
4-14
OL-6696-01
Chapter 4
Configuring Interfaces
Monitoring and Maintaining the Interface
This example shows how to shut down Fast Ethernet interface 5/5:
Switch(config)# interface fastethernet 5/5
Switch(config-if)# shutdown
Switch(config-if)#
*Sep 30 08:33:47: %LINK-5-CHANGED: Interface FastEthernet5/5, changed state to a
administratively down
Switch(config-if)#
To check whether or not an interface is disabled, enter the EXEC show interfaces command. An
interface that has been shut down is shown as being administratively down when you enter the show
interfaces command.
4-15
Chapter 4
Configuring Interfaces
4-16
OL-6696-01
C H A P T E R
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
5-1
Chapter 5
This example shows how to check module status for all modules on your switch:
Switch# show module all
Mod Ports Card Type
Model
Serial No.
----+-----+--------------------------------------+-----------------+----------1
2
1000BaseX (GBIC) Supervisor Module
WS-X4014
JAB012345AB
5
24
10/100/1000BaseTX (RJ45)
WS-X4424-GB-RJ45 JAB045304EY
6
48
10/100BaseTX (RJ45)
WS-X4148
JAB023402QK
M MAC addresses
Hw Fw
Sw
Stat
--+--------------------------------+---+-----------------+---------------+----1 0004.dd46.9f00 to 0004.dd46.a2ff 0.0 12.1(10r)EW(1.21) 12.1(10)EW(1)
Ok
5 0050.3e7e.1d70 to 0050.3e7e.1d87 0.0
Ok
6 0050.0f10.2370 to 0050.0f10.239f 1.0
Ok
Switch#
Name
Status
notconnect
notconnect
notconnect
notconnect
notconnect
notconnect
connected
connected
notconnect
notconnect
Vlan
1
1
1
1
1
1
1
2
1
1
Duplex
auto
auto
auto
auto
auto
auto
a-full
a-full
auto
auto
Speed
auto
auto
auto
auto
auto
auto
a-100
a-100
auto
auto
Type
No Gbic
No Gbic
10/100/1000-TX
10/100/1000-TX
10/100/1000-TX
10/100/1000-TX
10/100BaseTX
10/100BaseTX
10/100BaseTX
10/100BaseTX
Switch#
This example shows how to display the status of interfaces in error-disabled state:
Switch# show interfaces status err-disabled
Port
Name
Status
Reason
Fa9/4
err-disabled
link-flap
informational error message when the timer expires on a cause
-------------------------------------------------------------5d04h:%PM-SP-4-ERR_RECOVER:Attempting to recover from link-flap err-disable state on Fa9/4
Switch#
5-2
OL-6696-01
Chapter 5
This example shows how to display MAC address table information for a specific interface:
Switch# show mac-address-table interface gigabit 1/1
Multicast Entries
vlan
mac address
type
ports
-------+---------------+-------+------------------------------------------1
ffff.ffff.ffff system Switch,Gi6/1,Gi6/2,Gi6/9,Gi1/1
Switch#
Using Telnet
You can access the switch command-line interface (CLI) using Telnet. In addition, you can use Telnet
from the switch to access other devices in the network. You can have up to eight simultaneous Telnet
sessions.
Before you can open a Telnet session to the switch, you must first set the IP address (and in some cases
the default gateway) for the switch. For information about setting the IP address and default gateway,
see Chapter 3, Configuring the Switch for the First Time.
Note
To establish a Telnet connection to a host by using the hostname, configure and enable DNS.
5-3
Chapter 5
To establish a Telnet connection to another device on the network from the switch, perform this task:
Command
Purpose
This example shows how to establish a Telnet connection from the switch to the remote host named
labsparc:
Switch# telnet labsparc
Trying 172.16.10.3...
Connected to labsparc.
Escape character is '^]'.
UNIX(r) System V Release 4.0 (labsparc)
login:
Purpose
Purpose
5-4
OL-6696-01
Chapter 5
This example shows the output of the show users command when local authentication is enabled for
console and Telnet sessions (the asterisk [*] indicates the current session):
Switch#show users
Line
User
* 0 con 0
Interface
User
User
Host(s)
idle
Idle
00:00:00
Mode
Host(s)
idle
Idle
Idle
00:00:00
00:00:00
00:00:00
00:00:00
00:00:00
00:00:00
Mode
Idle
Location
Peer Address
Location
Peer Address
Purpose
This example shows how to disconnect an active console port session and an active Telnet session:
Switch> disconnect console
Console session disconnected.
Console> (enable) disconnect tim-nt.bigcorp.com
Telnet session from tim-nt.bigcorp.com disconnected. (1)
Switch# show users
Session User
Location
-------- ---------------- ------------------------telnet
jake
jake-mac.bigcorp.com
* telnet
suzy
suzy-pc.bigcorp.com
Switch#
Using Ping
These sections describe how to use IP ping:
5-5
Chapter 5
Using Ping
The ping command is configurable from normal executive and privileged EXEC mode. Ping returns one
of the following responses:
Destination does not respondIf the host does not respond, a No Answer message is returned.
Unknown hostIf the host does not exist, an Unknown Host message is returned.
Destination unreachableIf the default gateway cannot reach the specified network, a Destination
Unreachable message is returned.
Network or host unreachableIf there is no entry in the route table for the host or network, a
Network or Host Unreachable message is returned.
Running Ping
To ping another device on the network from the switch, perform this task:
Command
Purpose
This example shows how to ping a remote host from normal executive mode:
Switch# ping labsparc
labsparc is alive
Switch> ping 72.16.10.3
12.16.10.3 is alive
Switch#
This example shows how to enter a ping command in privileged EXEC mode specifying the number of
packets, the packet size, and the timeout period:
Switch# ping
Target IP Address []: 12.20.5.19
Number of Packets [5]: 10
Datagram Size [56]: 100
Timeout in seconds [2]: 10
Source IP Address [12.20.2.18]: 12.20.2.18
!!!!!!!!!!
----12.20.2.19 PING Statistics---10 packets transmitted, 10 packets received, 0% packet loss
round-trip (ms) min/avg/max = 1/1/1
Switch
5-6
OL-6696-01
Chapter 5
Using IP Traceroute
These sections describe how to use IP traceroute feature:
Running IP Traceroute
To trace the path that packets take through the network, perform this task in EXEC or privileged EXEC
mode:
Command
Purpose
5-7
Chapter 5
This example shows use the trace command to display the route a packet takes through the network to
reach its destination:
Switch# trace ip ABA.NYC.mil
Type escape sequence to abort.
Tracing the route to ABA.NYC.mil (26.0.0.73)
1 DEBRIS.CISCO.COM (192.180.1.6) 1000 msec 8 msec 4 msec
2 BARRNET-GW.CISCO.COM (192.180.16.2) 8 msec 8 msec 8 msec
3 EXTERNAL-A-GATEWAY.STANFORD.EDU (192.42.110.225) 8 msec 4 msec 4 msec
4 BB2.SU.BARRNET.NET (192.200.254.6) 8 msec 8 msec 8 msec
5 SU.ARC.BARRNET.NET (192.200.3.8) 12 msec 12 msec 8 msec
6 MOFFETT-FLD-MB.in.MIL (192.52.195.1) 216 msec 120 msec 132 msec
7 ABA.NYC.mil (26.0.0.73) 412 msec 628 msec 664 msec
Switch#
CDP must be enabled on all the devices in the network. For Layer 2 traceroute to functional properly,
do not disable CDP.
If any devices in the physical path are transparent to CDP, the switch cannot identify the path
through these devices.
Note
For more information about enabling CDP, see Chapter 20, Understanding and Configuring
CDP.
All switches in the physical path must have IP connectivity. When a switch is reachable from another
switch, you can test connectivity by using the ping command in privileged EXEC mode.
5-8
OL-6696-01
Chapter 5
You can enter the traceroute mac or the traceroute mac ip command in privileged EXEC mode on
a switch that is not in the physical path from the source device to the destination device. All switches
in the path must be reachable from this switch.
The traceroute mac command output shows the Layer 2 path only when the specified source and
destination MAC addresses belong to the same VLAN. If you specify source and destination MAC
addresses that belong to different VLANs, the Layer 2 path is not identified, and an error message
appears.
If you specify a multicast source or destination MAC address, the path is not identified, and an error
message appears.
If the source or destination MAC address belongs to multiple VLANs, you must specify the VLAN
to which both the source and destination MAC addresses belong. If the VLAN is not specified, the
path is not identified, and an error message appears.
The traceroute mac ip command output shows the Layer 2 path when the specified source and
destination IP addresses belong to the same subnet. When you specify the IP addresses, the switch
uses Address Resolution Protocol (ARP) to associate the IP address with the corresponding MAC
address and the VLAN ID.
If an ARP entry exists for the specified IP address, the switch uses the associated MAC address
address. If the IP address is not resolved, the path is not identified, and an error message
appears.
When multiple devices are attached to one port through hubs (for example, multiple CDP neighbors
are detected on a port), the Layer 2 traceroute feature is not supported. When more than one CDP
neighbor is detected on a port, the Layer 2 path is not identified, and an error message appears.
Purpose
or
Command
Purpose
5-9
Chapter 5
Configuring ICMP
These examples show how to use the traceroute mac and traceroute mac ip commands to display the
physical path a packet takes through the network to reach its destination:
Switch# traceroute mac 0000.0201.0601 0000.0201.0201
Source 0000.0201.0601 found on con6[WS-C2950G-24-EI] (2.2.6.6)
con6 (2.2.6.6) :Fa0/1 => Fa0/3
con5
(2.2.5.5
) :
Fa0/3 => Gi0/1
con1
(2.2.1.1
) :
Gi0/1 => Gi0/2
con2
(2.2.2.2
) :
Gi0/2 => Fa0/1
Destination 0000.0201.0201 found on con2[WS-C3550-24] (2.2.2.2)
Layer 2 trace completed
Switch#
Switch# traceroute mac ip 2.2.66.66 2.2.22.22 detail
Translating IP to mac .....
2.2.66.66 => 0000.0201.0601
2.2.22.22 => 0000.0201.0201
Source 0000.0201.0601 found on con6[WS-C2950G-24-EI] (2.2.6.6)
con6 / WS-C2950G-24-EI / 2.2.6.6 :
Fa0/1 [auto, auto] => Fa0/3 [auto, auto]
con5 / WS-C2950G-24-EI / 2.2.5.5 :
Fa0/3 [auto, auto] => Gi0/1 [auto, auto]
con1 / WS-C3550-12G / 2.2.1.1 :
Gi0/1 [auto, auto] => Gi0/2 [auto, auto]
con2 / WS-C3550-24 / 2.2.2.2 :
Gi0/2 [auto, auto] => Fa0/1 [auto, auto]
Destination 0000.0201.0201 found on con2[WS-C3550-24] (2.2.2.2)
Layer 2 trace completed.
Switch#
Configuring ICMP
Internet Control Message Protocol (ICMP) provides many services that control and manage IP
connections. ICMP messages are sent by routers or access servers to hosts or other routers when a
problem is discovered with the Internet header. For detailed information on ICMP, refer to RFC 792.
Purpose
5-10
OL-6696-01
Chapter 5
To limit the rate that Internet Control Message Protocol (ICMP) destination unreachable messages are
generated, perform this task:
Command
Purpose
Purpose
5-11
Chapter 5
Configuring ICMP
To have the Cisco IOS software respond to ICMP mask requests by sending ICMP Mask Reply
messages, perform this task:
Command
Purpose
5-12
OL-6696-01
C H A P T E R
Note
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
6-1
Chapter 6
Note
NSF capable devices are Catalyst 6500 series switches, Cisco 7500 series routers, Cisco 10000 series
routers, and Cisco 12000 series routers. The Catalyst 4500 series switch is an NSF-aware device for
Release 12.2(20)EWA.
For more information on BGP, EIGRP, OSPF, and IS-IS NSF-awareness, refer to the URL:
http://www.cisco.com/en/US/products/sw/iosswrel/ps1839/products_feature_guides_list.html
A typical topology for NSF and NSF-aware routers is given below.
Figure 6-1
Si
Si
Si
Catalyst 4500
NSF-Aware
Catalyst 4500
NSF-Aware
120103
6-2
OL-6696-01
Chapter 6
Table 6-1 lists the supervisor engines and Catalyst 4500 series switches that support NSF-awareness:
Table 6-1
NSF-Aware Capable Supervisor Engine and Catalyst 4500 Series Switch Matrix
Switch Support
In Release 12.2(20)EWA, NSF-awareness is supported on Catalyst 4500 series switches for EIGRP,
IS-IS, OSPF and BGP protocols. NSF-awareness is turned on by default for EIGRP, IS-IS and OSPF
protocols. For BGP, it needs to be turned on manually.
If the supervisor engine is configured for BGP (with the graceful-restart command), EIGRP, OSPF or
IS-IS routing protocols, routing updates are automatically sent during the supervisor engine switchover
of a neighboring NSF capable switch (typically a Catalyst 6500 series switch).
Overview
With supervisor engine redundancy enabled, if the active supervisor engine fails or if a manual
switchover is performed, the redundant supervisor engine becomes the active supervisor engine. The
redundant supervisor engine has been automatically initialized with the startup configuration of the
active supervisor engine, shortening the switchover time (30 seconds or longer in RPR mode, depending
on the configuration; subseconds in SSO mode).
In addition to the reduced switchover time, supervisor engine redundancy supports the following:
Software upgrade. (See the Performing a Software Upgrade section on page 6-12.)
To minimize down time during software changes on the supervisor engine, load the new image on
the redundant supervisor engine, and conduct a switchover.
6-3
Chapter 6
When power is first applied to a switch, the supervisor engine that boots first becomes the active
supervisor engine and remains active until a switchover occurs.
A switchover will occur when one or more of the following events take place:
The active supervisor engine fails (due to either hardware or software function) or is removed.
Table 6-2 provides information about chassis and supervisor engine support for redundancy.
Table 6-2
Chassis
(Product Number)
Catalyst 4507R
(WS-C4507R)
Catalyst 4510R
(WS-C4510R)
RPR Operation
RPR is supported in Release 12.2(12c)EW and later releases. When a redundant supervisor engine runs
in RPR mode, it starts up in a partially-initialized state and is synchronized with the persistent
configuration of the active supervisor engine.
Note
The redundant supervisor engine pauses the startup sequence after basic system initialization, and in the
event that the active supervisor engine fails, the redundant supervisor engine will become the new active
supervisor engine.
In a supervisor engine switchover, traffic is disrupted because in the RPR mode all of the physical ports
restart since there is no state maintained between supervisor engines relating to module types and
statuses. When the redundant supervisor engine completes its initialization, it will read hardware
information directly from the module.
SSO Operation
SSO is supported in Release 12.2(20)EWA and later releases. When a redundant supervisor engine runs
in SSO mode, the redundant supervisor engine starts up in a fully-initialized state and synchronizes with
the persistent configuration and the running configuration of the active supervisor engine. It
subsequently maintains the state on the protocols listed below, and all changes in hardware and software
states for features that support stateful switchover are kept in sync. Consequently, it offers no zero
interruption to Layer 2 sessions in a redundant supervisor engine configuration.
6-4
OL-6696-01
Chapter 6
Because the redundant supervisor engine recognizes the hardware link status of every link, ports that
were active before the switchover will remain active, including the uplink ports. However, because
uplink ports are physically on the supervisor engine, they will be disconnected if the supervisor engine
is removed.
If the active supervisor engine fails, the redundant supervisor engine become active. This newly active
supervisor engine uses existing Layer 2 switching information to continue forwarding traffic. Layer 3
forwarding will be delayed until the routing tables have been repopulated in the newly active supervisor
engine.
SSO supports stateful switchover of the following Layer 2 features. The state of these features is
preserved between both the active and redundant supervisor engines:
802.3
802.3u
802.3ab (GE)
802.3ad (LACP)
802.1q
802.1X (Authentication)
PAgP
VTP
DHCP snooping
IP source guard
MST
PVST+
Rapid-PVST
PortFast/UplinkFast/BackboneFast
Voice VLAN
Port security
QOS (DBL)
6-5
Chapter 6
SSO is compatible with the following list of features. However, the protocol database for these features
is not synchronized between the redundant and active supervisor engines:
Baby giants
CDP
Flood blocking
UDLD
SPAN/RSPAN
NetFlow
The following features are learned on the redundant supervisor engine if the SSO feature is enabled:
All Layer 3 protocols on Catalyst 4500 series switches (Switch Virtual Interfaces)
Note
You cannot enter CLI commands on the redundant supervisor engine console.
When the redundant supervisor engine boots, the auto-sync command synchronizes the persistent
configuration. This command is enabled by default. For details, refer to Synchronizing the
Supervisor Engine Configurations section on page 6-10.
When the active supervisor engine detects the redundant supervisor engine, the configuration
information is synchronized from the active supervisor engine to the redundant supervisor engine.
This synchronization overwrites any existing startup configuration file on the redundant supervisor
engine.
When you make changes to the configuration, you must use the write command to save and
synchronize the startup configuration of the redundant supervisor engine.
6-6
OL-6696-01
Chapter 6
When the active supervisor detects the redundant supervisor engine, synchronization of the
persistent and running configuration takes place, allowing the redundant supervisor engine to arrive
at a fully-initiated state.
When real-time changes occur, the active supervisor engine synchronizes the running-config and
(or) the persistent configuration (if necessary) with the redundant supervisor engine.
When you change the configuration, you must use the write command to allow the active supervisor
engine to save and synchronize the startup configuration of the redundant supervisor engine.
RPR requires Release 12.1(12c)EW, Release 12.1(19)E or later releases. SSO requires Release
12.2(20)EWA.
The Catalyst 4507R switch and the 4510R switch are the only Catalyst 4500 series switches that
support supervisor engine redundancy.
The Catalyst 4510R switch supports the WS-X4516 supervisor engine only. The Catalyst 4507R
switch supports supervisor engines WS-X4013+, WS-X4515, and WS-X4516.
Redundancy requires both supervisor engines in the chassis to be of the same supervisor engine
model and to use the same Cisco IOS software image.
Router ports are not supported when SSO redundancy mode is configured.
When you use the WS-X4013+ and WS-X4515 supervisor engines in RPR or SSO mode, only the
Gig1/1 and Gig2/1 Gigabit Ethernet interfaces are available, but the Gig1/2 and Gig2/2 uplink ports
are unavailable.
When the WS-X4516 active and redundant supervisor engines are installed in the same chassis, the
four uplink ports (Gig1/1, Gig2/1, Gig 1/2, and Gig2/2) are available.
The active and redundant supervisor engines in the chassis must be in slots 1 and 2.
Each supervisor engine in the chassis must have its own Flash device and console port connections
to operate the switch on its own.
Each supervisor engine must have a unique console connection. Do not connect a Y cable to the
console ports.
Supervisor engine redundancy does not provide supervisor engine load balancing.
The Cisco Express Forwarding (CEF) table is cleared on a switchover. As a result, routed traffic is
interrupted until route tables reconverge. This reconvergence time is minimal because the SSO
feature reduces the supervisor engine redundancy switchover time from 30+ seconds to subseconds,
so Layer 3 also has a faster failover time if the switch is configured for SSO.
Static IP routes are maintained across a switchover because they are configured from entries in the
configuration file.
Information about Layer 3 dynamic states that is maintained on the active supervisor engine is not
synchronized to the redundant supervisor engine and is lost on switchover.
6-7
Chapter 6
Starting with Cisco IOS Release 12.2, if an unsupported condition is detected (such as when the
active supervisor engine is running Release 12.2(20)EW and the redundant supervisor engine is
running Release 12.1(20)EW), the redundant supervisor engine will be reset multiple times and then
be placed in ROMMON mode. Therefore, it is important to follow the exact procedures outlined in
the Performing a Software Upgrade section on page 6-12.
If you are running (or upgrading to) Release 12.2(20)EWA or Release 12.2(25)EW and are using a
single supervisor engine in a redundant chassis (Catalyst 4507R or Catalyst 4510R series switch),
and you intend to use routed ports, do one of the following:
Use SVIs instead of routed ports.
Change the redundancy mode from SSO to RPR.
Configuration changes made to the redundant supervisor engine through SNMP are not
synchronized to the redundant supervisor engine.
After you configure the switch through SNMP, copy the running-config file to the startup-config file
on the active supervisor engine to trigger synchronization of the startup-config file on the redundant
supervisor engine. Then, reload the redundant supervisor engine so that new configuration is applied
on the redundant supervisor engine.
Configuring Redundancy
To configure redundancy, perform this task:
Command
Purpose
Step 1
Switch(config)# redundancy
Step 2
Step 3
Step 4
6-8
OL-6696-01
Chapter 6
This example shows how to configure the system for SSO and display the redundancy facility
information:
Switch> enable
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# redundancy
Switch(config-red)# mode sso
Switch(config-red)# end
Switch# show redundancy
Redundant System Information :
-----------------------------Available system uptime = 2 days, 2 hours, 39 minutes
Switchovers system experienced = 0
Standby failures = 0
Last switchover reason = none
Hardware Mode
Configured Redundancy Mode
Operating Redundancy Mode
Maintenance Mode
Communications
=
=
=
=
=
Duplex
Stateful Switchover
Stateful Switchover
Disabled
Up
6-9
Chapter 6
=
=
=
=
=
240000 milliseconds
9000 milliseconds
0
18
0x0
This example shows how to change the system configuration from RPR to SSO mode:
Switch(config)# redundancy
Switch(config-red)# mode
Switch(config-red)# mode sso
Changing to sso mode will reset the standby. Do you want to continue?[confirm]
Switch(config-red)# end
Switch#
*Aug 1 13:11:16: %C4K_REDUNDANCY-3-COMMUNICATION: Communication with the peer Supervisor
has been lost
*Aug 1 13:11:16: %C4K_REDUNDANCY-3-SIMPLEX_MODE: The peer Supervisor has been lost
This example shows how to change the system configuration from SSO to RPR mode:
Switch(config)# redundancy
Switch(config-red)# mode rpr
Changing to rpr mode will reset the standby. Do you want to continue?[confirm]
Switch(config-red)# end
*Aug 1 13:11:16: %C4K_REDUNDANCY-3-COMMUNICATION: Communication with the peer Supervisor
has been lost
*Aug 1 13:11:16: %C4K_REDUNDANCY-3-SIMPLEX_MODE: The peer Supervisor has been lost
Purpose
Step 1
Switch(config)# redundancy
Step 2
Switch(config-red)# main-cpu
Step 3
Step 4
Switch(config-r-mc)# end
Step 5
Note
Configuration changes made to the redundant supervisor engine through SNMP are not synchronized to
the redundant supervisor engine. For information on how to handle this situation, see the Supervisor
Engine Redundancy Guidelines and Restrictions section on page 6-7.
6-10
OL-6696-01
Chapter 6
Note
The auto-sync command controls the synchronization of the config-reg, bootvar, and startup/private
configuration files only. The calendar and VLAN database files are always synchronized when they
change. In SSO mode, the running-config is always synchronized.
This example shows how to reenable the default automatic synchronization feature using the auto-sync
standard command to synchronize the startup-config and config-register configuration of the active
supervisor engine with the redundant supervisor engine. Updates for the boot variables are automatic
and cannot be disabled.
Switch(config)# redundancy
Switch(config-red)# main-cpu
Switch(config-r-mc)# auto-sync standard
Switch(config-r-mc)# end
Switch# copy running-config startup-config
Note
To manually synchronize individual elements of the standard auto-sync configuration, disable the default
automatic synchronization feature.
This example shows how to disable default automatic synchronization and allow only automatic
synchronization of the config-registers of the active supervisor engine to the redundant supervisor
engine, while disallowing synchronization of the startup configuration:
Switch(config)# redundancy
Switch(config-red)# main-cpu
Switch(config-r-mc)# no auto-sync standard
Switch(config-r-mc)# auto-sync config-register
Switch(config-r-mc)# end
Note
This discussion assumes that SSO has been configured as the redundant mode.
To perform a manual switchover, perform this task on the active supervisor engine:
Step 1
Command
Purpose
Step 2
6-11
Chapter 6
To force a switchover, the redundant supervisor engine must be in a standby hot state. You can verify
the state with the show redundancy command. If the state is not standby hot, the
redundancy force-switchover command will not execute.
Use the redundancy force-switchover command, rather than the reload command, to initiate a
switchover. The redundancy force-switchover command will first check that the redundant
supervisor engine is in the correct state. If you issue the reload command and the status is not
standby hot, the reload command will reset the current supervisor engine only.
After an initial switchover, there might be occasions when you want to make the supervisor engine in
slot 1 of the chassis the active supervisor engine. If the image on supervisor engine 1 is the one you
intend to run on both supervisor engines, it is not necessary to re-boot the image on the supervisor engine
in slot 1 to make it redundant. Instead, you can force another switchover. However, if you want a newer
version of the image to run on both supervisor engines, follow the steps under Performing a Software
Upgrade on page 12. Use the show module command to see which slot contains the active supervisor
engine, and force another switchover if necessary.
Step 1
Command
Purpose
Or:
Switch# copy source_device:source_filename
bootflash:target_filename
Step 2
Or:
Switch# copy source_device:source_filename
slavebootflash:target_filename
Step 3
Step 4
Switch(config)# redundancy
Step 5
Switch(config-red)# main-cpu
Step 6
Step 7
Switch(config-r-mc)# end
Step 8
6-12
OL-6696-01
Chapter 6
Step 9
Command
Purpose
This example illustrates how to verify that the running configuration on the active supervisor engine has
successfully synchronized with the redundant supervisor engine:
Switch# config terminal
Switch(config)# redundancy
Switch(config-red)# main-cpu
Switch(config-r-mc)# auto-sync standard
4d01h: %C4K_REDUNDANCY-5-CONFIGSYNC:
standby supervisor
4d01h: %C4K_REDUNDANCY-5-CONFIGSYNC:
the standby supervisor
4d01h: %C4K_REDUNDANCY-5-CONFIGSYNC:
to the standby supervisor
4d01h: %C4K_REDUNDANCY-5-CONFIGSYNC:
to the standby supervisor
The example above shows that the boot variable, the config-register, and the startup configuration from
the active supervisor engine have successfully synchronized to the redundant supervisor engine.
6-13
Chapter 6
To manipulate the redundant supervisor engine bootflash, perform one or more of the following tasks:
Command
Purpose
Or:
Switch# dir slavebootflash:target_filename
Switch# delete slaveslot0:target_filename
Or:
Switch# delete slave bootflash:target_filename
Switch# squeeze slaveslot0:target_filename
Or:
Or:
Or:
6-14
OL-6696-01
C H A P T E R
Note
Before reading this chapter, read the "Preparing for Installation section of the
Catalyst 4500 Series Installation Guide. It is important to ensure that your installation site has enough
power and cooling to accommodate the additional electrical load and heat introduced by PoE.
This chapter describes power management and environmental monitoring features in the Catalyst 4500
series switches. It provides guidelines, procedures, and configuration examples.
This chapter consists of the following major sections:
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
7-1
Chapter 7
Keyword
Purpose
alarm
status
temperature
The following example shows how to display the environment conditions. This output indicates that the
power supplies are different. The switch will use only one power supply and disable the other.
Switch# show environment
no alarm
Chassis Temperature
= 35 degrees Celsius
Chassis Over Temperature Threshold
= 75 degrees Celsius
Chassis Critical Temperature Threshold = 95 degrees Celsius
Power
Supply
-----PS1
PS2
Model No
---------------PWR-C45-2800AC
PWR-C45-1000AC
Type
--------AC 2800W
AC 1000W
Status
----------good
err-disable
Fan
Sensor
-----good
good
Inline
Status
-----good
n.a.
System Alarms
The system has two types of alarms: major and minor. A major alarm indicates a critical problem that
could lead to system shutdown. A minor alarm is informationalit alerts you to a problem that could
turn critical if corrective action is not taken.
When the system issues an alarm (major or minor) that indicates an over-temperature condition, the
switch does not cancel the alarm nor take any action (such as module reset or shutdown) for five minutes.
If the temperature falls 5 degrees Celsius below the alarm threshold during this period, the alarm is
canceled.
An LED on the supervisor indicates if an alarm has been issued. See Table 7-2 for more information.
Note
Refer to the Catalyst 4500 Series Switch Module Installation Guide for information on LEDs, including
the startup behavior of the supervisor engine system LED.
7-2
OL-6696-01
Chapter 7
Table 7-2
Event
1
Alarm
Type
Supervisor LED
Color
Major
Red
Syslog message.
If the over-temperature condition is not corrected,
the system shuts down after 5 min.
Alarm threshold:
Red
Major
Syslog message.
Major
Red
Minor
Orange
Syslog message.
No problems
None
Green
1. The Supervisor is not a distinct module on the Catalyst 4948 switch as it is on Catalyst 4500 series switches. See the Catalyst 4948 Installation Guide
for LED behavior on the Catalyst 4948 switch.
2. Temperature sensors monitor key supervisor engine components, including daughter cards.
Power Management
This section describes the power management feature in the Catalyst 4500 series switches and the
Catalyst 4006 switch, and it includes the following major sections:
Power Management for the Catalyst 4500 Series Switches, page 7-4
7-3
Chapter 7
Power Management
These power supplies are incompatible with Catalyst 4500 series switches. Since Power over Ethernet
(PoE) is not supported on the Catalyst 4948 switch, only a limited wattage is needed. (For information
on PoE, see Chapter 8, Configuring Power over Ethernet.) When you insert power supplies in your
switch, the EEPROM on the power supplies can be read by the system software even if the supply is not
powered on. You may mix AC and DC power supplies.
Fixed WattageThis power supply always delivers a fixed amount of PoE and system power.
1000 W AC (not recommended on the Catalyst 4510R switch, PoE not supported)
1400 W ACData-only and does not support PoE
Variable WattageThese power supplies automatically adjusts the wattage to accommodate PoE
and system power requirements.
1300 W ACSupports PoE.
1400 W DCSupports up to 1400 W of system power and variable amounts of PoE, depending
on the input feed to the power supply. See Special Considerations for the 1400 W DC Power
Supply section on page 7-10 for more information.
1400 W DC Service ProviderUses up to three lines (12.5 A, 15 A, 15 A) of DC input and
delivers varying amounts of power in the range 400 W-1400 W depending on the lines powered.
See Special Considerations for the 1400 W DC SP Triple Input Power Supply section on
page 7-11 for more information.
2800 W ACSupports up to 1400 W of system power and up to 1400 W of PoE.
Note
All Catalyst 4500 series switch AC-input power supplies require single-phase source AC. The source AC
can be out of phase between multiple power supplies or multiple AC-power plugs on the same power
supply because all AC power supply inputs are isolated. Each chassis power supply should have its own
dedicated branch circuit: 20A for North America and circuits sized to local and national codes for
International locations.
When you insert power supplies in your switch, use power supplies that are of the same wattage. If you
mix power supplies, the switch will use the one it recognizes first and ignore the other power supply. The
power supply status displays as err-disable and the summary displays as all zeros (0) for wattage values
in the output for the show power command.
7-4
OL-6696-01
Chapter 7
The following example shows the output for the show power command for mixed power supplies:
Switch#
Power
Supply
-----PS1
PS2
show power
Model No
---------------PWR-C45-2800AC
PWR-C45-1000AC
Type
--------AC 2800W
AC 1000W
Status
----------good
err-disable
Fan
Sensor
-----good
good
Inline
Status
-----good
n.a.
Maximum
Used
Available
-----------328
1360
0
1400
10
40
---338 (not to exceed Total Maximum Available = 750)
Redundant modeRedundant mode uses one power supply as a primary power supply and the
second power supply as a back-up. If the primary power supply fails, the second power supply
immediately supports the switch without any disruption in the network. Both power supplies must
be the same wattage. A single power supply must have enough power to support the switch
configuration.
Combined modeCombined mode uses the power from all installed power supplies to support the
switch configuration power requirements. However, combined mode has no power redundancy. If a
power supply fails, one or more modules might shut down.
Note
On the Catalyst 4510R switch, the 1000 W AC power supply is not enough to support redundant
mode for all possible configurations. It is able to support redundant mode for limited
configurations that require less than 1000 W.
Note
The 1400 W DC power supply supports combined mode for data power. It does not support
combined mode for PoE power.
7-5
Chapter 7
Power Management
Your switch hardware configuration will dictate which power supply or supplies you should use. For
example, if your switch configuration requires more power than a single power supply provides, use the
combined mode. In combined mode, however, the switch has no power redundancy. Consider the
following possibilities:
The supervisor engine consumes 110 W, the fan boxes for the Catalyst 4503 switch consume 30 W
each, the fan boxes for the Catalyst 4506 and Catalyst 4507 switches consume 50 W each, the
backplane for the Catalyst 4503 and Catalyst 4506 switches consumes 10 W, and the backplane for
the Catalyst 4507 switch consumes 40 W.
1000 W can support a fully loaded Catalyst 4503 switch with no powered device support.
1300 W can support a fully loaded Catalyst 4503 switch with Cisco powered devices.
Each PoE port on a WS-X4148-RJ45V module requires 6.3 W. Five fully loaded WS-X4148-RJ45V
modules in a switch comprise 240 ports. This configuration requires 1512 W of PoE, plus 300 W for
the modules.
The power requirements for the installed modules exceed the power provided by the power supplies.
If you insert a single power supply and then set the switch to combined mode, the switch displays
this error message:
Insufficient power supplies present for specified configuration.
This error message also displays in the output for the show power command. This error message
displays because, by definition, combined mode requires that two working power supplies be
installed in your switch.
If the power requirements for the installed modules exceeds the power provided by the power
supplies, the switch displays this error message:
Insufficient power available for the current chassis configuration.
This error message also appears in the show power command output.
If you attempt to insert additional modules into your switch and exceed the power supply, the switch
immediately places the newly inserted module into reset mode, and the switch displays these error
messages:
Module has been inserted
Insufficient power supplies operating.
Additionally, if you power down a functioning switch and insert an additional module or change the
module configuration so that the power requirements exceed the available power, one or more
modules enter reset mode when you power on the switch again.
The power requirements for the PoE exceed the PoE provided by the power supplies.
If you have too many IP phones drawing power from the system, power to IP phones is cut, and some
phones may be powered down to reduce the power requirements to match the power supplies.
In the first scenario (power requirements exceed the power supplied), the system attempts to resolve this
power usage limitation by evaluating the type and number of modules installed. During the evaluation
cycle, beginning from the bottom of the chassis, the system puts the modules that it is unable to support
(for lack of power) into reset mode. The supervisor engine and modules for which there is adequate
7-6
OL-6696-01
Chapter 7
power always remain enabled, with no disruption of network connectivity. Modules placed in reset mode
still consume some power and can be removed from the chassis to further reduce power requirements. If
you configure the chassis correctly, the system will not enter the evaluation cycle.
A module in reset mode continues to draw power as long as it is installed in the chassis; you can use the
show power module command to determine how much power is required to bring the module online.
To compute the power requirements for your system and verify that your system has enough power, add
the power consumed by the supervisor engine module(s), the fan box(es), and the installed modules
(including PoE). For PoE, total the requirements for all the phones. See the Powering Down a Module
section on page 7-15 for more information on the power consumption for the various components of your
switch.
The 802.3af-compliant PoE modules can consume up to 20 W of PoE to power FPGAs and other
hardware components on the module. Be sure to add at least 20 W to your PoE requirements for each
802.3af-compliant PoE module to ensure that the system has adequate power for the PDs connected to
the switch.
On the WS-X4148-RJ45V PoE module, PoE consumption cannot be measured. Therefore, for all PoE
calculations, the PoE consumption on this module is presumed to be equal to its administrative PoE.
You can use the show module command to verify which modules are active and which, if any, have been
placed in reset.
The following example shows the show module command output for a system with inadequate power
for all installed modules. The system does not have enough power for Module 5; the Status displays
it as PwrDeny.
If the PoE that is consumed by the module is more than 50 W above the PoE you allocated using the
power inline consumption default command, the Status displays as PwrOver. If the PoE consumed
by the module is more than 50 W above the PoE module limit, the Status displays as PwrFault.
Switch# show module
Mod Ports Card Type
Model
Serial No.
----+-----+--------------------------------------+-----------------+----------1
2 1000BaseX (GBIC) Supervisor(active)
WS-X4014
JAB054109GH
2
6 1000BaseX (GBIC)
WS-X4306
00000110
3
18 1000BaseX (GBIC)
WS-X4418
JAB025104WK
5
0 Not enough power for module
WS-X4148-FX-MT
00000000000
6
48 10/100BaseTX (RJ45)
WS-X4148
JAB023402RP
M MAC addresses
Hw Fw
Sw
Status
--+--------------------------------+---+------------+----------------+--------1 005c.9d1a.f9d0 to 005c.9d1a.f9df 0.5 12.1(11br)EW 12.1(20020313:00 Ok
2 0010.7bab.9920 to 0010.7bab.9925 0.2
Ok
3 0050.7356.2b36 to 0050.7356.2b47 1.0
Ok
5 0001.64fe.a930 to 0001.64fe.a95f 0.0
PwrDeny
6 0050.0f10.28b0 to 0050.0f10.28df 1.0
Ok
Switch#
If you have the power management mode set to redundant mode and only one power supply
installed, your switch will accept the configuration but operates without redundancy.
7-7
Chapter 7
Power Management
Caution
If you have power supplies with different types or different wattages installed in your switch, the switch
will not recognize one of the power supplies and will not have power redundancy.
For fixed power supplies, choose a power supply that by itself is powerful enough to support the
switch configuration.
For variable power supplies, choose a power supply that provides enough power so that the chassis
and PoE requirements are less than the maximum available power. Variable power supplies
automatically adjust the power resources at startup to accommodate the chassis and PoE
requirements. Modules are brought up first, followed by IP phones.
The maximum available power for chassis and PoE for each power supply are listed in Table 7-3 on
page 7-10.
To configure redundant mode on your Catalyst 4500 series switch, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
Step 4
Note
The power redundancy-mode redundant command is not supported on a Catalyst 4006 switch.
The following example shows how to set the power management mode to redundant mode.
Switch (config)# power redundancy-mode redundant
Switch (config)# end
Switch#
The following example shows how to display the current power redundancy mode. The power supplies
needed by system: 1 indicates that the switch is in redundant mode.
Switch# show power supplies
Power supplies needed by system :1
Switch#
Use power supplies of the same type and wattage (fixed or variable and AC or DC).
If you use power supplies with different types or wattages, the switch will utilize only one of the
power supplies.
7-8
OL-6696-01
Chapter 7
For variable power supplies, choose a power supply that provides enough power so that the chassis
and PoE requirements are less than the maximum available power. Variable power supplies
automatically adjust the power resources at startup to accommodate the chassis and PoE
requirements.
The 1400 W DC power supply does not support combined mode. If you set the power budget to 2,
the switch disregards this setting.
If you have the power management mode set to combined mode and only one power supply installed,
your switch will accept the configuration, but power is available from only one power supply.
When your switch is configured to combined mode, the total available power is not the mathematical
sum of the individual power supplies. The power supplies have a predetermined current sharing ratio
(See Table 7-3 on page 7-10 for more information.)
The maximum available power for chassis and PoE for each power supply are listed in Table 7-3 on
page 7-10.
To configure combined mode on your Catalyst 4500 series switch, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
Step 4
Note
The power redundancy-mode combined command does not work on a Catalyst 4006 switch.
The following example shows how to set the power management mode to combined mode.
Switch (config)# power redundancy-mode combined
Switch (config)# end
Switch#
The following example shows how to display the current power redundancy mode. The power supplies
needed by system: 2 indicates that the switch is in combined mode.
Switch# show power supplies
Power supplies needed by system :2
Switch#
7-9
Chapter 7
Power Management
Table 7-3
Power Supply
1000 W AC
1300 W AC
Sharing Ratio
Chassis = 1000
Chassis = 1667
2/3
PoE = 0
PoE = 0
2/3
Chassis = 22674
PoE
Chassis2/3
PoE0
Chassis = 1360
PoE = 0
2800 W AC
Chassis = 2473
9/11
PoE = 0
Chassis = 1360
Chassis = 2473
Chassis79/11
PoE = 1400
PoE = 2333
PoE82/3
1. Chassis power includes power for the supervisor(s), all line cards, and the fan tray.
2. The efficiency for the 1400 W DC power supply is 0.75, and 0.96 is applied to PoE.
3. DC input can vary for the 1400 W DC power supply and is configurable. For more information, see Special Considerations
for the 1400 W DC Power Supply on page 10.
4. Not available for PoE.
5. Not available for PoE.
6. No voice power.
7. Data-only.
8. Inline power.
Do not mix the 1400 W DC power supply with any other power supply, even for a hot swap or other
short-term emergency. Doing so can seriously damage your switch.
Keep in mind the following guidelines when using a 1400 W DC power supply with your Catalyst 4500
series switch:
The 1400 W DC power supply works with a variety of DC sources. The DC input can vary from
300 W to 7500 W. Refer to the power supply documentation for additional information.
The supervisor engine cannot detect the DC source plugged into the 1400 W DC power supply. If
you are using the 1400 W DC power supply, use the power dc input command to set the DC input
power. For more information on this command, see the Configuring the DC Input for a Power
Supply section on page 7-11.
7-10
OL-6696-01
Chapter 7
The software automatically adjusts between system power (for modules, backplane, and fans) and
PoE. Although PoE is 96 percent efficient, system power has only 75 percent efficiency. For
example, each 120 W of system power requires 160 W from the DC input. This requirement is
reflected in the Power Used column of the output for the show power available command.
The 1400 W DC power supply does not support combined mode. If you set the power budget to 2
(combined mode), the switch allows you to configure combined modes but disregards the setting and
remains in redundant mode.
The 1400 W DC power supply has a separate power on or off switch for PoE. The power supply fan
status and main power supply status are tied together. If either of them fails, both the power supply
and its fan report as bad/off. You should verify that the main power is on before turning on the power
for the inline switch. In addition, you should verify that the power for the inline switch is off before
turning off the main power.
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
The same configuration is applied to both power slots. For example, if you set the dc power input to
1000 W, the switch expects 1000 W as the external DC source for both slot 1and slot 2 (if present)
respectively.
The following example shows how to set the external DC power source to 1000 W:
Switch# configure terminal
Switch (config)# power dc input 1000
Switch (config)# end
Switch#
If you use the 1400 W DC SP power supply in combined mode, the inputs do not have to match.
show power
Model No
---------------PWR-C45-1400DC
Type
--------DCSP1400W
12.5A
15.0A
15.0A
Status
----------good
good
bad
off
PS2
none
--
--
Fan
Sensor
------good
Inline
Status
------n.a.
--
--
7-11
Chapter 7
Power Management
Keep in mind the following guidelines when using a 1400 W DC SP power supply with your Catalyst
4500 series switch:
When you use two 48 V power rails to drive two power supplies, you might employ cross-wiring to
connect the power supplies (to rails) to minimize the "inrush" current drawn during an initial power
up. In this situation, you should configure the switch in combined mode before you take a rail down
for maintenance.
Ordinarily, when configured for redundancy, two power supplies must be "matched" ( have identical
inputs). For example, you might provide power to inputs 1 and 3 on both PS1 and PS2. If power
supplies are mismatched upon bootup, the right (second) power supply will be in err-disable state.
One Catalyst 4006 chassis with a WS-X4014 supervisor engine with two 400 W power supplies (in
1+1 redundancy mode) and four WS-X4148-RJ or WS-X4148-RJ21 modules
One Catalyst 4006 chassis with a WS-X4014 supervisor engine with two 650 W power supplies (in
1+1 redundancy mode) and five WS-X4148-RJ or WS-X4148-RJ21 modules
Although other configurations are possible, we do not recommend that you use them without careful
consideration of the power usage in the system. For example, other similar and possible configurations
may consist of four modules that consume less power, and the total module power usage does not exceed
the absolute maximum power usage for the system.
The supervisor engine uses 110 W, the fan box uses 25 W, and the backplane does not consume any
power. The system total load for the modules + supervisor + fan cannot total more than the power
supplied by the power supply. The 1+1 redundancy mode might not support a fully loaded chassis and,
therefore, one slot of the chassis might be empty. An attempt to use five modules risks an
oversubscription of available power.
7-12
OL-6696-01
Chapter 7
If you opt to use the 1+1 redundancy mode, the type and number of modules supported are limited by
the power available from a single power supply. To determine the power consumption for each module
in your chassis, see the Powering Down a Module section on page 7-15.
To choose a 1+1 redundancy configuration, you must change the system configuration from the default
2+1 redundancy mode to 1+1 redundancy mode by using the power supplies required 1 command. The
power supplies required 1 command sets the power redundancy to 1+1 redundancy mode. In the 1+1
redundancy mode, the nonredundant power available to the system is the power of the single weakest
power supply. The second power supply installed in your switch provides full redundancy.
This message will also appear in the show power command output.
If you are already operating in 1+1 redundancy mode with a valid module configuration and you attempt
to insert additional modules that require more power than the single power supply provides, the system
immediately places the newly inserted module into reset mode and issues these error messages:
Module has been inserted
Insufficient power supplies operating
Additionally, if a chassis that has been operating in 1+1 redundancy mode with a valid module
configuration is powered down, and you insert a module or change the module configuration
inappropriately and power on the switch again, the module(s) in the chassis (at boot up) that require more
power than is available, are placed into reset mode.
A module in reset mode continues to draw power as long as it is installed in the chassis and as long as
the show module command output indicates that there is not enough power for the module to be brought
out of reset mode.
A single power supply provides 400 W or 650 W. Two 400 W power supplies provide 725 W. Two 650 W
power supplies supply only 750 W. The 750 W limit is a restriction on the power supply cooling capacity
for the Catalyst 4006 switches.
If you mix a 400 W power supply and a 650 W power supply, the switch performs as if there were two
400 W power supplies. If you have one 400 W power supply and one 650 W power supply in 1+1
redundancy mode, and a second 650 W power supply is set as the backup, the system performs as if there
were 400 W. If the 400 W power supply fails, the backup 650 W power supply comes into service;
however, the switch still has only 400 W available. You need to remove the failed 400 W power supply
for the switch to make use of the 650 W available.
To compute the power requirements for your system and verify that your system has enough power, add
up the power consumed by the supervisor engine module, the fan box, and the installed modules. (See
the Powering Down a Module section on page 7-15 for more information on the power consumption
for the various components of your switch.) For 1+1 redundancy mode, verify that the total is less than
400 W or 650 W, depending on the power supplies installed in your switch. The following examples are
provided to further explain the use of power supplies.
The following configuration requires a minimum of 395 W:
7-13
Chapter 7
Power Management
Fan tray25 W
This configuration requires less than the maximum that a single power supply can provide in 1+1
redundancy mode.
The following configuration requires more power than a single 400 W power supply can provide:
Fan tray25 W
This configuration requires 445 W and cannot be used in 1+1 redundancy mode for a 400 W power
supply. A single 650 W power supply provides enough power for 1+1 redundancy mode for this
configuration.
The following configuration requires more power than either a single 400 W or 650 W power supply can
provide:
Five 48-port 100BASE-FX modules in slots 2 through 6120 W each (600 W total)
Fan box25 W
This configuration requires 735 W and cannot be used in 1+1 redundancy mode for either a 400 W or
650 W power supply.
Remember, when considering the 1+1 redundancy mode, you must carefully plan the configuration of
the module power usage of your chassis. An incorrect configuration will momentarily disrupt your
system during the evaluation cycle. To avoid this disruption, carefully plan your configuration to ensure
that it is within the power limits, or return to the default 2+1 redundancy configuration by installing a
third power supply in your switch and setting the power redundancy to 2+1 redundancy mode.
Use the power supplies required 2 command to set the power redundancy to the 2+1 redundancy mode.
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
Step 4
Note
The power supplies required command is not supported on a Catalyst 4500 series switch.
{1
| 2}
7-14
OL-6696-01
Chapter 7
Switch#
The following example shows how to display the current power status of system components and the
power redundancy mode. The Power supplies needed by system: 1 indicates that the switch is in 1+1
redundancy mode:
Switch# show power supplies
Power supplies needed by system :1
Switch#
The following example shows the show module command output for a system with inadequate power
for all installed modules. The system does not have enough power for Module 5; the Status displays
it as PwrDeny.
Switch# show module
Mod Ports Card Type
Model
Serial No.
----+-----+--------------------------------------+-----------------+----------1
2 1000BaseX (GBIC) Supervisor(active)
WS-X4014
JAB054109GH
2
6 1000BaseX (GBIC)
WS-X4306
00000110
3
18 1000BaseX (GBIC)
WS-X4418
JAB025104WK
5
0 Not enough power for module
WS-X4148-FX-MT
00000000000
6
48 10/100BaseTX (RJ45)V, Cisco/IEEE
WS-X4248-RJ45V
JAB074804LE
M MAC addresses
Hw Fw
Sw
Status
--+--------------------------------+---+------------+----------------+--------1 005c.9d1a.f9d0 to 005c.9d1a.f9df 0.5 12.1(11br)EW 12.1(20020313:00 Ok
2 0010.7bab.9920 to 0010.7bab.9925 0.2
Ok
3 0050.7356.2b36 to 0050.7356.2b47 1.0
Ok
5 0001.64fe.a930 to 0001.64fe.a95f 0.0
PwrDeny
6 000d.edc6.dac0 to 000d.edc6.daef 2.0
Ok
Switch#
Purpose
To power on a module that has been powered down, perform this task:
Command
Purpose
7-15
Chapter 7
Power Management
7-16
OL-6696-01
C H A P T E R
Note
Before reading this chapter, read "Preparing for Installation section of the
Catalyst 4500 Series Installation Guide. It is important to ensure that your installation site has enough
power and cooling to accommodate the additional electrical load and heat introduced by PoE.
This chapter describes how to configure Power over Ethernet (PoE) on the Catalyst 4500 series switch.
This chapter contains the following sections:
Catalyst 4500 series switches can sense if a powered device is connected to a PoE module. They can
supply PoE to the powered device if there is no power on the circuit. (If there is power on the circuit, the
switch does not supply it.) The powered device can also be connected to an AC power source and supply
its own power to the voice circuit.
Note
A powered device is any device connected to the switch that requires external power or can utilize PoE,
for example, an access point or Cisco IP phone.
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
8-1
Chapter 8
autoPoE interface. The supervisor engine directs the switching module to power up the interface
only if the switching module discovers the phone and the switch has enough power. You can specify
the maximum wattage that is allowed on the interface. If you do not specify a wattage, then the
switch will deliver no more than the hardware-supported maximum value. This mode has no effect
if the interface is not capable of providing PoE.
staticHigh priority PoE interface. The supervisor engine preallocates power to the interface, even
when nothing is connected, guaranteeing that there will be power for the interface. You can specify
the maximum wattage that is allowed on the interface. If you do not specify a wattage, then the
switch preallocates the hardware-supported maximum value. If the switch does not have enough
power for the allocation, the command will fail. The supervisor engine directs the switching module
to power up the interface only if the switching module discovers the powered device.
neverData interface only The supervisor engine never powers up the interface, even if an
unpowered phone is connected. This mode is only needed when you want to make sure power is
never applied to a PoE-capable interface.
The switch can measure the actual PoE consumption for an 802.3af-compliant PoE module, and displays
this in the show power module command. However, it cannot display the consumption of an individual
interface on an 802.3af-compliant PoE module.
PoE consumption cannot be measured on the WS-X4148-RJ45V PoE module. Therefore, for all PoE
calculations, the PoE consumption on this module is presumed to be equal to its administrative PoE.
For more information, see the Displaying the PoE Consumed by a Module section on page 8-7.
For most users, the default configuration of auto works well, providing plug and play capability. No
further configuration is required. However, to make an interface higher priority or data only, or to specify
a maximum wattage, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# end
Step 4
If you set a non-PoE-capable interface to automatically detect and apply power, an error message
indicates that the configuration is not valid.
8-2
OL-6696-01
Chapter 8
The following example shows how to set the Fast Ethernet interface 4/1 to automatically detect PoE and
send power through that interface:
Switch# configure terminal
Enter configuration commands, one per line.
Switch(config)# interface fastethernet 4/1
Switch(config-if)# power inline auto
Switch(config-if)# end
This example shows how to verify the PoE configuration for the Fast Ethernet interface 4/1:
Switch# show power inline fastethernet 4/1
Available:677(w) Used:11(w) Remaining:666(w)
Interface Admin
Oper
Power(Watts)
Device
Class
From PS
To Device
--------- ------ ---------- ---------- ---------- ------------------- ----Fa4/1
auto
on
11.2
10.0
Ieee PD
0
Interface
AdminPowerMax
AdminConsumption
(Watts)
(Watts)
---------- --------------- -------------------Fa4/1
15.4
10.0
Switch#
The following example shows how to configure an interface so that it never supplies power through the
interface:
Switch# configure terminal
Enter configuration commands, one per line.
Switch(config)# interface fastethernet 5/2
Switch(config-if)# power inline never
Switch(config-if)# end
Switch#
Overview
By default, when the switch detects a powered device on an interface, it assumes the powered device
consumes the maximum the port can provide (7 W on a legacy Power over Ethernet (PoE) module and
15.4W on the IEEE PoE modules introduced in Release 12.2(18)EW). Then, when the switch receives a
CDP packet from the powered device, the wattage automatically adjusts downward to the specific
amount required by that device. Normally, this automatic adjustment works well, and no further
configuration is required or recommended. However, you can specify the powered devices consumption
for the entire switch (or for a particular interface) to provide extra functionality from your switch. This
is useful when CDP is disabled or not available.
Note
When manually configuring the consumption for powered devices, you need to account for the power
loss over the cable between the switch and the powered device.
8-3
Chapter 8
To change the power consumption for the entire switch, perform this task:
Step 1
Command
Purpose
Step 2
Switch(config)# end
Step 3
This example shows how to set the default PoE consumption of all powered devices connected to the
switch to 5000 milliwatts:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# power inline consumption default 5000
Switch(config)# end
Switch#
To change the power consumption of a single powered device, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# end
Step 4
This example shows how to set the PoE consumption to 5000 milliwatts for Fast Ethernet interface 4/1
regardless what is mandated by the 802.3af class of the discovered device, or by any CDP packet
received from the powered device:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface fastethernet 4/1
Switch(config-if)# power inline consumption 5000
Switch(config-if)# end
Switch#
8-4
OL-6696-01
Chapter 8
This example shows how to verify the PoE consumption for a given interface:
Switch# show power inline fastethernet 4/1
Available:677(w) Used:11(w) Remaining:666(w)
Interface Admin
Oper
Power(Watts)
Device
Class
From PS
To Device
--------- ------ ---------- ---------- ---------- ------------------- ----Fa4/1
on
auto
11.2
10.0
Ieee PD
Interface
AdminPowerMax
AdminConsumption
(Watts)
(Watts)
---------- --------------- -------------------Fa4/1
Switch#
15.4
10.0
BIP-1236/S (BATM)
RIT balun with integrated unshielded twisted pair (UTP) cable, 6 and 24 foot lengths
8-5
Chapter 8
Catalyst 4500
series switch UTP Cable
Balun
Type 1/2
STP Cable
Balun
UTP Cable
Powered
Device
(Cisco IP Phone)
120556
Figure 8-1
In Figure 8-1, a Catalyst 4500 series switch is connected to a balun through a short length of Cat5 UTP
cable. Type 1/2 STP cable connects this balun to the next balun. Finally, another short length of Cat5
UTP cable connects the second balun to another Powered Device (e.g. Cisco IP phone).
offPower is not supplied by the port. If a powered device is connected to an interface with external
power, the switch does not recognize the powered device. The Device column in the show power
inline command displays as n/a.
Power-denyThe supervisor engine does not have enough power to allocate to the port, or the
power that is configured for the port is less than the power required by the port; power is not being
supplied by the port.
err-disableThe port is unable to provide power to the connected device that is configured in static
mode.
You can use the show power inline command to view the operational status for an interface.
This example shows how to display the operational status for all interfaces on module 3.
Switch# show power inline module 3
Available:677(w) Used:117(w) Remaining:560(w)
Interface Admin
Oper
Power(Watts)
Device
Class
From PS
To Device
--------- ------ ---------- ---------- ---------- ------------------- ----Fa3/1
Fa3/2
Fa3/3
Fa3/4
Fa3/5
Fa3/6
Fa3/7
Fa3/8
Fa3/9
Fa3/10
Fa3/11
on
on
on
on
on
on
on
on
on
on
off
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
17.3
4.5
7.1
7.1
17.3
17.3
4.5
7.9
17.3
17.3
0
15.4
4.0
6.3
6.3
15.4
15.4
4.0
7.0
15.4
15.4
0
Ieee PD
0
Ieee PD
1
Cisco IP Phone 7960 0
Cisco IP Phone 7960 n/a
Ieee PD
0
Ieee PD
0
Ieee PD
1
Ieee PD
2
Ieee PD
3
Ieee PD
4
n/a
n/a
8-6
OL-6696-01
Chapter 8
Fa3/12
Fa3/13
Fa3/14
Fa3/15
Fa3/16
Fa3/17
Fa3/18
auto
auto
auto
auto
auto
auto
auto
off
off
off
off
off
off
off
0
0
0
0
0
0
0
0
0
0
0
0
0
0
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
10
on
117.5
104.6
This example shows how to display the operational status for Fast Ethernet interface 4/1:
Switch#show power inline fa4/1
Available:677(w) Used:11(w) Remaining:666(w)
Interface Admin
Oper
Power(Watts)
Device
Class
From PS
To Device
--------- ------ ---------- ---------- ---------- ------------------- ----Fa4/1
on
auto
11.2
10.0
Ieee PD
Interface
AdminPowerMax
AdminConsumption
(Watts)
(Watts)
---------- --------------- -------------------Fa4/1
Switch#
15.4
10.0
Note
The operating PoE consumption for an 802.3af-compliant module can be non-zero, even when there are
no powered devices attached to the module, because of the PoE consumed by FPGAs and other hardware
components on the module. In addition, the operating PoE can vary due to fluctuations in the PoE
consumed by the hardware components.
8-7
Chapter 8
Mod
Model
---- ----------------2
WS-X4548-GB-RJ45V
3
WS-X4548-GB-RJ45V
----------------------Total
out of reset
-----------330
60
60
------------450
in reset
-------330
20
20
-------370
The example below displays the PoE consumption for an 802.3af-compliant module using the show
power detail and show power inline commands.
The Inline Power Oper column displays the amount of PoE consumed by the powered devices that are
attached to the module, in addition to the PoE consumed by the FPGAs and other hardware components
on the module. The Inline Power Admin column displays only the amount of PoE allocated by the
powered devices attached to the module.
switch# show power detail
Power
Supply
-----PS1
PS2
Model No
---------------PWR-C45-1300ACV
none
Type
--------AC 1300W
--
Status
----------good
--
Fan
Sensor
------good
--
Inline
Status
------good
--
Maximum
Used
Available
-----------480
1000
138
800
0
0
-----------618 (not to exceed Total Maximum Available = 1300)
8-8
OL-6696-01
Chapter 8
Mod
Model
---- ----------------1
WS-X4013+TS
2
WS-X4548-GB-RJ45V
3
WS-X4548-GB-RJ45V
-Fan Tray
----------------------Total
Mod
Model
---- ----------------2
WS-X4548-GB-RJ45V
3
WS-X4548-GB-RJ45V
----------------------Total
Oper
Gi1/1
on
Used:128(w)
Remaining:30(w)
Power(Watts)
Device
Class
From PS
To Device
--------- ------ ---------- ---------- ---------- ------------------- ----auto
10.3
10.3
CNU Platform
Interface
AdminPowerMax
AdminConsumption
(Watts)
(Watts)
---------- --------------- -------------------Gi1/1
15.4
15.4
Oper
Gi2/1
on
Used:138(w)
Remaining:662(w)
Power(Watts)
Device
Class
From PS
To Device
--------- ------ ---------- ---------- ---------- ------------------- ----auto
11.5
10.2
CNU Platform
n/a
8-9
Chapter 8
Interface
AdminPowerMax
AdminConsumption
(Watts)
(Watts)
---------- --------------- -------------------Gi2/1
switch#
15.4
15.4
Used:128(w)
Interface Admin
Oper
Gi1/1
Gi1/2
Gi1/3
Gi1/4
Gi1/5
Gi1/6
Gi1/7
Gi1/8
Gi1/9
Gi1/10
Gi1/11
Gi1/12
---------
on
on
on
on
on
on
on
on
on
on
on
on
----------
10.3
10.3
10.3
10.3
10.3
10.3
10.3
10.3
10.3
15.4
10.3
10.3
----------
10.3
10.3
10.3
10.3
10.3
10.3
10.3
10.3
10.3
15.4
10.3
10.3
----------
12
128.2
128.2
Remaining:30(w)
Power(Watts)
Device
Class
From PS
To Device
--------- ------ ---------- ---------- ---------- ------------------- ----auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
------
Totals:
on
CNU Platform
CNU Platform
CNU Platform
CNU Platform
CNU Platform
CNU Platform
CNU Platform
CNU Platform
CNU Platform
Cisco/Ieee PD
CNU Platform
CNU Platform
-------------------
3
3
3
3
3
3
3
3
3
3
3
3
-----
switch#
switch# show power inline module 2
Chassis Inline Power Supply: Available:800(w) Used:138(w) Remaining:662(w)
Interface Admin Oper
Power(Watts)
Device
Class
From PS
To Device
--------- ------ ---------- ---------- ---------- ------------------- ----Gi2/1
Gi2/2
Gi2/3
Gi2/4
Gi2/5
Gi2/6
Gi2/7
Gi2/8
Gi2/9
Gi2/10
Gi2/11
Gi2/12
Gi2/13
Gi2/14
Gi2/15
Gi2/16
Gi2/17
Gi2/18
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
on
on
on
on
off
off
off
off
on
on
on
on
on
on
on
on
off
off
11.5
11.5
11.5
11.5
0.0
0.0
0.0
0.0
11.5
11.5
11.5
11.5
11.5
11.5
11.5
11.5
0.0
0.0
10.2
10.2
10.2
10.2
0.0
0.0
0.0
0.0
10.2
10.2
10.2
10.2
10.2
10.2
10.2
10.2
0.0
0.0
CNU
CNU
CNU
CNU
n/a
n/a
n/a
n/a
CNU
CNU
CNU
CNU
CNU
CNU
CNU
CNU
n/a
n/a
Platform
Platform
Platform
Platform
Platform
Platform
Platform
Platform
Platform
Platform
Platform
Platform
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
3
n/a
n/a
n/a
3
3
3
3
n/a
n/a
8-10
OL-6696-01
Chapter 8
Interface Admin
Oper
Power(Watts)
Device
Class
From PS
To Device
--------- ------ ---------- ---------- ---------- ------------------- ----Gi2/19
Gi2/20
Gi2/21
Gi2/22
Gi2/23
Gi2/24
Gi2/25
Gi2/26
Gi2/27
Gi2/28
Gi2/29
Gi2/30
Gi2/31
Gi2/32
Gi2/33
Gi2/34
Gi2/35
Gi2/36
Gi2/37
Gi2/38
Gi2/39
Gi2/40
Interface
off
off
off
off
off
off
off
off
off
off
off
off
off
off
off
off
off
off
off
off
off
off
Oper
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
Power(Watts)
From PS
To Device
--------- ------ ---------- ---------- ----------
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
Device
Gi2/41
Gi2/42
Gi2/43
Gi2/44
Gi2/45
Gi2/46
Gi2/47
Gi2/48
---------
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
-------------------
Totals:
switch#
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
auto
Admin
auto
auto
auto
auto
auto
auto
auto
auto
------
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
off
off
off
off
off
off
off
off
----------
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
----------
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
----------
12
138.2
123.0
on
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
Class
------------------- ----n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
-----
8-11
Chapter 8
8-12
OL-6696-01
C H A P T E R
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/go/NetworkAssistant.
Note
Configuring the Cisco Device for Use with Network Assistant, page 9-4
The Network Assistant is not bundled with an online software image on Cisco.com. You can download
the Network Assistant from this URL: at http://www.cisco.com/go/NetworkAssistant
9-1
Chapter 9
Installation Requirements
The workstation on which you install Network Assistant must meet these minimum requirements:
DRAM: 128 MB
Type
Part Number
Chassis
WS-C4503
WS-C4506
Power supplies
PWR-C45-1300AC
PWR-C45-1000AC
9-2
OL-6696-01
Chapter 9
Table 1
Type
Part Number
Supervisors
WS-X4013+
WS-X4515
WS-X4013+TS
Modules
WS-X4124-RJ45
WS-X4148-RJ
WS-X4224-RJ45V
WS-X4248-RJ45V
WS-X4548-GB-RJ45
WS-X4424-GB-RJ45
WS-X4306-GB
Feature
Default Value
Recommended Value
HTTP server
Disabled
Enabled1
80
Optional2
Authentication
Disabled
Optional
Cluster
Disabled
Enabled3
Step 2
Step 3
Step 4
Download the Network Assistant Installer and initiate the application. (You can operate the installer
directly from the Web if your browser offers this choice.)
Network Assistant is freethere is no charge to download, install, or use it.
9-3
Chapter 9
When you initiate the installer, follow the displayed instructions. In the final panel, click Finish to
complete the installation of Network Assistant.
Table 3
CLI Commands
Command
Functions
show version
show running-config
cluster run
Enables clustering.
Purpose
Step 1
Step 2
Step 3
9-4
OL-6696-01
Chapter 9
Step 4
Command
Purpose
Note
Step 5
Note
Step 6
Step 7
Switch(config-if)# end
Step 8
This example shows how to configure the TCP/IP port number to the default (80):
Switch(config)# default ip http port
This example shows how to configure the TCP port number to 2398:
Switch(config)# ip http port 2398
9-5
Chapter 9
This example shows how to configure the authentication login to use local passwords and to verify the
configuration:
Switch(config)# ip http authentication local
Switch(config)# end
Switch# show running-config | include http
ip http server
ip http authentication local
This example illustrates the sample configuration files for the cluster command switch candidate:
Current configuration : 2481 bytes
!
version 12.2
no service pad
service timestamps debug uptime
service timestamps log uptime
no service password-encryption
service compress-config
!
hostname Switch
!
!
vtp domain switch
vtp mode transparent
ip subnet-zero
!
cluster run
!
no file verify auto
spanning-tree mode pvst
spanning-tree extend system-id
power redundancy-mode redundant
!
!
!
vlan internal allocation policy ascending
!
vlan 17,100,110,117,120,200
!
interface FastEthernet1
ip address 4.4.4.4 255.255.255.0
speed auto
duplex auto
!
interface GigabitEthernet1/1
!
interface GigabitEthernet1/2
!
interface GigabitEthernet3/1
no switchport
ip address 3.3.3.3 255.255.255.0
!
interface GigabitEthernet3/3
!
interface GigabitEthernet3/4
!
interface GigabitEthernet3/5
!
interface GigabitEthernet3/6
!
interface GigabitEthernet3/7
!
9-6
OL-6696-01
Chapter 9
interface GigabitEthernet3/8
!
interface GigabitEthernet3/9
shutdown
!
interface GigabitEthernet3/10
shutdown
!
interface GigabitEthernet3/11
shutdown
interface Vlan1
no ip address
!
interface Vlan100
no ip address
!
ip http server
Purpose
Step 1
Step 2
Enables clustering.
Note
Step 3
Step 4
Switch(config-vlan)# no shutdown
Step 5
Selects an interface.
Step 6
Switch(config-if)# no shutdown
Step 7
Step 8
Step 9
Step 10
Switch(config-if)# end
Step 11
9-7
Chapter 9
This example illustrates the sample configuration files for the cluster member candidate:
Building configuration...
Current configuration : 1492 bytes
!
version 12.2
no service pad
service timestamps debug uptime
service timestamps log uptime
no service password-encryption
service compress-config
!
hostname g5-7
!
!
vtp domain switch
vtp mode transparent
ip subnet-zero
!
cluster run
!
no file verify auto
spanning-tree mode pvst
spanning-tree extend system-id
vlan 2-3,5,17,100,200-201,300-301,555
9-8
OL-6696-01
Chapter 9
!
interface GigabitEthernet1/1
!
interface GigabitEthernet1/2
!
interface FastEthernet3/1
switchport access vlan 100
switchport mode access
!
interface Vlan1
no ip address
!
interface Vlan100
no ip address
ip http server
Purpose
9-9
Chapter 9
Clustering Switches
Connect Window
When the connection occurs, the Network Assistant window is in the connect mode. The toolbar adds
icons that represent device features. Similarly, the feature bar fills with menus that list the device features
that Network Assistant manages.
Note
For information on how to use Network Assistant, refer to Getting Started with Cisco Network Assistant,
available at the URL:
http://www.cisco.com/univercd/cc/td/doc/product/rtrmgmt/cna/v1_0/gsg/index.htmCisco.com
Clustering Switches
This section provides an overview of the concepts and of the procedures used to create and manage
Catalyst 4500 series switches. Unless otherwise noted, the term device refers to a standalone switch.
9-10
OL-6696-01
Chapter 9
You can create and manage switch clusters by using the standalone Network Assistant application or the
command-line interface (CLI). Configuring switch clusters is performed more easily from the Network
Assistant than through the CLI.
Note
For complete procedures about using Network Assistant to configure switch clusters, refer to Getting
Started with Cisco Network Assistant, available at:
http://www.cisco.com/univercd/cc/td/doc/product/rtrmgmt/cna/v1_0/gsg/index.htmCisco.com.
For the CLI cluster commands, refer to the Catalyst 4500 Series Switch Cisco IOS Command Reference
and related publications at:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
This section contains the following topics:
Note
Clustering is disabled by default on the Catalyst 4500 series switch. Refer to the Enable Intra-Cluster
Communication section on page 9-7 for details on how to enable clustering.
Clustering Overview
A switch cluster is a set of up to 16 connected, cluster-capable Catalyst switches that are managed as a
single entity. The switches in the cluster use the switch clustering technology so that you can configure
and troubleshoot a group of different Catalyst 4500 series switch platforms through a single IP address.
Using switch clusters simplifies the management of multiple switches, regardless of their physical
location and platform families.
In a switch cluster, one switch must be the cluster command switch, and up to 15 other switches can be
cluster member switches. The total number of switches in a cluster cannot exceed 16 switches. The
cluster command switch is the single point of access used to configure, manage, and monitor the cluster
member switches. Cluster members can belong to only one cluster at a time.
Note
Always chose a Catalyst 4500 series switch as the cluster command switch.
9-11
Chapter 9
Clustering Switches
Note
It has an IP address.
If your switch cluster contains a Catalyst 4500 series switch, the cluster command switch must also be
a Catalyst 4500 series switch.
Note
If your existing VTY lines have non-default configurations, you might want to apply those
configurations to the new VTY lines.
It is connected to the cluster command switch through at least one common VLAN.
Catalyst 4500 candidate and cluster member switches must be configured with an SVI on the VLAN
connection to the cluster command switch.
9-12
OL-6696-01
Chapter 9
If you do not know the member-switch number, enter the show cluster members privileged EXEC
command on the cluster command switch. For more information about the rcommand command and all
other cluster commands, refer to the Catalyst 4500 Series Switch Cisco IOS Command Reference.
The Telnet session accesses the member-switch CLI at the same privilege level as on the cluster
command switch. The Cisco IOS commands then operate as usual. For instructions on configuring the
switch for a Telnet session, see the Accessing the CLI Through Telnet section on page 2-2.
Note
9-13
Chapter 9
Step 1
Command
Purpose
Step 2
Step 3
Step 4
Step 5
Extracts the CiscoView files from the tar file on the TFTP
server to the CiscoView directory.
Step 6
Step 7
Step 8
Step 9
Step 10
Note
The default password for accessing the switch web page is the enable-level password of the switch.
The following example shows how to install and configure Embedded CiscoView on your switch:
Switch# dir
Directory of bootflash:/
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
-rw-rw-rw-rw-rw-rw-rw-rw-rw-rw-rw-rw-rw-rw-rw-rw-
8620304
9572396
9604192
1985024
1910127
7258
405
2738
20450
20743
12383
529
2523
9630880
1173
10511956
Dec 23
Dec 30
Jan 3
Jan 21
Jan 23
Jan 23
Jan 23
Jan 23
Jan 23
Jan 23
Jan 23
Jan 23
Jan 23
Feb 27
Mar 19
Mar 26
2002
2002
2003
2003
2003
2003
2003
2003
2003
2003
2003
2003
2003
2003
2003
2003
23:27:49
01:05:01
07:46:49
03:31:20
04:23:39
04:23:46
04:23:46
04:23:46
04:23:46
04:23:46
04:23:46
04:23:46
04:23:46
01:25:16
05:50:26
04:24:12
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
wickwire.EW1
cat4000-i9k2s-mz.121-19.EW
cat4000-i5k2s-mz.121-19.EW
Cat4000IOS.v4-0.tar
cv/Cat4000IOS-4.0.sgz
cv/Cat4000IOS-4.0_ace.html
cv/Cat4000IOS-4.0_error.html
cv/Cat4000IOS-4.0_install.html
cv/Cat4000IOS-4.0_jks.jar
cv/Cat4000IOS-4.0_nos.jar
cv/applet.html
cv/cisco.x509
cv/identitydb.obj
kurt70.devtest-enh
post-2003.03.19.05.50.07-passed.txt
kurt_alpha_bas_crypto_103
9-14
OL-6696-01
Chapter 9
-rw-rw-rw-rw-rw-rw-rw-rw-
8620304
9572396
9604192
1985024
9630880
1173
10511956
2031616
Dec 23
Dec 30
Jan 3
Jan 21
Feb 27
Mar 19
Mar 26
Mar 26
2002
2002
2003
2003
2003
2003
2003
2003
23:27:49
01:05:01
07:46:49
03:31:20
01:25:16
05:50:26
04:24:12
05:33:12
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
wickwire.EW1
cat4000-i9k2s-mz.121-19.EW
cat4000-i5k2s-mz.121-19.EW
Cat4000IOS.v4-0.tar
kurt70.devtest-enh
post-2003.03.19.05.50.07-passed.txt
kurt_alpha_bas_crypto_103
Cat4000IOS.v5-1.tar
-rw-rw-rw-rw-
8620304
9572396
9604192
1985024
Dec 23
Dec 30
Jan 3
Jan 21
2002
2002
2003
2003
23:27:49
01:05:01
07:46:49
03:31:20
+00:00
+00:00
+00:00
+00:00
wickwire.EW1
cat4000-i9k2s-mz.121-19.EW
cat4000-i5k2s-mz.121-19.EW
Cat4000IOS.v4-0.tar
9-15
Chapter 9
5
6
7
8
9
10
11
12
13
14
15
16
17
-rw-rw-rw-rw-rw-rw-rw-rw-rw-rw-rw-rw-rw-
9630880
1173
10511956
2031616
1956591
7263
410
2743
20450
20782
12388
529
2523
Feb
Mar
Mar
Mar
Mar
Mar
Mar
Mar
Mar
Mar
Mar
Mar
Mar
27
19
26
26
26
26
26
26
26
26
26
26
26
2003
2003
2003
2003
2003
2003
2003
2003
2003
2003
2003
2003
2003
01:25:16
05:50:26
04:24:12
05:33:12
05:36:11
05:36:19
05:36:19
05:36:19
05:36:19
05:36:19
05:36:19
05:36:19
05:36:19
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
+00:00
kurt70.devtest-enh
post-2003.03.19.05.50.07-passed.txt
kurt_alpha_bas_crypto_103
Cat4000IOS.v5-1.tar
cv/Cat4000IOS-5.1.sgz
cv/Cat4000IOS-5.1_ace.html
cv/Cat4000IOS-5.1_error.html
cv/Cat4000IOS-5.1_install.html
cv/Cat4000IOS-5.1_jks.jar
cv/Cat4000IOS-5.1_nos.jar
cv/applet.html
cv/cisco.x509
cv/identitydb.obj
For more information about web access to the switch, refer to the Using the Cisco Web Browser
chapter in the Cisco IOS Configuration Fundamentals Configuration Guide at this URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/fun_c/fcprt1/fcd105.htm
Purpose
9-16
OL-6696-01
Chapter 9
The following example shows how to display the Embedded CiscoView file and version information:
Switch# show ciscoview package
File source:
CVFILE
SIZE(in bytes)
-----------------------------------------------Cat4000IOS-5.1.sgz
1956591
Cat4000IOS-5.1_ace.html
7263
Cat4000IOS-5.1_error.html
410
Cat4000IOS-5.1_install.html
2743
Cat4000IOS-5.1_jks.jar
20450
Cat4000IOS-5.1_nos.jar
20782
applet.html
12388
cisco.x509
529
identitydb.obj
2523
Switch# show ciscoview version
Engine Version: 5.3.4 ADP Device: Cat4000IOS ADP Version: 5.1 ADK: 49
Switch#
9-17
Chapter 9
9-18
OL-6696-01
C H A P T E R
10
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Overview of VLANs
A VLAN is a group of devices on one or more LANs that are configured to communicate as if they were
attached to the same wire, when in fact they are located on a number of different LAN segments. Because
VLANs are based on logical instead of physical connections, they are extremely flexible.
VLANs define broadcast domains in a Layer 2 network. A broadcast domain is the set of all devices that
will receive broadcast frames originating from any device within the set. Broadcast domains are typically
bounded by routers because routers do not forward broadcast frames. Layer 2 switches create broadcast
domains based on the configuration of the switch. Switches are multiport bridges that allow you to create
multiple broadcast domains. Each broadcast domain is like a distinct virtual bridge within a switch.
You can define one or many virtual bridges within a switch. Each virtual bridge you create in the switch
defines a new broadcast domain (VLAN). Traffic cannot pass directly to another VLAN (between
broadcast domains) within the switch or between two switches. To interconnect two different VLANs,
you must use routers or Layer 3 switches. See the Overview of Layer 3 Interfaces section on page 23-1
for information on inter-VLAN routing on Catalyst 4500 series switches.
Figure 10-1 shows an example of three VLANs that create logically defined networks.
10-1
Chapter 10
Overview of VLANs
Marketing
VLAN
Accounting
VLAN
Cisco router
Floor 3
Fast
Ethernet
Floor 2
16751
Floor 1
VLANs are often associated with IP subnetworks. For example, all of the end stations in a particular IP
subnet belong to the same VLAN. Traffic between VLANs must be routed. You must assign LAN
interface VLAN membership on an interface-by-interface basis (this is known as interface-based or
static VLAN membership).
You can set the following parameters when you create a VLAN in the management domain:
Note
VLAN number
VLAN name
VLAN type
VLAN number to use when translating from one VLAN type to another
When the software translates from one VLAN type to another, it requires a different VLAN number for
each media type.
10-2
OL-6696-01
Chapter 10
Before creating a VLAN, put the Catalyst 4500 series switch in VTP server mode or VTP
transparent mode. If the Catalyst 4500 series switch is a VTP server, you must define a VTP domain.
For information on configuring VTP, see Chapter 27, Understanding and Configuring VTP.
The Cisco IOS end command is not supported in VLAN database mode.
VLAN Ranges
Note
You must enable the extended system ID to use 4094 VLANs. See the Understanding the Bridge ID
section on page 14-2.
With Cisco IOS Release 12.2(25)EW and later, Catalyst 4500 series switches support 4096 VLANs in
compliance with the IEEE 802.1Q standard. These VLANs are organized into three ranges: reserved,
normal, and extended.
Some of these VLANs are propagated to other switches in the network when you use the VLAN
Trunking Protocol (VTP). The extended-range VLANs are not propagated, so you must configure
extended-range VLANs manually on each network device.
Table 10-1 describes the uses for VLAN ranges.
VLANs
Range
Usage
Propagated
by VTP
0, 4095
Reserved
For system use only. You cannot see or use these VLANs.
N/A
Normal
Cisco default. You can use this VLAN but you cannot delete it.
Yes
21001
Normal
Used for Ethernet VLANs; you can create, use, and delete these VLANs.
Yes
10021005
Normal
Cisco defaults for FDDI and Token Ring. You cannot delete VLANs 10021005.
Yes
10064094
Extended
For Ethernet VLANs only. When configuring extended-range VLANs, note the
following:
No
Layer 3 ports and some software features require internal VLANs. Internal
VLANs are allocated from 1006 and up. You cannot use a VLAN that has been
allocated for such use. To display the VLANs used internally, enter the show
vlan internal usage command.
You must enable the extended system ID to use extended range VLANs. See
the Enabling the Extended System ID section on page 14-8.
10-3
Chapter 10
Ethernet VLANs 1 and 1006 through 4094 use only default values.
You can configure the following parameters for VLANs 2 through 1001:
VLAN name
VLAN type
SAID
Note
Parameter
Default
Valid Values
VLAN ID
14094
VLAN name
No range
802.10 SAID
100,001
14,294,967,294
MTU size
1500
150018,190
Translational bridge 1
1002
01005
Translational bridge 2
1003
01005
VLAN state
active
Catalyst 4500 series switches do not support Token Ring or FDDI media. The switch does not forward
FDDI, FDDI-NET, TrCRF, or TrBRF traffic, but it does propagate the VLAN configuration via VTP. The
software reserves parameters for these media types, but they are not truly supported.
Configuring VLANs
Note
Before you configure VLANs, you must use VLAN Trunking Protocol (VTP) to maintain global VLAN
configuration information for your network. For complete information on VTP, see Chapter 27,
Understanding and Configuring VTP.
10-4
OL-6696-01
Chapter 10
Note
VLANs support a number of parameters that are not discussed in detail in this section. For complete
information, refer to the Catalyst 4500 Series Switch Cisco IOS Command Reference.
Note
The VLAN configuration is stored in the vlan.dat file, which is stored in nonvolatile memory. You can
cause inconsistency in the VLAN database if you manually delete the vlan.dat file. If you want to
modify the VLAN configuration or VTP, use the commands described in the following sections and in
the Catalyst 4500 Series Switch Cisco IOS Command Reference.
These sections describe how to configure VLANs:
Note
When the switch boots, if the VTP domain name and VTP mode in the startup-config and vlan.dat files
do not match, the switch uses the configuration in the vlan.dat file.
You use the interface configuration command mode to define the port membership mode and add and
remove ports from a VLAN. The results of these commands are written to the running-config file, and
you can display the contents of the file by entering the show running-config command.
User-configured VLANs have unique IDs from 1 to 4094. To create a VLAN, enter the vlan command
with an unused ID. To verify whether a particular ID is in use, enter the show vlan id ID command. To
modify a VLAN, enter the vlan command for an existing VLAN.
See the VLAN Default Configuration section on page 10-4 for the list of default parameters that are
assigned when you create a VLAN. If you do not use the media keyword when specifying the VLAN
type, the VLAN is an Ethernet VLAN.
10-5
Chapter 10
Configuring VLANs
Purpose
Step 1
Step 2
You cannot delete the default VLANs for these media types:
Ethernet VLAN 1 and FDDI or Token Ring VLANs 1002 to
1005.
When you delete a VLAN, any LAN interfaces configured as
access ports assigned to that VLAN become inactive. They
remain associated with the VLAN (and thus inactive) until you
assign them to a new VLAN.
Switch(config-vlan)# end
Step 4
Because Layer 3 ports and some software features require internal VLANs allocated from 1006 and
up, configure extended-range VLANs starting with 4094 and work downward.
You can configure extended-range VLANs only in global configuration mode. You cannot configure
extended-range VLANs in VLAN database mode.
Layer 3 ports and some software features use extended-range VLANs. If the VLAN you are trying
to create or modify is being used by a Layer 3 port or a software feature, the switch displays a
message and does not modify the VLAN configuration.
This example shows how to create an Ethernet VLAN in global configuration mode and verify the
configuration:
Switch# configure terminal
Switch(config)# vlan 3
Switch(config-vlan)# end
Switch# show vlan id 3
VLAN Name
Status
Ports
---- -------------------------------- --------- ------------------------------3
VLAN0003
active
VLAN Type SAID
MTU
Parent RingNo BridgeNo Stp BrdgMode Trans1 Trans2
---- ----- ---------- ----- ------ ------ -------- ---- -------- ------ -----3
enet 100003
1500 0
0
Primary Secondary Type
Interfaces
------- --------- ----------------- ------------------------------------------Switch#
10-6
OL-6696-01
Chapter 10
Purpose
Step 1
Step 2
Switch(vlan)# exit
Step 4
This example shows how to create an Ethernet VLAN in VLAN database mode and verify the
configuration:
Switch# vlan database
Switch(vlan)# vlan 3
VLAN 3 added:
Name: VLAN0003
Switch(vlan)# exit
APPLY completed.
Exiting....
Switch# show vlan name VLAN0003
VLAN Name
Status
Ports
---- -------------------------------- --------- --------------------3
VLAN0003
active
VLAN Type SAID
MTU
Parent RingNo BridgeNo Stp Trans1 Trans2
---- ----- ---------- ----- ------ ------ -------- ---- ------ -----3
enet 100003
1500 0
0
Switch#
10-7
Chapter 10
Configuring VLANs
Note
Make sure you assign LAN interfaces to a VLAN of the proper type. Assign Fast Ethernet, Gigabit
Ethernet, and 10-Gigabit Ethernet interfaces to Ethernet-type VLANs.
To assign one or more LAN interfaces to a VLAN, complete the procedures in the Configuring Ethernet
Interfaces for Layer 2 Switching section on page 12-5.
10-8
OL-6696-01
C H A P T E R
11
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Understanding VMPS
The following subsections describe what a VMPS server does and how it operates.
The following topics are included:
11-1
Chapter 11
Understanding VMPS
VMPS uses a UDP port to listen to VQP requests from clients, so, it is not necessary for VMPS clients
to know if the VMPS resides on a local or remote device on the network. Upon receiving a valid request
from a VMPS client, a VMPS server searches its database for an entry of a MAC-address to VLAN
mapping.
In response to a request, the VMPS takes one of the following actions:
If the assigned VLAN is restricted to a group of ports, the VMPS verifies the requesting port against
this group and responds as follows:
If the VLAN is allowed on the port, the VMPS sends the VLAN name to the client in response.
If the VLAN is not allowed on the port and the VMPS is not in secure mode, the VMPS sends
an access-denied response.
If the VLAN is not allowed on the port and the VMPS is in secure mode, the VMPS sends a
port-shutdown response.
If the VLAN in the database does not match the current VLAN on the port and there are active hosts
on the port, the VMPS sends an access-denied (open), a fallback VLAN name (open with
fallback VLAN configured), a port-shutdown (secure), or a new VLAN name (multiple)
response, depending on the secure mode setting of the VMPS.
If the switch receives an access-denied response from the VMPS, the switch continues to block
traffic from the MAC address to or from the port. The switch continues to monitor the packets
directed to the port and sends a query to the VMPS when it identifies a new address. If the switch
receives a port-shutdown response from the VMPS, the switch disables the port. The port must be
manually re-enabled by using the CLI, Cisco Visual Switch Manager (CVSM), or SNMP.
You can also use an explicit entry in the configuration table to deny access to specific MAC
addresses for security reasons. If you enter the none keyword for the VLAN name, the VMPS sends
an access-denied or port-shutdown response.
For more information on a Catalyst 6500 series switch VMPS running Catalyst operating system
software, refer to the
Configuring Dynamic Port VLAN Membership with VMPS chapter at the URL:
http://www.cisco.com/univercd/cc/td/doc/product/lan/cat6000/sw_8_3/confg_gd/vmps.htm
Open mode
If the assigned VLAN is restricted to a group of ports, VMPS verifies the requesting port against this
group:
If the VLAN is allowed on the port, the VLAN name is returned to the client.
If the VLAN is not allowed on the port, the host receives an access denied response.
11-2
OL-6696-01
Chapter 11
If a VLAN in the database does not match the current VLAN on the port and a fallback VLAN name
is configured, VMPS sends the fallback VLAN name to the client.
If a VLAN in the database does not match the current VLAN on the port and a fallback VLAN name
is not configured, the host receives an access denied response.
Secure mode
If the assigned VLAN is restricted to a group of ports, VMPS verifies the requesting port against this
group:
If the VLAN is allowed on the port, the VLAN name is returned to the client.
If the VLAN is not allowed on the port, the port is shut down.
If a VLAN in the database does not match the current VLAN on the port, the port is shutdown, even
if a fallback VLAN name is configured.
Multiple mode
Multiple hosts (MAC addresses) can be active on a dynamic port if they are all in the same VLAN. If the
link goes down on a dynamic port, the port returns to the unassigned state. Any hosts that come online
through the port are checked again with VMPS before the port is assigned to a VLAN.
If multiple hosts connected to a dynamic port belong to different VLANs, the VLAN matching the MAC
address in the last request is returned to the client, provided that multiple mode is configured on the
VMPS server.
Note
Although Catalyst 4500 series and Catalyst 6500 series switches running Catalyst operating system
software support VMPS in all three operation modes, the Cisco network management tool URT (User
Registration Tool) supports open mode only.
Fall-back VLAN
You can configure a fallback VLAN name on a VMPS server. If you connect a device with a MAC
address that is not in the database, the VMPS sends the fallback VLAN name to the client. If you do not
configure a fallback VLAN name and the MAC address does not exist in the database, the VMPS sends
an access-denied response. If the VMPS is in secure mode, it sends a port-shutdown response,
whether or not a fallback VLAN has been configured on the server.
When a MAC-address mapping is not present in the VMPS database and no fall back VLAN is
configured on the VMPS.
When a port is already assigned a VLAN (and the VMPS mode is not multiple) but a second
VMPS client request is received on the VMPS for a different MAC-address.
11-3
Chapter 11
Note
The VMPS shuts down a dynamic port if more than 50 hosts are active on that port.
11-4
OL-6696-01
Chapter 11
Table 11-1
Feature
Default Configuration
None
60 minutes
Dynamic ports
None configured
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config)# end
Step 5
This example shows how to define the primary and secondary VMPS devices:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# vmps server 172.20.128.179 primary
Switch(config)# vmps server 172.20.128.178
Switch(config)# end
Note
You can configure up to four VMPS servers using this CLI on the VMPS client.
11-5
Chapter 11
Purpose
Step 1
Step 2
Step 3
Step 4
Step 5
Switch(config-if)# end
Step 6
This example shows how to configure a dynamic access port and then verify the entry:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface fa1/1
Switch(config-if)# switchport mode access
Switch(config-if)# switchport access vlan dynamic
Switch(config-if)# end
Switch# show interface fa1/1 switchport
Name: Fa0/1
Switchport: Enabled
Administrative mode: dynamic auto
Operational Mode: dynamic access
Administrative Trunking Encapsulation: isl
Operational Trunking Encapsulation: isl
Negotiation of Trunking: Disabled
Access Mode VLAN: 0 ((Inactive))
Trunking Native Mode VLAN: 1 (default)
Trunking VLANs Enabled: NONE
Pruning VLANs Enabled: NONE
11-6
OL-6696-01
Chapter 11
Voice Ports
If a VVID (voice VLAN ID) is configured on a dynamic access port, the port can belong to both an
access VLAN and a voice VLAN. Consequently, an access port configured for connecting an IP phone
can have separate VLANs for the following:
Data traffic to and from the PC that is connected to the switch through the access port of the IP phone
(access VLAN)
Purpose
Step 1
Step 2
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
Step 4
This example shows how to change the reconfirmation interval to 60 minutes and verify the change:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# vmps reconfirm 60
Switch(config)# end
Switch# show vmps
VQP Client Status:
-------------------VMPS VQP Version:
1
Reconfirm Interval: 60 min
Server Retry Count: 10
VMPS domain server: 172.20.130.50 (primary, current)
Reconfirmation status
--------------------VMPS Action:
No Host
11-7
Chapter 11
Purpose
Step 1
Step 2
Specifies the retry count for the VPQ queries. Default is 3. Range is
from 1 to 10.
Step 3
Switch(config)# end
Step 4
This example shows how to change the retry count to 5 and to verify the change:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# vmps retry 5
Switch(config)# end
Switch# show vmps
VQP Client Status:
-------------------VMPS VQP Version:
1
Reconfirm Interval: 60 min
Server Retry Count: 5
VMPS domain server: 172.20.130.50 (primary, current)
Reconfirmation status
--------------------VMPS Action:
No Host
Reconfirm Interval
11-8
OL-6696-01
Chapter 11
VMPS domain server The IP address of the configured VLAN membership policy
servers. The switch currently sends queries to the one marked
current. The one marked primary is the primary server.
VMPS Action
Note
Refer to the Catalyst 4500 Series Switch Cisco IOS Command Reference for details on VMPS statistics.
The VMPS is in secure mode, and it will not allow the host to connect to the port. The VMPS
errdisables the port to prevent the host from connecting to the network.
For information on how to display the status of interfaces in error-disabled state, refer to
Chapter 5, Checking Port Status and Connectivity. To recover an errdisabled port, use the
errdisable recovery cause vmps global configuration command.
11-9
Chapter 11
11-10
OL-6696-01
C H A P T E R
12
Note
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
12-1
Chapter 12
Note
With release 12.1(13)EW, the Catalyst 4500 series switches can handle packets of 1600 bytes, rather
than treat them as oversized and discard them. This size is larger than the usual IEEE Ethernet
Maximum Transmission Unit (MTU) (1518 bytes) and 802.1q MTU (1522 bytes). The ability to handle
larger packets is required to support two nested 802.1q headers and Multiprotocol Label Switching
(MPLS) on a network.
The Catalyst 4500 series solves congestion problems caused by high-bandwidth devices and a large
number of users by assigning each device (for example, a server) to its own 10-, 100-, or 1000-Mbps
segment. Because each Ethernet interface on the switch represents a separate Ethernet segment, servers
in a properly configured switched environment achieve full access to the bandwidth.
Because collisions are a major bottleneck in Ethernet networks, an effective solution is full-duplex
communication. Normally, Ethernet operates in half-duplex mode, which means that stations can either
receive or transmit. In full-duplex mode, two devices can transmit and receive at the same time. When
packets can flow in both directions simultaneously, effective Ethernet bandwidth doubles to 20 Mbps for
10-Mbps interfaces and to 200 Mbps for Fast Ethernet interfaces. Gigabit Ethernet interfaces on the
Catalyst 4500 series switch are full-duplex mode only, providing 2-Gbps effective bandwidth.
12-2
OL-6696-01
Chapter 12
Note
The blocking Gigabit ports on the WS-X4418-GB and WS-X4412-2GB-T modules do not
support ISL. Ports 3 to 18 are blocking Gigabit ports on the WS-X4418-GB module. Ports
1to 12 are blocking Gigabit ports on the WS-X4412-2GB-T module.
You can configure a trunk on a single Ethernet interface or on an EtherChannel bundle. For more
information about EtherChannel, see Chapter 17, Understanding and Configuring EtherChannel.
Ethernet trunk interfaces support different trunking modes (see Table 12-2). You can specify whether the
trunk uses ISL encapsulation, 802.1Q encapsulation, or if the encapsulation type is autonegotiated.
To autonegotiate trunking, make sure your interfaces are in the same VTP domain. Use the trunk or
nonegotiate keywords to force interfaces in different domains to trunk. For more information on VTP
domains, see Chapter 27, Understanding and Configuring VTP.
Trunk negotiation is managed by the Dynamic Trunking Protocol (DTP). DTP supports autonegotiation
of both ISL and 802.1Q trunks.
Encapsulation Types
Table 12-1 lists the Ethernet trunk encapsulation types.
Table 12-1 Ethernet Trunk Encapsulation Types
Encapsulation Type
Encapsulation Command
Purpose
ISL
802.1Q
Negotiate
The trunking mode, the trunk encapsulation type, and the hardware capabilities of the two connected
interfaces determine whether a link becomes an ISL or 802.1Q trunk.
12-3
Chapter 12
Note
Mode
Purpose
switchport nonegotiate
Puts the interface into permanent trunking mode but prevents the
interface from generating DTP frames. You must configure the
neighboring interface manually as a trunk interface to establish a
trunking link.
DTP is a point-to-point protocol. However, some internetworking devices might forward DTP frames
improperly. To avoid this problem, ensure that interfaces connected to devices that do not support DTP
are configured with the access keyword if you do not intend to trunk across those links. To enable
trunking to a device that does not support DTP, use the nonegotiate keyword to cause the interface to
become a trunk without generating DTP frames.
Feature
Default Value
Interface mode
Trunk encapsulation
VLANs 11005
12-4
OL-6696-01
Chapter 12
Feature
Default Value
VLAN 1
STP1
128
In a network of Cisco switches connected through 802.1Q trunks, the switches maintain one instance
of spanning tree for each VLAN allowed on the trunks. Non-Cisco 802.1Q switches maintain only
one instance of spanning tree for all VLANs allowed on the trunks.
When you connect a Cisco switch to a non-Cisco device through an 802.1Q trunk, the Cisco switch
combines the spanning tree instance of the native VLAN of the trunk with the spanning tree instance
of the non-Cisco 802.1Q switch. However, spanning tree information for each VLAN is maintained
by Cisco switches separated by a cloud of non-Cisco 802.1Q switches. The non-Cisco 802.1Q cloud
separating the Cisco switches is treated as a single trunk link between the switches.
Make sure the native VLAN for an 802.1Q trunk is the same on both ends of the trunk link. If the
VLAN on one end of the trunk is different from the VLAN on the other end, spanning tree loops
might result.
Disabling spanning tree on any VLAN of an 802.1Q trunk can cause spanning tree loops.
12-5
Chapter 12
The default for Layer 2 interfaces is switchport mode dynamic auto. If the neighboring interface
supports trunking and is configured to trunk mode or dynamic desirable mode, the link becomes a
Layer 2 trunk. By default, trunks negotiate encapsulation. If the neighboring interface supports ISL and
802.1Q encapsulation and both interfaces are set to negotiate the encapsulation type, the trunk uses ISL
encapsulation.
To configure an interface as a Layer 2 trunk, perform this task:
Command
Purpose
Step 1
Step 2
Switch(config-if)# shutdown
Step 3
You must enter this command with either the isl or dot1q
keyword to support the switchport mode trunk
command, which is not supported by the default mode
(negotiate).
Step 4
Step 5
Step 6
Step 7
Step 8
Step 9
Switch(config-if)# no shutdown
Step 10
Switch(config-if)# end
12-6
OL-6696-01
Chapter 12
Command
Purpose
Step 11
Step 12
Step 13
This example shows how to configure the Fast Ethernet interface 5/8 as an 802.1Q trunk. This example
assumes that the neighbor interface is configured to support 802.1Q trunking and that the native VLAN
defaults to VLAN 1:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface fastethernet 5/8
Switch(config-if)# shutdown
Switch(config-if)# switchport mode dynamic desirable
Switch(config-if)# switchport trunk encapsulation dot1q
Switch(config-if)# no shutdown
Switch(config-if)# end
Switch# exit
Mode
desirable
Encapsulation
n-802.1q
Status
trunking
Native vlan
1
Port
Vlans allowed on trunk
Fa5/8 1-1005
12-7
Chapter 12
Port
Vlans allowed and active in management domain
Fa5/8 1-6,10,20,50,100,152,200,300,303-305,349-351,400,500,521,524,570,801-8
02,850,917,999,1002-1005
Port
Vlans in spanning tree forwarding state and not pruned
Fa5/8 1-6,10,20,50,100,152,200,300,303-305,349-351,400,500,521,524,570,801-8
02,850,917,999,1002-1005
Switch#
If you assign an interface to a VLAN that does not exist, the interface is not operational until you create
the VLAN in the VLAN database (see the Configuring VLANs in Global Configuration Mode section
on page 10-5).
To configure an interface as a Layer 2 access port, perform this task:
Command
Purpose
Step 1
Step 2
Switch(config-if)# shutdown
Step 3
Switch(config-if)# switchport
Step 4
Step 5
Step 6
Switch(config-if)# no shutdown
Activates the interface. (Required only if you had shut down the
interface.)
Step 7
Switch(config-if)# end
Step 8
Step 9
This example shows how to configure the Fast Ethernet interface 5/6 as an access port in VLAN 200:
Switch# configure terminal
Enter configuration commands, one per line.
Switch(config)# interface fastethernet 5/6
Switch(config-if)# shutdown
12-8
OL-6696-01
Chapter 12
Switch(config-if)#
Switch(config-if)#
Switch(config-if)#
Switch(config-if)#
Switch# exit
Purpose
Step 1
Step 2
Switch(config-if)# end
Step 3
Step 4
This example shows how to clear the Layer 2 configuration on the Fast Ethernet interface 5/6:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# default interface fastethernet 5/6
Switch(config)# end
Switch# exit
12-9
Chapter 12
This example shows how to verify that the Layer 2 configuration was cleared:
Switch# show running-config interface fastethernet 5/6
Building configuration...
Current configuration:
!
interface FastEthernet5/6
end
12-10
OL-6696-01
C H A P T E R
13
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
This chapter consists of these sections:
13-1
Chapter 13
cisco-desktop
# Basic interface - Enable data VLAN only
# Recommended value for access vlan (AVID) should not be 1
switchport access vlan $AVID
switchport mode access
# Enable port security limiting port to a single
# MAC address -- that of desktop
switchport port-security
# Ensure port-security age is greater than one minute
# and use inactivity timer
# Port-security maximum 1 is the default and will not
# Show up in the config
switchport port-security violation restrict
switchport port-security aging time 2
switchport port-security aging type inactivity
# Configure port as an edge network port
spanning-tree portfast
spanning-tree bpduguard enable
cisco-phone
# VoIP enabled interface - Enable data VLAN
# and voice VLAN (VVID)
# Recommended value for access vlan (AVID) should not be 1\
switchport access vlan $AVID
switchport mode access
# Update the Voice VLAN (VVID) value which should be
# different from data VLAN
# Recommended value for voice vlan (VVID) should not be 1
switchport voice vlan $VVID
# Enable port security limiting port to a 3 MAC
13-2
OL-6696-01
Chapter 13
cisco-switch
# Access Uplink to Distribution
switchport trunk encapsulation dot1q
# Define unique Native VLAN on trunk ports
# Recommended value for native vlan (NVID) should not be 1
switchport trunk native vlan $NVID
# Update the allowed VLAN range (VRANGE) such that it
# includes data, voice and native VLANs
# switchport trunk allowed vlan $VRANGE
# Hardcode trunk and disable negotiation to
# speed up convergence
switchport mode trunk
switchport nonegotiate
# Configure qos to trust this interface
auto qos voip trust
# 802.1w defines the link as pt-pt for rapid convergence
spanning-tree link-type point-to-point
cisco-router
# Access Uplink to Distribution
switchport trunk encapsulation dot1q
# Define unique Native VLAN on trunk ports
# Recommended value for native vlan (NVID) should not be 1
switchport trunk native vlan $NVID
# Update the allowed VLAN range (VRANGE) such that it
# includes data, voice and native VLANs
# switchport trunk allowed vlan $VRANGE
# Hardcode trunk and disable negotiation to
# speed up convergence
# Hardcode speed and duplex to router
switchport mode trunk
switchport nonegotiate
speed 100
duplex full
# Configure qos to trust this interface
auto qos voip trust
qos trust dscp
# Ensure fast access to the network when enabling the interface.
# Ensure that switch devices cannot become active on the interface.
spanning-tree portfast
spanning-tree bpduguard enable
13-3
Chapter 13
Do not use exit or end commands when creating a macro. This action could cause commands that
follow exit or end to execute in a different command mode.
When creating a macro, all CLI commands should be interface configuration mode commands.
Some CLI commands are specific to certain interface types. The macro will fail the syntax check or
the configuration check, and the switch will return an error message if it is applied to an interface
that does not accept the configuration.
When a macro is applied to an interface, all existing configuration on the interface is retained. This
is helpful when applying an incremental configuration to an interface.
If you modify a macro definition by adding or deleting commands, the changes are not reflected on
the interface where the original macro was applied. You need to reapply the updated macro on the
interface to apply the new or changed commands.
You can use the macro trace macro-name interface configuration command to show what macros
are running on an interface or to debug the macro to determine any syntax or configuration errors.
If a command fails when you apply a macro, either due to a syntax error or to a configuration error,
the macro continues to apply the remaining commands to the interface.
Applying a macro to an interface range is the same as applying a macro to a single interface. When
you use an interface range, the macro is applied sequentially to each individual interface within the
range. If a macro command fails on one interface, it is still applied to the remaining interfaces.
Purpose
Step 1
Step 2
Step 3
Switch(config)# interface
Step 4
Step 5
Step 6
Switch(config-if)# end
13-4
OL-6696-01
Chapter 13
Command
Purpose
Step 7
Step 8
Step 9
The no form of the macro name global configuration command only deletes the macro definition. It
does not affect the configuration of those interfaces on which the macro is already applied. You can
delete a macro-applied configuration on an interface by entering the default interface interface-id
interface configuration command. Alternatively, you can create an anti-macro for an existing macro that
contains the no form of all the corresponding commands in the original macro. Then apply the
anti-macro to the interface.
The following sections illustrate how to apply and display the attachments on each of the supported
macros:
cisco-desktop
This example shows how to apply the cisco-desktop macro to interface Fast Ethernet interface 2/9:
Switch(config)# interface fastethernet2/9
Switch(config-if)# macro apply cisco-desktop $AVID 35
Switch(config-if)# end
Switch# show parser macro name cisco-desktop
Macro name : cisco-desktop
Macro type : customizable
# Basic interface - Enable data VLAN only
# Recommended value for access vlan (AVID) should not be 1
switchport access vlan $AVID [access_vlan_id]
switchport mode access
# Enable port security limiting port to a single
# MAC address -- that of desktop
switchport port-security
# Ensure port-security age is greater than one minute
# and use inactivity timer
# Port-security maximum 1 is the default and will not
# Show up in the config
switchport port-security violation restrict
switchport port-security aging time 2
switchport port-security aging type inactivity
# Configure port as an edge network port
spanning-tree portfast
spanning-tree bpduguard enable
Switch# show parser macro description
Interface
Macro Description
-------------------------------------------------------------Fa2/9
cisco-desktop
--------------------------------------------------------------
13-5
Chapter 13
cisco-phone
This example shows how to apply the cisco-phone macro to interface Fast Ethernet interface 2/9:
Switch(config)# interface fastethernet2/9
Switch(config-if)# macro apply cisco-phone
Switch(config-if)# macro description cisco-phone $AVID 35 $VVID 56
Switch(config-if)# end
Switch# show parser macro name cisco-phone
Macro name : cisco-phone
Macro type : customizable
# VoIP enabled interface - Enable data VLAN
# and voice VLAN (VVID)
# Recommended value for access vlan (AVID) should not be 1\
switchport access vlan $AVID [access_vlan_id]
switchport mode access
# Update the Voice VLAN (VVID) value which should be
# different from data VLAN
# Recommended value for voice vlan (VVID) should not be 1
switchport voice vlan $VVID [voice_vlan_id]
# Enable port security limiting port to a 3 MAC
# addressess -- One for desktop and two for phone
switchport port-security
switchport port-security maximum 3
# Ensure port-security age is greater than one minute
# and use inactivity timer
switchport port-security violation restrict
switchport port-security aging time 2
switchport port-security aging type inactivity
# Enable auto-qos to extend trust to attached Cisco phone
auto qos voip cisco-phone
# Configure port as an edge network port
spanning-tree portfast
spanning-tree bpduguard enable@
Switch# show parser macro description
Interface
Macro Description
-------------------------------------------------------------Fa2/9
cisco-phone
--------------------------------------------------------------
cisco-switch
This example shows how to apply the cisco-switch macro to interface Fast Ethernet interface 2/9:
Switch(config)# interface fastethernet2/9
Switch(config-if)# macro apply cisco-switch
Switch(config-if)# macro description cisco-switch $NVID 38
Switch(config-if)# end
Switch# show parser macro name cisco-switch
Macro name : cisco-switch
Macro type : customizable
# Access Uplink to Distribution
switchport trunk encapsulation dot1q
# Define unique Native VLAN on trunk ports
# Recommended value for native vlan (NVID) should not be 1
switchport trunk native vlan $NVID [native_vlan_id]
13-6
OL-6696-01
Chapter 13
cisco-router
This example shows how to apply the cisco-router macro to interface Fast Ethernet interface 2/9:
Switch(config)# interface fastethernet2/9
Switch(config-if)# macro apply cisco-router
Switch(config-if)# macro description cisco-router $NVID 45I
Switch(config-if)# end
Switch# show parser macro name cisco-router
Macro name : cisco-router
Macro type : customizable
# Access Uplink to Distribution
switchport trunk encapsulation dot1q
# Define unique Native VLAN on trunk ports
# Recommended value for native vlan (NVID) should not be 1
switchport trunk native vlan $NVID [native_vlan_id]
# Update the allowed VLAN range (VRANGE) such that it
# includes data, voice and native VLANs
# switchport trunk allowed vlan $VRANGE [vlan_range]
# Hardcode trunk and disable negotiation to
# speed up convergence
# Hardcode speed and duplex to router
switchport mode trunk
switchport nonegotiate
speed 100
duplex full
# Configure qos to trust this interface
auto qos voip trust
qos trust dscp
# Ensure fast access to the network when enabling the interface.
# Ensure that switch devices cannot become active on the interface.
spanning-tree portfast
spanning-tree bpduguard enable
Switch# show parser macro description
Interface
Macro Description
-------------------------------------------------------------Fa2/9
cisco-router
--------------------------------------------------------------
13-7
Chapter 13
Command
Purpose
13-8
OL-6696-01
C H A P T E R
14
Note
For information on configuring the PortFast, UplinkFast, and BackboneFast, and other spanning tree
enhancements, see Chapter 15, Configuring STP Features.
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Overview of STP
STP is a Layer 2 link management protocol that provides path redundancy while preventing undesirable
loops in the network. For a Layer 2 Ethernet network to function properly, only one active path can exist
between any two stations. A loop-free subset of a network topology is called a spanning tree. The
operation of a spanning tree is transparent to end stations, which cannot detect whether they are
connected to a single LAN segment or a switched LAN of multiple segments.
A Catalyst 4500 series switch use STP (the IEEE 802.1D bridge protocol) on all VLANs. By default, a
single spanning tree runs on each configured VLAN (provided you do not manually disable the spanning
tree). You can enable and disable a spanning tree on a per-VLAN basis.
When you create fault-tolerant internetworks, you must have a loop-free path between all nodes in a
network. The spanning tree algorithm calculates the best loop-free path throughout a switched Layer 2
network. Switches send and receive spanning tree frames at regular intervals. The switches do not
forward these frames, but use the frames to construct a loop-free path.
Multiple active paths between end stations cause loops in the network. If a loop exists in the network,
end stations might receive duplicate messages and switches might learn end station MAC addresses on
multiple Layer 2 interfaces. These conditions result in an unstable network.
14-1
Chapter 14
Overview of STP
A spanning tree defines a tree with a root switch and a loop-free path from the root to all switches in the
Layer 2 network. A spanning tree forces redundant data paths into a standby (blocked) state. If a network
segment in the spanning tree fails and a redundant path exists, the spanning tree algorithm recalculates
the spanning tree topology and activates the standby path.
When two ports on a switch are part of a loop, the spanning tree port priority and port path cost setting
determine which port is put in the forwarding state and which port is put in the blocking state. The
spanning tree port priority value represents the location of an interface in the network topology and how
well located it is to pass traffic. The spanning tree port path cost value represents media speed.
Extended System ID
Extended system IDs are VLAN IDs between 1025 and 4096. Releases 12.1(12c)EW and later releases
support a 12-bit extended system ID field as part of the bridge ID (see Table 14-2). Chassis that support
only 64 MAC addresses always use the 12-bit extended system ID. On chassis that support 1024 MAC
addresses, you can enable use of the extended system ID. STP uses the VLAN ID as the extended system
ID. See the Enabling the Extended System ID section on page 14-8.
Table 14-1 Bridge Priority Value with the Extended System ID Disabled
Bit 15
Bit 14
Bit 13
Bit 12
Bit 11
Bit 10
Bit 9
Bit 8
Bit 7
Bit 6
Bit 5
Bit 4
Bit 3
Bit 2
Bit 1
32768
16384
8192
4096
2048
1024
512
256
128
64
32
16
Bit 3
Bit 2
Bit 1
Table 14-2 Bridge Priority Value and Extended System ID with the Extended System ID Enabled
Bit 16
Bit 15
Bit 14
Bit 13
Bit 12
Bit 11
32768
16384
8192
4096
VLAN ID
Bit 10
Bit 9
Bit 8
Bit 7
Bit 6
Bit 5
Bit 4
14-2
OL-6696-01
Chapter 14
The unique bridge ID (bridge priority and MAC address) associated with each VLAN on each switch
The spanning tree path cost (or bridge priority value) to the root bridge
The port identifier (port priority and MAC address) associated with each Layer 2 interface
Bridge protocol data units (BPDUs) contain information about the transmitting bridge and its ports,
including the bridge and MAC addresses, bridge priority, port priority, and path cost. The system
computes the spanning tree topology by transmitting BPDUs among connecting switches, and in one
direction from the root switch. Each configuration BPDU contains at least the following:
The unique bridge ID of the switch that the transmitting switch believes to be the root switch
Values for the hello, forward delay, and max-age protocol timers
When a switch transmits a BPDU frame, all switches connected to the LAN on which the frame is
transmitted receive the BPDU. When a switch receives a BPDU, it does not forward the frame but instead
uses the information in the frame to calculate a BPDU and, if the topology changes, initiate a BPDU
transmission.
A BPDU exchange results in the following:
The shortest distance to the root bridge is calculated for each switch based on the path cost.
A designated bridge for each LAN segment is selected. This is the switch closest to the root bridge
through which frames are forwarded to the root.
A root port is selected. This is the port providing the best path from the bridge to the root bridge.
14-3
Chapter 14
Overview of STP
STP Timers
Table 14-3 describes the STP timers that affect the performance of the entire spanning tree.
Table 14-3 Spanning Tree Protocol Timers
Variable
Description
hello_time
forward_time
Determines how long each of the listening and learning states will last before
the port begins forwarding.
max_age
14-4
OL-6696-01
Chapter 14
DP
RP
DP
RP
B
D
DP DP
DP
RP
C
S5688
DP
RP = Root Port
DP = Designated Port
For example, assume that one port on Switch B is a fiber-optic link, and another port on Switch B (an
unshielded twisted-pair [UTP] link) is the root port. Network traffic might be more efficient over the
high-speed fiber-optic link. By changing the spanning tree port priority on the fiber-optic port to a higher
priority (lower numerical value) than the priority set for the root port, the fiber-optic port becomes the
new root port.
BlockingIn this state, the Layer 2 interface does not participate in frame forwarding.
ListeningThis state is the first transitional state after the blocking state when spanning tree
determines that the Layer 2 interface should participate in frame forwarding.
LearningIn this state, the Layer 2 interface prepares to participate in frame forwarding.
DisabledIn this state, the Layer 2 interface does not participate in spanning tree and does not
forward frames.
14-5
Chapter 14
Note
For more information on 802.1Q trunks, see Chapter 12, Configuring Layer 2 Ethernet Interfaces.
Feature
Default Value
Enable state
32,768
128
10-Gigabit Ethernet: 2
Gigabit Ethernet: 4
Fast Ethernet: 19
14-6
OL-6696-01
Chapter 14
Feature
Default Value
10-Gigabit Ethernet: 2
Gigabit Ethernet: 4
Fast Ethernet: 19
Hello time
2 sec
15 sec
20 sec
Configuring STP
The following sections describe how to configure spanning tree on VLANs:
Note
The spanning tree commands described in this chapter can be configured on any interface except those
configured with the no switchport command.
Enabling STP
Note
14-7
Chapter 14
Configuring STP
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
Step 4
Note
Because spanning tree is enabled by default, issuing a show running command to view the resulting
configuration will not display the command you entered to enable spanning tree.
This example shows how to verify that spanning tree is enabled on VLAN 200:
Switch# show spanning-tree vlan 200
VLAN200 is executing the ieee compatible Spanning Tree protocol
Bridge Identifier has priority 32768, address 0050.3e8d.6401
Configured hello time 2, max age 20, forward delay 15
Current root has priority 16384, address 0060.704c.7000
Root port is 264 (FastEthernet5/8), cost of root path is 38
Topology change flag not set, detected flag not set
Number of topology changes 0 last change occurred 01:53:48 ago
Times: hold 1, topology change 24, notification 2
hello 2, max age 14, forward delay 10
Timers: hello 0, topology change 0, notification 0
Port 264 (FastEthernet5/8) of VLAN200 is forwarding
Port path cost 19, Port priority 128, Port Identifier 129.9.
Designated root has priority 16384, address 0060.704c.7000
Designated bridge has priority 32768, address 00e0.4fac.b000
Designated port id is 128.2, designated path cost 19
Timers: message age 3, forward delay 0, hold 0
Number of transitions to forwarding state: 1
BPDU: sent 3, received 3417
Switch#
The extended system ID is enabled permanently on chassis that support 64 MAC addresses.
You can use the spanning-tree extend system-id command to enable the extended system ID on chassis
that support 1024 MAC addresses. See the Understanding the Bridge ID section on page 14-2.
14-8
OL-6696-01
Chapter 14
Step 1
Command
Purpose
Step 2
Switch(config)# end
Step 3
Note
When you enable or disable the extended system ID, the bridge IDs of all active STP instances are
updated, which might change the spanning tree topology.
This example shows how to enable the extended system ID:
Switch# configure terminal
Switch(config)# spanning-tree extend system-id
Switch(config)# end
Switch#
Note
The root switch for each instance of spanning tree should be a backbone or distribution switch. Do not
configure an access switch as the spanning tree primary root.
14-9
Chapter 14
Configuring STP
Use the diameter keyword to specify the Layer 2 network diameter (the maximum number of bridge
hops between any two end stations in the network). When you specify the network diameter, a switch
automatically picks an optimal hello time, forward delay time, and maximum age time for a network of
that diameter. This can significantly reduce the spanning tree convergence time.
Use the hello-time keyword to override the automatically calculated hello time.
Note
We recommend that you avoid manually configuring the hello time, forward delay time, and maximum
age time after configuring the switch as the root bridge.
To configure a switch as the root switch, perform this task:
Step 1
Command
Purpose
Step 2
Switch(config)# end
This example shows how to configure a switch as the root bridge for VLAN 10, with a network diameter
of 4:
Switch# configure terminal
Switch(config)# spanning-tree vlan 10 root primary diameter 4
Switch(config)# end
Switch#
This example shows how the configuration changes when a switch becomes a spanning tree root. This
is the configuration before the switch becomes the root for VLAN 1:
Switch#show spanning-tree vlan 1
VLAN1 is executing the ieee compatible Spanning Tree protocol
Bridge Identifier has priority 32768, address 0030.94fc.0a00
Configured hello time 2, max age 20, forward delay 15
Current root has priority 32768, address 0001.6445.4400
Root port is 323 (FastEthernet6/3), cost of root path is 19
Topology change flag not set, detected flag not set
Number of topology changes 2 last change occurred 00:02:19 ago
from FastEthernet6/1
Times: hold 1, topology change 35, notification 2
hello 2, max age 20, forward delay 15
Timers:hello 0, topology change 0, notification 0, aging 300
Port 323 (FastEthernet6/3) of VLAN1 is forwarding
Port path cost 19, Port priority 128, Port Identifier 129.67.
Designated root has priority 32768, address 0001.6445.4400
Designated bridge has priority 32768, address 0001.6445.4400
Designated port id is 129.67, designated path cost 0
Timers:message age 2, forward delay 0, hold 0
Number of transitions to forwarding state:1
BPDU:sent 3, received 91
14-10
OL-6696-01
Chapter 14
Note
Because the bridge priority is now set at 8192, this switch becomes the root of the spanning tree.
14-11
Chapter 14
Configuring STP
Note
We recommend that you avoid manually configuring the hello time, forward delay time, and maximum
age time after configuring the switch as the root bridge.
To configure a switch as the secondary root switch, perform this task:
Step 1
Step 2
Command
Purpose
Switch(config)# end
This example shows how to configure the switch as the secondary root switch for VLAN 10, with a
network diameter of 4:
Switch# configure terminal
Switch(config)# spanning-tree vlan 10 root secondary diameter 4
VLAN 10 bridge priority set to 16384
VLAN 10 bridge max aging time set to 14
VLAN 10 bridge hello time unchanged at 2
VLAN 10 bridge forward delay set to 10
Switch(config)# end
Switch#
Priority
32768
Address
0003.6b10.e800
Hello Time
2 sec Max Age 20 sec
Aging Time 300
Interface
---------------Fa3/1
Fa3/2
Fa3/48
Role
---Desg
Desg
Desg
Sts
--FWD
FWD
FWD
Cost
--------19
19
19
Prio.Nbr
-------128.129
128.130
128.176
Status
-------------------------------P2p
P2p
Edge P2p
Switch#
14-12
OL-6696-01
Chapter 14
Note
The Cisco IOS software uses the port priority value when the interface is configured as an access port
and uses VLAN port priority values when the interface is configured as a trunk port.
To configure the spanning tree port priority of an interface, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config-if)# end
Step 5
This example shows how to configure the spanning tree port priority of a Fast Ethernet interface:
Switch# configure terminal
Switch(config)# interface fastethernet 5/8
Switch(config-if)# spanning-tree port-priority 100
Switch(config-if)# end
Switch#
This example shows how to verify the configuration of a Fast Ethernet interface when it is configured as
an access port:
Switch# show spanning-tree interface fastethernet 3/1
Vlan
---------------VLAN0001
VLAN1002
VLAN1003
VLAN1004
VLAN1005
Switch#
Role
---Desg
Desg
Desg
Desg
Desg
Sts
--FWD
FWD
FWD
FWD
FWD
Cost
--------19
19
19
19
19
Prio.Nbr
-------128.129
128.129
128.129
128.129
128.129
Status
-------------------------------P2p
P2p
P2p
P2p
P2p
14-13
Chapter 14
Configuring STP
This example shows how to display the details of the interface configuration when the interface is
configured as an access port:
Switch# show spanning-tree interface fastethernet 3/1 detail
Port 129 (FastEthernet3/1) of VLAN0001 is forwarding
Port path cost 19, Port priority 128, Port Identifier 128.129.
Designated root has priority 32768, address 0003.6b10.e800
Designated bridge has priority 32768, address 0003.6b10.e800
Designated port id is 128.129, designated path cost 0
Timers:message age 0, forward delay 0, hold 0
Number of transitions to forwarding state:1
Link type is point-to-point by default
BPDU:sent 187, received 1
Port 129 (FastEthernet3/1) of VLAN1002 is forwarding
Port path cost 19, Port priority 128, Port Identifier 128.129.
Designated root has priority 32768, address 0003.6b10.ebe9
Designated bridge has priority 32768, address 0003.6b10.ebe9
Designated port id is 128.129, designated path cost 0
Timers:message age 0, forward delay 0, hold 0
Number of transitions to forwarding state:1
Link type is point-to-point by default
BPDU:sent 94, received 2
Port 129 (FastEthernet3/1) of VLAN1003 is forwarding
Port path cost 19, Port priority 128, Port Identifier 128.129.
Designated root has priority 32768, address 0003.6b10.ebea
Designated bridge has priority 32768, address 0003.6b10.ebea
Designated port id is 128.129, designated path cost 0
Timers:message age 0, forward delay 0, hold 0
Number of transitions to forwarding state:1
Link type is point-to-point by default
BPDU:sent 94, received 2
Port 129 (FastEthernet3/1) of VLAN1004 is forwarding
Port path cost 19, Port priority 128, Port Identifier 128.129.
Designated root has priority 32768, address 0003.6b10.ebeb
Designated bridge has priority 32768, address 0003.6b10.ebeb
Designated port id is 128.129, designated path cost 0
Timers:message age 0, forward delay 0, hold 0
Number of transitions to forwarding state:1
Link type is point-to-point by default
BPDU:sent 95, received 2
Port 129 (FastEthernet3/1) of VLAN1005 is forwarding
Port path cost 19, Port priority 128, Port Identifier 128.129.
Designated root has priority 32768, address 0003.6b10.ebec
Designated bridge has priority 32768, address 0003.6b10.ebec
Designated port id is 128.129, designated path cost 0
Timers:message age 0, forward delay 0, hold 0
Number of transitions to forwarding state:1
Link type is point-to-point by default
BPDU:sent 95, received 2
Switch#
Note
The show spanning-tree port-priority command displays only information for ports with an active
link. If there is no port with an active link, enter a show running-config interface command to verify
the configuration.
14-14
OL-6696-01
Chapter 14
This example shows how to configure the spanning tree VLAN port priority of a Fast Ethernet interface:
Switch# configure terminal
Switch(config)# interface fastethernet 5/8
Switch(config-if)# spanning-tree vlan 200 port-priority 64
Switch(config-if)# end
Switch#
This example shows how to verify the configuration of VLAN 200 on the interface when it is configured
as a trunk port:
Switch# show spanning-tree vlan 200
<...output truncated...>
Port 264 (FastEthernet5/8) of VLAN200 is forwarding
Port path cost 19, Port priority 64, Port Identifier 129.8.
Designated root has priority 32768, address 0010.0d40.34c7
Designated bridge has priority 32768, address 0010.0d40.34c7
Designated port id is 128.1, designated path cost 0
Timers: message age 2, forward delay 0, hold 0
Number of transitions to forwarding state: 1
BPDU: sent 0, received 13513
<...output truncated...>
Switch#
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config-if)# end
Step 5
14-15
Chapter 14
Configuring STP
This example shows how to change the spanning tree port cost of a Fast Ethernet interface:
Switch# configure terminal
Switch(config)# interface fastethernet 5/8
Switch(config-if)# spanning-tree cost 18
Switch(config-if)# end
Switch#
This example shows how to verify the configuration of the interface when it is configured as an access
port:
Switch# show spanning-tree interface fastethernet 5/8
Port 264 (FastEthernet5/8) of VLAN200 is forwarding
Port path cost 18, Port priority 100, Port Identifier 129.8.
Designated root has priority 32768, address 0010.0d40.34c7
Designated bridge has priority 32768, address 0010.0d40.34c7
Designated port id is 128.1, designated path cost 0
Timers: message age 2, forward delay 0, hold 0
Number of transitions to forwarding state: 1
BPDU: sent 0, received 13513
Switch#
This example shows how to configure the spanning tree VLAN port cost of a Fast Ethernet interface:
Switch# configure terminal
Switch(config)# interface fastethernet 5/8
Switch(config-if)# spanning-tree vlan 200 cost 17
Switch(config-if)# end
Switch#
This example shows how to verify the configuration of VLAN 200 on the interface when it is configured
as a trunk port:
Switch# show spanning-tree vlan 200
<...output truncated...>
Port 264 (FastEthernet5/8) of VLAN200 is forwarding
Port path cost 17, Port priority 64, Port Identifier 129.8.
Designated root has priority 32768, address 0010.0d40.34c7
Designated bridge has priority 32768, address 0010.0d40.34c7
Designated port id is 128.1, designated path cost 0
Timers: message age 2, forward delay 0, hold 0
Number of transitions to forwarding state: 1
BPDU: sent 0, received 13513
<...output truncated...>
Switch#
Note
The show spanning-tree command displays only information for ports with an active link (green light
is on). If there is no port with an active link, you can issue a show running-config command to confirm
the configuration.
Exercise care when configuring the bridge priority of a VLAN. In most cases, we recommend that you
enter the spanning-tree vlan vlan_ID root primary and the spanning-tree vlan vlan_ID root
secondary commands to modify the bridge priority.
14-16
OL-6696-01
Chapter 14
To configure the spanning tree bridge priority of a VLAN, perform this task:
Step 1
Command
Purpose
Step 2
Switch(config)# end
Step 3
This example shows how to configure the bridge priority of VLAN 200 to 33,792:
Switch# configure terminal
Switch(config)# spanning-tree vlan 200 priority 33792
Switch(config)# end
Switch#
Protocol
-------ieee
Exercise care when configuring the hello time. In most cases, we recommend that you use the
spanning-tree vlan vlan_ID root primary and the spanning-tree vlan vlan_ID root secondary
commands to modify the hello time.
To configure the spanning tree hello time of a VLAN, perform this task:
Command
Purpose
Step 1
Step 2
Switch(config)# end
Step 3
This example shows how to configure the hello time for VLAN 200 to 7 seconds:
Switch# configure terminal
Switch(config)# spanning-tree vlan 200 hello-time 7
Switch(config)# end
Switch#
14-17
Chapter 14
Configuring STP
Protocol
-------ieee
Exercise care when configuring aging time. In most cases, we recommend that you use the
spanning-tree vlan vlan_ID root primary and the spanning-tree vlan vlan_ID root secondary
commands to modify the maximum aging time.
To configure the spanning tree maximum aging time for a VLAN, perform this task:
Step 1
Command
Purpose
Step 2
Switch(config)# end
Step 3
This example shows how to configure the maximum aging time for VLAN 200 to 36 seconds:
Switch# configure terminal
Switch(config)# spanning-tree vlan 200 max-age 36
Switch(config)# end
Switch#
Protocol
-------ieee
Exercise care when configuring forward-delay time. In most cases, we recommend that you use the
spanning-tree vlan vlan_ID root primary and the spanning-tree vlan vlan_ID root secondary
commands to modify the forward delay time.
14-18
OL-6696-01
Chapter 14
To configure the spanning tree forward delay time for a VLAN, perform this task:
Step 1
Command
Purpose
Step 2
Switch(config)# end
Step 3
This example shows how to configure the forward delay time for VLAN 200 to 21 seconds:
Switch# configure terminal
Switch(config)# spanning-tree vlan 200 forward-time 21
Switch(config)# end
Switch#
Protocol
-------ieee
This example shows how to display spanning tree information for the bridge:
Switch# show spanning-tree bridge
Hello
Vlan
Bridge ID
Time
---------------- --------------------------------- ----VLAN200
49152 0050.3e8d.64c8
2
VLAN202
49152 0050.3e8d.64c9
2
VLAN203
49152 0050.3e8d.64ca
2
VLAN204
49152 0050.3e8d.64cb
2
VLAN205
49152 0050.3e8d.64cc
2
VLAN206
49152 0050.3e8d.64cd
2
Switch#
Max
Age
--20
20
20
20
20
20
Fwd
Dly
--15
15
15
15
15
15
Protocol
-------ieee
ieee
ieee
ieee
ieee
ieee
Purpose
Step 1
Step 2
Switch(config)# end
Step 3
14-19
Chapter 14
Configuring STP
Purpose
Step 1
Enables rapid-PVST+.
Step 2
Step 3
Switch(config)#
spanning-tree link-type point-to-point
Step 4
Switch(config-if)# exit
Step 5
Switch(config)# exit
Step 6
Step 7
14-20
OL-6696-01
Chapter 14
The switch, however, does not automatically revert to the MSTP mode if it no longer receives 802.1D
BPDUs because it cannot determine whether or not the legacy switch has been removed from the link
unless the legacy switch is the designated switch. A switch also might continue to assign a boundary role
to a port when the switch to which it is connected has joined the region.
To restart the protocol migration process on the entire switch (that is, to force renegotiation with
neighboring switches), use the clear spanning-tree detected-protocols commands in privileged EXEC
mode. To restart the protocol migration process on a specific interface, enter the clear spanning-tree
detected-protocols interface command in interface-id privileged EXEC mode.
14-21
Chapter 14
Configuring STP
14-22
OL-6696-01
C H A P T E R
15
Note
For information on configuring STP, see Chapter 14, Understanding and Configuring STP.
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
15-1
Chapter 15
B
3/1
3/1
3/2
3/2
3/1
3/2
Root port
Alternate port
55772
Designated port
15-2
OL-6696-01
Chapter 15
Enabling loop guard on a root switch has no effect but provides protection when a root switch becomes
a nonroot switch.
Follow these guidelines when using loop guard:
Enabling loop guard on ports that are not connected to a point-to-point link will not work.
Root guard forces a port to always be the root port. Loop guard is effective only if the port is a root
port or an alternate port. You cannot enable loop guard and root guard on a port at the same time.
Loop guard uses the ports known to spanning tree. Loop guard can take advantage of logical ports
provided by the Port Aggregation Protocol (PAgP). However, to form a channel, all the physical
ports grouped in the channel must have compatible configurations. PAgP enforces uniform
configurations of root guard or loop guard on all the physical ports to form a channel.
These caveats apply to loop guard:
Spanning tree always chooses the first operational port in the channel to send the BPDUs. If that
link becomes unidirectional, loop guard blocks the channel, even if other links in the channel
are functioning properly.
If a set of ports that are already blocked by loop guard are grouped together to form a channel,
spanning tree loses all the state information for those ports and the new channel port may obtain
the forwarding state with a designated role.
If a channel is blocked by loop guard and the channel breaks, spanning tree loses all the state
information. The individual physical ports may obtain the forwarding state with the designated
role, even if one or more of the links that formed the channel are unidirectional.
Note
You can enable UniDirectional Link Detection (UDLD) to help isolate the link failure.
A loop may occur until UDLD detects the failure, but loop guard will not be able to
detect it.
Overview of PortFast
Spanning Tree PortFast causes an interface configured as a Layer 2 access port to enter the forwarding
state immediately, bypassing the listening and learning states. You can use PortFast on Layer 2 access
ports connected to a single workstation or server to allow those devices to connect to the network
immediately, rather than waiting for spanning tree to converge. If the interface receives a bridge protocol
data unit (BPDU), which should not happen if the interface is connected to a single workstation or server,
spanning tree puts the port into the blocking state.
15-3
Chapter 15
Note
Because the purpose of PortFast is to minimize the time that access ports must wait for spanning tree to
converge, it is most effective when used on access ports. If you enable PortFast on a port connecting to
another switch, you risk creating a spanning tree loop.
Note
When the BPDU guard feature is enabled, spanning tree applies the BPDU guard feature to all
PortFast-configured interfaces.
Caution
Explicitly configuring PortFast BPDU filtering on a port that is not connected to a host can result in
bridging loops, because the port will ignore any BPDU it receives and go to the forwarding state.
When you enable PortFast BPDU filtering globally and set the port configuration as the default for
PortFast BPDU filtering (see the Enabling PortFast BPDU Filtering section on page 15-12), PortFast
enables or disables PortFast BPDU filtering.
If the port configuration is not set to default, then the PortFast configuration will not affect PortFast
BPDU filtering. Table 15-1 lists all the possible PortFast BPDU filtering combinations. PortFast BPDU
filtering allows access ports to move directly to the forwarding state as soon as the end hosts are
connected.
15-4
OL-6696-01
Chapter 15
Per-Port Configuration
Global Configuration
PortFast State
Default
Enable
Enable
Enable1
Default
Enable
Disable
Disable
Default
Disable
Not applicable
Disable
Disable
Not applicable
Not applicable
Disable
Enable
Not applicable
Not applicable
Enable
1. The port transmits at least 10 BPDUs. If this port receives any BPDUs, then PortFast and PortFast BPDU filtering are disabled.
Overview of UplinkFast
Note
UplinkFast is most useful in wiring-closet switches. This feature might not be useful for other types of
applications.
Spanning Tree UplinkFast provides fast convergence after a direct link failure and uses uplink groups to
achieve load balancing between redundant Layer 2 links. Convergence is the speed and ability of a group
of internetworking devices running a specific routing protocol to agree on the topology of an
internetwork after a change in that topology. An uplink group is a set of Layer 2 interfaces (per VLAN),
only one of which is forwarding at any given time. Specifically, an uplink group consists of the root port
(which is forwarding) and a set of blocked ports, except for self-looping ports. The uplink group provides
an alternate path in case the currently forwarding link fails.
Figure 15-2 shows an example of a topology with no link failures. Switch A, the root switch, is
connected directly to Switch B over link L1 and to Switch C over link L2. The Layer 2 interface on
Switch C that is connected directly to Switch B is in the blocking state.
Figure 15-2 UplinkFast Before Direct Link Failure
Switch A
(Root)
Switch B
L1
L2
L3
Switch C
11241
Blocked port
If Switch C detects a link failure on the currently active link L2 on the root port (a direct link failure),
UplinkFast unblocks the blocked port on Switch C and transitions it to the forwarding state without
going through the listening and learning states, as shown in Figure 15-3. This switchover takes
approximately one to five seconds.
15-5
Chapter 15
Overview of BackboneFast
Switch A
(Root)
Switch B
L1
L2
L3
Link failure
Switch C
11242
Overview of BackboneFast
BackboneFast is a complementary technology to UplinkFast. Whereas UplinkFast is designed to quickly
respond to failures on links directly connected to leaf-node switches, it does not help with indirect
failures in the backbone core. BackboneFast optimizes based on the Max Age setting. It allows the
default convergence time for indirect failures to be reduced from 50 seconds to 30 seconds. However, it
never eliminates forward delays and offers no assistance for direct failures.
Note
If the port that the inferior BPDUs are received on is already in blocking mode, then the root port
and other blocked ports on the switch become alternate paths to the root bridge.
If the inferior BPDUs are received on a root port, then all presently blocking ports become the
alternate paths to the root bridge. Also, if the inferior BPDUs are received on a root port and there
are no other blocking ports on the switch, the receiving switch assumes that the link to the root
bridge is down and the time defined by the Max Age setting expires, which turns the switch into the
root switch.
If the switch finds an alternate path to the root bridge, it will use this new alternate path. This new path,
and any other alternate paths, will be used to send a Root Link Query (RLQ) BPDU. When BackboneFast
is enabled, the RLQ BPDUs are sent out as soon as an inferior BPDU is received. This process can enable
faster convergence in the event of a backbone link failure.
Figure 15-4 shows an example of a topology with no link failures. Switch A, the root switch, connects
directly to Switch B over link L1 and to Switch C over link L2. In this example, because switch B has a
lower priority than A but higher than C, switch B becomes the designated bridge for L3. Consequently,
the Layer 2 interface on Switch C that connects directly to Switch B must be in the blocking state.
15-6
OL-6696-01
Chapter 15
Switch A
(Root)
Switch B
L1
L2
L3
Switch C
11241
Blocked port
Next, assume that L1 fails. Switch A and Switch B, the switches directly connected to this segment,
instantly know that the link is down. The blocking interface on Switch C must enter the forwarding state
for the network to recover by itself. However, because L1 is not directly connected to Switch C, Switch C
does not start sending any BPDUs on L3 under the normal rules of STP until the time defined by the Max
Age setting has expired.
In an STP environment without BackboneFast, if L1 should fail, Switch C cannot detect this failure
because it is not connected directly to link L1. However, because Switch B is directly connected to the
root switch over L1, Switch B detects the failure and elects itself the root. Then Switch B begins sending
configuration BDPUs to Switch C, listing itself as the root.
Here is what happens additionally when you use BackboneFast to eliminate the time defined by the Max
Age setting (20-second) delay:
1.
When Switch C receives the inferior configuration BPDUs from Switch B, Switch C infers that an
indirect failure has occurred.
2.
3.
Switch A receives the RLQ. Because Switch A is the root bridge, it replies with an RLQ response,
listing itself as the root bridge.
4.
When Switch C receives the RLQ response on its existing root port, it knows that it still has a stable
connection to the root bridge. Because Switch C originated the RLQ request, it does not need to
forward the RLQ response on to other switches.
5.
BackboneFast allows the blocked port on Switch C to move immediately to the listening state
without waiting for the time defined by the Max Age setting for the port to expire.
6.
BackboneFast transitions the Layer 2 interface on Switch C to the forwarding state, providing a path
from Switch B to Switch A.
This switchover takes approximately 30 seconds, twice the Forward Delay time if the default forward
delay time of 15 seconds is set.
Figure 15-5 shows how BackboneFast reconfigures the topology to account for the failure of link L1.
15-7
Chapter 15
Switch A
(Root)
Switch B
L1
Link failure
L3
BackboneFast transitions port
through listening and learning
states to forwarding state
Switch C
11244
L2
If a new switch is introduced into a shared-medium topology as shown in Figure 15-6, BackboneFast is
not activated, because the inferior BPDUs did not come from the recognized designated bridge
(Switch B). The new switch begins sending inferior BPDUs that say it is the root switch. However, the
other switches ignore these inferior BPDUs, and the new switch learns that Switch B is the designated
bridge to Switch A, the root switch.
Figure 15-6 Adding a Switch in a Shared-Medium Topology
Switch A
(Root)
Switch B
(Designated Bridge)
Switch C
Blocked port
11245
Added switch
Purpose
Step 1
Step 2
15-8
OL-6696-01
Chapter 15
Command
Purpose
Step 3
Switch(config-if)# end
Step 4
This example shows how to enable root guard on Fast Ethernet interface 5/8:
Switch(config)# interface fastethernet 5/8
Switch(config-if)# spanning-tree guard root
Switch(config-if)# end
Switch#
This example shows how to determine whether any ports are in root inconsistent state:
Switch# show spanning-tree inconsistentports
Name
-------------------VLAN0001
VLAN0001
VLAN1002
VLAN1002
VLAN1003
VLAN1003
VLAN1004
VLAN1004
VLAN1005
VLAN1005
Interface
---------------------FastEthernet3/1
FastEthernet3/2
FastEthernet3/1
FastEthernet3/2
FastEthernet3/1
FastEthernet3/2
FastEthernet3/1
FastEthernet3/2
FastEthernet3/1
FastEthernet3/2
Inconsistency
-----------------Port Type Inconsistent
Port Type Inconsistent
Port Type Inconsistent
Port Type Inconsistent
Port Type Inconsistent
Port Type Inconsistent
Port Type Inconsistent
Port Type Inconsistent
Port Type Inconsistent
Port Type Inconsistent
Purpose
Step 1
Step 2
Switch(config)# end
Step 3
15-9
Chapter 15
This example shows how to verify the previous configuration of port 4/4:
Switch# show spanning-tree interface fastethernet 4/4 detail
Port 196 (FastEthernet4/4) of VLAN0010 is forwarding
Port path cost 1000, Port priority 160, Port Identifier 160.196.
Designated root has priority 32768, address 00d0.00b8.140a
Designated bridge has priority 32768, address 00d0.00b8.140a
Designated port id is 160.196, designated path cost 0
Timers:message age 0, forward delay 0, hold 0
Number of transitions to forwarding state:1
The port is in the portfast mode by portfast trunk configuration
Link type is point-to-point by default
Bpdu filter is enabled
Loop guard is enabled by default on the port
BPDU:sent 0, received 0
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
Step 4
This example shows how to verify the configuration impact on port 4/4:
Switch# show spanning-tree interface fastEthernet 4/4 detail
Port 196 (FastEthernet4/4) of VLAN0010 is forwarding
Port path cost 1000, Port priority 160, Port Identifier 160.196.
Designated root has priority 32768, address 00d0.00b8.140a
Designated bridge has priority 32768, address 00d0.00b8.140a
Designated port id is 160.196, designated path cost 0
Timers:message age 0, forward delay 0, hold 0
Number of transitions to forwarding state:1
The port is in the portfast mode by portfast trunk configuration
Link type is point-to-point by default
Bpdu filter is enabled
Loop guard is enabled on the port
BPDU:sent 0, received 0
Switch#
15-10
OL-6696-01
Chapter 15
Enabling PortFast
Caution
Use PortFast only when connecting a single end station to a Layer 2 access port. Otherwise, you might
create a network loop.
To enable PortFast on a Layer 2 access port to force it to enter the forwarding state immediately, perform
this task:
Command
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# end
Step 4
This example shows how to enable PortFast on Fast Ethernet interface 5/8:
Switch(config)# interface fastethernet 5/8
Switch(config-if)# spanning-tree portfast
Switch(config-if)# end
Switch#
15-11
Chapter 15
Step 1
Command
Purpose
Step 2
Switch(config)# end
Step 3
Purpose
Step 1
Step 2
15-12
OL-6696-01
Chapter 15
This example shows how to verify the BPDU configuration in PVST+ mode:
Switch# show spanning-tree summary totals
Root bridge for:VLAN0010
EtherChannel misconfiguration guard is enabled
Extended system ID
is disabled
Portfast
is enabled by default
PortFast BPDU Guard is disabled by default
Portfast BPDU Filter is enabled by default
Loopguard
is disabled by default
UplinkFast
is disabled
BackboneFast
is disabled
Pathcost method used is long
Name
Blocking Listening Learning Forwarding STP Active
---------------------- -------- --------- -------- ---------- ---------2 vlans
0
0
0
3
3
Switch#
Note
For PVST+ information, see Chapter 16, Understanding and Configuring Multiple Spanning Trees.
To enable PortFast BPDU filtering, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
This example shows how to enable PortFast BPDU filtering on port 4/4:
Switch(config)# interface fastethernet 4/4
Switch(config-if)# spanning-tree bpdufilter enable
Switch(config-if)# ^Z
This example shows how to verify that PortFast BPDU filtering is enabled:
Switch# show spanning-tree interface fastethernet 4/4
Vlan
Role Sts Cost
Prio.Nbr Status
---------------- ---- --- --------- -------- -------------------------------VLAN0010
Desg FWD 1000
160.196 Edge P2p
15-13
Chapter 15
Enabling UplinkFast
Enabling UplinkFast
UplinkFast increases the bridge priority to 49,152 and adds 3000 to the spanning tree port cost of all
interfaces on the switch, making it unlikely that the switch will become the root switch. The
max_update_rate value represents the number of multicast packets transmitted per second (the default
is 150 packets per second [pps]).
UplinkFast cannot be enabled on VLANs that have been configured for bridge priority. To enable
UplinkFast on a VLAN with bridge priority configured, restore the bridge priority on the VLAN to the
default value by entering a no spanning-tree vlan vlan_ID priority command in global configuration
mode.
Note
When you enable UplinkFast, it affects all VLANs on the switch. You cannot configure UplinkFast on
an individual VLAN.
To enable UplinkFast, perform this task:
Step 1
Command
Purpose
Enables UplinkFast.
You can use the no keyword to disable UplinkFast and
restore the default rate, use the command
Step 2
Switch(config)# end
Step 3
This example shows how to enable UplinkFast with a maximum update rate of 400 pps:
Switch(config)# spanning-tree uplinkfast max-update-rate 400
Switch(config)# exit
Switch#
This example shows how to verify which VLANS have UplinkFast enabled:
Switch# show spanning-tree uplinkfast
UplinkFast is enabled
Station update rate set to 150 packets/sec.
UplinkFast statistics
----------------------Number of transitions via uplinkFast (all VLANs)
:14
Number of proxy multicast addresses transmitted (all VLANs) :5308
Name
-------------------VLAN1
VLAN2
VLAN3
VLAN4
VLAN5
VLAN6
VLAN7
VLAN8
VLAN10
Interface List
-----------------------------------Fa6/9(fwd), Gi5/7
Gi5/7(fwd)
Gi5/7(fwd)
15-14
OL-6696-01
Chapter 15
VLAN15
VLAN1002
VLAN1003
VLAN1004
VLAN1005
Switch#
Gi5/7(fwd)
Gi5/7(fwd)
Gi5/7(fwd)
Gi5/7(fwd)
Enabling BackboneFast
Note
For BackboneFast to work, you must enable it on all switches in the network. BackboneFast is supported
for use with third-party switches but it is not supported on Token Ring VLANs.
To enable BackboneFast, perform this task:
Step 1
Command
Purpose
Enables BackboneFast.
You can use the no keyword to disable BackboneFast.
Step 2
Switch(config)# end
Step 3
:
:
:
:
:
:
0
0
0
0
0
0
15-15
Chapter 15
Enabling BackboneFast
Name
Blocking Listening Learning Forwarding STP Active
---------------------- -------- --------- -------- ---------- ---------VLAN0001
0
0
0
3
3
VLAN1002
0
0
0
2
2
VLAN1003
0
0
0
2
2
VLAN1004
0
0
0
2
2
VLAN1005
0
0
0
2
2
---------------------- -------- --------- -------- ---------- ---------5 vlans
0
0
0
11
11
BackboneFast statistics
----------------------Number of transition via backboneFast (all VLANs)
Number of inferior BPDUs received (all VLANs)
Number of RLQ request PDUs received (all VLANs)
Number of RLQ response PDUs received (all VLANs)
Number of RLQ request PDUs sent (all VLANs)
Number of RLQ response PDUs sent (all VLANs)
Switch#
:0
:0
:0
:0
:0
:0
This example shows how to display the total lines of the spanning tree state section:
Switch#show spanning-tree summary totals
Root bridge for:VLAN0001, VLAN1002-VLAN1005
Extended system ID
is disabled
Portfast
is enabled by default
PortFast BPDU Guard is disabled by default
Portfast BPDU Filter is enabled by default
Loopguard
is disabled by default
EtherChannel misconfiguration guard is enabled
UplinkFast
is enabled
BackboneFast
is enabled
Pathcost method used is short
Name
Blocking Listening Learning Forwarding STP Active
---------------------- -------- --------- -------- ---------- ---------5 vlans
0
0
0
11
11
BackboneFast statistics
----------------------Number of transition via backboneFast (all VLANs)
Number of inferior BPDUs received (all VLANs)
Number of RLQ request PDUs received (all VLANs)
Number of RLQ response PDUs received (all VLANs)
Number of RLQ request PDUs sent (all VLANs)
Number of RLQ response PDUs sent (all VLANs)
Switch#
:0
:0
:0
:0
:0
:0
15-16
OL-6696-01
C H A P T E R
16
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Overview of MST
The following sections describe how MST works on a Catalyst 4500 series switch:
16-1
Chapter 16
Overview of MST
MST runs a variant of spanning tree called Internal Spanning Tree (IST). IST augments Common
Spanning Tree (CST) information with internal information about the MST region. The MST region
appears as a single bridge to adjacent single spanning tree (SST) and MST regions.
MST region.
IST connects all the MST bridges in the region and appears as a subtree in the CST that includes
the whole bridged domain. The MST region appears as a virtual bridge to adjacent SST bridges
and MST regions.
The Common and Internal Spanning Tree (CIST) is the collection of the following: ISTs in each
MST region, the CST that interconnects the MST regions, and the SST bridges. CIST is
identical to an IST inside an MST region and identical to a CST outside an MST region. The
STP, RSTP, and MSTP together elect a single bridge as the root of the CIST.
MST establishes and maintains additional spanning trees within each MST region. These spanning
trees are termed MST instances (MSTIs). The IST is numbered 0, and the MSTIs are numbered 1,
2, 3, and so on. Any MSTI is local to the MST region and is independent of MSTIs in another region,
even if the MST regions are interconnected.
MST instances combine with the IST at the boundary of MST regions to become the CST as follows:
Spanning tree information for an MSTI is contained in an MSTP record (M-record).
M-records are always encapsulated within MST bridge protocol data units (BPDUs). The
original spanning trees computed by MSTP are called M-trees, which are active only within the
MST region. M-trees merge with the IST at the boundary of the MST region and form the CST.
MST provides interoperability with PVST+ by generating PVST+ BPDUs for the non-CST VLANs.
16-2
OL-6696-01
Chapter 16
primary.
RSTP selectively sends 802.1D-configured BPDUs and Topology Change Notification (TCN)
BPDUs on a per-port basis.
When a port initializes, the migration delay timer starts and RSTP BPDUs are transmitted. While
the migration delay timer is active, the bridge processes all BPDUs received on that port.
If the bridge receives an 802.1D BPDU after a ports migration delay timer expires, the bridge
assumes it is connected to an 802.1D bridge and starts using only 802.1D BPDUs.
When RSTP uses 802.1D BPDUs on a port and receives an RSTP BPDU after the migration delay
expires, RSTP restarts the migration delay timer and begins using RSTP BPDUs on that port.
AlternateAn alternate path to the root bridge to that provided by the current root port.
BackupA backup for the path provided by a designated port toward the leaves of the spanning tree.
Backup ports can exist only where two ports are connected together in a loopback mode or bridge
with two or more connections to a shared LAN segment.
DisabledA port that has no role within the operation of spanning tree.
A root port or designated port role includes the port in the active topology.
An alternate port or backup port role excludes the port from the active topology.
16-3
Chapter 16
Overview of MST
Operational Status
Discarding
No
Enabled
Blocking
Enabled
Listening
Discarding
No
Enabled
Learning
Learning
Yes
Enabled
Forwarding
Forwarding
Yes
Disabled
Disabled
Discarding
No
In a stable topology, RSTP ensures that every root port and designated port transitions to the forwarding
state while all alternate ports and backup ports are always in the discarding state.
MST-to-SST Interoperability
A virtual bridged LAN may contain interconnected regions of SST and MST bridges. Figure 16-1 shows
this relationship.
Figure 16-1 Network with Interconnected SST and MST Regions
MST
Region
r
B
B
B
F
F
r
r
b SST
Region
F
F
F/f = Forwarding
B/b = Blocking
R = Root Bridge
r = Root port
r
r
F
F
R
MST
Region
68285
r
SST
b
Region
16-4
OL-6696-01
Chapter 16
To STP running in the SST region, an MST region appears as a single SST or pseudobridge, which
operates as follows:
Although the values for root identifiers and root path costs match for all BPDUs in all
pseudobridges, a pseudobridge differs from a single SST bridge as follows:
The pseudobridge BPDUs have different bridge identifiers. This difference does not affect STP
operation in the neighboring SST regions because the root identifier and root cost are the same.
BPDUs sent from the pseudobridge ports may have significantly different message ages.
Because the message age increases by one second for each hop, the difference in the message
age is measured in seconds.
Data traffic from one port of a pseudobridge (a port at the edge of a region) to another port follows
a path entirely contained within the pseudobridge or MST region. Data traffic belonging to different
VLANs might follow different paths within the MST regions established by MST.
MST Instances
This release supports up to 16 instances; each spanning tree instance is identified by an instance ID that
ranges from 0 to 15. Instance 0 is mandatory and is always present. Instances 1 through 15 are optional.
NameA 32-character string (null padded) that identifies the MST region.
Revision numberAn unsigned 16-bit number that identifies the revision of the current MST
configuration.
Note
You must set the revision number when required as part of the MST configuration. The
revision number is not incremented automatically each time you commit the MST
configuration.
MST configuration tableAn array of 4096 bytes. Each byte, interpreted as an unsigned integer,
corresponds to a VLAN. The value is the instance number to which the VLAN is mapped. The first
byte that corresponds to VLAN 0 and the 4096th byte that corresponds to VLAN 4095 are unused
and always set to zero.
You must configure each byte manually. You can use SNMP or the CLI to perform the configuration.
16-5
Chapter 16
Overview of MST
MST BPDUs contain the MST configuration ID and the checksum. An MST bridge accepts an MST
BPDU only if the MST BPDU configuration ID and the checksum match its own MST region
configuration ID and checksum. If either value is different, the MST BPDU is considered to be an
SST BPDU.
MST Regions
These sections describe MST regions:
An MST bridge interconnected by a LAN. A LANs designated bridge has the same MST
configuration as an MST bridge. All the bridges on the LAN can process MST BPDUs.
If you connect two MST regions with different MST configurations, the MST regions do the following:
Load balance across redundant paths in the network. If two MST regions are redundantly connected,
all traffic flows on a single connection with the MST regions in a network.
Provide an RSTP handshake to enable rapid connectivity between regions. However, the
handshaking is not as fast as between two bridges. To prevent loops, all the bridges inside the region
must agree upon the connections to other regions. This situation introduces a delay. We do not
recommend partitioning the network into a large number of regions.
Boundary Ports
A boundary port is a port that connects to a LAN, the designated bridge of which is either an SST bridge
or a bridge with a different MST configuration. A designated port knows that it is on the boundary if it
detects an STP bridge or receives an agreement message from an RST or MST bridge with a different
configuration.
At the boundary, the role of MST ports do not matter; their state is forced to be the same as the IST port
state. If the boundary flag is set for the port, the MSTP Port Role selection mechanism assigns a port
role to the boundary and the same state as that of the IST port. The IST port at the boundary can take up
any port role except a backup port role.
16-6
OL-6696-01
Chapter 16
IST Master
The IST master of an MST region is the bridge with the lowest bridge identifier and the least path cost
to the CST root. If an MST bridge is the root bridge for CST, then it is the IST master of that MST region.
If the CST root is outside the MST region, then one of the MST bridges at the boundary is selected as
the IST master. Other bridges on the boundary that belong to the same region eventually block the
boundary ports that lead to the root.
If two or more bridges at the boundary of a region have an identical path to the root, you can set a slightly
lower bridge priority to make a specific bridge the IST master.
The root path cost and message age inside a region stay constant, but the IST path cost is incremented
and the IST remaining hops are decremented at each hop. Enter the show spanning-tree mst command
to display the information about the IST master, path cost, and remaining hops for the bridge.
Edge Ports
A port that is connected to a nonbridging device (for example, a host or a switch) is an edge port. A port
that connects to a hub is also an edge port if the hub or any LAN that is connected to it does not have a
bridge. An edge port can start forwarding as soon as the link is up.
MST requires that you configure each port connected to a host. To establish rapid connectivity after a
failure, you need to block the non-edge designated ports of an intermediate bridge. If the port connects
to another bridge that can send back an agreement, then the port starts forwarding immediately.
Otherwise, the port needs twice the forward delay time to start forwarding again. You must explicitly
configure the ports that are connected to the hosts and switches as edge ports while using MST.
To prevent a misconfiguration, the PortFast operation is turned off if the port receives a BPDU. You can
display the configured and operational status of PortFast by using the show spanning-tree mst interface
command.
Link Type
Rapid connectivity is established only on point-to-point links. You must configure ports explicitly to a
host or switch. However, cabling in most networks meets this requirement, and you can avoid explicit
configuration by treating all full-duplex links as point-to-point links by entering the spanning-tree
linktype command.
16-7
Chapter 16
MST-to-PVST+ Interoperability
Keep these guidelines in mind when you configure MST switches (in the same region) to interact with
PVST+ switches:
Configure the root for all VLANs inside the MST region as shown in this example:
Switch# show spanning-tree mst interface gigabitethernet 1/1
GigabitEthernet1/1 of MST00 is root forwarding
Edge port: no
(trunk)
port guard : none
Link type: point-to-point (auto)
bpdu filter: disable
Boundary : boundary
(PVST)
bpdu guard : disable
Bpdus sent 10, received 310
Instance
-------0
3
Role
---Root
Boun
Sts
--FWD
FWD
Cost
--------20000
20000
Prio.Nbr
-------128.1
128.1
(default)
(default)
(default)
Vlans mapped
------------------------------1-2,4-2999,4000-4094
3,3000-3999
The ports that belong to the MST switch at the boundary simulate PVST+ and send PVST+ BPDUs
for all the VLANs.
If you enable loop guard on the PVST+ switches, the ports might change to a loop-inconsistent state
when the MST switches change their configuration. To correct the loop-inconsistent state, you must
disable and renewable loop guard on that PVST+ switch.
Do not locate the root for some or all of the VLANs inside the PVST+ side of the MST switch
because when the MST switch at the boundary receives PVST+ BPDUs for all or some of the
VLANs on its designated ports, root guard sets the port to the blocking state.
When you connect a PVST+ switch to two different MST regions, the topology change from the PVST+
switch does not pass beyond the first MST region. In such a case, the topology changes are propagated
only in the instance to which the VLAN is mapped. The topology change stays local to the first MST
region, and the Cisco Access Manager (CAM) entries in the other region are not flushed. To make the
topology change visible throughout other MST regions, you can map that VLAN to IST or connect the
PVST+ switch to the two regions through access links.
Do not disable spanning tree on any VLAN in any of the PVST bridges.
Do not connect switches with access links, because access links may partition a VLAN.
Ensure that all PVST root bridges have lower (numerically higher) priority than the CST root bridge.
Ensure that trunks carry all of the VLANs mapped to an instance or do not carry any VLANs at all
for this instance.
Complete any MST configuration that incorporates a large number of either existing or new logical
VLAN ports during a maintenance window because the complete MST database gets reinitialized
for any incremental change (such as adding new VLANs to instances or moving VLANs across
instances).
16-8
OL-6696-01
Chapter 16
Configuring MST
The following sections describe how to configure MST:
Enabling MST
To enable and configure MST on a Catalyst 4006 switch with Supervisor Engine III, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Step 4
Step 5
Step 6
Step 7
Step 8
Switch(config-mst)# end
Step 9
16-9
Chapter 16
Configuring MST
16-10
OL-6696-01
Chapter 16
Purpose
Step 1
Step 2
Step 3
Switch(config)# Ctrl-Z
Step 4
Role
---Back
Desg
Desg
Sts
--BLK
FWD
FWD
Cost
--------1000
200000
200000
Prio.Nbr
-------240.196
128.197
128.240
###### MST01
vlans mapped: 1-10
Bridge
address 00d0.00b8.1400 priority
Root
this switch for MST01
Interface
---------------Fa4/4
Fa4/5
Fa4/48
Role
---Back
Desg
Boun
Sts
--BLK
FWD
FWD
Cost
--------1000
200000
200000
Prio.Nbr
-------160.196
128.197
128.240
Status
-------------------------------P2p
P2p
P2p Bound(STP)
Status
-------------------------------P2p
P2p
P2p Bound(STP)
Switch#
16-11
Chapter 16
Configuring MST
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# Ctrl-Z
Step 4
(default)
(default)
(default)
16-12
OL-6696-01
Chapter 16
Purpose
Step 1
Step 2
Step 3
Step 4
Step 5
Step 6
The following examples show how to display spanning tree VLAN configurations in MST mode:
Switch(config)# spanning-tree mst configuration
Switch(config-mst)# instance 1 vlan 1-10
Switch(config-mst)# name cisco
Switch(config-mst)# revision 1
Switch(config-mst)# Ctrl-D
Switch# show spanning-tree mst configuration
Name
[cisco]
Revision 1
Instance Vlans mapped
-------- --------------------------------------------------------------------0
11-4094
1
1-10
------------------------------------------------------------------------------Switch# show spanning-tree mst
###### MST00
vlans mapped: 11-4094
Bridge
address 00d0.00b8.1400 priority 32768 (32768 sysid
Root
address 00d0.004a.3c1c priority 32768 (32768 sysid
port
Fa4/48
path cost 203100
IST master this switch
Operational hello time 2, forward delay 15, max age 20, max hops
Configured hello time 2, forward delay 15, max age 20, max hops
Interface
---------------Fa4/4
Fa4/5
Fa4/48
Role
---Back
Desg
Root
Sts
--BLK
FWD
FWD
Cost
--------1000
200000
200000
Prio.Nbr
-------240.196
128.197
128.240
###### MST01
vlans mapped: 1-10
Bridge
address 00d0.00b8.1400 priority
Root
this switch for MST01
Interface
---------------Fa4/4
Fa4/5
Fa4/48
Role
---Back
Desg
Boun
Sts
--BLK
FWD
FWD
Cost
--------1000
200000
200000
Prio.Nbr
-------240.196
128.197
128.240
0)
0)
20
20
Status
-------------------------------P2p
P2p
P2p Bound(STP)
Status
-------------------------------P2p
P2p
P2p Bound(STP)
16-13
Chapter 16
Configuring MST
Role
---Back
Desg
Boun
Sts
--BLK
FWD
FWD
Cost
--------1000
200000
200000
Prio.Nbr
-------240.196
128.197
128.240
Status
-------------------------------P2p
P2p
P2p Bound(STP)
Role
---Back
Back
Sts
--BLK
BLK
Cost
--------1000
1000
Prio.Nbr
-------240.196
240.196
(default)
(default)
(default)
Vlans mapped
------------------------------11-4094
1-10
is backup blocking
(default)
port guard :none
(auto)
bpdu filter:disable
bpdu guard :disable
received 364
(default)
(default)
(default)
16-14
OL-6696-01
Chapter 16
Priority
Address
Hello Time
Interface
---------------Fa4/4
Fa4/5
Role
---Back
Desg
Sts
--BLK
FWD
Prio.Nbr
-------240.196
128.197
Status
-------------------------------P2p
P2p
is enabled
default
default
default
default
Name
Blocking Listening Learning Forwarding STP Active
---------------------- -------- --------- -------- ---------- ---------MST00
1
0
0
2
3
MST01
1
0
0
2
3
---------------------- -------- --------- -------- ---------- ---------2 msts
2
0
0
4
6
Switch#
16-15
Chapter 16
Configuring MST
16-16
OL-6696-01
C H A P T E R
17
Note
The commands in the following sections can be used on all Ethernet interfaces on a Catalyst 4500 series
switch, including the uplink ports on the supervisor engine.
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Overview of EtherChannel
These subsections describe how EtherChannel works:
EtherChannel bundles individual Ethernet links into a single logical link that provides bandwidth up to
1600 Mbps (Fast EtherChannel full duplex) or 16 Gbps (Gigabit EtherChannel) between a Catalyst 4500
series switch and another switch or host.
A Catalyst 4500 series switch supports a maximum of 64 EtherChannels. You can form an EtherChannel
with up to eight compatibly configured Ethernet interfaces across modules in a Catalyst 4500 series
switch. All interfaces in each EtherChannel must be the same speed and must be configured as either
Layer 2 or Layer 3 interfaces.
17-1
Chapter 17
Overview of EtherChannel
Note
The network device to which a Catalyst 4500 series switch is connected may impose its own limits on
the number of interfaces in an EtherChannel.
If a segment within an EtherChannel fails, traffic previously carried over the failed link switches to the
remaining segments within the EtherChannel. Once the segment fails, an SNMP trap is sent, identifying
the switch, the EtherChannel, and the failed link. Inbound broadcast and multicast packets on one
segment in an EtherChannel are blocked from returning on any other segment of the EtherChannel.
Note
QoS does not propagate to members. The defaults, QoS cos = 0 and QoS dscp = 0, apply on the
port-channel. Input or output policies applied on individual interfaces will be ignored.
After you configure an EtherChannel, the configuration that you apply to the port-channel interface
affects the EtherChannel; the configuration that you apply to the physical interfaces affects only the
interface where you apply the configuration. To change the parameters of all ports in an EtherChannel,
apply configuration commands to the port-channel interface (such commands can be STP commands or
commands to configure a Layer 2 EtherChannel as a trunk).
17-2
OL-6696-01
Chapter 17
Mode
Description
on
Mode that forces the LAN port to channel unconditionally. In the on mode, a usable
EtherChannel exists only when a LAN port group in the on mode is connected to another
LAN port group in the on mode. Because ports configured in the on mode do not negotiate,
there is no negotiation traffic between the ports.
auto
PAgP mode that places a LAN port into a passive negotiating state, in which the port
responds to PAgP packets it receives but does not initiate PAgP negotiation.
desirable
PAgP mode that places a LAN port into an active negotiating state, in which the port
initiates negotiations with other LAN ports by sending PAgP packets.
passive
LACP mode that places a port into a passive negotiating state, in which the port responds
to LACP packets it receives but does not initiate LACP negotiation.
active
LACP mode that places a port into an active negotiating state, in which the port initiates
negotiations with other ports by sending LACP packets.
A LAN port in desirable mode can form an EtherChannel successfully with another LAN port that
is in desirable mode.
A LAN port in desirable mode can form an EtherChannel with another LAN port in auto mode.
A LAN port in auto mode cannot form an EtherChannel with another LAN port that is also in auto
mode, because neither port will initiate negotiation.
17-3
Chapter 17
Overview of EtherChannel
The protocol learns the capabilities of LAN port groups dynamically and informs the other LAN ports.
Once LACP identifies correctly matched Ethernet links, it facilitates grouping the links into an
EtherChannel. The EtherChannel is then added to the spanning tree as a single bridge port.
Both the passive and active modes allow LACP to negotiate between LAN ports to determine if they can
form an EtherChannel, based on criteria such as port speed and trunking state. Layer 2 EtherChannels
also use VLAN numbers.
LAN ports can form an EtherChannel when they are in different LACP modes as long as the modes are
compatible. For example:
A LAN port in active mode can form an EtherChannel successfully with another LAN port that is
in active mode.
A LAN port in active mode can form an EtherChannel with another LAN port in passive mode.
A LAN port in passive mode cannot form an EtherChannel with another LAN port that is also in
passive mode, because neither port will initiate negotiation.
LACP system priorityYou may configure an LACP system priority on each switch running LACP.
The system priority can be configured automatically or through the CLI. See the Configuring the
LACP System Priority and System ID section on page 17-11. LACP uses the system priority with
the switch MAC address to form the system ID and also during negotiation with other systems.
Note
Note
The LACP system ID is the combination of the LACP system priority value and the MAC
address of the switch.
LACP port priorityYou must configure an LACP port priority on each port configured to use
LACP. The port priority can be configured automatically or through the CLI. See the Configuring
Layer 2 EtherChannels section on page 17-9. LACP uses the port priority with the port number to
form the port identifier.
LACP administrative keyLACP automatically configures an administrative key value equal to the
channel group identification number on each port configured to use LACP. The administrative key
defines the ability of a port to aggregate with other ports. A ports ability to aggregate with other
ports is determined by these factors:
Port physical characteristics, such as data rate, duplex capability, and point-to-point or shared
medium
Configuration restrictions that you establish
LACP tries to configure the maximum number of compatible ports in an EtherChannel, up to the
maximum allowed by the hardware (eight ports). If a port can not be actively included in a channel, it
will not be included automatically if a channelled port fails.
17-4
OL-6696-01
Chapter 17
Note
Load balancing can only be configured globally. As a result, all channels (manually configured, PagP,
or LACP) will use the same load balancing method.
For additional information on load balancing, see the Configuring EtherChannel Load Balancing
section on page 17-12.
All Ethernet interfaces on all modules support EtherChannel (maximum of eight interfaces) with no
requirement that interfaces be physically contiguous or on the same module.
Configure all interfaces in an EtherChannel to operate at the same speed and duplex mode.
An EtherChannel will not form if one of the interfaces is a Switched Port Analyzer (SPAN)
destination port.
the channel.
same on all the trunks. Interfaces in an EtherChannel with different trunk modes can have
unexpected results.
An EtherChannel supports the same allowed range of VLANs on all the interfaces in a trunking
Layer 2 EtherChannel. If the allowed range of VLANs is not the same, the interfaces do not
form an EtherChannel.
Interfaces with different Spanning Tree Protocol (STP) port path costs can form an
EtherChannel as long they are otherwise compatibly configured. Setting different STP port path
costs does not, by itself, make interfaces incompatible for the formation of an EtherChannel.
17-5
Chapter 17
Configuring EtherChannel
After you configure an EtherChannel, any configuration that you apply to the port-channel interface
affects the EtherChannel; any configuration that you apply to the physical interfaces affects only the
interface where you apply the configuration.
Configuring EtherChannel
These sections describe how to configure EtherChannel:
Note
Configuring the LACP System Priority and System ID, page 17-11
Ensure that the interfaces are configured correctly. (See the EtherChannel Configuration Guidelines
and Restrictions section on page 17-5.)
To move an IP address from a physical interface to an EtherChannel, you must delete the IP address from
the physical interface before configuring it on the port-channel interface.
17-6
OL-6696-01
Chapter 17
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# end
Step 4
Purpose
Step 1
Step 2
Switch(config-if)# no switchport
Step 3
Switch(config-if)# no ip address
Step 4
17-7
Chapter 17
Configuring EtherChannel
Command
Purpose
Step 5
Switch(config-if)# end
Step 6
This example shows how to configure Fast Ethernet interfaces 5/4 and 5/5 into port-channel 1 with PAgP
mode desirable:
Switch# configure terminal
Switch(config)# interface range fastethernet 5/4 - 5 (Note: Space is mandatory.)
Switch(config-if)# no switchport
Switch(config-if)# no ip address
Switch(config-if)# channel-group 1 mode desirable
Switch(config-if)# end
Note
See the Configuring a Range of Interfaces section on page 4-4 for information about the range
keyword.
The following two examples shows how to verify the configuration of Fast Ethernet interface 5/4:
Switch# show running-config interface fastethernet 5/4
Building configuration...
Current configuration:
!
interface FastEthernet5/4
no ip address
no switchport
no ip directed-broadcast
channel-group 1 mode desirable
end
Switch# show interfaces fastethernet 5/4 etherchannel
Port state
= EC-Enbld Up In-Bndl Usr-Config
Channel group = 1
Mode = Desirable
Gcchange = 0
Port-channel = Po1
GC
= 0x00010001
Pseudo-port-channel = Po1
Port indx
= 0
Load = 0x55
Flags:
S
A
Timers: H
S
C
P
Q
I
Local information:
Port
Fa5/4
Flags State
SC
U6/S7
Timers
Hello
Partner PAgP
Interval Count
Priority
30s
1
128
Learning Group
Method Ifindex
Any
55
17-8
OL-6696-01
Chapter 17
Partner's information:
Port
Fa5/4
Partner
Name
JAB031301
Partner
Device ID
0050.0f10.230c
Partner
Port
2/45
Partner Group
Age Flags
Cap.
1s SAC
2D
This example shows how to verify the configuration of port-channel interface 1 after the interfaces have
been configured:
Switch# show etherchannel 1 port-channel
Channel-group listing:
---------------------Group: 1
-----------Port-channels in the group:
---------------------Port-channel: Po1
-----------Age of the Port-channel
= 01h:56m:20s
Logical slot/port
= 10/1
Number of ports = 2
GC
= 0x00010001
HotStandBy port = null
Port state
= Port-channel L3-Ag Ag-Inuse
Ports in the Port-channel:
Index
Load
Port
------------------1
00
Fa5/6
0
00
Fa5/7
Time since last port bundled:
00h:23m:33s
Fa5/6
Switch#
Note
Cisco IOS software creates port-channel interfaces for Layer 2 EtherChannels when you configure
Layer 2 Ethernet interfaces with the channel-group command.
17-9
Chapter 17
Configuring EtherChannel
To configure Layer 2 Ethernet interfaces as Layer 2 EtherChannels, perform this task for each interface:
Command
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# end
Step 4
This example shows how to configure Fast Ethernet interfaces 5/6 and 5/7 into port-channel 2 with PAgP
mode desirable:
Switch# configure terminal
Switch(config)# interface range fastethernet 5/6 - 7 (Note: Space is mandatory.)
Switch(config-if-range)# channel-group 2 mode desirable
Switch(config-if-range)# end
Note
See the Configuring a Range of Interfaces section on page 4-4 for information about the range
keyword.
This example shows how to verify the configuration of port-channel interface 2:
Switch# show running-config interface port-channel 2
Building configuration...
Current configuration:
!
interface Port-channel2
switchport access vlan 10
switchport mode access
end
Switch#
The following two examples show how to verify the configuration of Fast Ethernet interface 5/6:
Switch# show running-config interface fastethernet 5/6
Building configuration...
Current configuration:
!
interface FastEthernet5/6
switchport access vlan 10
switchport mode access
channel-group 2 mode desirable
end
17-10
OL-6696-01
Chapter 17
Port
Fa5/6
Partner
Name
JAB031301
Partner
Device ID
0050.0f10.230c
Partner
Port
2/47
Partner Group
Age Flags
Cap.
18s SAC
2F
This example shows how to verify the configuration of port-channel interface 2 after the interfaces have
been configured:
Switch# show etherchannel 2 port-channel
Port-channels in the group:
---------------------Port-channel: Po2
-----------Age of the Port-channel
= 00h:23m:33s
Logical slot/port
= 10/2
Number of ports in agport = 2
GC
= 0x00020001
HotStandBy port = null
Port state
= Port-channel Ag-Inuse
Ports in the Port-channel:
Index
Load
Port
------------------1
00
Fa5/6
0
00
Fa5/7
Time since last port bundled:
00h:23m:33s
Fa5/6
Switch#
17-11
Chapter 17
Configuring EtherChannel
To configure the LACP system priority and system ID, perform this task:
Command
Purpose
Step 2
Router(config)# end
Step 3
Step 1
The system priority is displayed first, followed by the MAC address of the switch.
Load balancing can only be configured globally. As a result, all channels (manually configured, PagP,
or LACP) will use the same load balancing method.
To configure EtherChannel load balancing, perform this task:
Step 1
Command
Purpose
17-12
OL-6696-01
Chapter 17
Command
Purpose
Step 2
Switch(config)# end
Step 3
src-ipSource IP addresses
dst-ipDestination IP addresses
This example shows how to configure EtherChannel to use source and destination IP addresses:
Switch# configure terminal
Switch(config)# port-channel load-balance dst-mac
Switch(config)# end
Switch(config)#
Purpose
Step 1
Step 2
Switch(config-if)# no channel-group
Step 3
Switch(config-if)# end
Step 4
This example shows how to remove Fast Ethernet interfaces 5/4 and 5/5 from port-channel 1:
Switch# configure terminal
Switch(config)# interface range fastethernet 5/4 - 5 (Note: Space is mandatory.)
Switch(config-if)# no channel-group 1
Switch(config-if)# end
17-13
Chapter 17
Configuring EtherChannel
Removing an EtherChannel
If you remove an EtherChannel, the member ports are shut down and removed from the Channel group.
Note
You must remove an EtherChannel before changing a port from Layer 2 to Layer 3, or Layer 3 to Layer 2.
To remove an EtherChannel, perform this task:
Command
Purpose
Step 1
Step 2
Switch(config)# end
Step 3
17-14
OL-6696-01
C H A P T E R
18
Note
To support Cisco Group Management Protocol (CGMP) client devices, configure the switch as a CGMP
server. For more information, see the chapters IP Multicast and Configuring IP Multicast Routing
in the Cisco IOS IP and IP Routing Configuration Guide, Release 12.2 at this URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/ip_c/ipcprt3/1cdmulti.htm
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Note
18-1
Chapter 18
In contrast to IGMPv1 and IGMPv2, IGMPv3 snooping provides immediate-leave processing by default.
It provides Explicit Host Tracking (EHT) and allows network administrators to deploy SSM
functionality on Layer 2 devices that truly support IGMPv3. (See Explicit Host Tracking, page 18-3.)
In subnets where IGMP is configured, IGMP snooping manages multicast traffic at Layer 2. You can
configure interfaces to dynamically forward multicast traffic only to those interfaces that are interested
in receiving it by using the switchport keyword.
IGMP snooping restricts traffic in MAC multicast groups 0100.5e00.0001 to 01-00-5e-ff-ff-ff. IGMP
snooping does not restrict Layer 2 multicast packets generated by routing protocols.
Note
For more information on IP multicast and IGMP, refer to RFC 1112, RFC 2236, RFC 3376 (for
IGMPv3).
IGMP (configured on a router) periodically sends out IGMP general queries. A host responds to these
queries with IGMP membership reports for groups that it is interested in. When IGMP snooping is
enabled, the switch creates one entry per VLAN in the Layer 2 forwarding table for each Layer 2
multicast group from which it receives an IGMP join request. All hosts interested in this multicast traffic
send IGMP membership reports and are added to the forwarding table entry.
Layer 2 multicast groups learned through IGMP snooping are dynamic. However, you can statically
configure Layer 2 multicast groups using the ip igmp snooping static command. If you specify group
membership statically, your setting supersedes any automatic manipulation by IGMP snooping.
Multicast group membership lists can contain both user-defined and IGMP snooping settings.
Groups with IP addresses in the range 224.0.0.0 to 224.0.0.255, which map to the multicast MAC address
range 0100.5E00.0001 to 0100.5E00.00FF, are reserved for routing control packets. These groups are
flooded to all forwarding ports of the VLAN with the exception of 224.0.0.22, which is used for IGMPv3
membership reports.
Note
If a VLAN experiences a spanning-tree topology change, IP multicast traffic floods on all VLAN ports
where PortFast is not enabled, as well as on ports with the no igmp snooping tcn flood command
configured for a period of TCN query count.
For a Layer 2 IGMPv2 host interface to join an IP multicast group, a host sends an IGMP membership
report for the IP multicast group. For a host to leave a multicast group, it can either ignore the periodic
IGMP general queries or it can send an IGMP leave message. When the switch receives an IGMP leave
message from a host, it sends out an IGMP group-specific query to determine whether any devices
connected to that interface are interested in traffic for the specific multicast group. The switch then
updates the table entry for that Layer 2 multicast group so that only those hosts interested in receiving
multicast traffic for the group are listed.
In contrast, IGMPv3 hosts send IGMPv3 membership reports (with the allow group record mode) to join
a specific multicast group. When IGMPv3 hosts send membership reports (with the block group record)
to reject traffic from all sources in the previous source list, the last host on the port will be removed by
immediate-leave if EHT is enabled.
18-2
OL-6696-01
Chapter 18
Immediate-Leave Processing
IGMP snooping immediate-leave processing allows the switch to remove an interface from the
forwarding-table entry without first sending out IGMP group-specific queries to the interface. The
VLAN interface is pruned from the multicast tree for the multicast group specified in the original IGMP
leave message. Immediate-leave processing ensures optimal bandwidth management for all hosts on a
switched network, even when multiple multicast groups are being used simultaneously.
When a switch with IGMP snooping enabled receives an IGMPv2 or IGMPv3 leave message, it sends
an IGMP group-specific query from the interface where the leave message was received to determine
when there are other hosts attached to that interface that are interested in joining the MAC multicast
group. If the switch does not receive an IGMP join message within the query response interval, the
interface is removed from the port list of the (MAC-group, VLAN) entry in the Layer 2 forwarding table.
Note
By default all IGMP joins are forwarded to all multicast router ports.
With immediate-leave processing enabled on the VLAN, an interface can be removed immediately from
the port list of the Layer 2 entry when the IGMP leave message is received, unless a multicast router was
learned on the port.
Note
When using IGMPv2 snooping, use immediate-leave processing only on VLANs where just one host is
connected to each interface. If immediate-leave processing is enabled on VLANs where multiple hosts
are connected to an interface, some hosts might be dropped inadvertently. When using IGMPv3,
immediate-leave processing is enabled by default, and due to Explicit Host Tracking (see below), the
switch can detect when a port has single or multiple hosts maintained by the switch for IGMPv3 hosts.
As a result, the switch can perform immediate-leave processing when it detects a single host behind a
given port.
Note
Note
18-3
Chapter 18
To determine whether or not EHT is enabled on a VLAN, use the show ip igmp snoop vlan command.
When configuring IGMP, configure the VLAN in the VLAN database mode. (See Chapter 10,
Understanding and Configuring VLANs.)
IGMP snooping allows switches to examine IGMP packets and make forwarding decisions based on their
content.
These sections describe how to configure IGMP snooping:
Feature
Default Value
IGMP snooping
Enabled
Multicast routers
None configured
Immediate-leave processing
Report Suppression
Enabled
PIM/DVMRP1
18-4
OL-6696-01
Chapter 18
Step 1
Command
Purpose
Step 2
Switch(config)# end
Step 3
This example shows how to enable IGMP snooping globally and verify the configuration:
Switch(config)# ip igmp snooping
Switch(config)# end
Switch# show ip igmp snooping
Global IGMP Snooping configuration:
----------------------------------IGMP snooping
: Enabled
IGMPv3 snooping
: Enabled
Report suppression
: Enabled
TCN solicit query
: Disabled
TCN flood query count
: 2
Vlan 1:
-------IGMP snooping
IGMPv2 immediate leave
Explicit host tracking
Multicast router learning mode
CGMP interoperability mode
:
:
:
:
:
Enabled
Disabled
Enabled
pim-dvmrp
IGMP_ONLY
Vlan 2:
-------IGMP snooping
IGMPv2 immediate leave
Explicit host tracking
Multicast router learning mode
CGMP interoperability mode
:
:
:
:
:
Enabled
Disabled
Enabled
pim-dvmrp
IGMP_ONLY
Step 1
Command
Purpose
Step 2
Switch(config)# end
Step 3
18-5
Chapter 18
This example shows how to enable IGMP snooping on VLAN 2 and verify the configuration:
Switch# configure terminal
Switch(config)# ip igmp snooping vlan 2
Switch(config)# end
Switch# show ip igmp snooping vlan 2
Global IGMP Snooping configuration:
----------------------------------IGMP snooping
: Enabled
IGMPv3 snooping
: Enabled
Report suppression
: Enabled
TCN solicit query
: Disabled
TCN flood query count
: 2
Vlan 2:
-------IGMP snooping
IGMPv2 immediate leave
Explicit host tracking
Multicast router learning mode
CGMP interoperability mode
:
:
:
:
:
Enabled
Disabled
Enabled
pim-dvmrp
IGMP_ONLY
Purpose
This example shows how to configure IP IGMP snooping to learn from PIM/DVMRP packets:
Switch(config)# ip igmp snooping vlan 1 mrouter learn pim-dvmrp
Switch(config)# end
Switch#
Purpose
18-6
OL-6696-01
Chapter 18
This example shows how to configure IP IGMP snooping to learn from CGMP self-join packets:
Switch(config)# ip igmp snooping vlan 1 mrouter learn cgmp
Switch(config)# end
Switch#
Step 1
Command
Purpose
Step 2
Switch(config)# end
Step 3
Note
Purpose
18-7
Chapter 18
This example shows how to enable IGMP immediate-leave processing on interface VLAN 200 and to
verify the configuration:
Switch(config)# ip igmp snooping vlan 200 immediate-leave
Configuring immediate leave on vlan 200
Switch(config)# end
Switch# show ip igmp interface vlan 200 | include immediate leave
Immediate leave
: Disabled
Switch(config)#
Purpose
This example shows how to disable IGMP EHT on VLAN 200 and to verify the configuration:
Switch(config)# no ip igmp snooping vlan 200 explicit-tracking
Switch(config)#
Switch(config)# end
Switch# show ip igmp snooping vlan 200 | include Explicit host tracking
Explicit host tracking
: Disabled
Purpose
This example shows how to configure a host statically in VLAN 200 on interface FastEthernet 2/11:
Switch(config)# ip igmp snooping vlan 200 static 0100.5e02.0203 interface fastethernet
2/11
Configuring port FastEthernet2/11 on group 0100.5e02.0203 vlan 200
Switch(config)#
18-8
OL-6696-01
Chapter 18
18-9
Chapter 18
While in multicast flooding mode, IP multicast traffic is delivered to all ports in the VLAN, and not
restricted to those ports on which multicast group members have been detected.
Starting with 12.1(11b)EW, you can manually prevent IP multicast traffic from being flooded to a
switchport by using the no ip igmp snooping tcn flood command on that port.
For trunk ports, the configuration will apply to all VLANs.
By default, multicast flooding is enabled. Use the no keyword to disable flooding, and use default to
restore the default behavior (flooding is enabled).
To disable multicast flooding on an interface, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
Step 4
This example shows how to disable multicast flooding on interface FastEthernet 2/11:
Switch(config)# interface fastethernet 2/11
Switch(config-if)# no ip igmp snooping tcn flood
Switch(config-if)# end
Switch#
Step 1
Command
Purpose
Switch(config)#
ip igmp snooping tcn flood query count <n>
Step 2
Switch(config)# end
18-10
OL-6696-01
Chapter 18
This example shows how to modify the switch to stop flooding multicast traffic after four queries:
Switch(config)# ip igmp snooping tcn flood query count 4
Switch(config)# end
Switch#
When a spanning tree root switch receives a topology change in an IGMP snooping-enabled VLAN, the
switch issues a query solicitation that causes an IOS router to send out one or more general queries. The
new command ip igmp snooping tcn query solicit causes the switch to send the query solicitation
whenever it notices a topology change, even if that switch is not the spanning tree root.
This command operates at the global configuration level.
By default, query solicitation is disabled unless the switch is the spanning tree root. The default keyword
restores the default behavior.
To direct a switch to send a query solicitation, perform this task:
Step 1
Command
Purpose
Switch(config)#
ip igmp snooping tcn query solicit
Step 2
Switch(config)# end
This example shows how to configure the switch to send a query solicitation upon detecting a TCN:
Switch(config)# ip igmp snooping tcn query solicit
Switch(config)# end
Switch#
18-11
Chapter 18
Purpose
This example shows how to display the IGMP snooping querier information for all VLANs on the
switch:
Switch# show ip igmp snooping querier
Vlan
IP Address
IGMP Version
Port
--------------------------------------------------2
10.10.10.1
v2
Router
3
172.20.50.22
v3
Fa3/15
This example shows how to display the IGMP snooping querier information for VLAN 3:
Switch# show ip igmp snooping querier vlan 3
Vlan
IP Address
IGMP Version
Port
--------------------------------------------------3
172.20.50.22
v3
Fa3/15
By default, EHT maintains a maximum of 1000 entries in the EHT database. Once this limit is reached,
no additional entries are created. To create additional entries, clear the database with the clear ip igmp
snooping membership vlan command.
To display host membership information, perform this task:
Command
Purpose
This example shows how to display host membership information for VLAN 20 and to delete the EHT
database:
Switch# show ip igmp snooping membership vlan 20
#channels: 5
#hosts : 1
Source/Group Interface Reporter Uptime Last-Join Last-Leave
40.40.40.2/224.10.10.10 Gi4/1 20.20.20.20 00:23:37 00:06:50 00:20:30
40.40.40.3/224.10.10.10 Gi4/2 20.20.2020 00:23:37 00:06:50 00:20:30
40.40.40.4/224.10.10.10Gi4/1 20.20.20.20 00:39:42 00:09:17 -
18-12
OL-6696-01
Chapter 18
40.40.40.5/224.10.10.10Fa2/1 20.20.20.20 00:39:42 00:09:17 40.40.40.6/224.10.10.10 Fa2/1 20.20.20.20 00:09:47 00:09:17 Switch# clear ip igmp snooping membership vlan 20
This example shows how to display host membership for interface gi4/1:
Switch# show ip igmp snooping membership interface gi4/1
#channels: 5
#hosts : 1
Source/Group Interface Reporter Uptime Last-Join Last-Leave
40.40.40.2/224.10.10.10 Gi4/1 20.20.20.20 00:23:37 00:06:50 00:20:30
40.40.40.4/224.10.10.10Gi4/1 20.20.20.20 00:39:42 00:09:17 -
This example shows how to display host membership for VLAN 20 and group 224.10.10.10:
Switch# show ip igmp snooping membership vlan 20 source 40.40.40.2 group 224.10.10.10
#channels: 5
#hosts : 1
Source/Group Interface Reporter Uptime Last-Join Last-Leave
40.40.40.2/224.10.10.10 Gi4/1 20.20.20.20 00:23:37 00:06:50 00:20:30
Purpose
18-13
Chapter 18
This example shows how to display the host types and ports of a group in VLAN 1:
Switch# show ip igmp snooping groups vlan 10 226.6.6.7
Vlan
Group
Version
Ports
--------------------------------------------------------10
226.6.6.7
v3
Fa7/13, Fa7/14
Switch>
This example shows how to display the current state of a group with respect to a source IP address:
Switch# show ip igmp snooping groups vlan 10 226.6.6.7 sources
Source information for group 226.6.6.7:
Timers: Expired sources are deleted on next IGMP General Query
SourceIP
Expires
Uptime
Inc Hosts Exc Hosts
------------------------------------------------------2.0.0.1
00:03:04 00:03:48 2
0
2.0.0.2
00:03:04 00:02:07 2
0
Switch>
This example shows how to display the current state of a group with respect to a host MAC address:
Switch# show ip igmp snooping groups vlan 10 226.6.6.7 hosts
IGMPv3 host information for group 226.6.6.7
Timers: Expired hosts are deleted on next IGMP General Query
Host (MAC/IP) Filter mode
Expires
Uptime
# Sources
------------------------------------------------------------175.1.0.29
INCLUDE
stopped
00:00:51
2
175.2.0.30
INCLUDE
stopped
00:04:14
2
This example shows how to display summary information for an IGMPv3 group:
Switch# show ip igmp snooping groups vlan 10 226.6.6.7 summary
Group Address (Vlan 10)
: 226.6.6.7
Host type
: v3
Member Ports
: Fa7/13, Fa7/14
Filter mode
: INCLUDE
Expires
: stopped
Sources
: 2
Reporters (Include/Exclude)
: 2/0
This example shows how to display the total number of group addresses learned by the system globally:
Switch# show ip igmp snooping groups count
Total number of groups:
54
This example shows how to display the total number of group addresses learned on VLAN 5:
Switch# show ip igmp snooping groups vlan 5 count
Total number of groups:
30
18-14
OL-6696-01
Chapter 18
Purpose
This example shows how to display the multicast router interfaces in VLAN 1:
Switch# show ip igmp snooping mrouter vlan 1
vlan
ports
-----+---------------------------------------1
Gi1/1,Gi2/1,Fa3/48,Router
Switch#
Purpose
This example shows how to display MAC address multicast entries for VLAN 1:
Switch# show mac-address-table multicast vlan 1
Multicast Entries
vlan
mac address
type
ports
-------+---------------+-------+------------------------------------------1
0100.5e01.0101
igmp Switch,Gi6/1
1
0100.5e01.0102
igmp Switch,Gi6/1
1
0100.5e01.0103
igmp Switch,Gi6/1
1
0100.5e01.0104
igmp Switch,Gi6/1
1
0100.5e01.0105
igmp Switch,Gi6/1
1
0100.5e01.0106
igmp Switch,Gi6/1
Switch#
This example shows how to display a total count of MAC address entries for VLAN 1:
Switch# show mac-address-table multicast vlan 1 count
Multicast MAC Entries for vlan 1:
4
Switch#
Purpose
18-15
Chapter 18
:Enabled
:Disabled
:Disabled
:pim-dvmrp
:IGMP_ONLY
Note
The IGMP filtering feature works for IGMPv1 and IGMPv2 only.
In some environments, for example metropolitan or multiple-dwelling unit (MDU) installations, an
administrator might want to control the multicast groups to which a user on a switch port can belong.
This allows the administrator to control the distribution of multicast services, such as IP/TV, based on
some type of subscription or service plan.
With the IGMP filtering feature, an administrator can exert this type of control. With this feature, you
can filter multicast joins on a per-port basis by configuring IP multicast profiles and associating them
with individual switch ports. An IGMP profile can contain one or more multicast groups and specifies
whether access to the group is permitted or denied. If an IGMP profile denying access to a multicast
group is applied to a switch port, the IGMP join report requesting the stream of IP multicast traffic is
dropped, and the port is not allowed to receive IP multicast traffic from that group. If the filtering action
permits access to the multicast group, the IGMP report from the port is forwarded for normal processing.
IGMP filtering controls only IGMP membership join reports and has no relationship to the function that
directs the forwarding of IP multicast traffic.
You can also set the maximum number of IGMP groups that a Layer 2 interface can join with the
ip igmp max-groups <n> command.
18-16
OL-6696-01
Chapter 18
Feature
Default Setting
IGMP filters
No filtering
No limit
IGMP profiles
None defined
deny: Specifies that matching addresses are denied; this is the default condition.
range: Specifies a range of IP addresses for the profile. You can enter a single IP address or a range
with starting and ending addresses.
By default, no IGMP profiles are configured. When a profile is configured with neither the permit nor
the deny keyword, the default is to deny access to the range of IP addresses.
To create an IGMP profile for a port, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config-igmp-profile)# range ip
multicast address
Step 5
Switch(config-igmp-profile)# end
18-17
Chapter 18
Command
Purpose
Step 6
Step 7
To delete a profile, use the no ip igmp profile profile number global configuration command.
To delete an IP multicast address or range of IP multicast addresses, use the no range ip multicast
address IGMP profile configuration command.
This example shows how to create IGMP profile 4 (allowing access to the single IP multicast address)
and how to verify the configuration. If the action were to deny (the default), it would not appear in the
show ip igmp profile command output.
Switch# config t
Switch(config)# ip igmp profile 4
Switch(config-igmp-profile)# permit
Switch(config-igmp-profile)# range 229.9.9.0
Switch(config-igmp-profile)# end
Switch# show ip igmp profile 4
IGMP Profile 4
permit
range 229.9.9.0 229.9.9.0
Note
You can apply IGMP profiles to Layer 2 ports only. You cannot apply IGMP profiles to routed ports (or
SVIs) or to ports that belong to an EtherChannel port group.
To apply an IGMP profile to a switch port, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config-if)# end
Step 5
Step 6
18-18
OL-6696-01
Chapter 18
Note
This restriction can be applied to Layer 2 ports only. You cannot set a maximum number of IGMP groups
on routed ports (or SVIs) or on ports that belong to an EtherChannel port group.
To apply an IGMP profile on a switch port, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Sets the maximum number of IGMP groups that the interface can
join. The range is from 0 to 4,294,967,294. By default, no
maximum is set.
Step 4
Switch(config-if)# end
Step 5
Step 6
18-19
Chapter 18
To remove the maximum group limitation and return to the default of no maximum, use the no ip igmp
max-groups command.
This example shows how to limit the number of IGMP groups that an interface can join to 25.
Switch# config t
Switch(config)# interface fastethernet2/12
Switch(config-if)# ip igmp max-groups 25
Switch(config-if)# end
Switch# show running-config interface fastethernet2/12
Building configuration...
Current configuration : 123 bytes
!
interface FastEthernet2/12
no ip address
shutdown
snmp trap link-status
ip igmp max-groups 25
ip igmp filter 4
end
Purpose
Purpose
This is an example of the show ip igmp profile privileged EXEC command when no profile number is
entered. All profiles defined on the switch are displayed.
Switch# show ip igmp profile
IGMP Profile 3
range 230.9.9.0 230.9.9.0
IGMP Profile 4
permit
range 229.9.9.0 229.255.255.255
18-20
OL-6696-01
Chapter 18
This is an example of the show running-config privileged EXEC command when an interface is
specified with IGMP maximum groups configured and IGMP profile 4 has been applied to the interface.
Switch# show running-config interface fastethernet2/12
Building configuration...
Current configuration : 123 bytes
!
interface FastEthernet2/12
no ip address
shutdown
snmp trap link-status
ip igmp max-groups 25
ip igmp filter 4
end
18-21
Chapter 18
18-22
OL-6696-01
C H A P T E R
19
Note
802.1Q requires Supervisor Engine V; Layer 2 protocol tunneling is supported on all supervisor engines.
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
This chapter contains these sections:
19-1
Chapter 19
A port configured to support 802.1Q tunneling is called a tunnel port. When you configure tunneling,
you assign a tunnel port to a VLAN ID that is dedicated to tunneling. Each customer requires a separate
Service Provider VLAN ID, but that Service Provider VLAN ID supports VLANs of all the customers.
Customer traffic tagged in the normal way with appropriate VLAN IDs comes from an 802.1Q trunk port
on the customer device and into a tunnel port on the Service Provider edge switch. The link between the
customer device and the edge switch is asymmetric because one end is configured as an 802.1Q trunk
port, and the other end is configured as a tunnel port. You assign the tunnel port interface to an access
VLAN ID that is unique to each customer. See Figure 19-1.
Figure 19-1 802.1Q Tunnel Ports in a Service Provider Network
Customer A
VLANs 1 to 100
Customer A
VLANs 1 to 100
Service
provider
Tunnel port
VLAN 30
Tunnel port
VLAN 30
Trunk
ports
Tunnel port
VLAN 30
Trunk
ports
Tunnel port
VLAN 40
74016
Tunnel port
VLAN 40
Customer B
VLANs 1 to 200
Trunk
Asymmetric link
Customer B
VLANs 1 to 200
Packets coming from the customer trunk port into the tunnel port on the Service Provider edge switch
are normally 802.1Q-tagged with the appropriate VLAN ID. When the tagged packets exit the trunk port
into the Service Provider network, they are encapsulated with another layer of an 802.1Q tag (called the
metro tag) that contains the VLAN ID that is unique to the customer. The original customer 802.1Q tag
is preserved in the encapsulated packet. Therefore, packets entering the Service Provider network are
double-tagged, with the metro tag containing the customers access VLAN ID, and the inner VLAN ID
being that of the incoming traffic.
When the double-tagged packet enters another trunk port in a Service Provider core switch, the metro
tag is stripped as the switch processes the packet. When the packet exits another trunk port on the same
core switch, the same metro tag is again added to the packet. Figure 19-2 shows the tag structures of the
Ethernet packets starting with the original, or normal, frame.
19-2
OL-6696-01
Chapter 19
Figure 19-2 Original (Normal), 802.1Q, and Double-Tagged Ethernet Packet Formats
Source
address
Destination
Length/
address
EtherType
SA
Len/Etype
DA
SA
Etype
DA
SA
Etype
Data
Tag
Tag
FCS
Len/Etype
Etype
Tag
Data
Len/Etype
FCS
Data
FCS
74072
DA
Frame Check
Sequence
Double-tagged
frame in service
provider
infrastructure
When the packet enters the trunk port of the Service Provider egress switch, the metro tag is again
stripped as the switch processes the packet. However, the metro tag is not added when the packet is sent
out the tunnel port on the edge switch into the customer network. The packet is sent as a normal
802.1Q-tagged frame to preserve the original VLAN numbers in the customer network.
All packets entering the Service Provider network through a tunnel port on an edge switch are treated as
untagged packets, whether they are untagged or already tagged with 802.1Q headers. The packets are
encapsulated with the metro tag VLAN ID (set to the access VLAN of the tunnel port) when they are
sent through the Service Provider network on an 802.1Q trunk port. The priority field on the metro tag
is set to the interface class of service (CoS) priority configured on the tunnel port. (The default is zero
if none is configured.)
In Figure 19-1, Customer A was assigned VLAN 30, and Customer B was assigned VLAN 40. Packets
entering the edge-switch tunnel ports with 802.1Q tags are double-tagged when they enter the Service
Provider network, with the metro tag containing VLAN ID 30 or 40, appropriately, and the inner tag
containing the original customer VLAN number, for example, VLAN 100. Even if Customers A and B
both have VLAN 100 in their networks, the traffic remains segregated within the Service Provider
network because the metro tag is different. Each customer controls its own VLAN numbering space,
which is independent of the VLAN numbering space used by other customers and the VLAN numbering
space used by the Service Provider network.
19-3
Chapter 19
Note
By default, 802.1Q tunneling is disabled because the default switch port mode is dynamic auto. Tagging
of 802.1Q native VLAN packets on all 802.1Q trunk ports is also disabled.
Native VLANs
When configuring 802.1Q tunneling on an edge switch, you must use 802.1Q trunk ports for sending
packets into the Service Provider network. However, packets going through the core of the Service
Provider network can be carried through 802.1Q trunks, ISL trunks, or nontrunking links. When 802.1Q
trunks are used in these core switches, the native VLANs of the 802.1Q trunks must not match any native
VLAN of the nontrunking (tunneling) port on the same switch because traffic on the native VLAN would
not be tagged on the 802.1Q sending trunk port.
See Figure 19-3. VLAN 40 is configured as the native VLAN for the 802.1Q trunk port from Customer A
at the ingress edge switch in the Service Provider network (Switch 2). Switch 1 of Customer A sends a
tagged packet on VLAN 30 to the ingress tunnel port of Switch 2 in the Service Provider network, which
belongs to access VLAN 40. Because the access VLAN of the tunnel port (VLAN 40) is the same as the
native VLAN of the edge-switch trunk port (VLAN 40), the metro tag is not added to tagged packets
received from the tunnel port. The packet carries only the VLAN 30 tag through the Service Provider
network to the trunk port of the egress-edge switch (Switch 3) and is misdirected through the egress
switch tunnel port to Customer B.
These are some ways to solve this problem:
Use ISL trunks between core switches in the Service Provider network. Although customer
interfaces connected to edge switches must be 802.1Q trunks, we recommend using ISL trunks for
connecting switches in the core layer.
Use the switchport trunk native vlan tag per-port command and the vlan dot1q tag native global
configuration command to configure the edge switch so that all packets going out an 802.1Q trunk,
including the native VLAN, are tagged. If the switch is configured to tag native VLAN packets on
all 802.1Q trunks, the switch accepts untagged packets, but sends only tagged packets.
Ensure that the native VLAN ID on the edge-switch trunk port is not within the customer VLAN
range. For example, if the trunk port carries traffic of VLANs 100 to 200, assign the native VLAN
a number outside that range.
19-4
OL-6696-01
Chapter 19
Figure 19-3 Potential Problem with 802.1Q Tunneling and Native VLANs
Switch 4
Customer A
VLANs 30-40
Native VLAN 40
Tag
removed
Service
provider
Tunnel port
VLANs 5-50
Packet tagged
for VLAN 30
Switch 1
Customer A
Native
VLAN 40
Q
Tunnel port
Access VLAN 40
Switch 3
VLAN 40
Tunnel port
Access VLAN 30
802.1Q
trunk port
VLANs 30-40
Native VLAN 40
Trunk
Asymmetric link
Correct path for traffic
Incorrect path for traffic due to
misconfiguration of native VLAN
by sending port on Switch 2
Q = 802.1Q trunk ports
Switch 5
Customer B
74074
Switch 2
System MTU
The default system MTU for traffic on the Catalyst 4500 series switch is 1500 bytes. You can configure
the switch to support larger frames by using the system mtu global configuration command. Because
the 802.1Q tunneling feature increases the frame size by 4 bytes when the metro tag is added, you must
configure all switches in the Service Provider network to be able to process larger frames by increasing
the switch system MTU size to at least 1504 bytes. The maximum allowable system MTU for Catalyst
4500 Gigabit Ethernet switches is 9198 bytes; the maximum system MTU for Fast Ethernet switches is
1552 bytes.
IP routing is not supported on a VLAN that includes 802.1Q ports. Packets received from a tunnel
port are forwarded based only on Layer 2 information. If routing is enabled on a switch virtual
interface (SVI) that includes tunnel ports, untagged IP packets received from the tunnel port are
recognized and routed by the switch. Customers can access the Internet through the native VLAN.
If this access is not needed, you should not configure SVIs on VLANs that include tunnel ports.
Layer 3 quality of service (QoS) ACLs and other QoS features related to Layer 3 information are
not supported on tunnel ports. MAC-based QoS is supported on tunnel ports.
19-5
Chapter 19
EtherChannel port groups are compatible with tunnel ports as long as the 802.1Q configuration is
consistent within an EtherChannel port group.
Port Aggregation Protocol (PAgP), Link Aggregation Control Protocol (LACP), and UniDirectional
Link Detection (UDLD) are supported on 802.1Q tunnel ports.
Dynamic Trunking Protocol (DTP) is not compatible with 802.1Q tunneling because you must
manually configure asymmetric links with tunnel ports and trunk ports.
When a port is configured as an 802.1Q tunnel port, spanning-tree bridge protocol data unit (BPDU)
filtering is automatically enabled on the interface. Cisco Discovery Protocol (CDP) is automatically
disabled on the interface.
Purpose
Step 1
Step 2
Switch(config)# interface
interface-id
Step 3
Switch(config-if)# switchport
access vlan vlan-id
Specifies the default VLAN, which is used if the interface stops trunking.
This VLAN ID is specific to the particular customer.
Step 4
Step 5
Switch(config-if)# exit
Step 6
Step 7
Switch(config)# end
Step 8
Step 9
Step 10
Use the no vlan dot1q tag native global command and the no switchport mode dot1q-tunnel interface
configuration command to return the port to the default state of dynamic auto. Use the no vlan dot1q
tag native global configuration command to disable tagging of native VLAN packets.
19-6
OL-6696-01
Chapter 19
This example shows how to configure an interface as a tunnel port, enable tagging of native VLAN
packets, and verify the configuration. In this configuration, the VLAN ID for the customer connected to
Gigabit Ethernet interface 2/7 is VLAN 22.
Switch(config)# interface gigabitethernet2/7
Switch(config-if)# switchport access vlan 22
% Access VLAN does not exist. Creating vlan 22
Switch(config-if)# switchport mode dot1q-tunnel
Switch(config-if)# exit
Switch(config)# vlan dot1q tag native
Switch(config)# end
Switch# show dot1q-tunnel interface gigabitethernet2/7
Port
----LAN Port(s)
----Gi2/7
Switch# show vlan dot1q tag native
dot1q native vlan tagging is enabled globally
Users on each of a customers sites can properly run STP, and every VLAN can build a correct
spanning tree, based on parameters from all sites and not just from the local site.
CDP discovers and shows information about the other Cisco devices connected through the Service
Provider network.
VTP provides consistent VLAN configuration throughout the customer network, propagating to all
switches through the Service Provider.
Layer 2 protocol tunneling can be used independently or can enhance 802.1Q tunneling. If protocol
tunneling is not enabled on 802.1Q tunneling ports, remote switches at the receiving end of the Service
Provider network do not receive the PDUs and cannot properly run STP, CDP, and VTP. When protocol
tunneling is enabled, Layer 2 protocols within each customers network are totally separate from those
running within the Service Provider network. Customer switches on different sites that send traffic
through the Service Provider network with 802.1Q tunneling achieve complete knowledge of the
customers VLAN. If 802.1Q tunneling is not used, you can still enable Layer 2 protocol tunneling by
connecting to the customer switch through access ports and by enabling tunneling on the Service
Provider access port.
As an example, Customer A in Figure 19-4 has four switches in the same VLAN that are connected
through the Service Provider network. If the network does not tunnel PDUs, switches on the far ends of
the network cannot properly run STP, CDP, and VTP. For example, STP for a VLAN on a switch in
19-7
Chapter 19
Customer As Site 1 will build a spanning tree on the switches at that site without considering
convergence parameters based on Customer As switch in Site 2. Figure 19-5 shows one possible
spanning tree topology.
Figure 19-4 Layer 2 Protocol Tunneling
Customer A Site 1
VLANs 1 to 100
Customer A Site 2
VLANs 1 to 100
Service
provider
VLAN 30
VLAN 30
VLAN 30
Switch 1
Trunk
ports
Trunk
ports
Switch 1
Switch 3
Switch 2
Switch 4
Trunk
ports
VLAN 40
VLAN 40
74073
Trunk
ports
Trunk
Asymmetric link
Customer B Site 1
VLANs 1 to 200
Customer B Site 2
VLANs 1 to 200
74017
Customer A
virtual network
VLANs 1 to 100
19-8
OL-6696-01
Chapter 19
Feature
Default Setting
Disabled.
Shutdown threshold
None set.
Drop threshold
None set.
CoS value
19-9
Chapter 19
The switch supports tunneling of CDP, STP, including multiple STP (MSTP), and VTP. Protocol
tunneling is disabled by default but can be enabled for the individual protocols on 802.1Q tunnel
ports or on access ports.
Dynamic Trunking Protocol (DTP) is not compatible with Layer 2 protocol tunneling because you
must manually configure asymmetric links with tunnel ports and trunk ports.
Tunneling is not supported on trunk ports. If you enter the l2protocol-tunnel interface configuration
command on a trunk port, the command is accepted, but Layer 2 tunneling does not take affect unless
you change the port to a tunnel port or an access port.
EtherChannel port groups are compatible with tunnel ports when the 802.1Q configuration is
consistent within an EtherChannel port group.
If an encapsulated PDU (with the proprietary destination MAC address) is received from a tunnel
port or an access port with Layer 2 tunneling enabled, the tunnel port is shut down to prevent loops.
The port also shuts down when a configured shutdown threshold for the protocol is reached. You can
manually re-enable the port (by entering a shutdown and a no shutdown command sequence). If
errdisable recovery is enabled, the operation is retried after a specified time interval.
Only decapsulated PDUs are forwarded to the customer network. The spanning-tree instance
running on the Service Provider network does not forward BPDUs to tunnel ports. CDP packets are
not forwarded from tunnel ports.
When protocol tunneling is enabled on an interface, you can set a per-protocol, per-port, shutdown
threshold for the PDUs generated by the customer network. If the limit is exceeded, the port shuts
down. You can also limit the BPDU rate by using QoS ACLs and policy maps on a tunnel port.
When protocol tunneling is enabled on an interface, you can set a per-protocol, per-port, drop
threshold for the PDUs generated by the customer network. If the limit is exceeded, the port drops
PDUs until the rate at which it receives them is below the drop threshold.
Because tunneled PDUs (especially STP BPDUs) must be delivered to all remote sites so that the
customer virtual network operates properly, you can give PDUs higher priority within the Service
Provider network than data packets received from the same tunnel port. By default, the PDUs use
the same CoS value as data packets.
Purpose
Step 1
Step 2
Switch(config)# interface
interface-id
19-10
OL-6696-01
Chapter 19
Command
Purpose
Step 3
Switch(config-if)# switchport
mode access
or
switchport mode dot1q-tunnel
Step 4
Switch(config-if)#
l2protocol-tunnel [cdp | stp |
vtp]
Step 5
Switch(config-if)#
l2protocol-tunnel
shutdown-threshold [cdp | stp |
vtp] value
Step 6
Switch(config-if)#
l2protocol-tunnel drop-threshold
[cdp | stp | vtp] value
Step 7
Switch(config-if)# exit
Step 8
Switch(config)# errdisable
recovery cause l2ptguard
Step 9
Switch(config)# l2protocol-tunnel
cos value
(Optional) Configures the CoS value for all tunneled Layer 2 PDUs. The
range is 0 to 7; the default is the default CoS value for the interface. If none
is configured, the default is 5.
Step 10
Switch(config)# end
Step 11
Displays the Layer 2 tunnel ports on the switch, including the protocols
configured, the thresholds, and the counters.
Step 12
Use the no l2protocol-tunnel [cdp | stp | vtp] interface configuration command to disable protocol
tunneling for one of the Layer 2 protocols or for all three. Use the no l2protocol-tunnel
shutdown-threshold [cdp | stp | vtp] and the no l2protocol-tunnel drop-threshold [cdp | stp | vtp]
commands to return the shutdown and drop thresholds to the default settings.
This example shows how to configure Layer 2 protocol tunneling for CDP, STP, and VTP and how to
verify the configuration.
Switch(config)# interface FastEthernet2/1
Switch(config-if)# l2protocol-tunnel cdp
Switch(config-if)# l2protocol-tunnel stp
Switch(config-if)# l2protocol-tunnel vtp
19-11
Chapter 19
Drop
Counter
------------0
0
0
Command
Purpose
Note
With Release 12.2(20)EW, the BPDU filtering configuration for both dot1q and Layer 2 protocol
tunneling is no longer visible in the running configuration as "spanning-tree bpdufilter enable. Instead,
it is visible in the output of the show spanning tree int detail command as shown below.
Switch# show spann int f6/1 detail
Port 321 (FastEthernet6/1) of VLAN0001 is listening
Port path cost 19, Port priority 128, Port Identifier 128.321.
Designated root has priority 32768, address 0008.e341.4600
Designated bridge has priority 32768, address 0008.e341.4600
Designated port id is 128.321, designated path cost 0
Timers: message age 0, forward delay 2, hold 0
Number of transitions to forwarding state: 0
Link type is point-to-point by default
** Bpdu filter is enabled internally **
BPDU: sent 0, received 0
19-12
OL-6696-01
C H A P T E R
20
Note
For complete syntax and usage information for the commands used in this chapter, refer to the
Cisco IOS Configuration Fundamentals Configuration Guide, Release 12.2;
Cisco IOS System Management; Configuring Cisco Discovery Protocol (CDP) at this URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/fun_c/fcprt3/fcd301c.htm
and to the Cisco IOS Configuration Fundamentals Command Reference, Release 12.1;
Cisco IOS System Management Commands; and CDP Commands publication at this URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/fun_r/frprt3/frd3001b.htm
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Overview of CDP
CDP is a protocol that runs over Layer 2 (the data link layer) on all Cisco routers, bridges, access servers,
and switches. CDP allows network management applications to discover Cisco devices that are
neighbors of already known devices, in particular, neighbors running lower-layer, transparent
protocols.With CDP, network management applications can learn the device type and the SNMP agent
address of neighboring devices. CDP enables applications to send SNMP queries to neighboring devices.
CDP runs on all LAN and WAN media that support Subnetwork Access Protocol (SNAP).
Each CDP-configured device sends periodic messages to a multicast address. Each device advertises at
least one address at which it can receive SNMP messages. The advertisements also contain the
time-to-live, or holdtime information, which indicates the length of time a receiving device should hold
CDP information before discarding it.
20-1
Chapter 20
Configuring CDP
Configuring CDP
The following sections describe how to configure CDP:
Purpose
Purpose
For additional CDP show commands, see the Monitoring and Maintaining CDP section on page 20-3.
20-2
OL-6696-01
Chapter 20
Purpose
This example shows how to enable CDP on Fast Ethernet interface 5/1:
Switch(config)# interface fastethernet 5/1
Switch(config-if)# cdp enable
This example shows how to disable CDP on Fast Ethernet interface 5/1:
Switch(config)# interface fastethernet 5/1
Switch(config-if)# no cdp enable
Purpose
This example shows how to display the CDP configuration of Fast Ethernet interface 5/1:
Switch# show cdp interface fastethernet 5/1
FastEthernet5/1 is up, line protocol is up
Encapsulation ARPA
Sending CDP packets every 120 seconds
Holdtime is 180 seconds
Switch#
Purpose
20-3
Chapter 20
Configuring CDP
Command
Purpose
This example shows how to clear the CDP counter configuration on your switch:
Switch# clear cdp counters
This example shows how to display information about the neighboring equipment:
Switch# show cdp neighbors
Capability Codes: R - Router, T - Trans Bridge, B - Source Route Bridge
S - Switch, H - Host, I - IGMP, r - Repeater
Device ID
JAB023807H1
JAB023807H1
JAB023807H1
JAB023807H1
JAB023807H1
JAB03130104
JAB03130104
Local Intrfce
Fas 5/3
Fas 5/2
Fas 5/1
Gig 1/2
Gig 1/1
Fas 5/8
Fas 5/9
Holdtme
127
127
127
122
122
167
152
Capability
T S
T S
T S
T S
T S
T S
T S
Platform
WS-C2948
WS-C2948
WS-C2948
WS-C2948
WS-C2948
WS-C4003
WS-C4003
Port ID
2/46
2/45
2/44
2/50
2/49
2/47
2/48
20-4
OL-6696-01
C H A P T E R
21
Configuring UDLD
This chapter describes how to configure the UniDirectional Link Detection (UDLD) and Unidirectional
Ethernet on the Catalyst 4500 series switch. It also provides guidelines, procedures, and configuration
examples.
This chapter includes the following major sections:
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Overview of UDLD
UDLD allows devices connected through fiber-optic or copper Ethernet cables (for example, Category 5
cabling) to monitor the physical configuration of the cables and detect when a unidirectional link exists.
A unidirectional link occurs whenever traffic transmitted by the local device over a link is received by
the neighbor but traffic transmitted from the neighbor is not received by the local device. When a
unidirectional link is detected, UDLD shuts down the affected interface and alerts the user.
Unidirectional links can cause a variety of problems, including spanning tree topology loops.
UDLD is a Layer 2 protocol that works with the Layer 1 mechanisms to determine the physical status of
a link. At Layer 1, autonegotiation takes care of physical signaling and fault detection. UDLD performs
tasks that autonegotiation cannot perform, such as detecting the identities of neighbors and shutting
down misconnected interfaces. When you enable both autonegotiation and UDLD, Layer 1 and Layer 2
detections work together to prevent physical and logical unidirectional connections and the
malfunctioning of other protocols.
If one of the fiber strands in a pair is disconnected, as long as autonegotiation is active, the link does not
stay up. In this case, the logical link is undetermined, and UDLD does not take any action. If both fibers
are working normally from a Layer 1 perspective, then UDLD at Layer 2 determines whether or not those
fibers are connected correctly and whether or not traffic is flowing bidirectionally between the right
neighbors. This check cannot be performed by autonegotiation because autonegotiation operates at
Layer 1.
21-1
Chapter 21
Configuring UDLD
The switch periodically transmits UDLD packets to neighbor devices on interfaces with UDLD enabled.
If the packets are echoed back within a specific time frame and they are lacking a specific
acknowledgment (echo), the link is flagged as unidirectional and the interface is shut down. Devices on
both ends of the link must support UDLD in order for the protocol to successfully identify and disable
unidirectional links.
Note
By default, UDLD is locally disabled on copper interfaces to avoid sending unnecessary control traffic
on this type of media, since it is often used for access interfaces.
Figure 21-1 shows an example of a unidirectional link condition. Switch B successfully receives traffic
from Switch A on the interface. However, Switch A does not receive traffic from Switch B on the same
interface. UDLD detects the problem and disables the interface.
Figure 21-1 Unidirectional Link
TX
RX
TX
RX
Switch B
18720
Switch A
Feature
Default Status
Globally disabled
UDLD per-interface enable state for twisted-pair (copper) media Disabled on all Ethernet 10/100 and 1000BaseTX
interfaces
21-2
OL-6696-01
Chapter 21
Configuring UDLD
Configuring UDLD on the Switch
Purpose
Purpose
Step 1
Step 2
Step 1
Command
Purpose
Step 2
21-3
Chapter 21
Configuring UDLD
Step 1
Command
Purpose
Purpose
21-4
OL-6696-01
C H A P T E R
22
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
You must configure Unidirectional Ethernet on the non-blocking GigaPort, which will automatically
disable UDLD on the port.
22-1
Chapter 22
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# end
Step 4
This example shows how to set Gigabit Ethernet interface 1/1 to unidirectionally send traffic:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface gigabitethernet 1/1
Switch(config-if)# unidirectional send-only
Switch(config-if)# end
Warning!
Enable l2 port unidirectional mode will automatically disable port udld.
You must manually ensure that the unidirectional link does not create
a spanning tree loop in the network.
Enable l3 port unidirectional mode will automatically disable ip routing
on the port. You must manually configure static ip route and arp entry
in order to route ip traffic.
This example shows how to set Gigabit Ethernet interface 1/1 to receive traffic unidirectionally:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface gigabitethernet 1/1
Switch(config-if)# unidrectional receive-only
Switch(config-if)# end
Warning!
Enable l2 port unidirectional mode will automatically disable port udld.
You must manually ensure that the unidirectional link does not create
a spanning tree loop in the network.
Enable l3 port unidirectional mode will automatically disable ip routing
on the port. You must manually configure static ip route and arp entry
in order to route ip traffic.
22-2
OL-6696-01
Chapter 22
This example shows how to disable Unidirectional Ethernet on Gigabit Ethernet interface 1/1:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface gigabitethernet 1/1
Switch(config-if)# no unidirectional
Switch(config-if)# end
This example shows the result of issuing the show interface command for a port that does not support
Unidirectional Ethernet:
Switch#show interface f6/1 unidirectional
Unidirectional Ethernet is not supported on FastEthernet6/1
22-3
Chapter 22
22-4
OL-6696-01
C H A P T E R
23
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
The Catalyst 4500 series switch supports Layer 3 interfaces with the Cisco IOS IP and IP routing
protocols. Layer 3, the network layer, is primarily responsible for the routing of data in packets across
logical internetwork paths.
Layer 2, the data link layer, contains the protocols that control the physical layer (Layer 1) and how data
is framed before being transmitted on the medium. The Layer 2 function of filtering and forwarding data
in frames between two segments on a LAN is known as bridging.
The Catalyst 4500 series switch supports two types of Layer 3 interfaces. The logical Layer 3 VLAN
interfaces integrate the functions of routing and bridging. The physical Layer 3 interfaces allow the
Catalyst 4500 series switch to be configured like a traditional router.
23-1
Chapter 23
Routing
Router
Interface Ethernet
1.1.1.1
Interface VLAN1
1.1.1.1
Interface Ethernet
2.1.1.1
L2 Switch
L2 Switch
VLAN1
VLAN2
Host 1
Host 2
VLAN2
Host 1
Host 2
94169
VLAN1
Interface VLAN2
2.1.1.1
Router
2/1
Host 1
2/2
Interface Ethernet
2.1.1.1
Host 2
94168
Interface Ethernet
1.1.1.1
23-2
OL-6696-01
Chapter 23
Configuration Guidelines
A Catalyst 4500 series switch supports AppleTalk routing and IPX routing. For AppleTalk routing and
IPX routing information, refer to Configuring AppleTalk and Configuring Novell IPX in the
Cisco IOS AppleTalk and Novell IPX Configuration Guide at the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/atipx_c/index.htm
A Catalyst 4500 series switch does not support subinterfaces or the encapsulation keyword on Layer 3
Fast Ethernet or Gigabit Ethernet interfaces.
Before you can configure logical Layer 3 VLAN interfaces, you must create and configure the VLANs
on the switch, assign VLAN membership to the Layer 2 interfaces, enable IP routing if IP routing is
disabled, and specify an IP routing protocol.
To configure logical Layer 3 VLAN interfaces, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config-if)# no shutdown
Step 5
Switch(config-if)# end
Step 6
Step 7
This example shows how to configure the logical Layer 3 VLAN interface vlan 2 and assign an IP
address:
Switch> enable
Switch# config term
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# vlan 2
Switch(config)# interface vlan 2
Switch(config-if)# ip address 10.1.1.1 255.255.255.248
Switch(config-if)# no shutdown
Switch(config-if)# end
23-3
Chapter 23
This example uses the show interfaces command to display the interface IP address configuration and
status of Layer 3 VLAN interface vlan 2:
Switch# show interfaces vlan 2
Vlan2 is up, line protocol is down
Hardware is Ethernet SVI, address is 00D.588F.B604 (bia 00D.588F.B604)
Internet address is 172.20.52.106/29
MTU 1500 bytes, BW 1000000 Kbit, DLY 10 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation ARPA, loopback not set
ARP type: ARPA, ARP Timeout 04:00:00
Last input never, output never, output hang never
Last clearing of "show interface" counters never
Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
Queueing strategy: fifo
Output queue: 0/40 (size/max)
5 minute input rate 0 bits/sec, 0 packets/sec
5 minute output rate 0 bits/sec, 0 packets/sec
0 packets input, 0 bytes, 0 no buffer
Received 0 broadcasts, 0 runts, 0 giants, 0 throttles
0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
0 packets output, 0 bytes, 0 underruns
0 output errors, 0 interface resets
0 output buffer failures, 0 output buffers swapped out
Switch#
This example uses the show running-config command to display the interface IP address configuration
of Layer 3 VLAN interface vlan 2:
Switch# show running-config
Building configuration...
Current configuration : !
interface Vlan2
ip address 10.1.1.1 255.255.255.248
!
ip classless
no ip http server
!
!
line con 0
line aux 0
line vty 0 4
!
end
Before you can configure physical Layer 3 interfaces, you must enable IP routing if IP routing is
disabled, and specify an IP routing protocol.
23-4
OL-6696-01
Chapter 23
Purpose
Step 1
Switch(config)#ip routing
Step 2
Step 3
Switch(config-if)#no switchport
Step 4
Step 5
Switch(config-if)# no shutdown
Step 6
Switch(config-if)# end
Step 7
Step 8
This example shows how to configure an IP address on Fast Ethernet interface 2/1:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# ip routing
Switch(config)# interface fastethernet 2/1
Switch(config-if)# no switchport
Switch(config-if)# ip address 10.1.1.1 255.255.255.248
Switch(config-if)# no shutdown
Switch(config-if)# end
Switch#
This example uses the show running-config command to display the interface IP address configuration
of Fast Ethernet interface 2/1:
Switch# show running-config
Building configuration...
!
interface FastEthernet2/1
no switchport
ip address 10.1.1.1 255.255.255.248
!
ip classless
no ip http server
!
!
line con 0
line aux 0
line vty 0 4
!
end
23-5
Chapter 23
23-6
OL-6696-01
C H A P T E R
24
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Overview of CEF
This section contains information on the two primary components that comprise the CEF operation:
Benefits of CEF
CEF is advanced Layer 3 IP switching technology that optimizes performance and scalability for large
networks with dynamic traffic patterns or networks with intensive web-based applications and
interactive sessions.
24-1
Chapter 24
Overview of CEF
Improves performance over the caching schemes of multilayer switches, which often flush the entire
cache when information changes in the routing tables.
Provides load balancing that distributes packets across multiple links based on Layer 3 routing
information. If a network device discovers multiple paths to a destination, the routing table is
updated with multiple entries for that destination. Traffic to that destination is then distributed
among the various paths.
CEF stores information in several data structures rather than the route cache of multilayer switches. The
data structures optimize lookup for efficient packet forwarding.
Adjacency Tables
In addition to the FIB, CEF uses adjacency tables to prepend Layer 2 addressing information. Nodes in
the network are said to be adjacent if they are within a single hop from each other. The adjacency table
maintains Layer 2 next-hop addresses for all FIB entries.
Adjacency Discovery
The adjacency table is populated as new adjacent nodes are discovered. Each time an adjacency entry is
created (such as through the Address Resolution Protocol (ARP), a link-layer header for that adjacent
node is stored in the adjacency table. Once a route is determined, the link-layer header points to a next
hop and corresponding adjacency entry. The link-layer header is subsequently used for encapsulation
during CEF switching of packets.
Adjacency Resolution
A route might have several paths to a destination prefix, such as when a router is configured for
simultaneous load balancing and redundancy. For each resolved path, a pointer is added for the
adjacency corresponding to the next-hop interface for that path. This mechanism is used for load
balancing across several paths.
24-2
OL-6696-01
Chapter 24
Null adjacency
Packets destined for a Null0 interface are dropped. A Null0 interface can
be used as an effective form of access filtering.
Glean adjacency
When a router is connected directly to several hosts, the FIB table on the
router maintains a prefix for the subnet rather than for each individual
host. The subnet prefix points to a glean adjacency. When packets need
to be forwarded to a specific host, the adjacency database is gleaned for
the specific prefix.
Punt adjacency
Features that require special handling or features that are not yet
supported by CEF switching are sent (punted) to the next higher
switching level.
Discard adjacency
Drop adjacency
Unresolved Adjacency
When a link-layer header is prepended to packets, FIB requires the prepend to point to an adjacency
corresponding to the next hop. If an adjacency was created by FIB and was not discovered through a
mechanism such as ARP, the Layer 2 addressing information is not known and the adjacency is
considered incomplete. When the Layer 2 information is known, the packet is forwarded to the route
processor, and the adjacency is determined through ARP.
Catalyst 4500 series switches support an ASIC-based Integrated Switching Engine that provides these
features:
IP routing at Layer 3
Because the ASIC is specifically designed to forward packets, the Integrated Switching Engine hardware
can run this process much faster than CPU subsystem software.
Figure 24-1 shows a high-level view of the ASIC-based Layer 2 and Layer 3 switching process on the
Integrated Switching Engine.
24-3
Chapter 24
Logical Router
L3 logical
interfaces
VLAN2
L2 switchports
68402
VLAN1
The Integrated Switching Engine performs inter-VLAN routing on logical Layer 3 interfaces with the
ASIC hardware. The ASIC hardware also supports a physical Layer 3 interface that can be configured
to connect with a host, a switch, or a router.
24-4
OL-6696-01
Chapter 24
Router
L3 interfaces
VLAN1
GRE
tunnel
VLAN2
GRE
tunnel
68127
L2 switchports
The Integrated Switching Engine performs inter-VLAN routing in hardware. The CPU subsystem
software supports Layer 3 interfaces to VLANs that use Subnetwork Access Protocol (SNAP)
encapsulation. The CPU subsystem software also supports generic routing encapsulation (GRE) tunnel.
Hardware Switching
Hardware switching is the normal operation for the Supervisor Engine III and Supervisor Engine IV.
Software Switching
Software switching occurs when traffic cannot be processed in hardware. The following types of
exception packets are processed in software at a much slower rate:
Note
Packets that use TCP header options are switched in hardware because they do not affect the
forwarding decision.
Packets that exceed the MTU of an output interface and must be fragmented
24-5
Chapter 24
Load Balancing
The Catalyst 4500 series switch supports load balancing for routing packets in the Integrated Switching
Engine hardware. Load balancing is always enabled. It works when multiple routes for the same network
with different next-hop addresses are configured. These routes can be configured either statically or
through a routing protocol such as OSPF or EIGRP.
The hardware makes a forwarding decision by using a hardware load sharing hash function to compute
a value, based on the source and destination IP addresses and the source and destination TCP port
numbers (if available). This load sharing hash value is then used to select which route to use to forward
the packet. All hardware switching within a particular flow (such as a TCP connection) will be routed to
the same next hop, thereby reducing the chance that packet reordering will occur. Up to eight different
routes for a particular network are supported.
Software Interfaces
Cisco IOS for the Catalyst 4500 series switch supports GRE and IP tunnel interfaces that are not part of
the hardware forwarding engine. All packets that flow to or from these interfaces must be processed in
software and will have a significantly lower forwarding rate than that of hardware-switched interfaces.
Also, Layer 2 features are not supported on these interfaces.
Configuring CEF
These sections describe how to configure CEF:
Enabling CEF
By default, CEF is enabled globally on the Catalyst 4500 series switch. No configuration is required.
To reenable CEF, perform this task:
Command
Purpose
Switch(config)# ip cef
24-6
OL-6696-01
Chapter 24
Purpose
24-7
Chapter 24
For more information on load sharing, refer to the Configuring Cisco Express Forwarding module of the
Cisco IOS documentation at this URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/fwitch_c/swprt1/
xcfcefc.htm
Note
The include-ports option does not apply to software-switched traffic on the Catalyst 4500 series
switches.
Purpose
Purpose
This example shows how to display information about IP unicast traffic on interface Fast Ethernet 3/3:
Switch# show interface fastethernet 3/3 | begin L3
L3 in Switched: ucast: 0 pkt, 0 bytes - mcast: 12 pkt, 778 bytes mcast
L3 out Switched: ucast: 0 pkt, 0 bytes - mcast: 0 pkt, 0 bytes
4046399 packets input, 349370039 bytes, 0 no buffer
Received 3795255 broadcasts, 2 runts, 0 giants, 0 throttles
<...output truncated...>
Switch#
Note
Displaying IP Statistics
IP unicast statistics are gathered on a per-interface basis. To display IP statistics, perform this task:
Command
Purpose
Displays IP statistics.
24-8
OL-6696-01
Chapter 24
This example shows how to display IP unicast statistics for Part 3/1:
Switch# show interface fastethernet 3/1 counters detail
Port
Fa3/1
InBytes
7263539133
InUcastPkts
5998222
InMcastPkts
6412307
InBcastPkts
156
Port
Fa3/1
OutBytes
7560137031
OutUcastPkts
5079852
OutMcastPkts
12140475
OutBcastPkts
38
Port
Fa3/1
InPkts 64
11274
OutPkts 64
168536
InPkts 65-127
7650482
OutPkts 65-127
12395769
Port
Fa3/1
InPkts 128-255
31191
OutPkts 128-255
55269
InPkts 256-511
26923
OutPkts 256-511
65017
Port
Fa3/1
InPkts 512-1023
133807
OutPkts 512-1023
151582
Port
Fa3/1
Port
Fa3/1
Port
Fa3/1
Tx-Bytes-Queue-1
64
Tx-Bytes-Queue-2 Tx-Bytes-Queue-3
0
91007
Tx-Bytes-Queue-4
7666686162
Port
Fa3/1
Tx-Drops-Queue-1
0
Tx-Drops-Queue-2 Tx-Drops-Queue-3
0
0
Tx-Drops-Queue-4
0
Port
Fa3/1
Rx-No-Pkt-Buff
0
Port
Fa3/1
Switch#
RxPauseFrames
0
TxPauseFrames
0
PauseFramesDrop
N/A
UnsupOpcodePause
0
To display CEF (software switched) and hardware IP unicast adjacency table information, perform this
task:
Command
Purpose
Note
24-9
Chapter 24
24-10
OL-6696-01
C H A P T E R
25
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Note
Overview of IP Multicast
This section includes these subsections:
At one end of the IP communication spectrum is IP unicast, where a source IP host sends packets to a
specific destination IP host. In IP unicast, the destination address in the IP packet is the address of a
single, unique host in the IP network. These IP packets are forwarded across the network from the source
to the destination host by routers. At each point on the path between source and destination, a router uses
a unicast routing table to make unicast forwarding decisions, based on the IP destination address in the
packet.
25-1
Chapter 25
Overview of IP Multicast
At the other end of the IP communication spectrum is an IP broadcast, where a source host sends packets
to all hosts on a network segment. The destination address of an IP broadcast packet has the host portion
of the destination IP address set to all ones and the network portion set to the address of the subnet. IP
hosts, including routers, understand that packets, which contain an IP broadcast address as the
destination address, are addressed to all IP hosts on the subnet. Unless specifically configured otherwise,
routers do not forward IP broadcast packets, so IP broadcast communication is normally limited to a
local subnet.
IP multicasting falls between IP unicast and IP broadcast communication. IP multicast communication
enables a host to send IP packets to a group of hosts anywhere within the IP network. To send
information to a specific group, IP multicast communication uses a special form of IP destination
address called an IP multicast group address. The IP multicast group address is specified in the IP
destination address field of the packet.
To multicast IP information, Layer 3 switches and routers must forward an incoming IP packet to all
output interfaces that lead to members of the IP multicast group. In the multicasting process on the
Catalyst 4500 series switch, a packet is replicated in the Integrated Switching Engine, forwarded to the
appropriate output interfaces, and sent to each member of the multicast group.
It is not uncommon for people to think of IP multicasting and video conferencing as almost the same
thing. Although the first application in a network to use IP multicast is often video conferencing, video
is only one of many IP multicast applications that can add value to a companys business model. Other
IP multicast applications that have potential for improving productivity include multimedia
conferencing, data replication, real-time data multicasts, and simulation applications.
This section contains the following subsections:
IP Multicast Protocols
The Catalyst 4500 series switch primarily uses these protocols to implement IP multicast routing:
Figure 25-1 shows where these protocols operate within the IP multicast environment.
25-2
OL-6696-01
Chapter 25
Host A
Router
Internet
IGMP and
IGMP
Snooping
PIM
94150
Host B
Protocol-Independent Multicast
PIM is protocol independent because it can leverage whichever unicast routing protocol is used to
populate the unicast routing table, including EIGRP, OSPF, BGP, or static route, to support IP multicast.
PIM also uses a unicast routing table to perform the reverse path forwarding (RPF) check function
instead of building a completely independent multicast routing table. PIM does not send and receive
multicast routing updates between routers like other routing protocols do.
25-3
Chapter 25
Overview of IP Multicast
Note
A Catalyst 4500 series switch can act as a CGMP server for switches that do not support IGMP snooping,
such as Catalyst 4500 family switches with Supervisor Engine I and Supervisor Engine II. You cannot
configure the switch as a CGMP client. To configure a Catalyst 4500 series switch as a client, use IGMP
snooping.
CGMP is a Cisco protocol that allows Catalyst switches to leverage IGMP information on Cisco routers
to make Layer 2 forwarding decisions. CGMP is configured on the multicast routers and the Layer 2
switches. As a result, IP multicast traffic is delivered only to those Catalyst switchports with hosts that
have requested the traffic. Switchports that have not explicitly requested the traffic will not receive it.
25-4
OL-6696-01
Chapter 25
Logical Router
L3 logical
interfaces
VLAN1
VLAN2
68402
L2 switchports
25-5
Chapter 25
Overview of IP Multicast
The Catalyst 4500 series switch performs Layer 3 routing and Layer 2 bridging at the same time. There
can be multiple Layer 2 switchports on any VLAN interface. To determine the set of output switchports
on which to forward a multicast packet, the Supervisor Engine III combines Layer 3 MFIB information
with Layer 2 forwarding information and stores it in the hardware MET for packet replication.
Figure 25-3 shows a functional overview of how the Catalyst 4500 series switch combines unicast
routing, multicast routing, and Layer 2 bridging information to forward in hardware.
Figure 25-3 Combining CEF, MFIB, and Layer 2 Forwarding Information in Hardware
Protocols
EIGRP / OSPF
Unicast
Software
Tables
PIM / IGMP
IGMP Snooping
Spanning Tree
L2 Multicast
Multicast
Unicast Routing
Table
Multicast Routing
Table
CEF
MFIB
CPU
Subsystem
Software
Layer 2 Forwarding
Table
Hardware
Tables
H/W Adjacency
Table
H/W FIB
Table
MET Replication
Table
Integrated
Switching
Engine
68614
Like the CEF unicast routes, the MFIB routes are Layer 3 and must be merged with the appropriate
Layer 2 information. The following example shows an MFIB route:
(*,224.1.2.3)
RPF interface is Vlan3
Output Interfaces are:
Vlan 1
Vlan 2
The route (*,224.1.2.3) is loaded in the hardware FIB table and the list of output interfaces is loaded into
the MET. A pointer to the list of output interfaces, the MET index, and the RPF interface are also loaded
in the hardware FIB with the (*,224.1.2.3) route. With this information loaded in hardware, merging of
the Layer 2 information can begin. For the output interfaces on VLAN1, the Integrated Switching Engine
must send the packet to all switchports in VLAN1 that are in the spanning tree forwarding state. The
same process applies to VLAN 2. To determine the set of switchports in VLAN 2, the Layer 2
Forwarding Table is used.
When the hardware routes a packet, in addition to sending it to all of the switchports on all output
interfaces, the hardware also sends the packet to all switchports (other than the one it arrived on) in the
input VLAN. For example, assume that VLAN 3 has two switchports in it, Gig 3/1 and Gig 3/2. If a host
on Gig 3/1 sends a multicast packet, the host on Gig 3/2 might also need to receive the packet. To send
a multicast packet to the host on Gig 3/2, all of the switchports in the ingress VLAN must be added to
the portset that is loaded in the MET.
25-6
OL-6696-01
Chapter 25
If VLAN 1 contains 1/1 and 1/2, VLAN 2 contains 2/1 and 2/2, and VLAN 3 contains 3/1 and 3/2, the
MET chain for this route would contain these switchports: (1/1,1/2,2/1,2/2,3/1, and 3/2).
If IGMP snooping is on, the packet should not be forwarded to all output switchports on VLAN 2. The
packet should be forwarded only to switchports where IGMP snooping has determined that there is either
a group member or router. For example, if VLAN 1 had IGMP snooping enabled, and IGMP snooping
determined that only port 1/2 had a group member on it, then the MET chain would contain these
switchports: (1/1,1/2, 2/1, 2/2, 3/1, and 3/2).
IP Multicast Tables
Figure 25-4 shows some key data structures that the Catalyst 4500 series switch uses to forward IP
multicast packets in hardware.
Figure 25-4 IP Multicast Tables and Protocols
CPU Subsystem
Hardware Tables
Software Tables
Multicast Routing
Table
(S,G), RPF
interface, set of
output interfaces
L2 Forwarding
Table
Vlan, MAC address
switchports
S,G
S1, G1
S2, G2
*, G4
rpf interface
vlan 3
vlan 7
vlan 99
met index
1219
1241
1356
index
0
..
..
1279
Routing Protocols
L3 Protocols
PIM
IGMP
L2 Protocols
IGMP
snooping
Spanning tree
68135
The Integrated Switching Engine maintains the hardware FIB table to identify individual IP multicast
routes. Each entry consists of a destination group IP address and an optional source IP address. Multicast
traffic flows on primarily two types of routes: (S,G) and (*,G). The (S,G) routes flow from a source to a
group based on the IP address of the multicast source and the IP address of the multicast group
destination. Traffic on a (*,G) route flows from the PIM RP to all receivers of group G. Only
sparse-mode groups use (*,G) routes. The Integrated Switching Engine hardware contains space for a
total of 128,000 routes, which are shared by unicast routes, multicast routes, and multicast fast-drop
entries.
25-7
Chapter 25
Overview of IP Multicast
Output interface lists are stored in the multicast expansion table (MET). The MET has room for up to
32,000 output interface lists. The MET resources are shared by both Layer 3 multicast routes and by
Layer 2 multicast entries. The actual number of output interface lists available in hardware depends on
the specific configuration. If the total number of multicast routes exceed 32,000, multicast packets might
not be switched by the Integrated Switching Engine. They would be forwarded by the CPU subsystem
at much slower speeds.
CPU Subsystem
Router
L3 interfaces
VLAN1
VLAN2
GRE
tunnel
GRE
tunnel
68127
L2 switchports
In the normal mode of operation, the Integrated Switching Engine performs inter-VLAN routing in
hardware. The CPU subsystem supports generic routing encapsulation (GRE) tunnels for forwarding in
software.
Replication is a particular type of forwarding where, instead of sending out one copy of the packet, the
packet is replicated and multiple copies of the packet are sent out. At Layer 3, replication occurs only
for multicast packets; unicast packets are never replicated to multiple Layer 3 interfaces. In IP
multicasting, for each incoming IP multicast packet that is received, many replicas of the packet are sent
out.
IP multicast packets can be transmitted on the following types of routes:
Hardware routes
Software routes
Partial routes
25-8
OL-6696-01
Chapter 25
Hardware routes occur when the Integrated Switching Engine hardware forwards all replicas of a packet.
Software routes occur when the CPU subsystem software forwards all replicas of a packet. Partial routes
occur when the Integrated Switching Engine forwards some of the replicas in hardware and the CPU
subsystem forwards some of the replicas in software.
Partial Routes
Note
The conditions listed below cause the replicas to be forwarded by the CPU subsystem software, but the
performance of the replicas that are forwarded in hardware is not affected.
The following conditions cause some replicas of a packet for a route to be forwarded by the CPU
subsystem:
The switch is configured with the ip igmp join-group command as a member of the IP multicast
group on the RPF interface of the multicast source.
The switch is the first-hop to the source in PIM sparse mode. In this case, the switch must send
PIM-register messages to the RP.
Software Routes
Note
If any one of the following conditions is configured on the RPF interface or the output interface, all
replication of the output is performed in software.
The following conditions cause all replicas of a packet for a route to be forwarded by the CPU subsystem
software:
The interface is a generic routing encapsulation (GRE) or Distance Vector Multicast Routing
Protocol (DVMRP) tunnel.
Packets sent to multicast groups that fall into the range 224.0.0.* (where * is in the range from 0 to
255). This range is used by routing protocols. Layer 3 switching supports all other multicast group
addresses.
25-9
Chapter 25
Overview of IP Multicast
Router A
Router B
Network A
Multicast Traffic
Non-RPF Traffic
68331
Network B
In this kind of topology, only Router A, the PIM designated router (PIM DR), forwards data to the
common VLAN. Router B receives the forwarded multicast traffic, but must drop this traffic because it
has arrived on the wrong interface and fails the RPF check. Traffic that fails the RPF check is called
non-RPF traffic.
25-10
OL-6696-01
Chapter 25
Internal Copy (IC) flagset on a route when a process on the router needs to receive a copy of all
packets matching the specified route
Signalling (S) flagset on a route when a process needs to be notified when a packet matching the
route is received; the expected behavior is that the protocol code updates the MFIB state in response
to receiving a packet on a signalling interface
Connected (C) flagwhen set on an MFIB route, has the same meaning as the Signalling (S) flag,
except that the C flag indicates that only packets sent by directly connected hosts to the route should
be signalled to a protocol process
A route can also have a set of optional flags associated with one or more interfaces. For example, an
(S,G) route with the flags on VLAN 1 indicates how packets arriving on VLAN 1 should be treated, and
they also indicate whether packets matching the route should be forwarded onto VLAN 1. The
per-interface flags supported in the MFIB include the following:
Accepting (A)set on the interface that is known in multicast routing as the RPF interface. A packet
that arrives on an interface that is marked as Accepting (A) is forwarded to all Forwarding (F)
interfaces.
Forwarding (F)used in conjunction with the Accepting (A) flag as described above. The set of
Forwarding interfaces that form what is often referred to as the multicast olist or output interface
list.
Signalling (S)set on an interface when some multicast routing protocol process in IOS needs to
be notified of packets arriving on that interface.
Not platform fast-switched (NP)used in conjunction with the Forwarding (F) flag. A Forwarding
interface is also marked as not platform fast-switched whenever that output interface cannot be fast
switched by the platform. The NP flag is typically used when the Forwarding interface cannot be
routed in hardware and requires software forwarding. For example, Catalyst 4500 series switch
tunnel interfaces are not hardware switched, so they are marked with the NP flag. If there are any
NP interfaces associated with a route, then for every packet arriving on an Accepting interface, one
copy of that packet is sent to the software forwarding path for software replication to those interfaces
that were not switched in hardware.
25-11
Chapter 25
Note
When PIM-SM routing is in use, the MFIB route might include an interface like in this example:
PimTunnel [1.2.3.4]. This is a virtual interface that the MFIB subsystem creates to indicate that packets
are being tunnelled to the specified destination address. A PimTunnel interface cannot be displayed with
the normal show interface command.
S/M, 224/4
An (S/M, 224/4) entry is created in the MFIB for every multicast-enabled interface. This entry ensures
that all packets sent by directly connected neighbors can be Register-encapsulated to the PIM-SM RP.
Typically, only a small number of packets would be forwarded using the (S/M,224/4) route, until the
(S,G) route is established by PIM-SM.
For example, on an interface with IP address 10.0.0.1 and netmask 255.0.0.0, a route would be created
matching all IP multicast packets in which the source address is anything in the class A network 10. This
route can be written in conventional subnet/masklength notation as (10/8,224/4). If an interface has
multiple assigned IP addresses, then one route is created for each such IP address.
Unsupported Features
The following IP multicast features are not supported in this release:
For more detailed information on IP multicast routing, such as Auto-RP, PIM Version 2, and IP multicast
static routes, refer to the Cisco IOS IP and IP Routing Configuration Guide, Release 12.2.
25-12
OL-6696-01
Chapter 25
Feature
Default Value
Enabled globally
IP multicast routing
Disabled globally
Note
PIM
IGMP snooping
Note
Purpose
Switch(config)# ip multicast-routing
25-13
Chapter 25
When the switch populates the multicast routing table, dense-mode interfaces are always added to the
table. Sparse-mode interfaces are added to the table only when periodic join messages are received from
downstream routers, or when there is a directly connected member on the interface. When forwarding
from a LAN, sparse-mode operation occurs if there is an RP known for the group. If so, the packets are
encapsulated and sent toward the RP. When no RP is known, the packet is flooded in a dense-mode
fashion. If the multicast traffic from a specific source is sufficient, the receivers first-hop router can send
join messages toward the source to build a source-based distribution tree.
There is no default mode setting. By default, multicast routing is disabled on an interface.
Purpose
See the PIM Dense Mode Example section at the end of this chapter for an example of how to
configure a PIM interface in dense mode.
Purpose
Switch(config-if)# ip pim
sparse-mode
See the PIM Sparse Mode Example section at the end of this chapter for an example of how to
configure a PIM interface in sparse mode.
25-14
OL-6696-01
Chapter 25
When an interface is treated in dense mode, it is populated in a multicast routing tables outgoing
interface list when either of the following is true:
When there are PIM neighbors and the group has not been pruned
When an interface is treated in sparse mode, it is populated in a multicast routing tables outgoing
interface list when either of the following is true:
When an explicit join has been received by a PIM neighbor on the interface
To enable PIM to operate in the same mode as the group, perform this task:
Command
Purpose
Switch(config-if)# ip pim
sparse-dense-mode
Purpose
25-15
Chapter 25
The following is sample output from the show ip mroute command for a router operating in sparse
mode:
Switch# show ip mroute
IP Multicast Routing Table
Flags: D - Dense, S - Sparse, C - Connected, L - Local, P - Pruned
R - RP-bit set, F - Register flag, T - SPT-bit set
Timers: Uptime/Expires
Interface state: Interface, Next-Hop, State/Mode
(*, 224.0.255.3), uptime 5:29:15, RP is 198.92.37.2, flags: SC
Incoming interface: Tunnel0, RPF neighbor 10.3.35.1, Dvmrp
Outgoing interface list:
Ethernet0, Forward/Sparse, 5:29:15/0:02:57
(198.92.46.0/24, 224.0.255.3), uptime 5:29:15, expires 0:02:59, flags: C
Incoming interface: Tunnel0, RPF neighbor 10.3.35.1
Outgoing interface list:
Ethernet0, Forward/Sparse, 5:29:15/0:02:57
Note
Interface timers are not updated for hardware-forwarded packets. Entry timers are updated
approximately every five seconds.
The following is sample output from the show ip mroute command with the summary keyword:
Switch# show ip mroute summary
IP Multicast Routing Table
Flags: D - Dense, S - Sparse, C - Connected, L - Local, P - Pruned
R - RP-bit set, F - Register flag, T - SPT-bit set, J - Join SPT
Timers: Uptime/Expires
Interface state: Interface, Next-Hop, State/Mode
(*, 224.255.255.255), 2d16h/00:02:30, RP 171.69.10.13, flags: SJPC
25-16
OL-6696-01
Chapter 25
The following is sample output from the show ip mroute command with the active keyword:
Switch# show ip mroute active
Active IP Multicast Sources - sending >= 4 kbps
Group: 224.2.127.254, (sdr.cisco.com)
Source: 146.137.28.69 (mbone.ipd.anl.gov)
Rate: 1 pps/4 kbps(1sec), 4 kbps(last 1 secs), 4 kbps(life avg)
Group: 224.2.201.241, ACM 97
Source: 130.129.52.160 (webcast3-e1.acm97.interop.net)
Rate: 9 pps/93 kbps(1sec), 145 kbps(last 20 secs), 85 kbps(life avg)
Group: 224.2.207.215, ACM 97
Source: 130.129.52.160 (webcast3-e1.acm97.interop.net)
Rate: 3 pps/31 kbps(1sec), 63 kbps(last 19 secs), 65 kbps(life avg)
The following is sample output from the show ip mroute command with the count keyword:
Switch# show ip mroute count
IP Multicast Statistics - Group count: 8, Average sources per group: 9.87
Counts: Pkt Count/Pkts per second/Avg Pkt Size/Kilobits per second
Group: 224.255.255.255, Source count: 0, Group pkt count: 0
RP-tree: 0/0/0/0
Group: 224.2.127.253, Source count: 0, Group pkt count: 0
RP-tree: 0/0/0/0
Group: 224.1.127.255, Source count: 0, Group pkt count: 0
RP-tree: 0/0/0/0
Group: 224.2.127.254, Source count: 9, Group pkt count: 14
RP-tree: 0/0/0/0
Source: 128.2.6.9/32, 2/0/796/0
Source: 128.32.131.87/32, 1/0/616/0
Source: 128.125.51.58/32, 1/0/412/0
Source: 130.207.8.33/32, 1/0/936/0
Source: 131.243.2.62/32, 1/0/750/0
Source: 140.173.8.3/32, 1/0/660/0
Source: 146.137.28.69/32, 1/0/584/0
Source: 171.69.60.189/32, 4/0/447/0
Source: 204.162.119.8/32, 2/0/834/0
Group: 224.0.1.40, Source count: 1, Group pkt count: 3606
RP-tree: 0/0/0/0
Source: 171.69.214.50/32, 3606/0/48/0, RPF Failed: 1203
25-17
Chapter 25
Note
Multicast route byte and packet statistics are supported only for the first 1024 multicast routes. Output
interface statistics are not maintained.
Displaying IP MFIB
You can display all routes in the MFIB, including routes that might not exist directly in the upper-layer
routing protocol database but that are used to accelerate fast switching. These routes appear in the MFIB,
even if dense-mode forwarding is in use.
To display various MFIB routing routes, perform one of these tasks:
Command
Purpose
Displays the (S,G) and (*,G) routes that are used for packet
forwarding. Displays counts for fast, slow, and
partially-switched packets for every multicast route.
25-18
OL-6696-01
Chapter 25
The fast-switched packet count represents the number of packets that were switched in hardware on the
corresponding route.
The partially switched packet counter represents the number of times that a fast-switched packet was
also copied to the CPU for software processing or for forwarding to one or more non-platform switched
interfaces (such as a PimTunnel interface).
The slow-switched packet count represents the number of packets that were switched completely in
software on the corresponding route.
Purpose
The following is sample output from the show ip mfib fastdrop command.
Switch> show ip mfib fastdrop
MFIB fastdrop is enabled.
MFIB fast-dropped flows:
(10.0.0.1, 224.1.2.3, Vlan9 ) 00:01:32
(10.1.0.2, 224.1.2.3, Vlan9 ) 00:02:30
(1.2.3.4, 225.6.7.8, Vlan3) 00:01:50
The full (S,G) flow and the ingress interface on which incoming packets are dropped is shown. The
timestamp indicates the age of the entry.
25-19
Chapter 25
Interface
Mode
198.92.37.6
198.92.36.129
10.1.37.2
Ethernet0
Ethernet1
Tunnel0
Dense
Dense
Dense
Neighbor
Count
2
2
1
Query
Interval
30
30
30
DR
198.92.37.33
198.92.36.131
0.0.0.0
The following is sample output from the show ip pim interface command with a count:
Switch# show ip pim interface count
Address
171.69.121.35
171.69.121.35
198.92.12.73
Interface
Ethernet0
Serial0.33
Serial0.1719
FS
*
*
*
Mpackets In/Out
548305239/13744856
8256/67052912
219444/862191
The following is sample output from the show ip pim interface command with a count when IP
multicast is enabled. The example lists the PIM interfaces that are fast-switched and process-switched,
and the packet counts for these. The H is added to interfaces where IP multicast is enabled.
Switch# show ip pim interface count
States: FS - Fast Switched, H - Hardware Switched
Address
Interface
FS Mpackets In/Out
192.1.10.2
Vlan10
* H 40886/0
192.1.11.2
Vlan11
* H 0/40554
192.1.12.2
Vlan12
* H 0/40554
192.1.23.2
Vlan23
*
0/0
192.1.24.2
Vlan24
*
0/0
Note
Command
Purpose
IP multicast routes can be regenerated in response to protocol events and as data packets arrive.
25-20
OL-6696-01
Chapter 25
Configuration Examples
The following sections provide IP multicast routing configuration examples:
25-21
Chapter 25
Configuration Examples
25-22
OL-6696-01
C H A P T E R
26
Note
For a complete description of the PBR commands in this chapter, refer to the Cisco IOS Quality of
Service Solutions Command Reference at:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios123/123tcr/123tqr/
Note
To identify the hardware platform or software image information associated with a feature, use the
Feature Navigator on Cisco.com to search for information about the feature or refer to the software
release notes for a specific release.
PBR gives you a flexible means of routing packets by allowing you to configure a defined policy for
traffic flows, lessening reliance on routes derived from routing protocols. To this end, PBR gives you
more control over routing by extending and complementing the existing mechanisms provided by routing
protocols. PBR allows you to specify a path for certain traffic, such as priority traffic over a high-cost
link.
You can set up PBR as a way to route packets based on configured policies. For example, you can
implement routing policies to allow or deny paths based on the identity of a particular end system, an
application protocol, or the size of packets.
26-1
Chapter 26
Classify traffic based on extended access list criteria. Access lists, then establish the match criteria.
Policies can be based on IP address, port numbers, or protocols. For a simple policy, you can use any
one of these descriptors; for a complicated policy, you can use all of them.
Understanding PBR
All packets received on an interface with PBR enabled are passed through enhanced packet filters known
as route maps. The route maps used by PBR dictate the policy, determining to where the packets are
forwarded.
Route maps are composed of statements. The route map statements can be marked as permit or deny, and
they are interpreted in the following ways:
If a statement is marked as deny, the packets meeting the match criteria are sent back through the
normal forwarding channels and destination-based routing is performed.
If the statement is marked as permit and a packet matches the access-lists, then the first valid set
clause is applied to that packet.
You specify PBR on the incoming interface (the interface on which packets are received), not outgoing
interface.
equal access
protocol-sensitive routing
source-sensitive routing
Some applications or traffic can benefit from source-specific routing; for example, you can transfer stock
records to a corporate office on a higher-bandwidth, higher-cost link for a short time while sending
routine application data, such as e-mail, over a lower-bandwidth, lower-cost link.
26-2
OL-6696-01
Chapter 26
Enabling PBR
To enable PBR, you must create a route map that specifies the match criteria and the resulting action if
all of the match clauses are met. Then you must enable PBR for that route map on a particular interface.
All packets arriving on the specified interface matching the match clauses will be subject to PBR.
To enable PBR on an interface, perform this task:
Command
Purpose
Step 1
Step 2
26-3
Chapter 26
Command
Purpose
Step 3
Specifies the next hop for which to route the packet (the
next hop must be adjacent). This behavior is identical to
a next hop specified in the normal routing table.
Step 4
Switch(config-route-map)# interface
interface-type interface-number
Step 5
Identifies the route map to use for PBR. One interface can
only have one route map tag, but you can have multiple route
map entries with different sequence numbers. These entries
are evaluated in sequence number order until the first match.
If there is no match, packets will be routed as usual.
The set commands can be used in conjunction with each other. These commands are evaluated in the
order shown in Step 3 in the previous task table. A usable next hop implies an interface. Once the local
router finds a next hop and a usable interface, it routes the packet.
26-4
OL-6696-01
Chapter 26
Purpose
All packets originating on the router will then be subject to local PBR.
Use the show ip local policy command to display the route map used for local PBR, if one exists.
Unsupported Commands
The following PBR commands in config-route-map mode are in the CLI but not supported in Cisco IOS
for the Catalyst 4500 series switches. If you attempt to use these commands, an error message displays.
match-length
set ip qos
set ip tos
set ip precedence
For information on how to configure policy-based routing, see the section Policy-Based Routing
Configuration Task List in this chapter.
26-5
Chapter 26
!
route-map equal-access permit 10
match ip address 1
set ip default next-hop 6.6.6.6
route-map equal-access permit 20
match ip address 2
set ip default next-hop 7.7.7.7
route-map equal-access permit 30
set default interface null0
Note
If the packets you want to drop do not match either of the first two route-map clauses, then change set
default interface null0 to set interface null0.
26-6
OL-6696-01
C H A P T E R
27
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Overview of VTP
VTP is a Layer 2 messaging protocol that maintains VLAN configuration consistency by managing the
addition, deletion, and renaming of VLANs within a VTP domain. A VTP domain (also called a VLAN
management domain) is made up of one or more network devices that share the same VTP domain name
and that are interconnected with trunks. VTP minimizes misconfigurations and configuration
inconsistencies that can result in a number of problems, such as duplicate VLAN names, incorrect
VLAN-type specifications, and security violations.
Before you create VLANs, you must decide whether you want to use VTP in your network. With VTP,
you can make configuration changes centrally on one or more network devices and have those changes
automatically communicated to all the other network devices in the network.
Note
For complete information on configuring VLANs, see Chapter 10, Understanding and Configuring
VLANs.
These sections describe how VTP works:
27-1
Chapter 27
Overview of VTP
Note
ServerIn VTP server mode, you can create, modify, and delete VLANs and specify other
configuration parameters (such as VTP version and VTP pruning) for the entire VTP domain. VTP
servers advertise their VLAN configuration to other network devices in the same VTP domain and
synchronize their VLAN configuration with other network devices based on advertisements received
over trunk links. VTP server is the default mode.
ClientVTP clients behave the same way as VTP servers, but you cannot create, change, or delete
VLANs on a VTP client.
Catalyst 4500 series switch automatically change from VTP server mode to VTP client mode if the
switch detects a failure while writing configuration to NVRAM. If this happens, the switch cannot be
returned to VTP server mode until the NVRAM is functioning.
27-2
OL-6696-01
Chapter 27
VLAN configuration, including maximum transmission unit (MTU) size for each VLAN
Frame format
Note
Catalyst 4500 series switch do not support Token Ring or FDDI media. The switch does not forward
FDDI, FDDI-Net, Token Ring Concentrator Relay Function [TrCRF], or Token Ring Bridge Relay
Function [TrBRF] traffic, but it does propagate the VLAN configuration via VTP.
VTP version 2 supports the following features, which are not supported in version 1:
Token Ring supportVTP version 2 supports Token Ring LAN switching and VLANs (TrBRF and
TrCRF).
Consistency ChecksIn VTP version 2, VLAN consistency checks (such as VLAN names and
values) are performed only when you enter new information through the CLI or SNMP. Consistency
checks are not performed when new information is obtained from a VTP message or when
information is read from NVRAM. If the digest on a received VTP message is correct, its
information is accepted without consistency checks.
27-3
Chapter 27
Overview of VTP
For VTP pruning to be effective, all devices in the management domain must either support VTP pruning
or, on devices that do not support VTP pruning, you must manually configure the VLANs allowed on
trunks.
Figure 27-1 shows a switched network without VTP pruning enabled. Interface 1 on Switch 1 and
Interface 2 on Switch 4 are assigned to the Red VLAN. A broadcast is sent from the host connected to
Switch 1. Switch 1 floods the broadcast and every network device in the network receives it, even though
Switches 3, 5, and 6 have no interfaces in the Red VLAN.
You can enable pruning globally on the Catalyst 4500 series switch (see the Enabling VTP Pruning
section on page 27-6).
Figure 27-1 Flooding Traffic without VTP Pruning
Catalyst series
switch 4
Interface 2
Catalyst series
switch 5
Catalyst series
switch 2
Red
VLAN
Catalyst series
switch 6
94151
Interface 1
Catalyst series Catalyst series
switch 3
switch 1
Figure 27-2 shows the same switched network with VTP pruning enabled. The broadcast traffic from
Switch 1 is not forwarded to Switches 3, 5, and 6 because traffic for the Red VLAN has been pruned on
the links indicated (Interface 5 on Switch 2 and Interface 4 on Switch 4).
Figure 27-2 Flooding Traffic with VTP Pruning
Switch 4
Interface 2
Interface 4
Flooded traffic
is pruned.
Switch 2
Red
VLAN
Switch 5
Interface 5
Switch 6
Switch 3
Switch 1
31075
Interface 1
27-4
OL-6696-01
Chapter 27
Enabling VTP pruning on a VTP server enables pruning for the entire management domain. VTP pruning
takes effect several seconds after you enable it. By default, VLANs 2 through 1000 are eligible for
pruning. VTP pruning does not prune traffic from pruning-ineligible VLANs. VLAN 1 is always
ineligible for pruning; traffic from VLAN 1 cannot be pruned.
To configure VTP pruning on a trunking LAN interface, use the switchport trunk pruning vlan
command. VTP pruning operates when a LAN interface is trunking. You can set VLAN pruning
eligibility regardless of whether VTP pruning is enabled or disabled for the VTP domain, whether any
given VLAN exists, and regardless of whether the LAN interface is currently trunking.
Caution
All network devices in a VTP domain must run the same VTP version.
You must configure a password on each network device in the management domain when VTP is in
secure mode.
If you configure VTP in secure mode, the management domain will not function properly if you do not
assign a management domain password to each network device in the domain.
A VTP version 2-capable network device can operate in the same VTP domain as a network device
running VTP version 1 if VTP version 2 is disabled on the VTP version 2-capable network device
(VTP version 2 is disabled by default).
Do not enable VTP version 2 on a network device unless all of the network devices in the same VTP
domain are version 2-capable. When you enable VTP version 2 on a server, all of the
version 2-capable network devices in the domain enable VTP version 2.
Enabling or disabling VTP pruning on a VTP server enables or disables VTP pruning for the entire
management domain.
Configuring VLANs as eligible for pruning on a Catalyst 4500 series switch affects pruning
eligibility for those VLANs on that switch only, not on all network devices in the VTP domain.
Feature
Default Value
Null
VTP mode
Server
Version 2 is disabled
VTP password
None
VTP pruning
Disabled
27-5
Chapter 27
Configuring VTP
Configuring VTP
The following sections describe how to configure VTP:
Purpose
Step 1
Command
Purpose
Step 2
27-6
OL-6696-01
Chapter 27
This example shows how to enable VTP pruning in the management domain:
Switch# vtp pruning
Pruning switched ON
Caution
VTP version 1 and VTP version 2 are not interoperable on network devices in the same VTP domain.
Every network device in the VTP domain must use the same VTP version. Do not enable VTP version 2
unless every network device in the VTP domain supports version 2.
To enable VTP version 2, perform this task:
Step 1
Command
Purpose
Step 2
Purpose
Step 1
Step 2
Step 3
27-7
Chapter 27
Configuring VTP
Command
Purpose
Step 4
Switch(config)# end
Step 5
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
Step 4
27-8
OL-6696-01
Chapter 27
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
Step 4
27-9
Chapter 27
Configuring VTP
Purpose
:
:
:
:
:
:
:
:
:
7
5
0
997
13
3
0
0
0
27-10
OL-6696-01
C H A P T E R
28
Configuring VRF-lite
Virtual Private Networks (VPNs) provide a secure way for customers to share bandwidth over an ISP
backbone network. A VPN is a collection of sites sharing a common routing table. A customer site is
connected to the service provider network by one or more interfaces, and the service provider associates
each interface with a VPN routing table. A VPN routing table is called a VPN routing/forwarding (VRF)
table.
With the VRF-lite feature, the Catalyst 4500 series switch supports multiple VPN routing/forwarding
instances in customer edge devices. (VRF-lite is also termed multi-VRF CE, or multi-VRF Customer
Edge Device). VRF-lite allows a service provider to support two or more VPNs with overlapping IP
addresses using one interface.
Note
The switch does not use Multiprotocol Label Switching (MPLS) to support VPNs. For information about
MPLS VRF, refer to the Cisco IOS Switching Services Configuration Guide for Release 12.3 at:
http://www.cisco.com/univerd/cc/td/doc/product/software/ios123/123cgcr/swit_vcg.htm
This chapter includes these topics:
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
28-1
Chapter 28
Configuring VRF-lite
Understanding VRF-lite
Understanding VRF-lite
VRF-lite is a feature that enables a service provider to support two or more VPNs, where IP addresses
can be overlapped among the VPNs. VRF-lite uses input interfaces to distinguish routes for different
VPNs and forms virtual packet-forwarding tables by associating one or more Layer 3 interfaces with
each VRF. Interfaces in a VRF can be either physical, such as Ethernet ports, or logical, such as VLAN
SVIs, but a Layer 3 interface cannot belong to more than one VRF at any time.
Note
Customer edge (CE) devices provide customer access to the service provider network over a data
link to one or more provider edge routers. The CE device advertises the sites local routes to the
provider edge router and learns the remote VPN routes from it. A Catalyst 4500 switch can be a CE.
Provider edge (PE) routers exchange routing information with CE devices by using static routing or
a routing protocol such as BGP, RIPv1, or RIPv2.
The PE is only required to maintain VPN routes for those VPNs to which it is directly attached,
eliminating the need for the PE to maintain all of the service provider VPN routes. Each PE router
maintains a VRF for each of its directly connected sites. Multiple interfaces on a PE router can be
associated with a single VRF if all of these sites participate in the same VPN. Each VPN is mapped
to a specified VRF. After learning local VPN routes from CEs, a PE router exchanges VPN routing
information with other PE routers by using internal BGP (IBPG).
Provider routers (or core routers) are any routers in the service provider network that do not attach
to CE devices.
With VRF-lite, multiple customers can share one CE, and only one physical link is used between the CE
and the PE. The shared CE maintains separate VRF tables for each customer and switches or routes
packets for each customer based on its own routing table. VRF-lite extends limited PE functionality to
a CE device, giving it the ability to maintain separate VRF tables to extend the privacy and security of
a VPN to the branch office.
Figure 28-1 shows a configuration where each Catalyst 4500 switch acts as multiple virtual CEs.
Because VRF-lite is a Layer 3 feature, each interface in a VRF must be a Layer 3 interface.
Figure 28-1 Catalyst 4500 Switches Acting as Multiple Virtual CEs
VPN 1
VPN 1
Catalyst 4500
switch
PE
PE
MPLS
network
Si
MPLS-VRF
router
CE
Si
Catalyst 4500
switch
MPLS-VRF
router
VPN 2
VPN 2
99721
CE
28-2
OL-6696-01
Chapter 28
Configuring VRF-lite
Default VRF-lite Configuration
This is the packet-forwarding process in a VRF-lite CE-enabled network as shown in Figure 28-1:
When the CE receives a packet from a VPN, it looks up the routing table based on the input interface.
When a route is found, the CE forwards the packet to the PE.
When the ingress PE receives a packet from the CE, it performs a VRF lookup. When a route is
found, the router adds a corresponding MPLS label to the packet and sends it to the MPLS network.
When an egress PE receives a packet from the network, it strips the label and uses the label to
identify the correct VPN routing table. Then the egress PE performs the normal route lookup. When
a route is found, it forwards the packet to the correct adjacency.
When a CE receives a packet from an egress PE, it uses the input interface to look up the correct
VPN routing table. If a route is found, the CE forwards the packet within the VPN.
To configure VRF, create a VRF table and specify the Layer 3 interface associated with the VRF. Then
configure the routing protocols in the VPN and between the CE and the PE. BGP is the preferred routing
protocol used to distribute VPN routing information across the providers backbone. The VRF-lite
network has three major components:
VPN route target communitiesLists of all other members of a VPN community. You need to
configure VPN route targets for each VPN community member.
VPN forwardingTransports all traffic between all VPN community members across a VPN
service-provider network.
Feature
Default Setting
VRF
Maps
None.
Forwarding table
28-3
Chapter 28
Configuring VRF-lite
A switch with VRF-lite is shared by multiple customers, and all customers have their own routing
tables.
Because customers use different VRF tables, the same IP addresses can be reused. Overlapped IP
addresses are allowed in different VPNs.
VRF-lite lets multiple customers share the same physical link between the PE and the CE. Trunk
ports with multiple VLANs separate packets among customers. All customers have their own
VLANs.
VRF-lite does not support all MPLS-VRF functionality: label exchange, LDP adjacency, or labeled
packets.
For the PE router, there is no difference between using VRF-lite or using multiple CEs. In
Figure 28-1, multiple virtual Layer 3 interfaces are connected to the VRF-lite device.
The Catalyst 4500 series switch supports configuring VRF by using physical ports, VLAN SVIs, or
a combination of both. The SVIs can be connected through an access port or a trunk port.
A customer can use multiple VLANs as long as they do not overlap with those of other customers.
A customers VLANs are mapped to a specific routing table ID that is used to identify the
appropriate routing tables stored on the switch.
The Layer 3 TCAM resource is shared between all VRFs. To ensure that any one VRF has sufficient
CAM space, use the maximum routes command.
A Catalyst 4500 series switch using VRF can support one global network and up to 64 VRFs. The
total number of routes supported is limited by the size of the TCAM.
Most routing protocols (BGP, OSPF, EIGRP, RIP and static routing) can be used between the CE
and the PE. However, we recommend using external BGP (EBGP) for these reasons:
BGP does not require multiple algorithms to communicate with multiple CEs.
BGP is designed for passing routing information between systems run by different
administrations.
BGP makes it easy to pass attributes of the routes to the CE.
Multicast cannot be configured on the same Layer 3 interface at the same time.
The capability vrf-lite subcommand under router ospf should be used when configuring OSPF as
the routing protocol between the PE and the CE.
28-4
OL-6696-01
Chapter 28
Configuring VRF-lite
Configuring VRFs
Configuring VRFs
To configure one or more VRFs, perform this task:
Command
Purpose
Step 1
Step 2
Switch(config)# ip routing
Enables IP routing.
Step 3
Step 4
Switch(config-vrf)# rd
route-distinguisher
Step 5
Switch(config-vrf)# route-target
{export | import | both}
route-target-ext-community
Step 6
Step 7
Switch(config-vrf)# interface
interface-id
Step 8
Step 9
Switch(config-if)# end
Step 10
Step 11
Note
For complete syntax and usage information for the commands, refer to the switch command reference
for this release and the Cisco IOS Switching Services Command Reference for Release 12.2.
| detail |
Use the no ip vrf vrf-name global configuration command to delete a VRF and to remove all interfaces
from it. Use the no ip vrf forwarding interface configuration command to remove an interface from the
VRF.
28-5
Chapter 28
Configuring VRF-lite
Purpose
Step 1
Step 2
Step 3
Switch(config-router)#
log-adjacency-changes
Step 4
Switch(config-router)# redistribute
bgp autonomous-system-number subnets
Step 5
Switch(config-router)# network
network-number area area-id
Step 6
Switch(config-router)# end
Step 7
Step 8
Use the no router ospf process-id vrf vrf-name global configuration command to disassociate the VPN
forwarding table from the OSPF routing process.
Purpose
Step 1
Step 2
Step 3
Switch(config-router)# network
network-number mask network-mask
Step 4
Switch(config-router)# redistribute
ospf process-id match internal
Step 5
Switch(config-router)# network
network-number area area-id
Step 6
Switch(config-router-af)#
address-family ipv4 vrf vrf-name
Step 7
Switch(config-router-af)# neighbor
address remote-as as-number
Step 8
Switch(config-router-af)# neighbor
address activate
Step 9
Switch(config-router-af)# end
28-6
OL-6696-01
Chapter 28
Configuring VRF-lite
VRF-lite Configuration Example
Command
Purpose
[ipv4] [neighbors] Verifies BGP configuration.
Step 10
Step 11
Use the no router bgp autonomous-system-number global configuration command to delete the BGP
routing process. Use the command with keywords to delete routing characteristics.
Catalyst 4500
Switch S8
VPN1
Router
Si
Catalyst 4500
Switch S9
Si
Switch S20
VPN1
208.0.0.0
Fast
Ethernet
3/8
Switch S13
Switch S10
108.0.0.0
VPN2
Fast
Ethernet
3/7
CE
Switch S11
118.0.0.0
Fast
Ethernet
3/11
VPN2
PE
CE
Switch S14
Fast
Ethernet
3/5
Global network
Switch S15
Global network
168.0.0.0
Fast
Ethernet
3/3
99722
Switch S16
28-7
Chapter 28
Configuring VRF-lite
Configuring Switch S8
On switch S8, enable routing and configure VRF.
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# ip routing
Switch(config)# ip vrf v11
Switch(config-vrf)# rd 800:1
Switch(config-vrf)# route-target export 800:1
Switch(config-vrf)# route-target import 800:1
Switch(config-vrf)# exit
Switch(config)# ip vrf v12
Switch(config-vrf)# rd 800:2
Switch(config-vrf)# route-target export 800:2
Switch(config-vrf)# route-target import 800:2
Switch(config-vrf)# exit
Configure the loopback and physical interfaces on switch S8. Fast Ethernet interface 3/5 is a trunk
connection to the PE. Interfaces 3/7 and 3/11 connect to VPNs:
Switch(config)# interface loopback1
Switch(config-if)# ip vrf forwarding v11
Switch(config-if)# ip address 8.8.1.8 255.255.255.0
Switch(config-if)# exit
Switch(config)# interface loopback2
Switch(config-if)# ip vrf forwarding v12
Switch(config-if)# ip address 8.8.2.8 255.255.255.0
Switch(config-if)# exit
Switch(config)# interface FastEthernet3/5
Switch(config-if)# switchport trunk encapsulation dot1q
Switch(config-if)# switchport mode trunk
Switch(config-if)# no ip address
Switch(config-if)# exit
Switch(config)# interface FastEthernet3/8
Switch(config-if)# switchport access vlan 208
Switch(config-if)# no ip address
Switch(config-if)# exit
Switch(config)# interface FastEthernet3/11
Switch(config-if)# switchport trunk encapsulation dot1q
Switch(config-if)# switchport mode trunk
Switch(config-if)# no ip address
Switch(config-if)# exit
Configure the VLANs used on switch S8. VLAN 10 is used by VRF 11 between the CE and the PE.
VLAN 20 is used by VRF 12 between the CE and the PE. VLANs 118 and 208 are used for VRF for the
VPNs that include switch S11 and switch S20, respectively:
Switch(config)# interface Vlan10
Switch(config-if)# ip vrf forwarding v11
Switch(config-if)# ip address 38.0.0.8 255.255.255.0
Switch(config-if)# exit
Switch(config)# interface Vlan20
Switch(config-if)# ip vrf forwarding v12
Switch(config-if)# ip address 83.0.0.8 255.255.255.0
Switch(config-if)# exit
28-8
OL-6696-01
Chapter 28
Configuring VRF-lite
VRF-lite Configuration Example
28-9
Chapter 28
Configuring VRF-lite
28-10
OL-6696-01
Chapter 28
Configuring VRF-lite
Displaying VRF-lite Status
Purpose
Note
For more information about the information in the displays, refer to the Cisco IOS Switching Services
Command Reference for Release 12.2 at:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/fswtch_r
28-11
Chapter 28
Configuring VRF-lite
28-12
OL-6696-01
C H A P T E R
29
Configuring QoS
This chapter describes how to configure quality of service (QoS) by using automatic QoS (auto-QoS)
commands or by using standard QoS commands on a Catalyst 4500 series switch. It also provides
guidelines, procedures, and configuration examples.
This chapter consists of these sections:
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Overview of QoS
Typically, networks operate on a best-effort delivery basis, which means that all traffic has equal priority
and an equal chance of being delivered in a timely manner. When congestion occurs, all traffic has an
equal chance of being dropped.
QoS selects network traffic (both unicast and multicast), prioritizes it according to its relative
importance, and uses congestion avoidance to provide priority-indexed treatment; QoS can also limit the
bandwidth used by network traffic. QoS can make network performance more predictable and bandwidth
utilization more effective.
This section contains the following subsections:
29-1
Chapter 29
Configuring QoS
Overview of QoS
Prioritization
The QoS implementation for this release is based on the DiffServ architecture, an emerging standard
from the Internet Engineering Task Force (IETF). This architecture specifies that each packet is
classified upon entry into the network. The classification is carried in the IP packet header, using 6 bits
from the deprecated IP type of service (TOS) field to carry the classification (class) information.
Classification can also be carried in the Layer 2 frame. These special bits in the Layer 2 frame or
a Layer 3 packet are described here and shown in Figure 29-1:
Encapsulated Packet
Layer 2
header
IP header
Data
FCS
(4 bytes)
Start frame
delimiter
DA
SA
Tag
PT
Data
FCS
Version
length
ToS
(1 byte)
Len
ID
Offset TTL
68140
IP precedence or DSCP
29-2
OL-6696-01
Chapter 29
Configuring QoS
Overview of QoS
All switches and routers across the Internet rely on the class information to provide the same forwarding
treatment to packets with the same class information and different treatment to packets with different
class information. The class information in the packet can be assigned by end hosts or by switches or
routers along the way, based on a configured policy, detailed examination of the packet, or both. Detailed
examination of the packet is expected to happen closer to the edge of the network so that the core
switches and routers are not overloaded.
Switches and routers along the path can use the class information to limit the amount of resources
allocated per traffic class. The behavior of an individual device when handling traffic in the DiffServ
architecture is called per-hop behavior. If all devices along a path provide a consistent per-hop behavior,
you can construct an end-to-end QoS solution.
Implementing QoS in your network can be a simple or complex task and depends on the QoS features
offered by your internetworking devices, the traffic types and patterns in your network, and the
granularity of control you need over incoming and outgoing traffic.
QoS Terminology
The following terms are used when discussing QoS features:
Labels are prioritization values carried in Layer 3 packets and Layer 2 frames:
Layer 2 class of service (CoS) values, which range between zero for low priority and seven for
high priority:
Layer 2 Inter-Switch Link (ISL) frame headers have a 1-byte User field that carries an IEEE
802.1p CoS value in the three least significant bits.
Layer 2 802.1Q frame headers have a 2-byte Tag Control Information field that carries the CoS
value in the three most significant bits, which are called the User Priority bits.
Other frame types cannot carry Layer 2 CoS values.
Note
On interfaces configured as Layer 2 ISL trunks, all traffic is in ISL frames. On interfaces
configured as Layer 2 802.1Q trunks, all traffic is in 802.1Q frames except for traffic in the
native VLAN.
Layer 3 IP precedence valuesThe IP version 4 specification defines the three most significant
bits of the 1-byte ToS field as IP precedence. IP precedence values range between zero for low
priority and seven for high priority.
Layer 3 differentiated services code point (DSCP) valuesThe Internet Engineering Task
Force (IETF) has defined the six most significant bits of the 1-byte IP ToS field as the DSCP.
The per-hop behavior represented by a particular DSCP value is configurable. DSCP values
range between 0 and 63. See the Configuring DSCP Maps section on page 29-45.
Note
Layer 3 IP packets can carry either an IP precedence value or a DSCP value. QoS supports
the use of either value, since DSCP values are backwards compatible with IP precedence
values. See Table 29-1.
29-3
Chapter 29
Configuring QoS
Overview of QoS
6 MSb1 of ToS
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
1
1
1
0
0
1
1
0
0
1
1
0
1
0
1
0
1
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
1
1
1
1
1
1
1
0
0
0
0
1
1
1
1
0
0
1
1
0
0
1
1
0
0
0
0
0
0
0
0
1
1
1
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
1
1
1
1
0
0
0
0
0
0
0
0
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
0
0
0
0
1
1
1
1
8 7 6
3-bit IP
Precedence
6 MSb1 of ToS
0
1
2
3
4
5
6
7
1
1
1
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
1
1
1
0
0
1
1
0
0
1
1
0
1
0
1
0
1
0
1
32
33
34
35
36
37
38
39
0
1
0
1
0
1
0
1
8
9
10
11
12
13
14
15
1
1
1
1
1
1
1
1
0
0
0
0
0
0
0
0
1
1
1
1
1
1
1
1
0
0
0
0
1
1
1
1
0
0
1
1
0
0
1
1
0
1
0
1
0
1
0
1
40
41
42
43
44
45
46
47
0
0
1
1
0
0
1
1
0
1
0
1
0
1
0
1
16
17
18
19
20
21
22
23
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
1
1
1
1
0
0
1
1
0
0
1
1
0
1
0
1
0
1
0
1
48
49
50
51
52
53
54
55
0
0
1
1
0
0
1
1
0
1
0
1
0
1
0
1
24
25
26
27
28
29
30
31
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
0
0
0
0
1
1
1
1
0
0
1
1
0
0
1
1
0
1
0
1
0
1
0
1
56
57
58
59
60
61
62
63
6-bit
5 4 3 DSCP
8 7 6
6-bit
5 4 3 DSCP
Marking, according to RFC 2475, is the process of setting a Layer 3 DSCP value in a packet; in this
publication, the definition of marking is extended to include setting Layer 2 CoS values.
Scheduling is the assignment of Layer 2 frames to a queue. QoS assigns frames to a queue based on
internal DSCP values as shown in Internal DSCP Values, page 29-12.
Policing is limiting bandwidth used by a flow of traffic. Policing can mark or drop traffic.
29-4
OL-6696-01
Chapter 29
Configuring QoS
Overview of QoS
Classifying distinguishes one kind of traffic from another. The process generates an internal DSCP
for a packet, which identifies all the future QoS actions to be performed on this packet. For more
information, see the Classification section on page 29-5.
Policing determines whether a packet is in or out of profile by comparing the traffic rate to the
configured policer, which limits the bandwidth consumed by a flow of traffic. The result of this
determination is passed to the marker. For more information, see the Policing and Marking section
on page 29-9.
Marking evaluates the policer configuration information regarding the action to be taken when a
packet is out of profile and decides what to do with the packet (pass through a packet without
modification, mark down the DSCP value in the packet, or drop the packet). For more information,
see the Policing and Marking section on page 29-9.
Queueing evaluates the internal DSCP and determines which of the four egress queues in which to
place the packet.
Scheduling services the four egress (transmit) queues based on the sharing and shaping
configuration of the egress (transmit) port. Sharing and shaping configurations are described in the
Queueing and Scheduling section on page 29-13.
Classification
Generate DSCP
Policing
Actions at egress
In profile or
out of profile
Mark
Queueing and
scheduling
Based on the marked
DSCP, determine into
which of the egress
queues to place the
packet. Then service
the queues according
to the configured
weights.
68141
Classification
Classification is the process of distinguishing one kind of traffic from another by examining the fields
in the packet. Classification is enabled only if QoS is globally enabled on the switch. By default, QoS is
globally disabled, so no classification occurs.
You specify which fields in the frame or packet that you want to use to classify incoming traffic.
Classification options are shown in Figure 29-3.
29-5
Chapter 29
Configuring QoS
Overview of QoS
Use the port default. If the packet is a non-IP packet, assign the default port DSCP value to the
incoming packet.
Trust the CoS value in the incoming frame (configure the port to trust CoS). Then use the
configurable CoS-to-DSCP map to generate the internal DSCP value. Layer 2 ISL frame headers
carry the CoS value in the three least-significant bits of the 1-byte User field. Layer 2 802.1Q frame
headers carry the CoS value in the three most-significant bits of the Tag Control Information field.
CoS values range from 0 for low priority to 7 for high priority. If the frame does not contain a CoS
value, assign the default port CoS to the incoming frame.
The trust DSCP configuration is meaningless for non-IP traffic. If you configure a port with trust
DSCP and non-IP traffic is received, the switch assigns the default port DSCP.
Trust the IP DSCP in the incoming packet (configure the port to trust DSCP), and assign the same
DSCP to the packet for internal use. The IETF defines the six most-significant bits of the 1-byte
Type of Service (ToS) field as the DSCP. The priority represented by a particular DSCP value is
configurable. DSCP values range from 0 to 63.
Trust the CoS value (if present) in the incoming packet, and generate the DSCP by using the
CoS-to-DSCP map.
Perform the classification based on a configured IP standard or extended ACL, which examines
various fields in the IP header. If no ACL is configured, the packet is assigned the default DSCP
based on the trust state of the ingress port; otherwise, the policy map specifies the DSCP to assign
to the incoming frame.
For information on the maps described in this section, see the Mapping Tables section on page 29-13.
For configuration information on port trust states, see the Configuring the Trust State of Interfaces
section on page 29-40.
29-6
OL-6696-01
Chapter 29
Configuring QoS
Overview of QoS
Start
Read interface
configuration for classification.
Are there
Is there a
Yes
any more
QoS policy attached
traffic classes with
to this interface?
QoS
actions?
No
No
Yes
Does the
packet satisfy
the classification
match criteria?
No
Yes
Does the
Yes
policy action
specify DSCP for
this traffic
class
Use configured
DSCP in ACL
No
Is Trust
No configured for this
traffic class
Yes
Use Port Trust
configuration.
Yes
No
No
Trust
CoS?
IP
Packet?
Yes
No
Assign Port default
DSCP
Yes
Use Port
default DSCP
Packet
recieved with No
Tag (with
CoS)?
Use Port
CoS
Yes
Generate DSCP from CoS
using CoS to DSCP map
Done
63704
Trust
DSCP?
29-7
Chapter 29
Configuring QoS
Overview of QoS
Note
Note
When you use the IP standard and IP extended ACLs, the permit and deny ACEs in the ACL have a
slightly different meaning in the QoS context.
If a packet encounters (and satisfies) an ACE with a permit, then the packet matches the match
criterion in the QoS classification.
If a packet encounters (and satisfies) an ACE with a deny, then the packet does not match the
match criterion in the QoS classification.
If no match with a permit action is encountered and all the ACEs have been examined, then the
packet does not match the criterion in the QoS classification.
When creating an access list, remember that, by default, the end of the access list contains an implicit
deny statement for everything if it did not find a match before reaching the end.
After a traffic class has been defined with the class map, you can create a policy that defines the QoS
actions for a traffic class. A policy might contain multiple classes with actions specified for each one of
them. A policy might include commands to classify the class as a particular aggregate (for example,
assign a DSCP) or rate limit the class. This policy is then attached to a particular port on which it
becomes effective.
You implement IP ACLs to classify IP traffic by using the access-list global configuration command.
For configuration information, see the Configuring a QoS Policy section on page 29-28.
29-8
OL-6696-01
Chapter 29
Configuring QoS
Overview of QoS
You create a class map by using the class-map global configuration command. When you enter the
class-map command, the switch enters the class-map configuration mode. In this mode, you define the
match criteria for the traffic by using the match class-map configuration command.
You create and name a policy map by using the policy-map global configuration command. When you
enter this command, the switch enters the policy-map configuration mode. In this mode, you specify the
actions to take on a specific traffic class by using the trust or set policy-map configuration and
policy-map class configuration commands. To make the policy map effective, you attach it to an interface
by using the service-policy interface configuration command.
The policy map can also contain commands that define the policer, (the bandwidth limitations of the
traffic) and the action to take if the limits are exceeded. For more information, see the Policing and
Marking section on page 29-9.
A policy map also has these characteristics:
For configuration information, see the Configuring a QoS Policy section on page 29-28.
Individual
QoS applies the bandwidth limits specified in the policer separately to each matched traffic class for
each port/VLAN to which the policy map is attached to. You configure this type of policer within a
policy map by using the police command under policy-map class configuration mode.
Aggregate
QoS applies the bandwidth limits specified in an aggregate policer cumulatively to all matched
traffic flows. You configure this type of policer by specifying the aggregate policer name within a
policy map by using the police aggregate policy-map configuration command. You specify the
bandwidth limits of the policer by using the qos aggregate-policer global configuration command.
In this way, the aggregate policer is shared by multiple classes of traffic within a policy map.
Flow or Microflow
With flow-based policing, all the identified flows are policed to the specified rate individually.
Because the flows are dynamic, key distinguishing fields must be configured in class maps. Two
flow-matching options are provided: source ip based (each flow with unique source IP address is
treated as a new flow) and destination ip based (each flow with unique destination IP address is
treated as new flow). For information on flow-based policer configuration, see Configuring User
Based Rate Limiting on page 35.
29-9
Chapter 29
Configuring QoS
Overview of QoS
For IP packets, only the length of the IP payload (the total length field in the IP header) is used by
the policer for policing computation. The Layer 2 header and trailer length are not taken into
account. For example, for a 64-byte Ethernet II IP packet, only 46 bytes are taken into account for
policing (64 bytes - 14 byte Ethernet Header - 4 bytes Ethernet CRC).
For non-IP packets, the Layer 2 length as specified in the Layer 2 Header is used by the policer for
policing computation. To specify additional Layer 2 encapsulation length when policing IP packets,
use the qos account layer2 encapsulation command.
Only the average rate and committed burst parameters are configurable.
Policing for individual and aggregate policers can occur in ingress and egress interfaces.
With the Supervisor Engine V-10GE (WS-X4516-10GE), 8192 policers are supported on
Note
Policers can be of individual or aggregate type. On the Supervisor Engine V-10GE, flow-based
policers are supported.
Policing for flow policers can occur on ingress Layer 3 interfaces only.
512 unique flow policers can be configured on the Supervisor Engine V-10GE.
Note
Because one flow policer is reserved by software, 511 unique flow policers can be defined.
Greater than 100,000 flows can be microflow policed. For details, refer to the Checking for
Note
Microflow currently supports two flow matching options (source IP address based and
destination IP address based). When microflow policing is used together with Netflow Statistics
Collection, full flow statistics for the flows matching the source IP address or destination IP
address will not be available. For information on configuring Netflow Statistics, refer to
Enabling NetFlow Statistics Collection on page 7.
On an interface configured for QoS, all traffic received or sent through the interface is classified,
policed, and marked according to the policy map attached to the interface. However, if the interface
is configured to use VLAN-based QoS (using the qos vlan-based command), the traffic received or
sent through the interface is classified, policed, and marked according to the policy map attached to
the VLAN (configured on the VLAN interface) to which the packet belongs. If there is no policy
map attached to the VLAN to which the packet belongs, the policy map attached to the interface is
used.
After you configure the policy map and policing actions, attach the policy to an ingress or egress
interface by using the service-policy interface configuration command. For configuration information,
see the Configuring a QoS Policy section on page 29-28 and the Creating Named Aggregate Policers
section on page 29-26.
29-10
OL-6696-01
Chapter 29
Configuring QoS
Overview of QoS
Is there
a QoS Policy
attached to the
port?
Is the
port QoS VLANbased?
Yes
No
Yes
Is there a QoS
Policy attached to the
VLAN to which the
packet belongs
Is there a QoS
No
Policy attached to the
VLAN to which the
packet belongs
Yes
Yes
Use QoS
policy on
the VLAN
No
No
Use QoS
policy on
the port
Are there
any more QoS
ACLs in the
policy?
Yes
Does the
packet match a
"permit" ACB in
the ACL?
No
Yes
No
Are there
any more QoS
ACLs in the
policy?
Yes
Yes
No
Mark-down
Transmit
Done
Out of Profile
Action?
Mark-down
Drop
Drop
63703
Is the packet
in-profile for
the policer?
29-11
Chapter 29
Configuring QoS
Overview of QoS
For trust-CoS traffic, from received or ingress interface Layer 2 CoS values
The trust state of traffic is the trust state of the ingress interface unless set otherwise by a policy action
for this traffic class.
QoS uses configurable mapping tables to derive the internal 6-bit DSCP value from CoS, which are 3-bit
values (see theConfiguring DSCP Maps section on page 29-45).
Note
The internal ToS value can mimic an IP precedence value (see Table 29-1 on page 29-4).
For all egress traffic, QoS uses a configurable mapping table to derive a CoS value from the internal ToS
value associated with traffic (see the Configuring the DSCP-to-CoS Map section on page 29-47). QoS
sends the CoS value to be written into ISL and 802.1Q frames.
For traffic received on an ingress interface configured to trust CoS using the qos trust cos command, the
transmit CoS is always the incoming packet CoS (or the ingress interface default CoS if the packet is
received untagged).
When the interface trust state is not configured to trust dscp using the qos trust dscp command, the
security and QoS ACL classification will always use the interface DSCP and not the incoming packet
DSCP.
29-12
OL-6696-01
Chapter 29
Configuring QoS
Overview of QoS
Mapping Tables
During QoS processing, the switch represents the priority of all traffic (including non-IP traffic) with an
internal DSCP value:
During classification, QoS uses configurable mapping tables to derive the internal DSCP (a 6-bit
value) from received CoS. These maps include the CoS-to-DSCP map.
During policing, QoS can assign another DSCP value to an IP or non-IP packet (if the packet is out
of profile and the policer specifies a marked down DSCP value). This configurable map is called the
policed-DSCP map.
Before the traffic reaches the scheduling stage, QoS uses the internal DSCP to select one of the four
egress queues for output processing. The DSCP-to-egress queue mapping can be configured using
the qos map dscp to tx-queue command.
The CoS-to-DSCP and DSCP-to-CoS map have default values that might or might not be appropriate for
your network.
For configuration information, see the Configuring DSCP Maps section on page 29-45.
29-13
Chapter 29
Configuring QoS
Overview of QoS
For systems using Supervisor Engine V, bandwidth can be configured on all ports (10/100 Fast Ethernet,
10/100/1000BASE-T, and 1000BASE-X).
Traffic Shaping
Traffic Shaping provides the ability to control the rate of outgoing traffic in order to make sure that the
traffic conforms to the maximum rate of transmission contracted for it. Traffic that meets certain profile
can be shaped to meet the downstream traffic rate requirements to handle any data rate mismatches.
Each transmit queue can be configured to transmit a maximum rate using the shape command. The
configuration allows you to specify the maximum rate of traffic. Any traffic that exceeds the configured
shape rate will be queued and transmitted at the configured rate. If the burst of traffic exceeds the size
of the queue, packets will be dropped to maintain transmission at the configured shape rate.
29-14
OL-6696-01
Chapter 29
Configuring QoS
Overview of QoS
Packet Modification
A packet is classified, policed, and queued to provide QoS. Packet modifications can occur during this
process:
For IP packets, classification involves assigning a DSCP to the packet. However, the packet is not
modified at this stage; only an indication of the assigned DSCP is carried along. The reason for this
is that QoS classification and ACL lookup occur in parallel, and it is possible that the ACL specifies
that the packet should be denied and logged. In this situation, the packet is forwarded with its
original DSCP to the CPU, where it is again processed through ACL software.
For non-IP packets, classification involves assigning an internal DSCP to the packet, but because
there is no DSCP in the non-IP packet, no overwrite occurs. Instead, the internal DSCP is used both
for queueing and scheduling decisions and for writing the CoS priority value in the tag if the packet
is being transmitted on either an ISL or 802.1Q trunk port.
During policing, IP and non-IP packets can have another DSCP assigned to them (if they are out of
profile and the policer specifies a markdown DSCP). Once again, the DSCP in the packet is not
modified, but an indication of the marked-down value is carried along. For IP packets, the packet
modification occurs at a later stage.
29-15
Chapter 29
Configuring QoS
Configuring Auto-QoS
Configuring Auto-QoS
You can use the auto-QoS feature to simplify the deployment of existing QoS features. Auto-QoS makes
assumptions about the network design, and as a result, the switch can prioritize different traffic flows
and appropriately use the egress queues instead of using the default QoS behavior. (The default is that
QoS is disabled. The switch then offers best-effort service to each packet, regardless of the packet
content or size, and sends it from a single queue.)
When you enable auto-QoS, it automatically classifies traffic based on ingress packet label. The switch
uses the resulting classification to choose the appropriate egress queue.
You use auto-QoS commands to identify ports connected to Cisco IP phones and to identify ports that
receive trusted voice over IP (VoIP) traffic through an uplink. Auto-QoS then performs these functions:
When you enter the auto qos voip trust interface configuration command, the ingress classification
on the specified interface is set to trust the CoS label received in the packet if the specified interface
is configured as Layer 2 (and is set to trust DSCP if the interface is configured as Layer 3). (See
Table 29-2.)
When you enter the auto qos voip cisco-phone interface configuration command, the trusted
boundary feature is enabled. It uses the Cisco Discovery Protocol (CDP) to detect the presence or
absence of a Cisco IP phone. When a Cisco IP phone is detected, the ingress classification on the
interface is set to trust the cos label received in the packet, if the interface is configured as Layer 2.
(The classification is set to trust DSCP if the interface is configured as Layer 3.) When a Cisco IP
phone is absent, the ingress classification is set to not trust the cos label in the packet.
For information about the trusted boundary feature, see the Configuring a Trusted Boundary to
Ensure Port Security section on page 29-24.
When you enable auto-QoS by using the auto qos voip cisco-phone or the auto qos voip trust interface
configuration commands, the switch automatically generates a QoS configuration based on the traffic
type and ingress packet label and applies the commands listed in Table 29-2 to the interface.
29-16
OL-6696-01
Chapter 29
Configuring QoS
Configuring Auto-QoS
Description
Switch(config)#
Switch(config)#
Switch(config)#
Switch(config)#
Switch(config-if)# tx-queue
Switch(config-if-tx-queue)#
Switch(config-if-tx-queue)#
Switch(config-if-tx-queue)#
qos
qos map cos 3 to 26
qos dbl
qos map cos 5 to 46
3
priority high
shape percent 33
bandwidth percent 33
Configuration Guidelines
Before configuring auto-QoS, you should be aware of this information:
In this release, auto-QoS configures the switch only for VoIP with Cisco IP phones.
To take advantage of the auto-QoS defaults, do not configure any standard-QoS commands before
entering the auto-QoS commands. If necessary, you can fine-tune the QoS configuration, but we
recommend that you do so only after the auto-QoS configuration is completed.
You can enable auto-QoS on static, dynamic-access, voice VLAN access, and trunk ports.
By default, the CDP is enabled on all interfaces. For auto-QoS to function properly, do not disable
the CDP.
To enable auto qos voip trust on Layer 3 interfaces, change the port to Layer 3, then apply auto-QoS
to make it trust DSCP.
29-17
Chapter 29
Configuring QoS
Configuring Auto-QoS
Purpose
Step 1
Step 2
Step 3
Step 4
Enables auto-QoS.
The keywords have these meanings:
Step 5
Switch(config)# end
Step 6
To disable auto-QoS on an interface, use the no auto qos voip interface configuration command. When
you enter this command, the switch changes the auto-QoS settings to the standard-QoS default settings
for that interface. It will not change any global configuration performed by auto-QoS. Global
configuration remains the same.
This example shows how to enable auto-QoS and to trust the CoS labels in incoming packets when the
device connected to Fast Ethernet interface 1/1 is detected as a Cisco IP phone:
Switch(config)# interface fastethernet1/1
Switch(config-if)# auto qos voip cisco-phone
This example shows how to enable auto-QoS and to trust the cos/dscp labels in incoming packets when
the switch or router connected to Gigabit Ethernet interface 1/1 is a trusted device:
Switch(config)# interface gigabitethernet1/1
Switch(config-if)# auto qos voip trust
29-18
OL-6696-01
Chapter 29
Configuring QoS
Configuring Auto-QoS
This example shows how to display the QoS commands that are automatically generated when auto-QoS
is enabled:
Switch# debug auto qos
AutoQoS debugging is on
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface gigabitethernet1/1
Switch(config-if)# auto qos voip cisco-phone
show qos
For more information about these commands, refer to the command reference for this release.
29-19
Chapter 29
Configuring QoS
Configuring Auto-QoS
Cisco router
To Internet
Gigabit Ethernet 1/1
Catalyst 4500 switch
Gigabit Ethernet 2/2
Trunk
link
Gigabit
Ethernet
2/1
Catalyst
4500 switch
Gigabit
Ethernet 1/1
IP
IP
IP
Gigabit
Ethernet
1/1
IP
Catalyst 4500 switch
at the edge of the
QoS domain
IP
Cisco IP phones
94183
End stations
Catalyst
4500 switch
Gigabit
Ethernet 1/1
Gigabit
Ethernet
1/2
Video server
172.20.10.16
The intelligent wiring closets in Figure 29-5 are composed of Catalyst 4500 switches. The object of this
example is to prioritize the VoIP traffic over all other traffic. To do so, enable auto-QoS on the switches
at the edge of the QoS domains in the wiring closets.
Note
You should not configure any standard QoS commands before entering the auto-QoS commands. You
can fine-tune the QoS configuration, but we recommend that you do so only after the auto-QoS
configuration is completed.
29-20
OL-6696-01
Chapter 29
Configuring QoS
Configuring Auto-QoS
To configure the switch at the edge of the QoS domain to prioritize the VoIP traffic over all other traffic,
perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config)# interface
fastethernet2/3
Step 5
Step 6
Switch(config)# interface
fastethernet2/5
Step 7
Step 8
Switch(config)# interface
fastethernet2/7
Step 9
Step 10
Switch(config)# interface
gigabit1/1
Step 11
Step 12
Switch(config)# end
Step 13
Step 14
Step 15
29-21
Chapter 29
Configuring QoS
Configuring QoS
Configuring QoS
Before configuring QoS, you must have a thorough understanding of these items:
The types of applications used and the traffic patterns on your network.
Traffic characteristics and needs of your network. Is the traffic bursty? Do you need to reserve
bandwidth for voice and video streams?
These sections describe how to configure QoS on the Catalyst 4000 family switch:
Feature
Default Value
Disabled
29-22
OL-6696-01
Chapter 29
Configuring QoS
Configuring QoS
Feature
Default Value
CoS 0 = DSCP 0
CoS 1 = DSCP 8
CoS 2 = DSCP 16
CoS 3 = DSCP 24
CoS 4 = DSCP 32
CoS 5 = DSCP 40
CoS 6 = DSCP 48
CoS 7 = DSCP 56
DSCP 07 = CoS 0
DSCP 815 = CoS 1
DSCP 1623 = CoS 2
DSCP 2431 = CoS 3
DSCP 3239 = CoS 4
DSCP 4047 = CoS 5
DSCP 4855 = CoS 6
DSCP 5663 = CoS 7
Policers
None
Policy maps
None
1/4 of the transmit queue entries for the port. The transmit queue size of a
port depends on the type of port, ranging from 240 packets per transmit
queue to 1920 packets per transmit queue.
None
Disabled
Trust DSCP
With QoS enabled and all other QoS parameters at default values, QoS sets
IP DSCP to zero and Layer 2 CoS to zero in all traffic transmitted.
Untrusted
29-23
Chapter 29
Configuring QoS
Configuring QoS
Configuration Guidelines
Before beginning the QoS configuration, you should be aware of this information:
Note
If you have EtherChannel ports configured on your switch, you must configure QoS classification
and policing on the EtherChannel. The transmit queue configuration must be configured on the
individual physical ports that comprise the EtherChannel.
It is not possible to match IP fragments against configured IP extended ACLs to enforce QoS. IP
fragments are transmitted as best effort. IP fragments are denoted by fields in the IP header.
It is not possible to match IP options against configured IP extended ACLs to enforce QoS. These
packets are sent to the CPU and processed by software. IP options are denoted by fields in the IP
header.
Control traffic (such as spanning-tree BPDUs and routing update packets) received by the switch are
subject to all ingress QoS processing.
If you want to use the set command in the policy map, you must enable IP routing (disabled by
default) and configure an IP default route to send traffic to the next-hop device that is capable of
forwarding.
Step 1
Command
Purpose
Switch(config)# qos
Step 2
Switch(config)# end
Step 3
29-24
OL-6696-01
Chapter 29
Configuring QoS
Configuring QoS
(CoS) 3-bit field, which determines the priority of the packet. For most Cisco IP phone configurations,
the traffic sent from the telephone to the switch is trusted to ensure that voice traffic is properly
prioritized over other types of traffic in the network. By using the qos trust cos interface configuration
command, you can configure the switch port to which the telephone is connected to trust the CoS labels
of all traffic received on that port.
In some situations, you also might connect a PC or workstation to the IP phone. In this case, you can use
the switchport priority extend cos interface configuration command to configure the telephone through
the switch CLI to override the priority of the traffic received from the PC. With this command, you can
prevent a PC from taking advantage of a high-priority data queue.
However, if a user bypasses the telephone and connects the PC directly to the switch, the CoS labels
generated by the PC are trusted by the switch (because of the trusted CoS setting) and can allow misuse
of high-priority queues. The trusted boundary feature solves this problem by using the CDP to detect the
presence of a Cisco IP phone (such as the Cisco IP Phone 7910, 7935, 7940, and 7960) on a switch port.
Note
If CDP is not running on the switch globally or on the port in question, trusted boundary will not work.
When you configure trusted boundary on a port, trust is disabled. Then, when a phone is plugged in and
detected, trust is enabled. (It may take a few minutes to detect the phone.) Now, when a phone is
unplugged (and not detected), the trusted boundary feature disables the trusted setting on the switch port
and prevents misuse of a high-priority queue.
To enable trusted boundary on a port, perform this task:
Command
Purpose
Step 1
Step 2
Switch(config)# interface
interface-id
Step 3
Step 4
Step 5
Switch(config)# end
Step 6
Step 7
To disable the trusted boundary feature, use the no qos trust device cisco-phone interface configuration
command.
29-25
Chapter 29
Configuring QoS
Configuring QoS
Step 1
Command
Purpose
Step 2
Switch(config)# end
Step 3
Purpose
An aggregate policer can be applied to one or more interfaces. However, if you apply the same policer
to the input direction on one interface and to the output direction on a different interface, then you have
created the equivalent of two different aggregate policers in the switching engine. Each policer has the
same policing parameters, with one policing the ingress traffic on one interface and the other policing
the egress traffic on another interface. If an aggregate policer is applied to multiple interfaces in the same
direction, then only one instance of the policer is created in the switching engine.
Similarly, an aggregate policer can be applied to a port or to a VLAN. If you apply the same aggregate
policer to a port and to a VLAN, then you have created the equivalent of two different aggregate policers
in the switching engine. Each policer has the same policing parameters, with one policing the traffic on
the configured port and the other policing the traffic on the configured VLAN. If an aggregate policer is
applied to only ports or only VLANs, then only one instance of the policer is created in the switching
engine.
29-26
OL-6696-01
Chapter 29
Configuring QoS
Configuring QoS
In effect, if you apply a single aggregate policer to ports and VLANs in different directions, then you
have created the equivalent of four aggregate policers; one for all ports sharing the policer in input
direction, one for all ports sharing the policer in output direction, one for all VLANs sharing the policer
in input direction and one for all VLANs sharing the policer in output direction.
When creating a named aggregate policer, note the following:
Rates can be entered in bits-per-second, or you can use the following abbreviations:
k to denote 1000 bps
m to denote 1000000 bps
g to denote 1000000000 bps
Note
You can also use a decimal point. For example, a rate of 1,100,000 bps can be entered
as 1.1m.
Bursts can be entered in bytes, or you can use the following abbreviation:
k to denote 1000 bytes
m to denote 1000000 bytes
g to denote 1000000000 bytes
Note
You can also use a decimal point. For example, a burst of 1,100,000 bytes can be entered
as 1.1m.
Optionally, you can specify a conform action for matched in-profile traffic as follows:
The default conform action is transmit.
Enter the drop keyword to drop all matched traffic.
Note
When you configure drop as the conform action, QoS configures drop as the exceed action.
Optionally, for traffic that exceeds the CIR, you can specify an exceed action as follows:
The default exceed action is drop.
Enter the policed-dscp-transmit keyword to cause all matched out-of-profile traffic to be
You can enter the no qos aggregate-policer policer_name command to delete a named aggregate
policer.
29-27
Chapter 29
Configuring QoS
Configuring QoS
This example shows how to create a named aggregate policer with a 10 Mbps rate limit and a 1-MB burst
size that transmits conforming traffic and marks down out-of-profile traffic.
Switch(config)# qos aggregate-policer aggr-1 10000000 1000000 conform-action transmit
exceed-action policed-dscp-transmit
Switch(config)# end
Switch#
Note
access-list (optional for IP trafficyou can filter IP traffic with class-map commands):
QoS supports these access list types:
Protocol
IP
Yes:
1 to 99
1300 to 1999
Yes:
100 to 199
2000 to 2699
Yes
See Chapter 35, Configuring Network Security with ACLs, for information about ACLs on
class-map (optional)Enter the class-map command to define one or more traffic classes by
specifying the criteria by which traffic is classified. (See the Configuring a Class Map (Optional)
section on page 29-29.)
29-28
OL-6696-01
Chapter 29
Configuring QoS
Configuring QoS
policy-mapEnter the policy-map command to define the following for each class of traffic:
Internal DSCP source
Aggregate or individual policing and marking
Enter the class-map configuration command to define a traffic class and the match criteria that will be
used to identify traffic as belonging to that class. Match statements can include criteria such as an ACL,
an IP precedence value, or a DSCP value. The match criteria are defined with one match statement
entered within the class-map configuration mode.
Purpose
Purpose
29-29
Chapter 29
Configuring QoS
Configuring QoS
Note
Any Input or Output policy that uses a class map with the match ip precedence or match ip dscp
class-map commands, requires that the port on which the packet is received, be configured to trust dscp.
If the incoming port trust state is not set to trust dscp, the IP packet DSCP/IP-precedence is not used
for matching the traffic; instead the receiving ports default DSCP is used.
Note
The interfaces on the Catalyst 4000 family switch do not support the match classmap, match
destination-address, match input-interface, match mpls, match not, match protocol, match
qos-group, and match source-address keywords.
Purpose
Step 1
Step 2
This example shows how to create a class map named ipp5 and how to configure filtering to match traffic
with IP precedence 5:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# class-map ipp5
Switch(config-cmap)# match ip precedence 5
Switch(config-cmap)# end
Switch#
29-30
OL-6696-01
Chapter 29
Configuring QoS
Configuring QoS
Purpose
Purpose
When configuring the policy-map class trust state, note the following:
You can enter the no trust command to use the trust state configured on the ingress interface (this
is the default).
With the cos keyword, QoS sets the internal DSCP value from received or interface CoS.
To configure the policy map class DBL state, perform this task:
Command
Purpose
29-31
Chapter 29
Configuring QoS
Configuring QoS
When configuring the policy-map class DBL state, note the following:
Any class that uses a named aggregate policer must have the same DBL configuration to work.
To use a named aggregate policer (see the Creating Named Aggregate Policers section on page 29-26),
perform this task:
Command
Purpose
To configure a per-interface policer (see the Policing and Marking section on page 29-9), perform this
task:
Command
Purpose
Note
Rates can be entered in bits-per-second, or you can use the following abbreviations:
k to denote 1000 bps
m to denote 1000000 bps
g to denote 1000000000 bps
Note
You can also use a decimal point. For example, a rate of 1,100,000 bps can be entered
as 1.1m.
29-32
OL-6696-01
Chapter 29
Configuring QoS
Configuring QoS
Bursts can be entered in bytes, or you can use the following abbreviation:
k to denote 1000 bytes
m to denote 1000000 bytes
g to denote 1000000000 bytes
Note
You can also use a decimal point. For example, a burst of 1,100,000 bytes can be entered
as 1.1m.
Optionally, you can specify a conform action for matched in-profile traffic as follows:
The default conform action is transmit.
You can enter the drop keyword to drop all matched traffic.
Optionally, for traffic that exceeds the CIR, you can enter the policed-dscp-transmit keyword to
cause all matched out-of-profile traffic to be marked down as specified in the markdown map. See
Configuring the Policed-DSCP Map section on page 29-46.
For no policing, you can enter the transmit keyword to transmit all matched out-of-profile
traffic.
This example shows how to create a policy map named ipp5-policy that uses the class map named ipp5.
The class map ipp5 is configured to rewrite the packet precedence to 6 and to aggregate police the traffic
that matches IP precedence value of 5:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# policy-map ipp5-policy
Switch(config-pmap)# class ipp5
Switch(config-pmap-c)# set ip precedence 6
Switch(config-pmap-c)# dbl
Switch(config-pmap-c)# police 2000000000 2000000 conform-action transmit exceed-action
policed-dscp-transmit
Switch(config-pmap-c)# end
Step 1
Command
Purpose
Switch(config-pmap-c)# end
Step 2
29-33
Chapter 29
Configuring QoS
Configuring QoS
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# end
Step 4
This example shows how to attach the policy map named pmap1 to Fast Ethernet interface 5/36:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface fastethernet 5/36
Switch(config-if)# service-policy input pmap1
Switch(config-if)# end
29-34
OL-6696-01
Chapter 29
Configuring QoS
Configuring QoS
Note
Flow policers (and UBRL) are supported only on the Supervisor Engine V-10GE. Flow policers are
supported only in the input direction and on Layer 3 interfaces. You can configure up to 511 unique flow
policers and can microflow police more than 100,000 flows.
When you specify the match flow command with the source-address keyword, each flow with a unique
source address is treated as a new flow. When you specify the match flow command with the
destination-address keyword, each flow with a unique destination address is treated as a new flow. If
the class map used by the policy map has any flow options configured, it is treated as a flow-based policy
map.
To configure the flow-based class maps and policy maps, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Switch(config-cmap)# end
Step 4
This example shows how to create a flow-based class map associated with a source address:
Switch(config)# class-map match-all c1
Switch(config-cmap)# match flow ip source-address
Switch(config-cmap)# end
Switch#
Switch# show class-map c1
Class Map match-all c1 (id 2)
Match flow ip source-address
This example shows how to create a flow-based class map associated with a destination address:
Switch(config)# class-map match-all c1
Switch(config-cmap)# match flow ip destination-address
Switch(config-cmap)# end
Switch#
Switch# show class-map c1
Class Map match-all c1 (id 2)
Match flow ip destination-address
29-35
Chapter 29
Configuring QoS
Configuring QoS
Assume there are two active flows on the Fast Ethernet interface 6/1 with source addresses
192.168.10.20 and 192.168.10.21. The following example shows how to maintain each flow at 1 Mbps
with an allowed burst value of 9000 bytes:
Switch# conf t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# class-map c1
Switch(config-cmap)# match flow ip source-address
Switch(config-cmap)# exit
Switch(config)# policy-map p1
Switch(config-pmap)# class c1
Switch(config-pmap-c)# police 1000000 9000
Switch(config-pmap-c)# exit
Switch(config-pmap)# exit
Switch(config)# interface fa6/1
Switch(config-if)# service-policy input p1
Switch(config-if)# end
Switch# write memory
Switch# show policy-map interface
FastEthernet6/1
Service-policy input: p1
Class-map: c1 (match-all)
15432182 packets
Match: flow ip source-address
police: Per-interface
Conform: 64995654 bytes Exceed: 2376965424 bytes
Class-map: class-default (match-any)
0 packets
Match: any
0 packets
Assume there are two active flows on the Fast Ethernet interface 6/1 with destination addresses of
192.168.20.20 and 192.168.20.21. The following example shows how to maintain each flow at 1 Mbps
with an allowed burst value of 9000 byte:
Switch# conf t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# class-map c1
Switch(config-cmap)# match flow ip destination-address
Switch(config-cmap)# exit
Switch(config)# policy-map p1
Switch(config-pmap)# class c1
Switch(config-pmap-c)# police 1000000 9000
Switch(config-pmap-c)# exit
Switch(config-pmap)# exit
Switch(config)# interface fa6/1
Switch(config-if)# service-policy input p1
Switch(config-if)# end
Switch# write memory
Switch# show policy-map interface
FastEthernet6/1
Service-policy input: p1
29-36
OL-6696-01
Chapter 29
Configuring QoS
Configuring QoS
Class-map: c1 (match-all)
2965072 packets
Match: flow ip destination-address
police: Per-interface
Conform: 6105636 bytes Exceed: 476652528 bytes
Class-map: class-default (match-any)
0 packets
Match: any
0 packets
Hierarchical policers
You can tie flow policers with the existing policers to create dual policing rates on an interface. For
example, using dual policing, you can limit all incoming traffic rates on a given interface to 50 Mbps
and can limit the rate of each flow that is part of this traffic to 2 Mbps.
You can configure hierarchical policers with the service-policy policy-map config command. A policy
map is termed flow-based if the class map it uses matches any of the flow-based match criteria
(such as match flow ip source-address). Each child policy map inherits all the match access-group
commands of the parent.
NoteYou can configure only flow-based policy maps as child policy maps. A parent policy map cannot be a
flow-based policy map. Both the child policy map and parent policy map must have match-all in their
class-map configuration.
To configure a flow-based policy map as a child of an individual or aggregate policer, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Switch(config-flow-cache)# service-policy
service_policy_name
This example shows how to create a hierarchical policy map. A policy map with the name
aggregate-policy has a class map with the name aggregate-class. A flow-based policy map with the name
flow-policy is attached to this policy map as a child policy map.
Switch(config)#
Switch(config)# policy-map aggregate-policy
Switch(config-pmap)# class aggregate-class
Switch(config-pmap-c)# service-policy flow-policy
Switch(config-pmap-c)# end
Switch#
In the following example, traffic in the IP address range of 101.237.0.0 to 101.237.255.255 is policed to
50 Mbps. Flows ranging from 101.237.10.0 to 101.237.10.255 are individually policed to a rate of 2
Mbps. This traffic goes through two policers: the aggregate policer and the other flow-based policer.
29-37
Chapter 29
Configuring QoS
Configuring QoS
29-38
OL-6696-01
Chapter 29
Configuring QoS
Configuring QoS
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# end
Step 4
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# end
Step 4
29-39
Chapter 29
Configuring QoS
Configuring QoS
Note
If no input QoS policy is attached to a Layer 2 interface, then the input QoS policy attached to the VLAN
(on which the packet is received), if any, is used even if the port is not configured as VLAN-based. If
you do not want this default, attach a placeholder input QoS policy to the Layer 2 interface. Similarly,
if no output QoS policy is attached to a Layer 2 interface, then the output QoS policy attached to the
VLAN (on which the packet is transmitted), if any, is used even if the port is not configured as
VLAN-based. If you do not want this default, attach a placeholder output QoS policy to the layer 2
interface.
This example shows how to configure VLAN-based QoS on Fast Ethernet interface 5/42:
Switch# configure terminal
Enter configuration commands, one per line.
Switch(config)# interface fastethernet 5/42
Switch(config-if)# qos vlan-based
Switch(config-if)# end
Note
When a layer 2 interface is configured with VLAN-based QoS, and if a packet is received on the port for
a VLAN on which there is no QoS policy, then the QoS policy attached to the port, if any is used. This
applies for both Input and Output QoS policies.
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# end
Step 4
29-40
OL-6696-01
Chapter 29
Configuring QoS
Configuring QoS
You can use the no qos trust command to set the interface state to untrusted.
For traffic received on an ingress interface configured to trust CoS using the qos trust cos command,
the transmit CoS is always the incoming packet CoS (or the ingress interface default CoS if the
packet is received untagged).
When the interface trust state is not configured to trust dscp using the qos trust dscp command, the
security and QoS ACL classification will always use the interface DSCP and not the incoming
packet DSCP.
This example shows how to configure Gigabit Ethernet interface 1/1 with the trust cos keywords:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface gigabitethernet 1/1
Switch(config-if)# qos trust cos
Switch(config-if)# end
Switch#
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# end
Step 4
This example shows how to configure the CoS 5 as the default on Fast Ethernet interface 5/24:
Switch# configure terminal
Enter configuration commands, one per line.
Switch(config)# interface fastethernet 5/24
Switch(config-if)# qos cos 5
Switch(config-if)# end
Switch#
29-41
Chapter 29
Configuring QoS
Configuring QoS
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# end
Step 4
This example shows how to configure the DSCP 5 as the default on Fast Ethernet interface 5/24:
Switch# configure terminal
Enter configuration commands, one per line.
Switch(config)# interface fastethernet 5/24
Switch(config-if)# qos dscp 5
Switch(config-if)# end
Switch#
Bandwidth
(bps)
31250000
31250000
31250000
31250000
ShapeRate
(bps)
disabled
disabled
disabled
disabled
Priority
N/A
N/A
normal
N/A
QueueSize
(packets)
240
240
240
240
29-42
OL-6696-01
Chapter 29
Configuring QoS
Configuring QoS
Depending on the complexity of your network and your QoS solution, you might need to perform all of
the procedures in the next sections, but first you will need to make decisions about these characteristics:
What is the size of a transmit queue relative to other queues for a given port?
What is the maximum rate and burst of traffic that can be transmitted out of each transmit queue?
Step 1
Command
Purpose
Step 2
Switch(config)# end
Step 3
29-43
Chapter 29
Configuring QoS
Configuring QoS
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config-if-tx-queue)# end
Step 5
This example shows how to configure the bandwidth of 1 Mbps on transmit queue 2.
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface gigabitethernet 1/1
Switch(config-if)# tx-queue 2
Switch(config-if-tx-queue)#bandwidth 1000000
Switch(config-if-tx-queue)# end
Switch#
Purpose
Step 1
Step 2
Step 3
29-44
OL-6696-01
Chapter 29
Configuring QoS
Configuring QoS
Command
Purpose
Step 4
Switch(config-if-tx-queue)# end
Step 5
This example shows how to configure the shape rate to 1 Mbps on transmit queue 2.
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface gigabitethernet 1/1
Switch(config-if-tx-queue)# tx-queue 2
Switch(config-if-tx-queue)# shape 1000000
Switch(config-if-tx-queue)# end
Switch#
Purpose
Step 1
Step 2
Switch(config-if)# tx-queue 3
Step 3
Step 4
Switch(config-if)# end
Step 5
All the maps are globally defined and are applied to all ports.
29-45
Chapter 29
Configuring QoS
Configuring QoS
CoS value
DSCP value
16
24
32
40
48
56
If these values are not appropriate for your network, you need to modify them.
To modify the CoS-to-DSCP map, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
Step 4
Step 5
To return to the default map, use the no qos cos to dscp global configuration command.
This example shows how to modify and display the CoS-to-DSCP map:
Switch# configure terminal
Switch(config)# qos map cos 0 to dscp 20
Switch(config)# end
Switch# show qos maps cos dscp
CoS-DSCP Mapping Table:
CoS: 0
1 2 3 4 5 6 7
-------------------------------DSCP: 20 8 16 24 32 40 48 56
Switch(config)#
29-46
OL-6696-01
Chapter 29
Configuring QoS
Configuring QoS
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
Step 4
Step 5
To return to the default map, use the no qos dscp policed global configuration command.
This example shows how to map DSCP 50 to 57 to a marked-down DSCP value of 0:
Switch# configure terminal
Switch(config)# qos map dscp policed 50 51 52 53 54 55 56 57 to dscp 0
Switch(config)# end
Switch# show qos maps dscp policed
Policed-dscp map:
d1 : d2 0 1 2 3 4 5 6 7 8 9
--------------------------------------0 :
00 01 02 03 04 05 06 07 08 09
1 :
10 11 12 13 14 15 16 17 18 19
2 :
20 21 22 23 24 25 26 27 28 29
3 :
30 31 32 33 34 35 36 37 38 39
4 :
40 41 42 43 44 45 46 47 48 49
5 :
00 00 00 00 00 00 00 00 58 59
6 :
60 61 62 63
Note
In the above policed-DSCP map, the marked-down DSCP values are shown in the body of the matrix.
The d1 column specifies the most-significant digit of the original DSCP; the d2 row specifies the
least-significant digit of the original DSCP. The intersection of the d1 and d2 values provides the
marked-down value. For example, an original DSCP value of 53 corresponds to a marked-down DSCP
value of 0.
DSCP value
07
815
1623
2431
3239
4047
4855
5663
CoS value
If the values above are not appropriate for your network, you need to modify them.
29-47
Chapter 29
Configuring QoS
Configuring QoS
Purpose
Step 1
Step 2
For cos, enter only one CoS value to which the DSCP values
correspond.
Switch(config)# end
Step 4
Step 5
To return to the default map, use the no qos dscp to cos global configuration command.
This example shows how to map DSCP values 0, 8, 16, 24, 32, 40, 48, and 50 to CoS value 0 and to
display the map:
Switch# configure terminal
Switch(config)# qos map dscp 0 8 16 24 32 40 48 50 to cos 0
Switch(config)# end
Switch# show qos maps dscp cos
Dscp-cos map:
d1 : d2 0 1 2 3 4 5 6 7 8 9
--------------------------------------0 :
00 00 00 00 00 00 00 00 00 01
1 :
01 01 01 01 01 01 00 02 02 02
2 :
02 02 02 02 00 03 03 03 03 03
3 :
03 03 00 04 04 04 04 04 04 04
4 :
00 05 05 05 05 05 05 05 00 06
5 :
00 06 06 06 06 06 07 07 07 07
6 :
07 07 07 07
Note
In the above DSCP-to-CoS map, the CoS values are shown in the body of the matrix. The d1 column
specifies the most-significant digit of the DSCP; the d2 row specifies the least-significant digit of the
DSCP. The intersection of the d1 and d2 values provides the CoS value. For example, in the
DSCP-to-CoS map, a DSCP value of 08 corresponds to a CoS value of 0.
29-48
OL-6696-01
C H A P T E R
30
Note
Configuring Voice Ports for Voice and Data Traffic, page 30-2
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Port 1 connects to the Catalyst 4500 series switch or other device that supports voice-over-IP.
30-1
Chapter 30
Figure 30-1 Cisco 7960 IP Phone Connected to a Catalyst 4500 Series Switch
IP Phone
PC
105247
IP
All traffic is transmitted according to the default CoS priority of the port. This is the default.
Voice traffic is given a higher priority by the phone (CoS priority is always 5), and all traffic is in
the same VLAN.
To configure a port to instruct the phone to give voice traffic a higher priority and to forward all traffic
through the 802.1Q native VLAN, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config-if)# end
Step 5
Note
See the Using 802.1X with Voice VLAN Ports section on page 31-10 for information about
using 802.1X with voice VLANs.
30-2
OL-6696-01
Chapter 30
To configure a port to receive voice and data from a Cisco IP Phone on different VLANs, perform this
task:
Command
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config-if)# end
Step 5
In the following example, VLAN 1 carries data traffic, and VLAN 2 carries voice traffic. In this
configuration, you must connect all Cisco IP phones and other voice-related devices to switch ports that
belong to VLAN 2.
Switch# configure terminal
Switch(config)# interface fastethernet 2/5
SSwitch(config-if)# switchport voice vlan 2
switchport voice vlan 2
Switch(config-if)# end
Switch# show interface fastethernet 2/5 switchport
show interface fastethernet 2/5 switchport
Name:Fa2/5
Switchport:Enabled
Administrative Mode:dynamic auto
Operational Mode:down
Administrative Trunking Encapsulation:negotiate
Negotiation of Trunking:On
Access Mode VLAN:1 (default)
Trunking Native Mode VLAN:1 (default)
Voice VLAN:2 ((Inactive))
Appliance trust:none
Administrative private-vlan host-association:none
Administrative private-vlan mapping:none
Operational private-vlan:none
Trunking VLANs Enabled:ALL
Pruning VLANs Enabled:2-1001
Switch#
30-3
Chapter 30
To override the CoS priority setting received from the non-voice port on the Cisco 7960 IP phone,
perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config-if)# end
Step 5
30-4
OL-6696-01
C H A P T E R
31
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Note
802.1X support requires an authentication server that is configured for Remote Authentication Dial-In
User Service (RADIUS). 802.1X authentication does not work unless the network access switch can
route packets to the configured authentication RADIUS server. To verify that the switch can route
packets, you must ping the server from the switch.
31-1
Chapter 31
802.1X defines 802.1X port-based authentication as a client-server based access control and
authentication protocol that restricts unauthorized clients from connecting to a LAN through publicly
accessible ports. An authentication server validates each supplicant (client) connected to an
authenticator (network access switch) port before making available any services offered by the switch or
the LAN.
Until a client is authenticated, only Extensible Authentication Protocol over LAN (EAPOL) traffic is
allowed through the port to which the client is connected. Once authentication succeeds, normal traffic
can pass through the port.
Device Roles
With 802.1X port-based authentication, network devices have specific roles. Figure 31-1 shows the roles
of each device.
Figure 31-1 802.1X Device Roles
Supplicants
Authenticator
RADIUS
Authentication
server
ClientThe workstation that requests access to the LAN, and responds to requests from the switch.
The workstation must be running 802.1X-compliant client software.
Note
94158
Client
Workstations
AuthenticatorControls physical access to the network based on the authentication status of the
client. The switch acts as an intermediary between the client and the authentication server,
requesting identity information from the client, verifying that information with the authentication
server, and relaying a response to the client. The switch encapsulates and decapsulates the
Extensible Authentication Protocol (EAP) frames and interacts with the RADIUS authentication
server.
When the switch receives EAPOL frames and relays them to the authentication server, the Ethernet
header is stripped and the remaining EAP frame is reencapsulated in the RADIUS format. The EAP
frames are not modified or examined during encapsulation, and the authentication server must
support EAP within the native frame format. When the switch receives frames from the
authentication server, the frame header is removed from the server, leaving the EAP frame, which
is then encapsulated for Ethernet and sent to the client.
Cisco devices that are capable of functioning as an 802.1X network access point include
Catalyst 4500 series switches, the Catalyst 3550 multilayer switch, the Catalyst 2950 switch, and a
Cisco Airnet series wireless access point. These devices must be running software that supports the
RADIUS client and 802.1X.
31-2
OL-6696-01
Chapter 31
Authentication serverPerforms the actual authentication of the client. The authentication server
validates the identity of the client and notifies the switch that the client is authorized to access the
LAN and switch services. (The only supported authentication server is the RADIUS authentication
server with EAP extensions; it is available in Cisco Secure Access Control Server version 3.2 and
later.)
31-3
Chapter 31
Client
Workstation
RADIUS
EAPOL-Start
EAP-Request/Identity
EAP-Response/Identity
RADIUS Access-Request
EAP-Request/OTP
RADIUS Access-Challenge
EAP-Response/OTP
RADIUS Access-Request
EAP-Success
RADIUS Access-Accept
Port Authorized
Port Unauthorized
Supplicant
Authenticator
Authentication
server
94159
EAPOL-Logoff
force-unauthorizedCauses the port to remain in the unauthorized state, ignoring all attempts by
the client to authenticate. The switch cannot provide authentication services to the client through the
interface.
31-4
OL-6696-01
Chapter 31
autoEnables 802.1X authentication and causes the port to begin in the unauthorized state,
allowing only EAPOL frames to be sent and received through the port. The authentication process
begins when the link state of the port transitions from down to up or when an EAPOL-start frame is
received. The switch requests the identity of the client and begins relaying authentication messages
between the client and the authentication server. The switch can uniquely identify each client
attempting to access the network by the clients MAC address.
If the client is successfully authenticated (receives an Accept frame from the authentication server), the
port state changes to authorized, and all frames from the authenticated client are allowed through the
port. If authentication fails, the port remains in the unauthorized state, but authentication can be retried.
If the authentication server cannot be reached, the switch can retransmit the request. If no response is
received from the server after the specified number of attempts, authentication fails and network access
is not granted.
If the link state of a port transitions from up to down, or if an EAPOL-logoff frame is received by the
port, the port returns to the unauthorized state.
Note
To enable the guest VLAN feature in Release 12.1(19)EW and later releases, the port must be statically
configured as an access port.
When configured on the switch and the RADIUS server, 802.1X with VLAN assignment has these
characteristics:
If no VLAN is supplied by the RADIUS server, the port is configured in its access VLAN when
authentication succeeds.
If the authentication server provides invalid VLAN information, the port remains unauthorized. This
situation prevents ports from appearing unexpectedly in an inappropriate VLAN due to a
configuration error.
Configuration errors might occur if you specify a VLAN for a routed port, a malformed VLAN ID,
or a nonexistent or internal (routed port) VLAN ID. Similarly, an error might occur if you make an
assignment to a voice VLAN ID.
If the authentication server provides valid VLAN information, the port is authorized and placed in
the specified VLAN when authentication succeeds.
If the multiple-hosts mode is enabled, all hosts are in the same VLAN as the first authenticated user.
If 802.1X is disabled on the port, the port is returned to the configured access VLAN.
Enable AAA authorization with the network keyword to allow interface configuration from the
RADIUS server. For an illustration of how to apply the aaa authorization network group radius
command, refer to the section Enabling 802.1X Authentication on page 13.
Enable 802.1X. (The VLAN assignment feature is automatically enabled when you configure
802.1X on an access port.)
31-5
Chapter 31
Assign vendor-specific tunnel attributes in the RADIUS server. To ensure proper VLAN assignment,
the RADIUS server must return these attributes to the switch:
Tunnel-Type = VLAN
Tunnel-Medium-Type = 802
Tunnel-Private-Group-ID = VLAN NAME
Usage Guidelines for Using 802.1X Authentication with Guest VLANs on Windows-XP Hosts
The usage guidelines for using 802.1X authentication with guest VLANs on Windows-XP hosts are as
follows:
If the host fails to respond to the authenticator, the port attempts to connect three times (with a 30
second timeout between each attempt). After this time, the login/password window does not appear
on the host, so you must unplug and reconnect the network interface cable.
Hosts responding with an incorrect login/password fail authentication. Hosts failing authentication
are not put in the guest VLAN. The first time that a host fails authentication, the quiet-period timer
starts, and no activity occurs for the duration of the quiet-period timer. When the quiet-period timer
expires, the host is presented with the login/password window. If the host fails authentication for the
second time, the quiet-period timer starts again, and no activity will occur for the duration of the
quiet-period timer. The host is presented with the login/password window a third time. If the host
fails authentication the third time, the port is placed in the unauthorized state, and you must
disconnect and reconnect the network interface cable.
31-6
OL-6696-01
Chapter 31
These examples describe the interaction between 802.1X and port security on the switch:
When a client is authenticated, and the port security table is not full, the clients MAC address is
added to the port security list of secure hosts. The port then proceeds to come up normally.
When a client is authenticated and manually configured for port security, it is guaranteed an entry
in the secure host table (unless port security static aging has been enabled).
A security violation occurs if an additional host is learned on the port. The action taken depends on
which feature (802.1X or port security) detects the security violation:
If 802.1X detects the violation, the action is to err-disable the port.
If port security detects the violation, the action is to shutdown or restrict the port (the action is
configurable).
The following describes when port security and 802.1X security violations occur:
In single host mode, after the port is authorized, any MAC address received other than the
security has already reached its limit (due to a configured secure MAC addresses), a port
security violation is triggered.
In multi host mode, once the port is authorized, any additional MAC addresses that cannot be
installed because the port security has reached its limit will trigger a port security violation.
When an 802.1X client logs off, the port transitions back to an unauthenticated state, and all
dynamic entries in the secure host table are cleared, including the entry for the client. Normal
authentication then ensues.
If you administratively shut down the port, the port becomes unauthenticated, and all dynamic
entries are removed from the secure host table.
Only 802.1X can remove the clients MAC address from the port security table. Note that in multi
host mode, with the exception of the clients MAC address, all MAC addresses that are learned by
port security can be deleted using port security CLIs.
Whenever port security ages out a 802.1X clients MAC address, 802.1X attempts to reauthenticate
the client. Only if the reauthentication succeeds will the clients MAC address be retained in the port
security table.
All of the 802.1X clients MAC addresses are tagged with (dot1x) when you display the port security
table by using CLI.
31-7
Chapter 31
Client
Workstation
RADIUS
EAPOL-Start
EAP-Request/Identity
EAP-Response/Identity
RADIUS Access-Request
EAP-Request/OTP
RADIUS Access-Challenge
EAP-Response/OTP
RADIUS Access-Request
EAP-Success
RADIUS Access-Accept
Port Authorized
RADIUS Account-Request (start)
RADIUS Account-Response
EAPOL-Logoff
Port Unauthorized
RADIUS Account-Response
Supplicant
Note
Authenticator
105283
Authentication
server
You must configure the 802.1X client to send an EAP-logoff (Stop) message to the switch when the user
logs off. If you do not configure the 802.1X client, an EAP-logoff message is not sent to the switch and
the accompanying accounting Stop message will not be sent to the authentication server. Refer to the
Microsoft Knowledge Base article at the URL: http://support.microsoft.com. Also refer to the Microsoft
article at the URL:
http://www.microsoft.com/technet/treeview/default.asp?url=/technet/columns/cableguy/cg0703.asp,
and set the SupplicantMode registry to 3 and the AuthMode registry to 1.
The client uses EAP to authenticate itself with the RADIUS server. The switch relays EAP packets
between the client and the RADIUS server.
After the client is authenticated, the switch sends accounting-request packets to the RADIUS server,
which responds with accounting-response packets to acknowledge the receipt of the request.
A RADIUS accounting-request packet contains one or more Attribute-Value pairs to report various
events and related information to the RADIUS server. The following events are tracked:
User logs-off
Reauthentication succeeds
Reauthentication fails
31-8
OL-6696-01
Chapter 31
When the port state transitions between authorized and unauthorized, the RADIUS messages are
transmitted to the RADIUS server.
The switch does not log any accounting information. Instead, it sends such information to the RADIUS
server, which must be configured to log accounting messages.
The 802.1X authentication, authorization and accounting process is as follows:
Step 1
Step 2
Step 3
Step 4
Step 5
Step 6
The switch sends an interim accounting update to the accounting server that is based on the result of
reauthentication.
Step 7
Step 8
Enable logging of Update/Watchdog packets from this AAA client in your RADIUS servers
Network Configuration tab.
Enable Logging>CVS RADIUS Accounting in your RADIUS server System Configuration tab.
Enable AAA accounting by using the aaa system accounting command. Refer to the Enabling
802.1X Accounting section on page 31-16.
Enabling AAA system accounting along with 802.1X accounting allows system reload events to be sent
to the accounting RADIUS server for logging. By doing this, the accounting RADIUS server can infer
that all active 802.1X sessions are appropriately closed.
Because RADIUS uses the unreliable transport protocol UDP, accounting messages may be lost due to
poor network conditions. If the switch does not receive the accounting response message from the
RADIUS server after a configurable number of retransmissions of an accounting request, the following
system message appears:
Accounting message %s for session %s failed to receive Accounting Response.
When the stop message is not transmitted successfully, the following message appears:
00:09:55: %RADIUS-3-NOACCOUNTINGRESPONSE: Accounting message Start for session
172.20.50.145 sam 11/06/03 07:01:16 11000002 failed to receive Accounting Response.
Use the show radius statistics command to display the number of RADIUS messages that do not receive
the accounting response message.
31-9
Chapter 31
Voice VLAN ID (VVID) to carry voice traffic to and from the IP phone. The VVID is used to
configure the IP phone connected to the port.
Port VLAN ID (PVID) to carry the data traffic to and from the workstation connected to the switch
through the IP phone. The PVID is the native VLAN of the port.
Each port that you configure for a voice VLAN is associated with a VVID and a PVID. This
configuration allows voice traffic and data traffic to be separated onto different VLANs.
When you enable the single-host mode, only one 802.1X client is allowed on the primary VLAN; other
workstations are blocked. When you enable the multiple-hosts mode and an 802.1X client is
authenticated on the primary VLAN, additional clients on the voice VLAN are unrestricted after 802.1X
authentication succeeds on the primary VLAN.
A voice VLAN port becomes active when there is link, and the device MAC address appears in the
MAC-address table after the first CDP message from the IP phone. Cisco IP phones do not relay CDP
messages from other devices. As a result, if several Cisco IP phones are connected in series, the switch
recognizes only the one directly connected to it. When 802.1X is enabled on a voice VLAN port, the
switch drops packets from unrecognized Cisco IP phones more than one hop away.
When 802.1X is enabled on a port, you cannot configure a PVID that is equal to a VVID. For more
information about voice VLANs, see Chapter 30, Configuring Voice Interfaces.
Be aware of the following feature interactions:
802.1X VLAN assignment cannot assign to the port the same VLAN as the voice VLAN; otherwise,
the 802.1X authentication will fail.
802.1X guest VLAN works with the 802.1X voice VLAN port feature. However, the guest VLAN
cannot be the same as the voice VLAN.
802.1X port security works with the 802.1X voice VLAN port feature and is configured per port.
Three secure addresses must be configured: one for the Cisco IP phone MAC address on the VVID,
one for the PC MAC-address on PVID, and a third to allow the Cisco IP phone MAC address on the
PVID.
However, you cannot use the 802.1X voice VLAN port feature with 802.1X port securitys sticky
MAC address configuration and 802.1X port-security's statically configured MAC address
configuration.
When 802.1X is configured on a port, you cannot connect multiple IP-phones to a Catalyst 4500
series switch through a hub.
Supported Topologies
The 802.1X port-based authentication supports two topologies:
Point to point
Wireless LAN
In a point-to-point configuration (see Figure 31-1 on page 31-2), only one client can be connected to the
802.1X-enabled switch port when the multi-host mode is not enabled (the default). The switch detects
the client when the port link state changes to the up state. If a client leaves or is replaced with another
client, the switch changes the port link state to down, and the port returns to the unauthorized state.
31-10
OL-6696-01
Chapter 31
Figure 31-4 illustrates 802.1X port-based authentication in a wireless LAN. You must configure the
802.1X port as a multiple-host port that is authorized as a wireless access point once the client is
authenticated. (See the Enabling Multiple Hosts section on page 31-21.) When the port is authorized,
all other hosts that are indirectly attached to the port are granted access to the network. If the port
becomes unauthorized (reauthentication fails or an EAPOL-logoff message is received), the switch
denies access to the network for all wireless access point-attached clients. In this topology, the wireless
access point is responsible for authenticating clients attached to it, and the wireless access point acts as
a client to the switch.
Figure 31-4 Wireless LAN Example
Wireless
access point
Supplicants
Authenticator
RADIUS
Authentication server
94160
Wireless
clients
Resetting the 802.1X Configuration to the Default Values, page 31-22 (optional)
31-11
Chapter 31
Feature
Default Setting
Disabled
RADIUS server
IP address
None specified
1812
Key
None specified
Disabled (force-authorized)
The port transmits and receives normal traffic without
802.1X-based authentication of the client.
Periodic reauthentication
Disabled
3600 sec
Quiet period
60 sec
Number of seconds that the switch remains in the quiet state
following a failed authentication exchange with the client.
Retransmission time
30 sec
Number of seconds that the switch should wait for a response to an
EAP request/identity frame from the client before retransmitting the
request.
2
Number of times that the switch will send an EAP-request/identity
frame before restarting the authentication process.
Disabled
30 sec
When relaying a request from the authentication server to the client,
the amount of time that the switch waits for a response before
retransmitting the request to the client.
30 sec
When relaying a response from the client to the authentication
server, the amount of time that the switch waits for a reply before
retransmitting the response to the server. This setting is not
configurable.
31-12
OL-6696-01
Chapter 31
The 802.1X protocol is supported on both Layer 2 static-access ports and Layer 3 routed ports, but
it is not supported on the following port types:
Trunk portIf you try to enable 802.1X on a trunk port, an error message appears, and 802.1X
is not enabled. If you try to change the mode of an 802.1X-enabled port to trunk, the port mode
is not changed.
Default portsAll ports default as dynamic-access ports (auto). Use the no switchport
port. If you try to enable 802.1X on a dynamic port, an error message appears, and 802.1X is
not enabled. If you try to change the mode of an 802.1X-enabled port to dynamic, the port mode
is not changed.
EtherChannel portBefore enabling 802.1X on the port, you must first remove it from the
SPAN destination port; however, 802.1X is disabled until the port is removed as a SPAN
destination. You can enable 802.1X on a SPAN source port.
If you are planning to use either 802.1X accounting or VLAN assignment, be aware that both features
utilize general AAA commands. For information how to configure AAA, refer to Enabling 802.1X
Authentication on page 13 and Enabling 802.1X Accounting on page 16. Alternatively, you can refer
to the Cisco IOS security documentation.
Refer to the following Cisco IOS security documentation for information on how to configure AAA
system accounting:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/fsecur_c/index.htm
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/fsecur_r/index.htm
31-13
Chapter 31
Purpose
Step 1
Step 2
Switch(config)#
[no] dot1x system-auth-control
Step 3
Enables AAA.
Step 4
Step 5
(Optional) Configure the switch for user RADIUS authorization for all
network-related service requests, such as VLAN assignment.
Step 6
Switch(config)# interface
interface-id
Step 7
Switch(config-if)# dot1x
port-control auto
Step 8
Switch(config-if)# end
Step 9
Step 10
Step 11
31-14
OL-6696-01
Chapter 31
This example shows how to enable AAA and 802.1X on Fast Ethernet port 2/1:
Switch# configure terminal
Switch(config)# dot1x system-auth-control
Switch(config)# aaa new-model
Switch(config)# aaa authentication dot1x default group radius
Switch(config)# interface fastethernet2/1
Switch(config-if)# dot1x port-control auto
Switch(config-if)# end
Purpose
Step 1
Step 2
Switch(config-if)# ip radius
source-interface m/p
Establishes the IP address to be used as the source address for all outgoing
RADIUS packets.
Step 4
Switch(config)# end
Step 5
Step 6
31-15
Chapter 31
To delete the specified RADIUS server, use the no radius-server host {hostname | ip-address} global
configuration command.
This example shows how to specify the server with IP address 172.20.39.46 as the RADIUS server. The
first command specifies port 1612 as the authorization port, sets the encryption key to rad123. The
second command dictates that key matches will be performed on the RADIUS server:
Switch(config)# radius-server host 172.l20.39.46 auth-port 1612 key rad123
Switch(config)# ip radius source-interface m/p
You can globally configure the timeout, retransmission, and encryption key values for all RADIUS
servers by using the radius-server host global configuration command. If you want to configure these
options on a per-server basis, use the radius-server timeout, radius-server retransmit, and the
radius-server key global configuration commands.
You also need to configure some settings on the RADIUS server. These settings include the IP address
of the switch and the key string to be shared by both the server and the switch.
Refer to the following Cisco IOS security documentation for information on how to configure AAA
system accounting:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/fsecur_c/index.htm
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/fsecur_r/index.htm
If you plan to implement system-wide accounting, you should also configure 802.1X accounting.
Moreover, you need to inform the accounting server of the system reload event when the system is
reloaded. Doing this, ensures that the accounting server knows that all outstanding 802.1X sessions on
this system are closed.
Once you configure 802.1X authentication and switch-to-RADIUS server communication, perform this
task to enable 802.1X accounting:
Command
Purpose
Step 1
Step 2
Step 3
Sets the time zone for the accounting event-time stamp field.
Step 4
Switch(config)# clock
calendar-valid
Step 5
Step 6
Switch(config-if)# end
Step 7
Step 8
31-16
OL-6696-01
Chapter 31
This example shows how to configure 802.1X accounting. The first command configures the RADIUS
server, specifying 1813 as the UDP port for accounting:
Switch(config)# radius-server host 172.120.39.46 auth-port 1812 acct-port 1813 key rad123
Switch(config)# aaa accounting dot1x default start-stop group radius
Switch(config)# aaa accounting system default start-stop group radius
Note
You must configure the RADIUS server to perform accounting tasks, such as logging start, stop, and
interim-update messages and time stamps. To turn on these functions, enable logging of
Update/Watchdog packets from this AAA client in your RADIUS server Network Configuration tab.
Next, enable CVS RADIUS Accounting in your RADIUS server System Configuration tab.
When a port is put into a guest VLAN, it is automatically placed into multihost mode, and an unlimited
number of hosts can connect through the port. Changing the multihost configuration does not effect a
port in a guest VLAN.
To configure 802.1X with guest-VLAN, perform this task:
Command
Purpose
Step 1
Step 2
Switch(config)# interface
interface-id
Step 3
Switch(config-if)# dot1x
port-control auto]
Step 4
Step 5
Switch(config-if)# end
Step 6
Switch(config)# end
To disable the guest VLAN feature on a particular port, use the no dot1x guest-vlan interface
configuration command.
This example shows how to enable a guest VLAN on Fast Ethernet interface 4/3:
Switch# configure terminal
Switch(config)# interface fastethernet4/3
Switch(config-if)# dot1x port-control auto
Switch(config-if)# dot1x guest-vlan 50
Switch(config-if)# end
Switch(config)# end
Switch#
31-17
Chapter 31
Purpose
Step 1
Step 2
Switch(config)# interface
interface-id
Step 3
Switch(config-if)# switchport
access vlan vlan-id
Step 4
Step 5
Step 6
Switch(config-if)# dot1x
port-control auto
Step 7
Switch(config-if)# end
Step 8
Switch(config)# end
This example shows how to enable 802.1X with voice VLAN feature on Fast Ethernet interface 5/9:
Switch# configure terminal
Switch(config)# interface fastethernet5/9
Switch(config-if)# switchport access vlan 2
Switch(config-if)# switchport mode access
Switch(config-if)# switchport voice vlan 10
Switch(config-if)# dot1x port-control auto
Switch(config-if)# end
Note
You must configure 802.1X and voice VLAN at the same time.
Purpose
Step 1
Step 2
Switch(config)# interface
interface-id
31-18
OL-6696-01
Chapter 31
Command
Purpose
Step 3
Switch(config-if)# dot1x
re-authentication
Step 4
Step 5
Switch(config)# end
Step 6
Step 7
Purpose
Step 1
Step 2
Switch(config)# interface
interface-id
31-19
Chapter 31
Step 3
Command
Purpose
Sets the number of seconds that the switch remains in the quiet-period
following a failed authentication exchange with the client.
The range is 0 to 65,535 seconds; the default is 60.
Step 4
Switch(config)# end
Step 5
Step 6
To return to the default quiet-period, use the no dot1x timeout quiet-period configuration command.
This example shows how to set the quiet-period on the switch to 30 seconds:
Switch(config)# dot1x timeout quiet-period 30
Note
You should change the default value of this command only to adjust for unusual circumstances, such as
unreliable links or specific behavioral problems with certain clients and authentication servers.
To change the amount of time that the switch waits for client notification, perform this task:
Command
Purpose
Step 1
Step 2
Switch(config)# interface
interface-id
Step 3
Sets the number of seconds that the switch waits for a response to an
EAP-request/identity frame from the client before retransmitting the
request.
The range is 1 to 65,535 seconds; the default is 30.
Step 4
Switch(config)# end
Step 5
Step 6
To return to the default retransmission time, use the no dot1x timeout tx-period interface configuration
command.
This example shows how to set the retransmission time to 60 seconds:
Switch(config)# dot1x timeout tx-period 60
31-20
OL-6696-01
Chapter 31
Note
You should change the default values of these commands only to adjust for unusual circumstances such
as unreliable links or specific behavioral problems with certain clients and authentication servers.
To set the switch-to-client frame-retransmission numbers, perform this task:
Command
Purpose
Step 1
Step 2
Switch(config)# interface
interface-id
Step 3
or
Switch(config-if)# dot1x max-req
count
Step 4
Switch(config)# end
Step 5
Step 6
To return to the default retransmission number, use the no dot1x max-req and
no dot1x max-reauth-req global configuration command.
This example shows how to set 5 as the number of times that the switch retransmits an
EAP-request/identity request before restarting the authentication process:
Switch(config)# dot1x max-reauth-req 5
31-21
Chapter 31
To allow multiple hosts (clients) on an 802.1X-authorized port that has the dot1x port-control interface
configuration command set to auto, perform this task:
Command
Purpose
Step 1
Step 2
Switch(config)# interface
interface-id
Step 3
Step 4
Switch(config-if)# end
Step 5
Step 6
To disable multiple hosts on the port, use the no dot1x multiple-hosts interface configuration command.
This example shows how to enable 802.1X on Fast Ethernet interface 0/1 and to allow multiple hosts:
Switch(config)# interface fastethernet0/1
Switch(config-if)# dot1x port-control auto
Switch(config-if)# dot1x multiple-hosts
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
Step 4
Step 5
31-22
OL-6696-01
C H A P T E R
32
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
This chapter consists of these sections:
You can configure all secure MAC addresses by using the switchport port-security mac-address
mac_address interface configuration command.
You can allow the port to dynamically configure secure MAC addresses with the MAC addresses of
connected devices.
You can configure a number of addresses and allow the rest to be dynamically configured.
32-1
Chapter 32
Note
If the port shuts down, all dynamically learned addresses are removed.
You can configure MAC addresses to be sticky. These can be dynamically learned or manually
configured, stored in the address table, and added to the running configuration. If these addresses
are saved in the configuration file, the interface does not need to dynamically relearn them when the
switch restarts. Although sticky secure addresses can be manually configured, it is not
recommended.
You can configure an interface to convert the dynamic MAC addresses to sticky secure MAC addresses
and to add them to the running configuration by enabling sticky learning. To enable sticky learning, enter
the switchport port-security mac-address sticky command. When you enter this command, the
interface converts all the dynamic secure MAC addresses, including those that were dynamically learned
before sticky learning was enabled, to sticky secure MAC addresses.
The sticky secure MAC addresses do not automatically become part of the configuration file, which is
the startup configuration used each time the switch restarts. If you save the sticky secure MAC addresses
in the configuration file, when the switch restarts, the interface does not need to relearn these addresses.
If you do not save the configuration, they are lost.
If sticky learning is disabled, the sticky secure MAC addresses are converted to dynamic secure
addresses and are removed from the running configuration.
After the maximum number of secure MAC addresses is configured, they are stored in an address table.
To ensure that an attached device has the full bandwidth of the port, configure the MAC address of the
attached device and set the maximum number of addresses to one, which is the default.
Note
When a Catalyst 4500 series switch port is configured to support voice as well as port security, the
maximum number of allowable MAC addresses on this port should be changed to three.
A security violation occurs if the maximum number of secure MAC addresses has been added to the
address table and a workstation whose MAC address is not in the address table attempts to access the
interface.
You can configure the interface for one of these violation modes, based on the action to be taken if a
violation occurs:
RestrictA port security violation restricts data, causes the SecurityViolation counter to increment,
and causes an SNMP Notification to be generated. The rate at which SNMP traps are generated can be
controlled by the snmp-server enable traps port-security trap-rate command. The default value (0)
causes an SNMP trap to be generated for every security violation.
ShutdownA port security violation causes the interface to shut down immediately. When a secure
port is in the error-disabled state, you can bring it out of this state by entering the errdisable
recovery cause psecure-violation global configuration command or you can manually reenable it
by entering the shutdown and no shut down interface configuration commands. This is the default
mode.
You can also customize the time to recover from the specified error disable cause (default is 300
seconds) by entering the errdisable recovery interval interval command.
32-2
OL-6696-01
Chapter 32
Feature
Default Setting
Port security
Disabled on a port
Violation mode
Aging
Disabled
Aging type
Absolute
Static Aging
Disabled
Sticky
Disabled
A secure port cannot be a destination port for Switch Port Analyzer (SPAN).
A secure port and static MAC address configuration are mutually exclusive.
32-3
Chapter 32
Purpose
Step 1
Step 2
Step 3
Step 4
Step 5
Note
Step 6
Step 7
Step 8
Step 9
Switch(config-if)# end
interface interface_id
Switch# show port-security address
32-4
OL-6696-01
Chapter 32
To return the interface to the default condition as not a secure port, use the no switchport
port-security interface configuration command.
To return the interface to the default number of secure MAC addresses, use the no switchport
port-security maximum value.
To delete a MAC address from the address table, use the no switchport port-security mac-address
mac_address command.
To return the violation mode to the default condition (shutdown mode), use the no switchport
port-security violation {restrict | shutdown} command.
To disable sticky learning on an interface, use the no switchport port-security mac-address sticky
command. The interface converts the sticky secure MAC addresses to dynamic secure addresses.
To delete a sticky secure MAC addresses from the address table, use the no switchport
port-security sticky mac-address mac_address command. To delete all the sticky addresses on an
interface or a VLAN, use the no switchport port-security sticky interface interface-id command.
To clear dynamically learned port security MAC in the CAM table, use the clear port-security
dynamic command. The address keyword enables you to clear a secure MAC addresses. The
interface keyword enables you to clear all secure addresses on an interface.
This example shows how to enable port security on Fast Ethernet port 12 and how to set the maximum
number of secure addresses to 5. The violation mode is the default, and no secure MAC addresses are
configured.
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface fastethernet 3/12
Switch(config-if)# switchport mode access
Switch(config-if)# switchport port-security
Switch(config-if)# switchport port-security maximum 5
Switch(config-if)# switchport port-security mac-address sticky
Switch(config-if)# end
Switch# show port-security interface fastethernet 3/12
Port Security
:Enabled
Port Status
:Secure-up
Violation Mode
:Shutdown
Aging Time
:0
Aging Type
:Absolute
SecureStatic Address Aging :Enabled
Maximum MAC Addresses
:5
Total MAC Addresses
:0
Configured MAC Addresses
:0
Sticky MAC Addresses
:11
Last Source Address
:0000.0000.0401
Security Violation Count
:0
This example shows how to configure a secure MAC address on Fast Ethernet port 5/1 and verify the
configuration:
Switch# configure terminal
Enter configuration commands, one per line.
Switch(config)# interface fastethernet 5/1
Switch(config-if)# switchport mode access
Switch(config-if)# switchport port-security
Switch(config-if)# switchport port-security
Switch(config-if)# switchport port-security
Switch(config-if)# switchport port-security
Switch(config-if)#
switchport port-security mac-address sticky
Switch(config-if)# switchport port-security
Switch(config-if)# end
maximum 10
mac-address 0000.0000.0003 (Static secure MAC)
mac-address sticky
0000.0000.0001 (Sticky static MAC)
mac-address sticky 0000.0000.0002
32-5
Chapter 32
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# end
Step 4
To disable port security aging for all secure addresses on a port, use the no switchport port-security
aging time interface configuration command.
This example shows how to set the aging time as 2 hours for the secure addresses on the Fast Ethernet
interface 5/1:
Switch(config)# interface fastethernet 5/1
Switch(config-if)# switchport port-security aging time 120
32-6
OL-6696-01
Chapter 32
You can verify the previous commands by entering the show port-security interface interface_id
command.
Purpose
This example displays output from the show port-security command when you do not enter an interface:
Switch# show port-security
Secure Port MaxSecureAddr CurrentAddr SecurityViolation Security Action
(Count)
(Count)
(Count)
--------------------------------------------------------------------------Fa3/1
2
2
0
Restrict
Fa3/2
2
2
0
Restrict
Fa3/3
2
2
0
Shutdown
Fa3/4
2
2
0
Shutdown
Fa3/5
2
2
0
Shutdown
Fa3/6
2
2
0
Shutdown
Fa3/7
2
2
0
Shutdown
Fa3/8
2
2
0
Shutdown
Fa3/10
1
0
0
Shutdown
Fa3/11
1
0
0
Shutdown
Fa3/12
1
0
0
Restrict
Fa3/13
1
0
0
Shutdown
Fa3/14
1
0
0
Shutdown
Fa3/15
1
0
0
Shutdown
Fa3/16
1
0
0
Shutdown
--------------------------------------------------------------------------Total Addresses in System (excluding one mac per port)
:8
Max Addresses limit in System (excluding one mac per port) :1024
Global SNMP trap control for port-security
:20 (traps per second)
32-7
Chapter 32
This example displays output from the show port-security command for a specified interface:
Switch# show port-security
Port Security
Port Status
Violation Mode
Aging Time
Aging Type
SecureStatic Address Aging
Maximum MAC Addresses
Total MAC Addresses
Configured MAC Addresses
Sticky MAC Addresses
Last Source Address
Security Violation Count
This example displays output from the show port-security address command:
Switch#sh port-security address
Secure Mac Address Table
------------------------------------------------------------------Vlan
Mac Address
Type
Ports
Remaining Age
(mins)
--------------------------------1
0000.0001.0000
SecureConfigured
Fa3/1
15 (I)
1
0000.0001.0001
SecureConfigured
Fa3/1
14 (I)
1
0000.0001.0100
SecureConfigured
Fa3/2
1
0000.0001.0101
SecureConfigured
Fa3/2
1
0000.0001.0200
SecureConfigured
Fa3/3
1
0000.0001.0201
SecureConfigured
Fa3/3
1
0000.0001.0300
SecureConfigured
Fa3/4
1
0000.0001.0301
SecureConfigured
Fa3/4
1
0000.0001.1000
SecureDynamic
Fa3/5
1
0000.0001.1001
SecureDynamic
Fa3/5
1
0000.0001.1100
SecureDynamic
Fa3/6
1
0000.0001.1101
SecureDynamic
Fa3/6
1
0000.0001.1200
SecureSticky
Fa3/7
1
0000.0001.1201
SecureSticky
Fa3/7
1
0000.0001.1300
SecureSticky
Fa3/8
1
0000.0001.1301
SecureSticky
Fa3/8
------------------------------------------------------------------Total Addresses in System (excluding one mac per port)
:8
Max Addresses limit in System (excluding one mac per port) :1024
32-8
OL-6696-01
C H A P T E R
33
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
33-1
Chapter 33
Note
In order to enable DHCP snooping on a VLAN, you must enable DHCP snooping on the switch.
You can configure DHCP snooping for switches and VLANs. When you enable DHCP snooping on a
switch, the interface acts as a Layer 2 bridge, intercepting and safeguarding DHCP messages going to a
Layer 2 VLAN. When you enable DHCP snooping on a VLAN, the switch acts as a Layer 2 bridge
within a VLAN domain.
Each entry in the file is tagged with a checksum that is used to validate the entries whenever the file is
read. The <initial-checksum> entry on the first line helps distinguish entries associated with the latest
write from entries that are associated with a previous write.
This is a sample bindings file:
3ebe1518
TYPE DHCP-SNOOPING
VERSION 1
BEGIN
1.1.1.1 512 0001.0001.0005 3EBE2881 Gi1/1
1.1.1.1 512 0001.0001.0002 3EBE2881 Gi1/1
1.1.1.1 1536 0001.0001.0004 3EBE2881 Gi1/1
1.1.1.1 1024 0001.0001.0003 3EBE2881 Gi1/1
1.1.1.1 1 0001.0001.0001 3EBE2881 Gi1/1
END
e5e1e733
4b3486ec
f0e02872
ac41adf9
34b3273e
Each entry holds an IP address, VLAN, MAC address, lease time (in hex), and the interface associated
with a binding. At the end of each entry is a checksum that accounts for all the bytes from the start of
the file through all the bytes associated with the entry. Each entry consists of 72 bytes of data, followed
by a space, followed by a checksum.
Upon bootup, when the calculated checksum equals the stored checksum, a switch reads entries from the
file and adds the bindings to the DHCP snooping database. When the calculated checksum does not equal
the stored checksum, the entry read from the file is ignored and so are all the entries following the failed
entry. The switch also ignores all those entries from the file whose lease time has expired. (This situation
33-2
OL-6696-01
Chapter 33
is possible because the lease time might indicate an expired time.) An entry from the file is also ignored
if the interface referred to in the entry, no longer exists on the system or if it is a router port or a DHCP
snooping-trusted interface.
When a switch learns of new bindings or when it loses some bindings, the switch writes the modified set
of entries from the snooping database to the file. The writes are performed with a configurable delay to
batch as many changes as possible before the actual write happens. Associated with each transfer is a
timeout after which a transfer is aborted if it is not completed. These timers are referred to as the write
delay and abort timeout.
Note
For DHCP server configuration information, refer to Configuring DHCP in the Cisco IOS IP and IP
Routing Configuration Guide at:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/ip_c/ipcprt1/1cddhcp.htm
Option
Default Value/State
DHCP snooping
Disabled
Enabled
33-3
Chapter 33
Option
Default Value/State
Untrusted
Disabled
If you want to change the default configuration values, see the Enabling DHCP Snooping section.
When DHCP snooping is enabled globally, DHCP requests are dropped until the ports are configured.
Consequently, you should probably this feature during a maintenance window and not during
production.
To enable DHCP snooping, perform this task:
Step 1
Command
Purpose
Step 2
Step 3
Step 4
Step 5
Switch(config)# end
Step 6
1.
Cisco recommends not configuring the untrusted interface rate limit to more than 100 packets per second. The recommended rate limit for
each untrusted client is 15 packets per second. Normally, the rate limit applies to untrusted interfaces. If you want to set up rate limiting for
trusted interfaces, keep in mind that trusted interfaces aggregate all DHCP traffic in the switch, and you will need to adjust the rate limit to a
higher value. You should fine tune this threshold depending on the network configuration. The CPU should not receive DHCP packets at a
sustained rate of more than 1,000 packets per second
You can configure DHCP snooping for a single VLAN or a range of VLANs. To configure a single
VLAN, enter a single VLAN number. To configure a range of VLANs, enter a beginning and an ending
VLAN number or a dash and range of VLANs.
This example shows how to enable DHCP snooping on VLANs 10 through 100:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# ip dhcp snooping
Switch(config)# ip dhcp snooping vlan 10 100
Switch(config)# interface GigabitEthernet 5/1
Switch(config-if)# ip dhcp snooping trust
Switch(config-if)# interface FastEthernet 2/1
Switch(config-if)# ip dhcp snooping limit rate 100
33-4
OL-6696-01
Chapter 33
Switch(config)# end
Switch# show ip dhcp snooping
Switch DHCP snooping is enabled.
DHCP Snooping is configured on the
10-100
Insertion of option 82 information
Interface
Trusted
--------------FastEthernet2/1
yes
FastEthernet2/2
yes
FastEthernet3/1
no
GigabitEthernet5/1
yes
following VLANs:
is enabled.
Rate limit (pps)
---------------100
none
20
none
Switch#
The following configuration describes the DHCP snooping configuration steps if routing is defined on
another Catalyst switch (for example, a Catalyst 6500 series switch):
// Trust the uplink gigabit Ethernet trunk port
interface range GigabitEthernet 1/1 2
switchport mode trunk
switchport trunk encapsulation dot1q
ip dhcp snooping trust
!
interface VLAN 14
ip address 10.33.234.1 255.255.254.0
ip helper-address 10.5.1.2
Note
If you are enabling trunking on uplink gigabit interfaces, and the above routing configuration is defined
on a Catalyst 6500 series switch, you must configure the trust relationship with downstream DHCP
Snooping (on a Catalyst 4500 series switch) which adds Option 82. On a Catalyst 6500 series switch,
this task is accomplished with ip dhcp relay information trusted VLAN configuration command.
The show ip dhcp snooping command will display all VLANs (both primary and secondary) that have
DHCP snooping enabled.
33-5
Chapter 33
Purpose
Note
Because both NVRAM and bootflash have limited storage capacity, using TFTP or network-based files
is preferrable. If you use bootflash to store the database file, new updates to the file (by the agent) result
in the creation of new files, causing the flash to fill very quickly. Moreover, when a file is stored in a
remote location accessible through TFTP, an RPR standby supervisor engine can take over the binding
list when a switchover occurs.
Note
Network-based URLs (such as TFTP and FTP) require that you create an empty file at the configured
URL before the switch can write the set of bindings for the first time.
33-6
OL-6696-01
Chapter 33
Agent Running : No
Delay Timer Expiry : 7 (00:00:07)
Abort Timer Expiry : Not Running
Last Succeded Time : None
Last Failed Time : 17:14:25 UTC Sat Jul 7 2001
Last Failed Reason : Unable to access URL.
Total Attempts
Successful Transfers
Successful Reads
Successful Writes
Media Failures
:
:
:
:
:
21
0
0
0
0
Startup Failures
Failed Transfers
Failed Reads
Failed Writes
:
:
:
:
0
21
0
21
:
0
0
0
Expired leases
:
Unsupported vlans :
0
0
Expired leases
:
Unsupported vlans :
0
0
Switch#
The first three lines of output show the configured URL and related timer configuration values. The next
three lines show the operating state and the amount of time left for expiry of write delay and abort timers.
Among the statistics shown in the output, startup failures indicate the number of attempts the read or
create of the file has failed upon bootup.
Note
Because the location is based off in the network, you must create a temporary file on the TFTP server.
You can create a temporary file on a typical UNIX workstation by creating a 0 byte file file in the
directory directory that can be referenced by the TFTP server daemon. With some server
implementations on UNIX workstations, the file should be provided with full (777) permissions for write
access to the file.
DHCP snooping bindings are keyed on the MAC address and VLAN combination. Therefore, if an entry
in the remote file has an entry for a given MAC address and VLAN set, for which the switch already has
a binding, the entry from the remote file is ignored when the file is read. This condition is referred to as
the binding collision.
An entry in a file may no longer be valid because the lease indicated by the entry may have expired by
the time it is read. The expired leases counter indicates the number of bindings ignored because of this
condition. The Invalid interfaces counter refers to the number of bindings that have been ignored when
the interface referred by the entry either does not exist on the system or is a router or DHCP snooping
trusted interface if it exists, when the read happened. Unsupported VLANs refers to the number of
entries that have been ignored because the indicated VLAN is not supported on the system. The Parse
failures counter provides the number of entries that have been ignored when the switch is unable to
interpret the meaning of the entries from the file.
33-7
Chapter 33
The switch maintains two sets of counters for these ignored bindings. One provides the counters for a
read that has at least one binding ignored by at least one of these conditions. These counters are shown
as the Last ignored bindings counters. The total ignored bindings counters provides a sum of the
number of bindings that have been ignored because of all the reads since the switch bootup. These two
set of counters are cleared by the clear command. Therefore, the total counter set may indicate the
number of bindings that have been ignored since the last clear.
Purpose
Step 1
Step 2
Step 3
Step 4
33-8
OL-6696-01
Chapter 33
VLAN
---512
512
1536
1024
1
Interface
-------------------GigabitEthernet1/1
GigabitEthernet1/1
GigabitEthernet1/1
GigabitEthernet1/1
GigabitEthernet1/1
VLAN
----
Interface
--------------------
Purpose
Step 1
Step 2
Step 3
This example shows how to manually add a binding to the DHCP snooping database:
Switch# show ip dhcp snooping binding
MacAddress
IpAddress
Lease(sec) Type
VLAN Interface
------------------ --------------- ---------- ------------- ---- -------------------Switch#
Switch# ip dhcp snooping binding 1.1.1 vlan 1 1.1.1.1 interface gi1/1 expiry 1000
Switch# show ip dhcp snooping binding
MacAddress
IpAddress
Lease(sec)
------------------ --------------- ---------00:01:00:01:00:01
1.1.1.1
992
Switch#
Type
------------dhcp-snooping
VLAN
---1
Interface
-------------------GigabitEthernet1/1
33-9
Chapter 33
Lease(sec)
---------6943
Type
------------dhcp-snooping
VLAN
---10
Interface
-------------------FastEthernet6/10
Table 33-2 describes the fields in the show ip dhcp snooping binding command output.
Table 33-2 show ip dhcp snooping binding Command Output
Field
Description
MAC Address
IP Address
Lease (seconds)
Type
VLAN
Interface
following VLANs:
is enabled.
Rate limit (pps)
---------------10
none
20
33-10
OL-6696-01
Chapter 33
Note
If IP Source Guard is enabled on a trunk port with a large number of VLANs that have DHCP snooping
enabled, you might run out of ACL hardware resources, and some packets might be switched in software
instead.
Note
When IP Source Guard is enabled, you might want to designate an alternative scheme for ACL hardware
programming. For more information, see the TCAM Programming and ACLs section in the
"Configuring Network Security with ACLs chapter.
IP Source Guard supports the Layer 2 port only, including both access and trunk. For each untrusted
Layer 2 port, there are two levels of IP traffic security filtering:
Note
When IP source guard is enabled in IP and MAC filtering mode, the DHCP snooping option 82 must be
enabled to ensure that the DHCP protocol works properly. Without option 82 data, the switch cannot
locate the client host port to forward the DHCP server reply. Instead, the DHCP server reply is dropped,
and the client cannot obtain an IP address.
Step 1
Command
Purpose
Step 2
Step 3
Step 4
33-11
Chapter 33
Step 5
Command
Purpose
Step 6
Step 7
Switch(config)# end
Step 8
Note
The static IP source binding can only be configured on switch port. If you issue the
ip source binding vlan interface command on a Layer 3 port, you will receive this error message:
Static IP source binding can only be configured on switch port.
This example shows how to enable per-Layer 2-port IP source guard on VLANs 10 through 20:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# ip dhcp snooping
Switch(config)# ip dhcp snooping vlan 10 20
Switch(config)# interface fa6/1
Switch(config-if)# switchport trunk encapsulation dot1q
Switch(config-if)# switchport mode trunk
Switch(config-if)# switchport trunk native vlan 10
Switch(config-if)# switchport trunk allowed vlan 11-20
Switch(config-if)# no ip dhcp snooping trust
Switch(config-if)# ip verify source vlan dhcp-snooping
Switch(config)# end
Switch# sh ip verify source interface f6/1
Interface Filter-type Filter-mode IP-address
Mac-address
--------- ----------- ----------- --------------- ----------------Fa6/1
ip-mac
active
10.0.0.1
Fa6/1
ip-mac
active
deny-all
Switch#
Vlan
---------10
11-20
The output shows that there is one valid DHCP binding to VLAN 10.
Warning
IP source filter may not take effect on secondary vlan where IP source binding is configured. If private
vlan feature is enabled, IP source filter on primary vlan will automatically propagate to all secondary
vlans.
33-12
OL-6696-01
Chapter 33
This example shows displayed PVACLs if DHCP snooping is enabled on VLAN 10 through 20, if
interface fa6/1 is configured for IP filtering, and if there is an existing IP address binding 10.0.01
on VLAN 10:
Interface
--------fa6/1
fa6/1
Note
Filter-type
----------ip
ip
Filter-mode
----------active
active
IP-address
--------------10.0.0.1
deny-all
Mac-address
--------------
Vlan
--------10
11-20
The second entry shows that a default PVACL (deny all IP traffic) is installed on the port for those
snooping-enabled VLANs that do not have a valid IP source binding.
Vlan
---------
Filter-type
----------ip
Filter-mode IP-address
----------- --------------inactive-no-snooping-vlan
Mac-address
--------------
Vlan
---------
Filter-type
----------ip-mac
ip-mac
ip-mac
Filter-mode
----------active
active
active
IP-address
--------------10.0.0.2
11.0.0.1
deny-all
Mac-address
-------------aaaa.bbbb.cccc
aaaa.bbbb.cccd
deny-all
Vlan
--------10
11
12-20
This example shows displayed PVACLs for a port configured for IP/MAC filtering but not for port
security:
Interface
--------fa6/5
fa6/5
Note
Mac-address
--------------
This example shows displayed PVACLs for a port with multiple bindings configured for an IP/MAC
filtering:
Interface
--------fa6/4
fa6/4
fa6/4
Filter-mode IP-address
----------- --------------inactive-trust-port
This example shows displayed PVACL for a port in a VLAN not configured for DHCP snooping:
Interface
--------fa6/3
Filter-type
----------ip
Filter-type
----------ip-mac
ip-mac
Filter-mode
----------active
active
IP-address
--------------10.0.0.3
deny-all
Mac-address
-------------permit-all
permit-all
Vlan
--------10
11-20
The MAC filter shows permit-all because port security is not enabled, so the MAC filter
cannot apply to the port/VLAN and is effectively disabled. Always enable port security first.
This example shows displayed error message when issuing the show ip verify source command on
a port that does not have an IP source filter mode configured:
IP Source Guard is not configured on the interface fa6/6.
33-13
Chapter 33
You can also use the show ip verify source command to display all interfaces on the switch that have IP
source guard enabled:
Interface
--------fa6/1
fa6/1
fa6/2
fa6/3
fa6/4
fa6/4
fa6/4
fa6/5
fa6/5
Filter-type
----------ip
ip
ip
ip
ip-mac
ip-mac
ip-mac
ip-mac
ip-mac
Filter-mode IP-address
----------- --------------active
10.0.0.1
active
deny-all
inactive-trust-port
inactive-no-snooping-vlan
active
10.0.0.2
active
11.0.0.1
active
deny-all
active
10.0.0.3
active
deny-all
Mac-address
--------------
Vlan
--------10
11-20
aaaa.bbbb.cccc
aaaa.bbbb.cccd
deny-all
permit-all
permit-all
10
11
12-20
10
11-20
Lease(sec)
---------6522
infinite
Type
------------dhcp-snooping
static
VLAN
---10
10
Interface
-------------------FastEthernet6/10
FastEthernet6/10
Table 33-3 describes the fields in the show ip source binding command output.
Table 33-3 show ip source binding Command Output
Field
Description
MAC Address
IP Address
Lease (seconds)
Type
VLAN
Interface
33-14
OL-6696-01
C H A P T E R
34
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Interface Trust state, Security Coverage and Network Configuration, page 34-3
Relative Priority of Static Bindings and DHCP Snooping Entries, page 34-4
34-1
Chapter 34
HA
(IA, MA)
HB
(IB, MB)
HC
(IC, MC)
94072
Hosts HA, HB, and HC are connected to the switch on interfaces A, B and C, all of which are on the
same subnet. Their IP and MAC addresses are shown in parentheses; for example, Host HA uses IP
address IA and MAC address MA. When HA needs to communicate to HB at the IP Layer, HA
broadcasts an ARP request for the MAC address associated with IB. As soon as HB receives the ARP
request, the ARP cache on HB is populated with an ARP binding for a host with the IP address IA and
a MAC address MA; for example, IP address IA is bound to MAC address MA. When HB responds, the
ARP cache on HA is populated with a binding for a host with the IP address IB and a MAC address MB.
Host HC can poison the ARP caches of HA and HB by broadcasting forged ARP responses with
bindings for a host with an IP address of IA (or IB) and a MAC address of MC. Hosts with poisoned
ARP caches use the MAC address MC as the destination MAC address for traffic intended for IA or IB.
This means that HC intercepts that traffic. Because HC knows the true MAC addresses associated with
IA and IB, HC can forward the intercepted traffic to those hosts using the correct MAC address as the
destination. HC has inserted itself into the traffic stream from HA to HB, the classic man in the middle
attack.
34-2
OL-6696-01
Chapter 34
DHCP server
Switch S1
Fa6/4
Host H1
Fa3/3
Fa3/4
Host H2
94075
Fa6/3
Switch S2
Note
Depending on the setup of DHCP server and the network, it may not be possible to perform validation
of a given ARP packet on all switches in the VLAN.
34-3
Chapter 34
34-4
OL-6696-01
Chapter 34
Scenario One: Two Switches Support Dynamic ARP Inspection, page 34-5
Scenario Two: One Switch Supports Dynamic ARP Inspection, page 34-9
Configuring Switch S1
To enable DAI and configure fa6/3 on S1 as trusted, follow these steps:
Step 1
Step 2
Local Intrfce
Fas 6/3
Holdtme
177
Capability
R S I
Platform
WS-C4006
Port ID
Fas 3/3
Configuration
------------Enabled
Operation
--------Active
ACL Logging
----------Deny
DHCP Logging
-----------Deny
ACL Match
---------
Static ACL
----------
34-5
Chapter 34
Step 3
Step 4
Rate (pps)
---------None
Step 5
Lease(sec)
---------4993
Type
------------dhcp-snooping
VLAN
---1
Interface
-------------------FastEthernet6/4
Check the statistics before and after Dynamic ARP processes any packets:
S1# show ip arp inspection statistics vlan 1
Vlan
---1
Forwarded
--------0
Dropped
------0
Vlan
---1
DHCP Permits
-----------0
ACL Permits
----------0
Vlan
---1
S1#
DHCP Drops
---------0
ACL Drops
---------0
IP Validation Failures
---------------------0
If H1 then sends out two ARP requests with an IP address of 1.1.1.2 and a MAC address of
0002.0002.0002, both requests are permitted, as reflected in the following statistics:
S1# show ip arp inspection statistics vlan 1
Vlan
---1
Forwarded
--------2
Dropped
------0
Vlan
---1
DHCP Permits
-----------2
ACL Permits
----------0
Vlan
---1
S1#
DHCP Drops
---------0
ACL Drops
---------0
IP Validation Failures
---------------------0
If H1 then tries to send an ARP request with an IP address of 1.1.1.3, the packet is dropped and an error
message is logged:
00:12:08: %SW_DAI-4-DHCP_SNOOPING_DENY: 2 Invalid ARPs (Req) on Fa6/4, vlan
1.([0002.0002.0002/1.1.1.3/0000.0000.0000/0.0.0.0/02:42:35 UTC Tue Jul 10 2001])
S1# show ip arp inspection statistics vlan 1
S1#
34-6
OL-6696-01
Chapter 34
Forwarded
--------2
Dropped
------2
Vlan
---1
DHCP Permits
-----------2
ACL Permits
----------0
Vlan
---1
S1#
DHCP Drops
---------2
ACL Drops
---------0
IP Validation Failures
---------------------0
Configuring Switch S2
To enable DAI and configure fa3/3 on S2 as trusted, follow these steps:
Step 1
Step 2
Local Intrfce
Fas 3/3
Holdtme
120
Capability
R S I
Platform
WS-C4006
Port ID
Fas 6/3
Step 3
Configuration
------------Enabled
Operation
--------Active
ACL Logging
----------Deny
DHCP Logging
-----------Deny
ACL Match
---------
Static ACL
----------
34-7
Chapter 34
Interface
Trust State
--------------- ----------Gi1/1
Untrusted
Gi1/2
Untrusted
Gi3/1
Untrusted
Gi3/2
Untrusted
Fa3/3
Trusted
Fa3/4
Untrusted
Fa3/5
Untrusted
Fa3/6
Untrusted
Fa3/7
Untrusted
Rate (pps)
---------15
15
15
15
None
15
15
15
15
<output truncated>
S2#
Step 4
Step 5
Lease(sec)
---------4995
Type
------------dhcp-snooping
VLAN
---1
Interface
-------------------FastEthernet3/4
Check the statistics before and after Dynamic ARP processes any packets:
S2# show ip arp inspection statistics vlan 1
Vlan
---1
Forwarded
--------0
Dropped
------0
Vlan
---1
DHCP Permits
-----------0
ACL Permits
----------0
Vlan
---1
S2#
DHCP Drops
---------0
ACL Drops
---------0
IP Validation Failures
---------------------0
If H2 then sends out an ARP request with the IP address 1.1.1.1 and the MAC address 0001.0001.0001,
the packet is forwarded and the statistics are updated appropriately:
S2# show ip arp inspection statistics vlan 1
Vlan
---1
Forwarded
--------1
Dropped
------0
Vlan
---1
DHCP Permits
-----------1
ACL Permits
----------0
Vlan
---1
S2#
DHCP Drops
---------0
ACL Drops
---------0
IP Validation Failures
---------------------0
Conversely, if H2 attempts to send an ARP request with the IP address 1.1.1.2, the request is dropped
and an error message is logged:
00:18:08: %SW_DAI-4-DHCP_SNOOPING_DENY: 1 Invalid ARPs (Req) on Fa3/4, vlan
1.([0001.0001.0001/1.1.1.2/0000.0000.0000/0.0.0.0/01:53:21 UTC Fri May 23 2003])
S2#
34-8
OL-6696-01
Chapter 34
Forwarded
--------1
Dropped
------1
Vlan
---1
DHCP Permits
-----------1
ACL Permits
----------0
Vlan
---1
S2#
DHCP Drops
---------1
ACL Drops
---------0
IP Validation Failures
---------------------0
Set up the access list to permit the IP address 1.1.1.1 and the MAC address 0001.0001.0001, and verify
the configuration:
S1# conf t
Enter configuration commands, one per line. End with CNTL/Z.
S1(config)# arp access-list H2
S1(config-arp-nacl)# permit ip host 1.1.1.1 mac host 1.1.1
S1(config-arp-nacl)# end
S1# show arp access-list
ARP access list H2
permit ip host 1.1.1.1 mac host 0001.0001.0001
Step 2
Configuration
------------Enabled
Operation
--------Active
ACL Match
--------H2
Static ACL
---------No
34-9
Chapter 34
Vlan
---1
S1#
Step 3
ACL Logging
----------Deny
DHCP Logging
-----------Deny
Trust State
----------Untrusted
Rate (pps)
---------15
Switch#
When H2 sends 5 ARP requests through interface fa6/3 on S1 and a get is permitted by S1, the
statistics are updated appropriately:
Switch# show ip arp inspection statistics vlan 1
Vlan
Forwarded
Dropped
DHCP Drops
ACL Drops
-----------------------------------1
5
0
0
0
Vlan
DHCP Permits
ACL Permits
Source MAC Failures
------------------------------------------1
0
5
0
Vlan
Dest MAC Failures
IP Validation Failures
----------------------------------------1
0
0
Switch#
34-10
OL-6696-01
C H A P T E R
35
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
This chapter consists of the following major sections:
Using PACL with VLAN Maps and Router ACLs, page 35-26
Understanding ACLs
This section contains the following subsections:
35-1
Chapter 35
Understanding ACLs
ACL Overview
An ACL is a collection of sequential permit and deny conditions that applies to packets. When a packet
is received on an interface, the switch compares the fields in the packet against any applied ACLs to
verify that the packet has the permissions required to be forwarded, based on the conditions specified in
the access lists. It tests the packets against the conditions in an access list one-by-one. The first match
determines whether the switch accepts or rejects the packets. Because the switch stops testing conditions
after the first match, the order of conditions in the list is critical. If no conditions match, the switch drops
the packet. If there are no restrictions, the switch forwards the packet; otherwise, the switch drops the
packet.
Switches traditionally operate at Layer 2, switching traffic within a VLAN, whereas routers route traffic
between VLANs at Layer 3. The Catalyst 4500 series switch can accelerate packet routing between
VLANs by using Layer 3 switching. The Layer 3 switch bridges the packet, and then routed the packet
internally without going to an external router. The packet is then bridged again and sent to its destination.
During this process, the switch can control all packets, including packets bridged within a VLAN.
You configure access lists on a router or switch to filter traffic and provide basic security for your
network. If you do not configure ACLs, all packets passing through the switch could be allowed on all
parts of the network. You can use ACLs to control which hosts can access different parts of a network
or to decide which types of traffic are forwarded or blocked at router interfaces. For example, you can
allow e-mail traffic to be forwarded but not Telnet traffic. ACLs can be configured to block inbound
traffic, outbound traffic, or both. However, on Layer 2 interfaces, you can apply ACLs only in the
inbound direction.
An ACL contains an ordered list of access control entries (ACEs). Each ACE specifies permit or deny
and a set of conditions the packet must satisfy in order to match the ACE. The meaning of permit or deny
depends on the context in which the ACL is used.
The Catalyst 4500 series switch supports two types of ACLs:
IP ACLs, which filter IP traffic, including TCP, the User Datagram Protocol (UDP), Internet Group
Management Protocol (IGMP), and Internet Control Message Protocol (ICMP).
Router ACLs are applied to Layer 3 interfaces. They control the access of routed traffic between
VLANs. All Catalyst 4500 series switches can create router ACLs, but you must have a Cisco IOS
software image on your switch to apply an ACL to a Layer 3 interface and filter packets routed
between VLANs.
Port ACLs perform access control on traffic entering a Layer 2 interface. If there are not enough
hardware CAM entries, the output port ACL is not applied to the port and a warning message is given
to user. (This restriction applies to all access group modes for output port ACLs.) When there are
enough CAM entries, the output port ACL might be reapplied.
If there is any output port ACL configured on a Layer 2 port, then no VACL or router ACL can be
configured on the VLANs that the Layer 2 port belongs to. Also, the reverse is true: port ACLs and
VLAN-based ACLs (VACLs and router ACLs) are mutually exclusive on a Layer 2 port. This
restriction applies to all access group modes.
35-2
OL-6696-01
Chapter 35
You can apply only one IP access list and one MAC access list to a Layer 2 interface.
VLAN ACLs or VLAN maps control the access of all packets (bridged and routed). You can use
VLAN maps to filter traffic between devices in the same VLAN. You do not need the enhanced
image to create or apply VLAN maps. VLAN maps are configured to control access based on
Layer 3 addresses for IP. MAC addresses using Ethernet ACEs control the access of unsupported
protocols. After you apply a VLAN map to a VLAN, all packets (routed or bridged) entering the
VLAN are checked against that map. Packets can either enter the VLAN through a switch port or
through a routed port after being routed.
You can use both router ACLs and VLAN maps on the same switch.
Router ACLs
You can apply router ACLs on switch virtual interfaces (SVIs), which are Layer 3 interfaces to VLANs;
on physical Layer 3 interfaces; and on Layer 3 EtherChannel interfaces. Router ACLs are applied on
interfaces for specific directions (inbound or outbound). You can apply one IP access list in each
direction.
Multiple features can use one ACL for a given interface, and one feature can use multiple ACLs. When
a single router ACL is used by multiple features, it is examined multiple times. The access list type
determines the input to the matching operation:
Extended IP access lists use source and destination addresses and optional protocol type information
for matching operations.
The switch examines ACLs associated with features configured on a given interface and a direction. As
packets enter the switch on an interface, ACLs associated with all inbound features configured on that
interface are examined. After packets are routed and before they are forwarded to the next hop, all ACLs
associated with outbound features configured on the egress interface are examined.
ACLs permit or deny packet forwarding based on how the packet matches the entries in the ACL. For
example, you can use access lists to allow one host to access a part of a network, but prevent another
host from accessing the same part. In Figure 35-1, ACLs applied at the router input allow Host A to
access the Human Resources network, but prevent Host B from accessing the same network.
35-3
Chapter 35
Understanding ACLs
Host A
Si
Host B
Research &
Development
network
94152
Human
Resources
network
Port ACLs
You can also apply ACLs to Layer 2 interfaces on a switch. Port ACLs are supported on physical
interfaces and EtherChannel interfaces.
The following access lists are supported on Layer 2 interfaces:
Extended IP access lists using source and destination addresses and optional protocol type
information
MAC extended access lists using source and destination MAC addresses and optional protocol type
information
As with router ACLs, the switch examines ACLs associated with features configured on a given interface
and permits or denies packet forwarding based on how the packet matches the entries in the ACL. In the
example in Figure 35-1, if all workstations were in the same VLAN, ACLs applied at the Layer 2 input
would allow Host A to access the Human Resources network, but prevent Host B from accessing the
same network.
When you apply a port ACL to a trunk port, the ACL filters traffic on all VLANs present on the trunk
port. When you apply a port ACL to a port with voice VLAN, the ACL filters traffic on both data and
voice VLANs.
With port ACLs, you can filter IP traffic by using IP access lists and non-IP traffic by using MAC
addresses. You can filter both IP and non-IP traffic on the same Layer 2 interface by applying both an IP
access list and a MAC access list to the interface.
Note
You cannot apply more than one IP access list and one MAC access list to a Layer 2 interface. If an IP
access list or MAC access list is already configured on a Layer 2 interface and you apply a new IP access
list or MAC access list to the interface, the new ACL replaces the previously configured one.
35-4
OL-6696-01
Chapter 35
VLAN Maps
VLAN maps can control the access of all traffic in a VLAN. You can apply VLAN maps on the switch
to all packets that are routed into or out of a VLAN or are bridged within a VLAN. Unlike router ACLs,
VLAN maps are not defined by direction (input or output).
You can configure VLAN maps to match Layer 3 addresses for IP traffic. Access of all non-IP protocols
is controlled with a MAC address and an Ethertype using MAC ACLs in VLAN maps. (IP traffic is not
controlled by MAC ACLs in VLAN maps.) You can enforce VLAN maps only on packets going through
the switch; you cannot enforce VLAN maps on traffic between hosts on a hub or on another switch
connected to this switch.
With VLAN maps, forwarding packets is permitted or denied, based on the action specified in the map.
Figure 35-2 illustrates how a VLAN map is applied to deny a specific type of traffic from Host A in
VLAN 10 from being forwarded.
Figure 35-2 Using VLAN Maps to Control Traffic
Si
Host A
(VLAN 10)
Host B
(VLAN 10)
94153
Flows that match a deny statement in standard and extended ACLs (input only) are dropped in
hardware if ICMP unreachable messages are disabled.
Flows that match a permit statement in standard and extended ACLs (input and output) are processed
in hardware.
35-5
Chapter 35
Note
Packets that require logging are processed in software. A copy of the packets is sent to the CPU for
logging while the actual packets are forwarded in hardware so that non-logged packet processing is not
impacted.
By default, the Catalyst 4500 series switch sends ICMP unreachable messages when a packet is denied
by an access list; these packets are not dropped in hardware but are forwarded to the switch so that it can
generate the ICMP unreachable message.
To drop access-list denied packets in hardware on the input interface, you must disable ICMP
unreachable messages using the no ip unreachables interface configuration command. The ip
unreachables command is enabled by default.
Packets denied by an output access list are always forwarded to the CPU.
Note
To determine whether the packed algorithm is configured, use the show running config command. If
packed is configured, the line access-list hardware entries packed will appear.
Note
35-6
OL-6696-01
Chapter 35
The following output was collected after the algorithm was switched to scattered. Observe that the
number of masks required to program 49 percent of the entries has decreased to 49 percent.
Note
When you enable DHCP snooping and IP Source Guard on all ports on a chassis, you must use the
scattered keyword.
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# access-list hardware entries scattered
Switch(config)# end
Switch#
01:39:37: %SYS-5-CONFIG_I: Configured from console by console
Switch#
Switch# show platform hardware acl statistics utilization brief
Entries/Total(%) Masks/Total(%)
----------------- --------------Input Acl(PortAndVlan) 2016 / 4096 ( 49)
252 / 512 ( 49)
Input Acl(PortOrVlan)
6 / 4096 ( 0)
5 / 512 ( 0)
Input Qos(PortAndVlan)
0 / 4096 ( 0)
0 / 512 ( 0)
Input Qos(PortOrVlan)
0 / 4096 ( 0)
0 / 512 ( 0)
Output Acl(PortAndVlan)
0 / 4096 ( 0)
0 / 512 ( 0)
Output Acl(PortOrVlan)
0 / 4096 ( 0)
0 / 512 ( 0)
Output Qos(PortAndVlan)
0 / 4096 ( 0)
0 / 512 ( 0)
Output Qos(PortOrVlan)
0 / 4096 ( 0)
0 / 512 ( 0)
L4Ops: used 2 out of 64
Switch#
35-7
Chapter 35
gt (greater than)
lt (less than)
We recommend that you not specify more than six different operations on the same ACL. If you exceed
this number, each new operation might cause the affected ACE (access control entry) to be translated
into multiple ACEs in hardware. If you exceed this number, the affected ACE might be processed in
software.
Layer 4 operations are considered different if the operator or operand differ. For example, the
following ACL contains three different Layer 4 operations because gt 10 and gt 11 are considered
two different Layer 4 operations:
... gt 10 permit
... lt 9 deny
... gt 11 deny
Note
The eq operator can be used an unlimited number of times because eq does not use a Layer 4 operation
in hardware.
Layer 4 operations are considered different if the same operator/operand couple applies once to a
source port and once to a destination port, as in the following example:
... Src gt 10....
... Dst gt 10
35-8
OL-6696-01
Chapter 35
Access lists 101 and 102 use the following Layer 4 operations:
Total Layer 4 operations: 8 (due to sharing between the two access lists)
neg6 permit is shared between the two ACLs because they are identical and both operate on the
For some packets, when the hardware runs out of resources, the software must perform the ACL
matches:
TCP flag combinations other than rst ack and syn fin rst are processed in software. rst ack is
operations to be guaranteed to be processed in hardware. More than six Layer 4 operations will
trigger an attempt to translate the excess operations into multiple ACEs in hardware. If this
attempt fails, packets will be processed in software. The translation process is less likely to
succeed on large ACLs with a great number of Layer 4 operations, and on switches with large
numbers of ACLs configured. The precise limit depends on how many other ACLs are
configured and which specific Layer 4 operations are used by the ACLs being translated. The
eq operator does not require any Layer 4 operations and can be used any number of times.
If the total number of Layer 4 operations in an ACL is less than six, you can distribute the
35-9
Chapter 35
Access lists 104 and 105 are identical; established is shorthand for rst and ack.
Access list 101, below, will be processed completely in software:
access-list 101 permit tcp any any urg
Because four source and two destination operations exist, access list 106, below, will be
processed in hardware:
access-list
access-list
access-list
access-list
106
106
106
106
permit tcp any range 100 120 any range 120 140
permit tcp any range 140 160 any range 180 200
permit tcp any range 200 220
deny tcp any range 220 240
In the following code, the Layer 4 operations for the third ACE will trigger an attempt to
translate dst lt 1023 into multiple ACEs in hardware, because three source and three destination
operations exist. If the translation attempt fails, the third ACE will be processed in software.
access-list 102 permit tcp any lt 80 any gt 100
access-list 102 permit tcp any range 100 120 any range 120 1024
access-list 102 permit tcp any gt 1024 any lt 1023
Similarly, for access list 103, below, the third ACE will trigger an attempt to translate dst gt
1023 into multiple ACEs in hardware. If the attempt fails, the third ACE will be processed in
software. Although the operations for source and destination ports look similar, they are
considered different Layer 4 operations.)
access-list 103 permit tcp any lt 80 any lt 80
access-list 103 permit tcp any range 100 120 any range 100 120
access-list 103 permit tcp any gt 1024 any gt 1023
Note
Remember that source port lt 80 and destination port lt 80 are considered different
operations.
Some packets must be sent to the CPU for accounting purposes, but the action is still performed by
the hardware. For example, if a packet must be logged, a copy is sent to the CPU for logging, but
the forwarding (or dropping) is performed in the hardware. Although logging slows the CPU, it does
not affect the forwarding rate. This sequence of events would happen under the following
conditions:
When a log keyword is used
When an output ACL denies a packet
When an input ACL denies a packet, and on the interface where the ACL is applied, ip
35-10
OL-6696-01
Chapter 35
Purpose
This example shows how to block all unicast traffic to or from MAC address 0050.3e8d.6400 in VLAN
12:
Router# configure terminal
Router(config)# mac-address-table static 0050.3e8d.6400 vlan 12 drop
Note
Command
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config-ext-macl)# end
Step 5
Step 6
35-11
Chapter 35
You can use the no mac access-list extended name global configuration command to delete the entire
ACL. You can also delete individual ACEs from named MAC extended ACLs.
This example shows how to create and display an access list named mac1, denying only EtherType
DECnet Phase IV traffic, but permitting all other types of traffic.
Switch(config)# mac access-list extended mac1
Switch(config-ext-macl)# deny any any decnet-iv (old) protocol-family decnet (new)
Switch(config-ext-macl)# permit any any
Switch(config-ext-macl)# end
Switch # show access-lists
Extended MAC access list mac1
deny
any any decnet-iv (old) protocol-family decnet (new)
permit any any
This section describes how to configure VLAN maps, which is the only way to control filtering within
a VLAN. VLAN maps have no direction. To filter traffic in a specific direction by using a VLAN map,
you need to include an ACL with specific source or destination addresses. If there is a match clause for
that type of packet (IP or MAC) in the VLAN map, the default action is to drop the packet if the packet
does not match any of the entries within the map. If there is no match clause for that type of packet, the
default is to forward the packet.
To create a VLAN map and apply it to one or more VLANs, perform this task
Step 1
Create the standard or extended IP ACLs or named MAC extended ACLs that you want to apply to the
VLAN.
Step 2
Enter the vlan access-map global configuration command to create a VLAN ACL map entry.
Step 3
In access map configuration mode, you have the optional to enter an action (forward [the default] or
drop) and enter the match command to specify an IP packet or a non-IP packet and to match the packet
against one or more ACLs (standard or extended). If a match clause is not specified, the action is applied
to all packets. The match clause can be used to match against multiple ACLs. If a packet matches any of
the specified ACLs, the action is applied.
Note
Step 4
If the VLAN map has a match clause for the type of packet (IP or MAC) and the packet does not
match the type, the default is to drop the packet. If there is no match clause in the VLAN map
for that type of packet, and no action specified, the packet is forwarded.
Use the vlan filter global configuration command to apply a VLAN map to one or more VLANs.
35-12
OL-6696-01
Chapter 35
Note
You cannot apply a VLAN map to a VLAN on a switch that has ACLs applied to Layer 2 interfaces (port
ACLs).
If there is no router ACL configured to deny traffic on a routed VLAN interface (input or output),
and no VLAN map configured, all traffic is permitted.
Each VLAN map consists of a series of entries. The order of entries in a VLAN map is important.
A packet that comes into the switch is tested against the first entry in the VLAN map. If it matches,
the action specified for that part of the VLAN map is taken. If there is no match, the packet is tested
against the next entry in the map.
If the VLAN map has at least one match clause for the type of packet (IP or MAC) and the packet
does not match any of these match clauses, the default is to drop the packet. If there is no match
clause for that type of packet in the VLAN map, the default is to forward the packet.
The system might take longer to boot if you have configured a very large number of ACLs.
Purpose
Step 1
Step 2
Creates a VLAN map, and give it a name and (optionally) a number. The
number is the sequence number of the entry within the map.
When you create VLAN maps with the same name, numbers are assigned
sequentially in increments of 10. When modifying or deleting maps, you
can enter the number of the map entry that you want to modify or delete.
This command enables access-map configuration mode.
Step 3
Switch(config-access-map)# action
{drop | forward}
(Optional) Sets the action for the map entry. The default is to forward.
Step 4
Switch(config-access-map)# match
{ip | mac} address {name |
number} [name | number]
Matches the packet (using either the IP or MAC address) against one or
more standard or extended access lists. Note that packets are matched only
against access lists of the correct protocol type. IP packets are compared
with standard or extended IP access lists. Non-IP packets are only compared
with named MAC extended access lists. If a match clause is not specified,
the action is taken on all packets.
Step 5
Switch(config-access-map)# end
35-13
Chapter 35
Command
Purpose
Step 6
Switch(config)# show
running-config
Step 7
Switch(config)# copy
running-config startup-config
You can use the no vlan access-map name global configuration command to delete a map. You can use
the no vlan access-map name number global configuration command to delete a single sequence entry
from within the map. You can use the no action access-map configuration command to enforce the
default action, which is to forward.
VLAN maps do not use the specific permit or deny keywords. To deny a packet by using VLAN maps,
create an ACL that would match the packet, and then set the action to drop. A permit in the ACL is the
same as a match. A deny in the ACL means no match.
Example 1
This example shows how to create an ACL and a VLAN map to deny a packet. In the first map, any
packets that match the ip1 ACL (TCP packets) would be dropped. You first create the ip1 ACL to permit
any TCP packet and no other packets. Because there is a match clause for IP packets in the VLAN map,
the default action is to drop any IP packet that does not match any of the match clauses.
Switch(config)# ip access-list extended ip1
Switch(config-ext-nacl)# permit tcp any any
Switch(config-ext-nacl)# exit
Switch(config)# vlan access-map map_1 10
Switch(config-access-map)# match ip address ip1
Switch(config-access-map)# action drop
This example shows how to create a VLAN map to permit a packet. ACL ip2 permits UDP packets; and
any packets that match the ip2 ACL are forwarded.
Switch(config)# ip access-list extended ip2
Switch(config-ext-nacl)# permit udp any any
Switch(config-ext-nacl)# exit
Switch(config)# vlan access-map map_1 20
Switch(config-access-map)# match ip address ip2
Switch(config-access-map)# action forward
In this map, any IP packets that did not match any of the previous ACLs (that is, packets that are not TCP
packets or UDP packets) would get dropped.
35-14
OL-6696-01
Chapter 35
Example 2
In this example, the VLAN map is configured to drop IP packets and to forward MAC packets by default.
By applying standard ACL 101 and the extended named access lists igmp-match and tcp-match, the
VLAN map is configured to do the following:
Example 3
In this example, the VLAN map is configured to drop MAC packets and forward IP packets by default.
By applying MAC extended access lists, good-hosts and good-protocols, the VLAN map is configured
to do the following:
Forward MAC packets of DECnet or VINES (Virtual Integrated Network Service) protocol-family
35-15
Chapter 35
Example 4
In this example, the VLAN map is configured to drop all packets (IP and non-IP). By applying access
lists tcp-match and good-hosts, the VLAN map is configured to do the following:
Purpose
Step 1
Step 2
Step 3
Switch(config)# show
running-config
Step 4
cSwitch(config)# copy
running-config startup-config
Note
You cannot apply a VLAN map to a VLAN on a switch that has ACLs applied to Layer 2 interfaces (port
ACLs).
This example shows how to apply VLAN map 1 to VLANs 20 through 22:
Switch(config)# vlan filter map 1 vlan-list 20-22
35-16
OL-6696-01
Chapter 35
Switch B
Switch A
Switch C
VLAN 1
VLAN 2
Packet
Host X
10.1.1.32
For example, if you do not want HTTP traffic to be switched from Host X to Host Y, you could apply a
VLAN map on Switch A to drop all HTTP traffic moving from Host X (IP address 10.1.1.32) to Host Y
(IP address 10.1.1.34) at Switch A and not bridge the traffic to Switch B. To configure this scenario, you
would do the following:
First, define an IP access list http to permit (match) any TCP traffic on the HTTP port, as follows:
Switch(config)# ip access-list extended http
Switch(config-ext-nacl)# permit tcp host 10.1.1.32 host 10.1.1.34 eq www
Switch(config-ext-nacl)# exit
Next, create a VLAN access map named map2 so that traffic that matches the http access list is dropped
and all other IP traffic is forwarded, as follows:
Switch(config)# vlan access-map map2 10
Switch(config-access-map)# match ip address http
Switch(config-access-map)# action drop
Switch(config-access-map)# exit
Switch(config)# ip access-list extended match_all
Switch(config-ext-nacl)# permit ip any any
Switch(config-ext-nacl)# exit
Switch(config)# vlan access-map map2 20
Switch(config-access-map)# match ip address match_all
Switch(config-access-map)# action forward
Then, apply the VLAN access map named map2 to VLAN 1, as follows:
Switch(config)# vlan filter map2 vlan 1
35-17
Chapter 35
VLAN map
10.1.1.100
Subnet
10.1.2.0/8
10.1.1.4
Host (VLAN 10)
Packet
94155
10.1.1.8
This procedure configures ACLs with VLAN maps to deny access to a server on another VLAN. The
VLAN map SERVER 1_ACL denies access to hosts in subnet 10.1.2.0/8, host 10.1.1.4, and host
10.1.1.8. Then it permits all other IP traffic. In Step 3, VLAN map SERVER1 is applied to VLAN 10.
To configure this scenario, you could take the following steps:
Step 1
Step 2
Define a VLAN map using the ACL to drop IP packets that match SERVER1_ACL and forward IP
packets that do not match the ACL.
Switch(config)# vlan access-map SERVER1_MAP
Switch(config-access-map)# match ip address SERVER1_ACL
Switch(config-access-map)# action drop
Switch(config)# vlan access-map SERVER1_MAP 20
Switch(config-access-map)# action forward
Switch(config-access-map)# exit
Step 3
35-18
OL-6696-01
Chapter 35
Purpose
Note
Sequence 30 does not have a match clause. All packets (IP as well as non-IP) will be matched against it
and dropped.
This is a sample output of the show vlan filter command:
Switch# show vlan filter
VLAN Map map_1 is filtering VLANs:
20-22
Note
You cannot combine VLAN maps or input router ACLs with port ACLs on a switch.
35-19
Chapter 35
35-20
OL-6696-01
Chapter 35
VLAN 10
map
Input
router
ACL
Output
router
ACL
VLAN 20
map
Frame
Host A
(VLAN 10)
Routing function
VLAN 10
Packet
VLAN 20
94156
Host C
(VLAN 10)
2.
3.
4.
35-21
Chapter 35
Configuring PACLs
VLAN 10
map
Input
router
ACL
Output
router
ACL
VLAN 20
map
Frame
Host B
(VLAN 20)
Host A
(VLAN 10)
VLAN 10
Packet
VLAN 20
94157
Routing function
Configuring PACLs
This section describes how to configure PACLs, which are used to control filtering on Layer 2 interfaces.
PACLs can filter traffic to or from Layer 2 interfaces based on Layer 3 information, Layer 4 head
information or non-IP Layer 2 information.
This section contains the following topics:
Creating a PACL
To create a PACL and apply it to one or more interfaces, perform this task:
Step 1
Create the standard or extended IP ACLs or named MAC extended ACLs that you want to apply to the
interface.
Step 2
Use the ip access-group or mac access-group interface command to apply a IP ACL or MAC ACL to
one or more Layer 2 interfaces.
35-22
OL-6696-01
Chapter 35
There can be at most one IP access list and MAC access list applied to the same Layer 2 interface
per direction.
The IP access list filters only IP packets, whereas the MAC access list filters only non-IP packets.
The number of ACLs and ACEs that can be configured as part of a PACL are bounded by the
hardware resources on the switch. Those hardware resources are shared by various ACL features
(for example, RACL, VACL) that are configured on the system. If there are insufficient hardware
resources to program PACL in hardware, the actions for input and output PACLs differ:
For input PACLs, some packets are sent to CPU for software forwarding.
For output PACLs, the PACL is disabled on the port.
The input IP ACL logging option is supported, although logging is not supported for output IP
ACLs, and MAC ACLs.
The access group mode can change the way PACLs interact with other ACLs. To maintain consistent
behavior across Cisco platforms, use the default access group mode.
Purpose
Step 1
Switch# configure t
Step 2
Switch(config)# interface
interface
Step 3
Step 4
Switch(config)# show
running-config
35-23
Chapter 35
Configuring PACLs
The following example shows how to configure the Extended Named IP ACL simple-ip-acl to permit all
TCP traffic and implicitly deny all other IP traffic:
Switch(config)# ip access-list extended simple-ip-acl
Switch(config-ext-nacl)# permit tcp any any
Switch(config-ext-nacl)# end
The following example shows how to configure the Extended Named MACL simple-mac-acl to permit
source host 000.000.011 to any destination host:
Switch(config)# mac access-list extended simple-mac-acl
Switch(config-ext-macl)# permit host 000.000.011 any
Switch(config-ext-macl)# end
Note
prefer port modeIf PACL is configured on a Layer 2 interface, then PACL takes effect and
overwrites the effect of other ACLs (Router ACL and VACL). If no PACL feature is configured on
the Layer 2 interface, other features applicable to the interface are merged and applied on the
interface. This is the default access group mode.
prefer vlan modeVLAN-based ACL features take effect on the port provided they have been
applied on the port and no PACLs are in effect. If no VLAN-based ACL features are applicable to
the Layer 2 interface, then the PACL feature already on the interface is applied.
merge modeMerges applicable ACL features before they are programmed into the hardware.
Because output PACLs are mutually exclusive with VACL and Router ACLs, the access group mode does
not change the behavior of output traffic filtering.
Purpose
Step 1
Switch# configure t
Step 2
Switch(config)# interface
interface
Step 3
Switch(config-if)# [no]
access-group mode
{prefer {port | vlan} | merge}
Step 4
Switch(config)# show
running-config
35-24
OL-6696-01
Chapter 35
This example shows how to merge and apply features other than PACL on the interface:
Switch# configure t
Switch(config)# interface interface
Switch(config-if)# access-group mode prefer port
This example shows how to merge applicable ACL features before they are programmed into hardware:
Switch# configure t
Switch(config)# interface interface
Switch(config-if)# access-group mode merge
Purpose
Note
Supervisor Engines III and Supervisor Engine IV running on a Catalyst 4500 series switch support both
input and output PACLs on an interface.
This example applies the extended named IP ACL simple-ip-acl to interface FastEthernet 6/1 ingress
traffic:
Switch# configure t
Switch(config)# interface fastEthernet 6/1
Switch(config-if)# ip access-group simple-ip-acl in
This example applies the extended named MAC ACL simple-mac-acl to interface FastEthernet 6/1
egress traffic:
Switch# configure t
Switch(config)# interface fastEthernet 6/1
Switch(config-if)# mac access-group simple-mac-acl out
Purpose
35-25
Chapter 35
This example shows that the IP access group simple-ip-acl is configured on the inbound direction of
interface fa6/1:
Switch# show ip interface fast 6/1
FastEthernet6/1 is up, line protocol is up
Inbound access list is simple-ip-acl
Outgoing access list is not set
This example shows that MAC access group simple-mac-acl is configured on the inbound direction of
interface fa6/1:
Switch# show mac access-group interface fast 6/1
Interface FastEthernet6/1:
Inbound access-list is simple-mac-acl
Outbound access-list is not set
This example shows that access group merge is configured on interface fa6/1:
Switch# show access-group mode interface fast 6/1
Interface FastEthernet6/1:
Access group mode is: merge
ACL Type(s)
Input PACL
prefer port
mode
prefer vlan
mode
merge mode
1.
PACL applied
Input Router
ACL applied
2.
VACL
PACL applied
VACL
applied
3.
VACL +
Input Router
ACL applied
Each ACL Type listed in Table 35-1 is synonymous with a different scenario, as explained in the
following discussion.
35-26
OL-6696-01
Chapter 35
Scenario 1: Host A is connected to an interface in VLAN 20, which has an SVI configured. The interface
has input PACL configured, and the SVI has input Router ACL configured as shown in Figure 35-7:
Figure 35-7 Scenario 1: PACL Interaction with an Input Router ACL
Input
PACL
Input
router
ACL
Output
PACL
Frame
Host B
(VLAN 20)
Host A
(VLAN 10)
VLAN 10
Packet
VLAN 20
94092
Routing function
If the interface access group mode is prefer port, then only the input PACL is applied on the ingress
traffic from Host A. If the mode is prefer vlan, then only the input Router ACL is applied to ingress
traffic from Host A that requires routing. If the mode is merge, then the input PACL is first applied to
the ingress traffic from Host A, and the input Router ACL is applied on the traffic that requires routing.
Scenario 2: Host A is connected to an interface in VLAN 10, which has a VACL (VLAN Map)
configured and an input PACL configured as shown in Figure 35-8:
Figure 35-8 Scenario 2: PACL Interaction with a VACL
Input
PACL
VLAN 10
map
Frame
VLAN 10
Packet
94093
Host B
(VLAN 10)
Host A
(VLAN 10)
35-27
Chapter 35
If the interface access group mode is prefer port, then only the input PACL is applied on the ingress
traffic from Host A. If the mode is prefer vlan, then only the VACL is applied to the ingress traffic from
Host A. If the mode is merge, the input PACL is first applied to the ingress traffic from Host A, and the
VACL is applied on the traffic.
Scenario 3: Host A is connected to an interface in VLAN 10, which has a VACL and an SVI configured.
The SVI has an input Router ACL configured and the interface has an input PACL configured, as shown
in Figure 35-9:
Figure 35-9 Scenario 3: VACL and Input Router ACL
Input VLAN 10
PACL
map
Input
router
ACL
Output
router
ACL
VLAN 20
map
Frame
Host B
(VLAN 20)
Host A
(VLAN 10)
VLAN 10
Packet
VLAN 20
94094
Routing function
If the interface access group mode is prefer port, then only the input PACL is applied on the ingress
traffic from Host A. If the mode is prefer vlan, then the merged results of the VACL and the input Router
ACL are applied to the ingress traffic from Host A. If the mode is merge, the input PACL is first applied
to the ingress traffic from Host A, the VACL is applied on the traffic and finally, and the input Router
ACL is applied to the traffic that needs routing. (that is, the merged results of the input PACL, VACL,
and input Router ACL are applied to the traffic).
35-28
OL-6696-01
C H A P T E R
36
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Overview of PVLANs
PVLANs provide Layer 2 isolation between ports within the same PVLAN. There are three types of
PVLAN ports:
PromiscuousA promiscuous port can communicate with all interfaces, including the isolated and
community ports within a PVLAN.
IsolatedAn isolated port has complete Layer 2 separation from the other ports within the same
PVLAN, but not from the promiscuous ports. PVLANs block all traffic to isolated ports except
traffic from promiscuous ports. Traffic from isolated port is forwarded only to promiscuous ports.
CommunityCommunity ports communicate among themselves and with their promiscuous ports.
These interfaces are separated at Layer 2 from all other interfaces in other communities or isolated
ports within their PVLAN.
Because trunks can support the VLANs carrying traffic between isolated, community, and promiscuous
ports, isolated and community port traffic might enter or leave the switch through a trunk interface.
PVLAN ports are associated with a set of supporting VLANs that are used to create the PVLAN
structure. A PVLAN uses VLANs three ways:
As a primary VLANCarries traffic from promiscuous ports to isolated, community, and other
promiscuous ports in the same primary VLAN.
As a community VLANCarries traffic between community ports and to promiscuous ports. You
can configure multiple community VLANs in a PVLAN.
36-1
Chapter 36
Overview of PVLANs
Isolated and community VLANs are called secondary VLANs. You can extend PVLANs across multiple
devices by trunking the primary, isolated, and community VLANs to other devices that support
PVLANs.
In a switched environment, you can assign an individual PVLAN and associated IP subnet to each
individual or common group of end stations. The end stations need to communicate with a default
gateway only to gain access outside the PVLAN. With end stations in a PVLAN, you can do the
following:
Note
Designate which ports will be connected to end stations. For example, interfaces connected to
servers as isolated ports prevent any communication at Layer 2.
Designate the interfaces to which the default gateway(s) and selected end stations (for example,
backup servers or LocalDirector) are attached as promiscuous ports to allow all end stations access.
Reduce VLAN and IP subnet consumption, because you can prevent traffic between end stations
even though they are in the same VLAN and IP subnet.
A promiscuous port can service only one primary VLAN. A promiscuous port can service one isolated
or many community VLANs.
With a promiscuous port, you can connect a wide range of devices as access points to a PVLAN. For
example, you can connect a promiscuous port to the server port of a LocalDirector to connect an isolated
VLAN or a number of community VLANs to the server. LocalDirector can load balance the servers
present in the isolated or community VLANs, or you can use a promiscuous port to monitor or back up
all the PVLAN servers from an administration workstation.
PVLAN Trunks
A PVLAN trunkport can carry multiple secondary and non-PVLANs. Packets are received and
transmitted with secondary or regular VLAN tags on the PVLAN trunk ports.
PVLAN trunk port behavior is the same as PVLAN isolated or community port behavior, except that
PVLANs can tag packets and carry multiple secondary and regular VLANs.
Note
A packet received on a PVLAN trunk port belongs to the secondary VLAN if the packet is tagged
with a secondary VLAN or if the packet is untagged and the native VLAN on the port is a secondary
VLAN.
A packet received on a PVLAN host or trunk port and assigned to a secondary VLAN is bridged on the
secondary VLAN. Because of this bridging, the secondary VLAN ACL as well as the secondary VLAN
QoS (on input direction) apply.
36-2
OL-6696-01
Chapter 36
When a packet is transmitted out of a PVLAN host or trunk port, the packet logically belongs to the
primary VLAN. This relationship applies even though the packet may be transmitted with the secondary
VLAN tagging for PVLAN trunk ports. In this situation, the primary VLAN ACL and the primary VLAN
QoS on output apply to the packet.
Set VTP mode to transparent. See the Disabling VTP (VTP Transparent Mode) section on page 27-9.
Step 2
Create the secondary VLANs. See the Configuring a VLAN as a PVLAN section on page 36-5.
Step 3
Create the primary VLAN. See the Configuring a VLAN as a PVLAN section on page 36-5.
Step 4
Associate the secondary VLAN to the primary VLAN. See the Associating a Secondary VLAN with a
Primary VLAN section on page 36-6.
Note
Only one isolated VLAN can be mapped to a primary VLAN, but more than one community
VLAN can be mapped to a primary VLAN.
Step 5
Configure an interface to an isolated or community port. See the Configuring a Layer 2 Interface as a
PVLAN Host Port section on page 36-8.
Step 6
Associate the isolated port or community port to the primary-secondary VLAN pair. See the
Associating a Secondary VLAN with a Primary VLAN section on page 36-6.
Step 7
Configure an interface as a promiscuous port. See the Configuring a Layer 2 Interface as a PVLAN
Promiscuous Port section on page 36-7.
Step 8
Map the promiscuous port to the primary-secondary VLAN pair. See the Configuring a Layer 2
Interface as a PVLAN Promiscuous Port section on page 36-7.
36-3
Chapter 36
Use only PVLAN commands to assign ports to primary, isolated, or community VLANs.
Layer 2 interfaces on primary, isolated, or community VLANs are inactive in PVLANs. Layer 2
trunk interfaces remain in the STP forwarding state.
Do not configure private VLAN ports as EtherChannels. While a port is part of the private VLAN
configuration, its associated EtherChannel configuration is inactive.
To prevent spanning tree loops due to misconfigurations, enable PortFast on the PVLAN trunk ports
with the spanning-tree portfast trunk command.
Any VLAN ACL configured on a secondary VLAN is effective in the input direction, and any VLAN
ACL configured on the primary VLAN associated with the secondary VLAN is effective in the
output direction.
You can stop Layer 3 switching on an isolated or community VLAN by deleting the mapping of that
VLAN with its primary VLAN.
PVLAN ports can be on different network devices as long as the devices are trunk-connected and
the primary and secondary VLANs remain associated with the trunk.
Isolated ports on two different devices cannot communicate with each other, but community VLAN
ports can.
A primary VLAN can be associated with multiple community VLANs, but only one isolated VLAN.
An isolated or community VLAN can be associated with only one primary VLAN.
If you delete a VLAN used in a private VLAN configuration, the private VLAN ports associated
with the VLAN become inactive.
VTP does not support private VLANs. You must configure private VLANs on each device in which
you plan to use private VLAN ports.
To maintain the security of your PVLAN configuration and avoid other use of VLANs configured
as PVLANs, configure PVLANs on all intermediate devices, even if the devices have no PVLAN
ports.
Prune the PVLANs from trunks on devices that carry no traffic in the PVLANs.
With port ACLS functionality available, you can apply Cisco IOS ACLS to secondary VLAN ports
and Cisco IOS ACLS to PVLANS (VACLs). For more information on VACLs, see Chapter 35,
Configuring Network Security with ACLs.
36-4
OL-6696-01
Chapter 36
You can apply different quality of service (QoS) configurations to primary, isolated, and community
VLANs. (See Chapter 29, Configuring QoS.) Cisco IOS ACLs applied to the Layer 3 VLAN
interface of a primary VLAN automatically apply to the associated isolated and community VLANs.
On a PVLAN trunk port a secondary VLAN ACL is applied on ingress traffic and a primary VLAN
ACL is applied on egress traffic.
You cannot change the VTP mode to client or server for PVLANs.
An isolated or community VLAN can have only one primary VLAN associated with it.
VTP does not support PVLANs. You must configure PVLANs on each device where you want
PVLAN ports.
ARP entries learned on Layer 3 PVLAN interfaces are termed sticky ARP entries (we recommend
that you display and verify PVLAN interface ARP entries).
For security reasons, PVLAN port sticky ARP entries do not age out. Connecting a device with a
different MAC address but with the same IP address generates an error message and the ARP entry
is not created.
Because PVLAN port sticky ARP entries do not age out, you must manually remove the entries if
you change the MAC address. To overwrite a sticky ARP entry, first delete the entry with the no arp
command, then overwrite the entry with the arp command.
In a DHCP environment, if you shut down your PC, it is not possible to give your IP address to
someone else. To solve this problem, the Catalyst 4500 series switch supports the no ip sticky-arp
command. This command promotes IP address overwriting and reuse in a DHCP environment.
Purpose
Step 1
Step 2
Step 3
Switch(config-vlan)# end
Step 4
This example shows how to configure VLAN 202 as a primary VLAN and verify the configuration:
Switch# configure terminal
Switch(config)# vlan 202
Switch(config-vlan)# private-vlan primary
Switch(config-vlan)# end
Switch# show vlan private-vlan
36-5
Chapter 36
This example shows how to configure VLAN 303 as a community VLAN and verify the configuration:
Switch# configure terminal
Switch(config)# vlan 303
Switch(config-vlan)# private-vlan community
Switch(config-vlan)# end
Switch# show vlan private-vlan
Primary Secondary Type
Interfaces
------- --------- ----------------- -----------------------------------------202
primary
303
community
This example shows how to configure VLAN 440 as an isolated VLAN and verify the configuration:
Switch# configure terminal
Switch(config)# vlan 440
Switch(config-vlan)# private-vlan isolated
Switch(config-vlan)# end
Switch# show vlan private-vlan
Primary Secondary Type
Interfaces
------- --------- ----------------- -----------------------------------------202
primary
303
community
440
isolated
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config-vlan)# end
Step 5
When you associate secondary VLANs with a primary VLAN, note the following:
The secondary_vlan_list parameter cannot contain spaces. It can contain multiple comma-separated
items. Each item can be a single private VLAN ID or a hyphenated range of private VLAN IDs.
The secondary_vlan_list parameter can contain only one isolated VLAN ID.
36-6
OL-6696-01
Chapter 36
Use the remove keyword with a secondary_vlan_list to clear the association between secondary
VLANs and a primary VLAN.
The command does not take effect until you exit VLAN configuration submode.
This example shows how to associate community VLANs 303 through 307 and 309 and isolated VLAN
440 with primary VLAN 202 and verify the configuration:
Switch# configure terminal
Switch(config)# vlan 202
Switch(config-vlan)# private-vlan association 303-307,309,440
Switch(config-vlan)# end
Switch# show vlan private-vlan
Primary
------202
202
202
202
202
202
202
Note
Secondary
--------303
304
305
306
307
309
440
308
Type
Interfaces
----------------- -----------------------------------------community
community
community
community
community
community
isolated
community
Purpose
Step 1
Step 2
Step 3
Step 4
Step 5
Switch(config-if)# end
Step 6
When you configure a Layer 2 interface as a PVLAN promiscuous port, note the following:
The secondary_vlan_list parameter cannot contain spaces. It can contain multiple comma-separated
items. Each item can be a single PVLAN ID or a hyphenated range of PVLAN IDs.
Enter a secondary_vlan_list or use the add keyword with a secondary_vlan_list to map the
secondary VLANs to the PVLAN promiscuous port.
36-7
Chapter 36
Use the remove keyword with a secondary_vlan_list to clear the mapping between secondary
VLANs and the PVLAN promiscuous port.
This example shows how to configure interface FastEthernet 5/2 as a PVLAN promiscuous port, map it
to a PVLAN, and verify the configuration:
Switch# configure terminal
Switch(config)# interface fastethernet 5/2
Switch(config-if)# switchport mode private-vlan promiscuous
Switch(config-if)# switchport private-vlan mapping 200 2
Switch(config-if)# end
Switch#show interfaces fastethernet 5/2 switchport
Name:Fa5/2
Switchport:Enabled
Administrative Mode:private-vlan promiscuous
Operational Mode:private-vlan promiscuous
Administrative Trunking Encapsulation:negotiate
Operational Trunking Encapsulation:native
Negotiation of Trunking:Off
Access Mode VLAN:1 (default)
Trunking Native Mode VLAN:1 (default)
Voice VLAN:none
Administrative Private VLAN Host Association:none
Administrative Private VLAN Promiscuous Mapping:200 (VLAN0200) 2 (VLAN0002)
Private VLAN Trunk Native VLAN:none
Administrative Private VLAN Trunk Encapsulation:dot1q
Administrative Private VLAN Trunk Normal VLANs:none
Administrative Private VLAN Trunk Private VLANs:none
Operational Private VLANs:
200 (VLAN0200) 2 (VLAN0002)
Trunking VLANs Enabled:ALL
Pruning VLANs Enabled:2-1001
Capture Mode Disabled
Capture VLANs Allowed:ALL
Purpose
Step 1
Step 2
Step 3
Step 4
Step 5
Switch(config-if)# end
Step 6
36-8
OL-6696-01
Chapter 36
This example shows how to configure interface FastEthernet 5/1 as a PVLAN host port and verify the
configuration:
Switch# configure terminal
Switch(config)# interface fastethernet 5/1
Switch(config-if)# switchport mode private-vlan host
Switch(config-if)# switchport private-vlan host-association 202 440
Switch(config-if)# end
Switch#show interfaces fastethernet 5/1 switchport
Name: Fa5/1
Switchport: Enabled
Administrative Mode: private-vlan host
Operational Mode: private-vlan host
Administrative Trunking Encapsulation: negotiate
Operational Trunking Encapsulation: native
Negotiation of Trunking: Off
Access Mode VLAN: 1 (default)
Trunking Native Mode VLAN: 1 (default)
Voice VLAN: none
Appliance trust: none
Administrative Private Vlan
Host Association: 202 (VLAN0202) 440 (VLAN0440)
Promiscuous Mapping: none
Trunk encapsulation : dot1q
Trunk vlans:
Operational private-vlan(s):
2 (VLAN0202) 3 (VLAN0440)
Trunking VLANs Enabled: ALL
Pruning VLANs Enabled: 2-1001
Capture Mode Disabled
Capture VLANs Allowed: ALL
Purpose
Step 1
Switch> enable
Step 2
Step 3
Step 4
36-9
Chapter 36
Step 5
Command
Purpose
Step 7
Step 8
Switch(config-if)# end
Step 9
This example shows how to configure interface FastEthernet 5/1 as a PVLAN trunk port, maps
VLAN0202 to VLAN0440, and configures the PVLAN trunk:
Switch# configure terminal
Switch(config)# interface fastethernet 5/1
Switch(config-if)# switchport private-vlan association trunk 202 440
Switch(config-if)# switchport mode private-vlan trunk
Switch(config-if)# end
Switch#show interfaces fastethernet 5/1 switchport
Name: Fa5/1
Switchport: Enabled
Administrative Mode: private-vlan trunk
Operational Mode: private-vlan trunk
Administrative Trunking Encapsulation: negotiate
Operational Trunking Encapsulation: dot1q
Negotiation of Trunking: On
36-10
OL-6696-01
Chapter 36
Command
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config-if)# end
Step 5
When you permit routing on the secondary VLAN ingress traffic, note the following:
The private-vlan mapping interface configuration command only affects private VLAN ingress
traffic that is Layer 3 switched.
The secondary_vlan_list parameter cannot contain spaces. It can contain multiple comma-separated
items. Each item can be a single private VLAN ID or a hyphenated range of private VLAN IDs.
Use the remove keyword with a secondary_vlan_list parameter to clear the mapping between
secondary VLANs and the primary VLAN.
36-11
Chapter 36
This example shows how to permit routing of secondary VLAN ingress traffic from private VLANs 303
through 307, 309, and 440 and verify the configuration:
Switch# configure terminal
Switch(config)# interface vlan 202
Switch(config-if)# private-vlan mapping add 303-307,309,440
Switch(config-if)# end
Switch# show interfaces private-vlan mapping
Interface Secondary VLAN Type
--------- -------------- ----------------vlan202
303
community
vlan202
304
community
vlan202
305
community
vlan202
306
community
vlan202
307
community
vlan202
309
community
vlan202
440
isolated
Switch#
36-12
OL-6696-01
C H A P T E R
37
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
Note
The flood blocking feature is supported on all switched ports (including PVLAN ports) and is applied
to all VLANs on which the port is forwarding.
Note
Blocking of unicast or multicast traffic is not automatically enabled on a switch port; you must
explicitly configure it.
37-1
Chapter 37
The interface can be a physical interface (for example, GigabitEthernet 1/1) or an EtherChannel
group (such as port-channel 5). When you block multicast or unicast traffic for a port channel, it is
blocked on all ports in the port channel group.
To disable the flooding of multicast and unicast packets to an interface, perform this task:
Command
Purpose
Step 1
Step 2
Step 3
Step 4
Step 5
Switch(config)# end
Step 6
Switch#
show interface interface-id switchport
Step 7
This example shows how to block unicast and multicast flooding on a GigabitEthernet interface 0/1 and
how to verify the configuration:
Switch# configure terminal
Switch(config)# interface gigabitethernet0/1
Switch(config-if)# switchport block multicast
Switch(config-if)# switchport block unicast
Switch(config-if)# end
Switch# show interface gigabitethernet1/1 switchport
Name: Gi1/3
Switchport: Enabled
<output truncated>
Port Protected: On
Unknown Unicast Traffic: Not Allowed
Unknown Multicast Traffic: Not Allowed
Broadcast Suppression Level: 100
Multicast Suppression Level: 100
Unicast Suppression Level: 100
37-2
OL-6696-01
Chapter 37
Purpose
Step 1
Step 2
Switch(config)# interface
interface-id
Enters interface configuration mode and enter the type and number of
the switchport interface (GigabitEthernet1/1).
Step 3
Switch(config-if)# no switchport
block multicast
Step 4
Switch(config-if)# no switchport
block unicast
Step 5
Switch(config)# end
Step 6
switchport
Step 7
37-3
Chapter 37
37-4
OL-6696-01
C H A P T E R
38
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
This chapter consists of these sections:
Storm control prevents LAN interfaces from being disrupted by a broadcast storm. A broadcast storm
occurs when broadcast packets flood the subnet, creating excessive traffic and degrading network
performance. Errors in the protocol-stack implementation or in the network configuration can cause a
broadcast storm.
Note
Storm control is supported in hardware on all ports on the WS-X4516 supervisor engine. In contrast, the
supervisor engines WS-X4515, WS-X4014, and WS-X4013+ support storm control in hardware on
non-blocking gigabit ports and in software on all other ports, implying that the counters for these
interfaces are approximate and computed. Multicast storm control is only supported on the WS-X4516
supervisor engine.
38-1
Chapter 38
Total
number of
broadcast
packets
or bytes
T1
T2
T3
T4
T5
Time
S5706
Threshold
The broadcast suppression threshold numbers and the time interval combination make the broadcast
suppression algorithm work with different levels of granularity. A higher threshold allows more
broadcast packets to pass through.
Broadcast suppression on the Catalyst 4500 series switches is implemented in hardware. The
suppression circuitry monitors packets passing from a LAN interface to the switching bus. If the packet
destination address is broadcast, then the broadcast suppression circuitry tracks the current count of
broadcasts within the one-second interval, and when a threshold is reached, it filters out subsequent
broadcast packets.
Because hardware broadcast suppression uses a bandwidth-based method to measure broadcast activity,
the most significant implementation factor is setting the percentage of total available bandwidth that can
be used by broadcast traffic. Because packets do not arrive at uniform intervals, the one-second interval
during which broadcast activity is measured can affect the behavior of broadcast suppression.
38-2
OL-6696-01
Chapter 38
Purpose
Step 1
Step 2
Step 3
Switch(config-if)# storm-control
broadcast level [high level] [lower
level]
Step 4
Switch(config-if)# storm-control
action {shutdown | trap}
Step 5
Switch(config-if)# exit
Step 6
Switch(config)# end
Step 7
Step 8
38-3
Chapter 38
Purpose
Step 1
Step 2
Switch(config)# interface
interface-id
Step 3
Switch(config-if)# no storm-control
broadcast level
Step 4
Switch(config-if)# no storm-control
action { shutdown | trap}
Disables the specified storm control action and returns to default filter
action.
Step 5
Switch(config-if)# exit
Step 6
Switch(config)# end
Step 7
Step 8
Use the show interface capabilities command to determine the mode in which storm control is
supported on an interface.
The following example shows an interface that supports broadcast suppression in software (sw).
Switch# show interfaces g4/4 capabilities
show interfaces g4/4 capabilities
GigabitEthernet4/4
Model:
WS-X4418-Gbic
Type:
1000BaseSX
38-4
OL-6696-01
Chapter 38
Speed:
Duplex:
Trunk encap. type:
Trunk mode:
Channel:
Broadcast suppression:
Flowcontrol:
VLAN Membership:
Fast Start:
Queuing:
CoS rewrite:
ToS rewrite:
Inline power:
SPAN:
UDLD:
Link Debounce:
Link Debounce Time:
Port Security:
Dot1x:
Maximum MTU:
Media Type:
1000
full
802.1Q
on,off,desirable,nonegotiate
yes
percentage(0-100), sw
rx-(off,on,desired),tx-(off,on,desired)
static, dynamic
yes
rx-(N/A), tx-(4q1t, Shaping)
yes
yes
no
source/destination
yes
no
no
yes
yes
1552 bytes (Baby Giants)
no
Switch#
The following example shows an interface that supports broadcast suppression in hardware (hw).
Switch# show interfaces g4/1 capabilities
show interfaces g4/1 capabilities
GigabitEthernet4/1
Model:
WS-X4418-Gbic
Type:
No Gbic
Speed:
1000
Duplex:
full
Trunk encap. type:
802.1Q,ISL
Trunk mode:
on,off,desirable,nonegotiate
Channel:
yes
Broadcast suppression: percentage(0-100), hw
Flowcontrol:
rx-(off,on,desired),tx-(off,on,desired)
VLAN Membership:
static, dynamic
Fast Start:
yes
Queuing:
rx-(N/A), tx-(4q1t, Sharing/Shaping)
CoS rewrite:
yes
ToS rewrite:
yes
Inline power:
no
SPAN:
source/destination
UDLD:
yes
Link Debounce:
no
Link Debounce Time:
no
Port Security:
yes
Dot1x:
yes
Maximum MTU:
1552 bytes (Baby Giants)
Media Type:
no
Switch#
Note
Use the show interfaces counters storm-control command to display a count of discarded packets.
Switch# show interfaces counters storm-control
Port
Gi4/4
Switch#
BcastSuppLevel
2.00%
TotalSuppressedPackets
0
38-5
Chapter 38
Note
Use the show storm-control command to display the configured thresholds and status of storm on an
interface.
Switch# show storm-control
Interface
--------Gi4/4
Switch
Note
Filter State
------------Forwarding
Upper
------2.00%
Lower
------2.00%
Current
------N/A
In the example shown above, current represents the percentage of traffic suppressed at a given instant,
and the value is N/A for ports that perform suppression in hardware.
Note
Multicast storm control is available only on WS-X4516 supervisors; only a hardware-based solution is
provided.
Purpose
Step 1
Step 2
Switch(config)# interface
interface-id
Step 3
Switch(config-if)# [no]
storm-control broadcast include
multicast
Step 4
Switch(config-if)# end
38-6
OL-6696-01
Chapter 38
The following example shows how to enable multicast suppression on ports that have broadcast
suppression already enabled:
Switch# configuration terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface fa3/1
Switch(config-if)# storm-control broadcast include multicast
Switch(config-if)# end
Switch#
38-7
Chapter 38
38-8
OL-6696-01
C H A P T E R
39
Note
For complete syntax and usage information for the switch commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm.
SPAN mirrors traffic from one or more source interfaces on any VLAN or from one or more VLANs to
a destination interface for analysis. In Figure 39-1, all traffic on Ethernet interface 5 (the source
interface) is mirrored to Ethernet interface 10. A network analyzer on Ethernet interface 10 receives all
network traffic from Ethernet interface 5 without being physically attached to it.
39-1
Chapter 39
For SPAN configuration, the source interfaces and the destination interface must be on the same switch.
SPAN does not affect the switching of network traffic on source interfaces; copies of the packets received
or transmitted by the source interfaces are sent to the destination interface.
Figure 39-1 Example SPAN Configuration
E5
E6 E7
E4
E2
E3
E11
E12
E8
E9
E10
Network analyzer
S6884
E1
RSPAN extends SPAN by enabling remote monitoring of multiple switches across your network. The
traffic for each RSPAN session is carried over a user-specified RSPAN VLAN that is dedicated for that
RSPAN session in all participating switches. The SPAN traffic from the sources is copied onto the
RSPAN VLAN and then forwarded over trunk ports that are carrying the RSPAN VLAN to any RSPAN
destination sessions monitoring the RSPAN VLAN, as shown in Figure 39-2.
Figure 39-2 Example of RSPAN Configuration
Intermediate switch
RSPAN
VLAN
RSPAN
source port
Destination switch
RSPAN
VLAN
105028
Source switch
RSPAN
destination port
SPAN and RSPAN do not affect the switching of network traffic on source ports or source VLANs; a
copy of the packets received or sent by the sources is sent to the destination. Except for traffic that is
required for the SPAN or RSPAN session, by default, destination ports do not receive or forward traffic.
You can use the SPAN or RSPAN destination port to forward transmitted traffic from a network security
device. For example, if you connect a Cisco Intrusion Detection System (IDS) sensor appliance to a
destination port, the IDS device can send TCP reset packets to close down the TCP session of a suspected
attacker.
39-2
OL-6696-01
Chapter 39
SPAN Session
A local SPAN session associates a destination port with source ports. You can monitor incoming or
outgoing traffic on a series or range of ports and source VLANs. An RSPAN session associates source
ports and source VLANs across your network with an RSPAN VLAN. The destination source is the
RSPAN VLAN.
You configure SPAN sessions by using parameters that specify the source of network traffic to monitor.
You can configure multiple SPAN or RSPAN sessions with separate or overlapping sets of SPAN
sources. Both switched and routed ports can be configured as SPAN sources or destination ports.
An RSPAN source session associates SPAN source ports or VLANs with a destination RSPAN VLAN.
An RSPAN destination session associates an RSPAN VLAN with a destination port.
SPAN sessions do not interfere with the normal operation of the switch; however, an oversubscribed
SPAN destination (for example, a 10-Mbps port monitoring a 100-Mbps port) results in dropped or lost
packets.
You can configure SPAN sessions on disabled ports; however, a SPAN session does not become active
unless you enable the destination port and at least one source port or VLAN for that session.
A SPAN session remains inactive after system startup until the destination port is operational.
Traffic Types
SPAN sessions include these traffic types:
Receive (Rx) SPANThe goal of receive (or ingress) SPAN is to monitor as much as possible all
packets received by the source interface or VLAN before any modification or processing is
performed by the switch. A copy of each packet received by the source is sent to the destination port
for that SPAN session. You can monitor a series or range of ingress ports or VLANs in a SPAN
session.
On tagged packets (Inter-Switch Link [ISL] or IEEE 802.1Q), the tagging is removed at the ingress
port. At the destination port, if tagging is enabled, the packets appear with the ISL or 802.1Q
headers. If no tagging is specified, packets appear in the native format.
Packets that are modified because of routing are copied without modification for Rx SPAN; that is,
the original packet is copied. Packets that are modified because of quality of service (QoS)for
example, modified Differentiated Services Code Point (DSCP)are copied with modification for Rx
SPAN.
39-3
Chapter 39
Some features that can cause a packet to be dropped during receive processing have no effect on
SPAN; the destination port receives a copy of the packet even if the actual incoming packet is
dropped. These features include IP standard and extended input access control lists (ACLs), IP
standard and extended output ACLs for unicast and ingress QoS policing, VLAN maps, ingress QoS
policing, and policy-based routing. Switch congestion that causes packets to be dropped also has no
effect on SPAN.
Transmit (Tx) SPANThe goal of transmit (or egress) SPAN is to monitor as much as possible all
packets sent by the source interface after the switch performs all modification and processing. After
the packet is modified, the source sends a copy of each packet to the destination port for that SPAN
session. You can monitor a range of egress ports in a SPAN session.
Packets that are modified because of routingfor example, with a time-to-live (TTL) or
MAC-address modificationare duplicated at the destination port. On packets that are modified
because of QoS, the modified packet might not have the same DSCP (IP packet) or CoS (non-IP
packet) as the SPAN source.
Some features that can cause a packet to be dropped during transmit processing might also affect the
duplicated copy for SPAN. These features include VLAN maps, IP standard and extended output
ACLs on multicast packets, and egress QoS policing. In the case of output ACLs, if the SPAN source
drops the packet, the SPAN destination would also drop the packet. In the case of egress QoS
policing, if the SPAN source drops the packet, the SPAN destination might not drop it. If the source
port is oversubscribed, the destination ports will have different dropping behavior.
BothIn a SPAN session, you can monitor a single port series or a range of ports for both received
and sent packets.
Source Port
A source port (also called a monitored port) is a switched or routed port that you monitor for network
traffic analysis. In a single local SPAN session or RSPAN source session, you can monitor source port
traffic, such as received (Rx), transmitted (Tx), or bidirectional (both). The switch supports any number
of source ports (up to the maximum number of available ports on the switch) and any number of source
VLANs.
A source port has these characteristics:
It can be any port type (for example, EtherChannel, Fast Ethernet, Gigabit Ethernet, and so forth).
Each source port can be configured with a direction (ingress, egress, or both) to monitor. For
EtherChannel sources, the monitored direction would apply to all physical ports in the group.
For VLAN SPAN sources, all active ports in the source VLAN are included as source ports.
You can configure a trunk port as a source port. By default, all VLANs active on the trunk are monitored.
You can limit SPAN traffic monitoring on trunk source ports to specific VLANs by using VLAN
filtering. Only switched traffic in the selected VLANs is sent to the destination port. This feature affects
only traffic forwarded to the destination SPAN port and does not affect the switching of normal traffic.
This feature is not allowed in sessions with VLAN sources.
39-4
OL-6696-01
Chapter 39
Destination Port
Each local SPAN session or RSPAN destination session must have a destination port (also called a
monitoring port) that receives a copy of traffic from the source ports and VLANs.
A destination port has these characteristics:
A destination port must reside on the same switch as the source port (for a local SPAN session).
A destination port can participate in only one SPAN session at a time. (A destination port in one
SPAN session cannot be a destination port for a second SPAN session.)
A destination port can be a physical port that is assigned to an EtherChannel group, even if the
EtherChannel group has been specified as a SPAN source. The port is removed from the group while
it is configured as a SPAN destination port.
The port does not transmit any traffic except that traffic required for the SPAN session unless
learning is enabled. If learning is enabled, the port will also transmit traffic directed to hosts that
have been learned on the destination port.
If ingress traffic forwarding is enabled for a network security device, the destination port forwards
traffic at Layer 2.
A destination port does not participate in spanning tree while the SPAN session is active.
When it is a destination port, it does not participate in any of the Layer 2 protocols (STP, VTP, CDP,
DTP, PagP).
A destination port that belongs to a source VLAN of any SPAN session is excluded from the source
list and is not monitored.
A destination port receives copies of sent and received traffic for all monitored source ports. If a
destination port is oversubscribed, it could become congested. This congestion could affect traffic
forwarding on one or more of the source ports.
VLAN-Based SPAN
VLAN-based SPAN (VSPAN) is the monitoring of the network traffic in one or more VLANs.
Use these guidelines for VSPAN sessions:
If a destination port belongs to a source VLAN, it is excluded from the source list and is not
monitored.
If ports are added to or removed from the source VLANs, the traffic on the source VLAN received
by those ports is added to or removed from the sources being monitored.
VLAN pruning and the VLAN allowed list have no effect on SPAN monitoring.
VSPAN monitors only traffic that enters the switch, not traffic that is routed between VLANs. For
example, if a VLAN is being Rx-monitored, and the multilayer switch routes traffic from another
VLAN to the monitored VLAN, that traffic is not monitored and is not received on the SPAN
destination port.
39-5
Chapter 39
Configuring SPAN
You cannot use filter VLANs in the same session with VLAN sources.
SPAN Traffic
You can use local SPAN to monitor all network traffic, including multicast and bridge protocol data unit
(BPDU) packets, Cisco Discovery Protocol (CDP), VLAN Trunk Protocol (VTP), Dynamic Trunking
Protocol (DTP), Spanning Tree Protocol (STP), and Port Aggregation Protocol (PAgP) packets. You
cannot use RSPAN to monitor Layer 2 protocols. (See the RSPAN Configuration Guidelines section
on page 39-16 for more information.)
In some SPAN configurations, multiple copies of the same source packet are sent to the SPAN
destination port. For example, a bidirectional (both Rx and Tx) SPAN session is configured for the
sources a1 Rx monitor and the a2 Rx and Tx monitor to destination port d1. If a packet enters the switch
through a1 and is switched to a2, both incoming and outgoing packets are sent to destination port d1.
Both packets are the same (unless a Layer-3 rewrite occurs, in which case the packets are different
because of the added Layer 3 information).
Feature
Default Setting
SPAN state
Disabled.
Filters
Disabled.
Disabled.
Configuring SPAN
The following sections describe how to configure SPAN:
39-6
OL-6696-01
Chapter 39
Note
Entering SPAN configuration commands does not clear previously configured SPAN parameters. You
must enter the no monitor session command to clear configured SPAN parameters.
You cannot mix source VLANs and filter VLANs within a SPAN session. You can have source
VLANs or filter VLANs, but not both at the same time.
EtherChannel interfaces can be SPAN source interfaces; they cannot be SPAN destination interfaces.
When you specify source interfaces and do not specify a traffic type (Tx, Rx, or both), both is used
by default.
If you specify multiple SPAN source interfaces, the interfaces can belong to different VLANs.
You must enter the no monitor session number command with no other parameters to clear the
SPAN session number.
SPAN destinations never participate in any spanning tree instance. SPAN includes BPDUs in the
monitored traffic, so any BPDUs seen on the SPAN destination are from the SPAN source.
39-7
Chapter 39
Configuring SPAN
Purpose
This example shows how to configure sources with differing directions within a SPAN session:
Switch(config)# monitor session 1 source interface fa2/3 rx
Switch(config)# monitor session 1 source interface fa2/2 tx
Switch(config)#
39-8
OL-6696-01
Chapter 39
Purpose
This example shows how to configure interface Fast Ethernet 5/48 as the destination for SPAN session 1:
Switch(config)# monitor session 1 destination interface fastethernet 5/48
Purpose
This example shows how to monitor VLANs 1 through 5 and VLAN 9 when the SPAN source is a trunk
interface:
Switch(config)# monitor session 2 filter vlan 1 - 5 , 9
39-9
Chapter 39
Configuration Scenario
This example shows how to use the commands described in this chapter to completely configure and
unconfigure a span session. Assume that you want to monitor bidirectional traffic from source interface
Fast Ethernet 4/10, which is configured as a trunk interface carrying VLANs 1 through 4094. Moreover,
you want to monitor only traffic in VLAN 57 on that trunk. Using Fast Ethernet 4/15 as your destination
interface, you would enter the following commands:
Switch(config)# monitor session 1 source interface fastethernet 4/10
Switch(config)# monitor session 1 filter vlan 57
Switch(config)# monitor session 1 destination interface fastethernet 4/15
You are now monitoring traffic from interface Fast Ethernet 4/10 that is on VLAN 57 out of interface
FastEthernet 4/15. To disable the span session enter the following command:
Switch(config)# no monitor session 1
39-10
OL-6696-01
Chapter 39
Purpose
This example shows how to use queue names and queue number ranges for the CPU as a SPAN source:
Switch(config)# monitor session 2 source cpu queue control-packet rx
Switch(config)# monitor session 3 source cpu queue 21 -23 rx
39-11
Chapter 39
Encapsulation Configuration
Encapsulation Configuration
When configuring a SPAN destination port, you can explicitly specify the encapsulation type used by
the port. Packets sent out the port are tagged in accordance with the specified mode. (The encapsulation
mode also controls how tagged packets are handled when the ingress packet option is enabled.) The
Catalyst 4500 series switch supervisor engines support ISL encapsulation and 802.1q encapsulation, as
well as untagged packets. The replicate encapsulation type (in which packets are transmitted from the
destination port using whatever encapsulation applied to the original packet) is not supported. If no
encapsulation mode is specified, the port default is untagged. To view the task of configuring
encapsulation, see the command table below.
Ingress Packets
When ingress is enabled, the SPAN destination port accepts incoming packets (potentially tagged
depending on the specified encapsulation mode) and switches them normally. When configuring a SPAN
destination port, you can specify whether or not the ingress feature is enabled and what VLAN to use to
switch untagged ingress packets. (Specifying an ingress VLAN is not required when ISL encapsulation
is configured, as all ISL encapsulated packets have VLAN tags.) Although the port is STP forwarding,
it does not participate in the STP, so use caution when configuring this feature lest a spanning-tree loop
be introduced in the network. When both ingress and a trunk encapsulation are specified on a SPAN
destination port, the port will go forwarding in all active VLANs. Configuring a non-existent VLAN as
an ingress VLAN is not allowed.
By default, host learning is disabled on SPAN destination ports with ingress enabled. The port is also
removed from VLAN floodsets, so regular traffic will not be switched out of the destination port. If
learning is enabled, however, then traffic for hosts learned on the destination port will be switched out
the destination port. It is also possible to configure static host entries (including a static ARP entry and
a static entry in the MAC-address table) on SPAN destination ports.
Note
This configuration will not work if the SPAN session does not have a source configured; the session is
half configured with only the SPAN destination port.
To configure ingress packets and encapsulation, perform this task:
Command
Purpose
39-12
OL-6696-01
Chapter 39
This example shows how to configure a destination port with 802.1q encapsulation and ingress packets
using native VLAN 7:
Switch(config)# monitor session 1 destination interface fastethernet 5/48
encapsulation dot1q ingress vlan 7
With this configuration, traffic from SPAN sources associated with session 1 would be copied out of
interface Fast Ethernet 5/48, with 802.1q encapsulation. Incoming traffic would be accepted and
switched, with untagged packets being classified into VLAN 7.
Note
If an ACL is associated with a SPAN session, the rules associated with that ACL are applied against
all packets exiting the SPAN destination interface. Rules pertaining to other VACLs or RACLs
previously associated with the SPAN destination interface are not applied.
When no ACLs are applied to packets exiting a SPAN destination interface, all traffic is permitted
regardless of the PACLs, VACLs, or RACLs that have been previously applied to the destination
interface or VLAN to which the SPAN destination interface belongs.
If an ACL is removed from a SPAN session, all traffic is permitted once again.
If SPAN configuration is removed from the SPAN session, all rules associated with the SPAN
destination interface are applied once again.
If a SPAN destination port is configured as a trunk port and the VLANs to which it belongs have
ACLs associated with them, the traffic is not subjected to the VACLs.
ACL configuration applies normally to the RSPAN VLAN and to trunk ports carrying the RSPAN
VLAN. This configuration enables the user to apply VACLs on RSPAN VLANs. If a user attempts
to configure an ACL on a SPAN session with the destination port as an RSPAN VLAN, the
configuration is rejected.
If CAM resources are exhausted and packets are passed to the CPU for lookup, any output port ACLs
associated with a SPAN session are not applied.
If a named IP ACL is configured on a SPAN session before an ACL is created, the configuration is
accepted, and the software creates an empty ACL with no ACEs. (An empty ACL permits all
packets.) Subsequently, the rules can be added to the ACL.
The ACLs associated with a SPAN session are applied on the destination interface on output.
39-13
Chapter 39
Purpose
Note
IP access lists must be created in configuration mode as described in the chapter Configuring Network
Security with ACLs.
This example shows how to configure IP access group 10 on a SPAN session and verify that an access
list has been configured:
Switch(config)# monitor
Switch(config)# monitor
Switch(config)# monitor
Switch(config)# monitor
Switch(config)# exit
Switch# show monitor
Session 1
--------Type
Source Ports
Both
Destination Ports
Encapsulation
Ingress
Learning
Filter VLANs
IP Access-group
:
:
:
:
:
:
:
:
:
session
session
session
session
1
1
1
1
Local Session
Fa6/1
Fa6/2
Native
Disabled
Disabled
1
10
39-14
OL-6696-01
Chapter 39
There are two categories of packet filtering: packet-based (good, error) or address-based
(unicast/multicast/broadcast). Packet-based filters can only be applied in the ingress direction. Packets
are classified as broadcast, multicast, or unicast by the hardware based on the destination address.
Note
When filters of both types are configured, only packets that pass both filters are spanned. For example,
if you set both error and multicast, only multicast packets with errors will be spanned.
To configure packet type filtering, perform this task:
Command
Purpose
This example shows how to configure a session to accept only unicast packets in the ingress direction:
Switch(config)# monitor session 1 filter address-type unicast rx
Configuration Example
The following is an example of SPAN configuration using some of the SPAN enhancements.
In the example below, you configure a session to sniff unicast traffic arriving on interface Gi1/1. The
traffic is mirrored out of interface Gi1/2 with ISL encapsulation. Ingress traffic is permitted.
Switch(config)# monitor session 1 source interface gi1/1 rx
Switch(config)# monitor session 1 destination interface gi1/2 encapsulation isl ingress
Switch(config)# monitor session 1 filter address-type unicast rx
Switch(config)# exit
Switch# show monitor
Session 1
--------Type
Source Ports
RX Only
Destination Ports
Encapsulation
Ingress
Learning
Filter Addr Type
RX Only
:
:
:
:
:
:
:
:
:
Local Session
Gi1/1
Gi1/2
ISL
Enabled
Disabled
Unicast
39-15
Chapter 39
Configuring RSPAN
Configuring RSPAN
This section describes how to configure RSPAN on your switch and it contains this configuration
information:
Creating an RSPAN Destination Session and Enabling Ingress Traffic, page 39-19
Note
Since RSPAN VLANs have special properties, you should reserve a few VLANs across your network
for use as RSPAN VLANs; do not assign access ports to these VLANs.
Note
You can apply an output access control list (ACL) to RSPAN traffic to selectively filter or monitor
specific packets. Specify these ACLs on the RSPAN VLAN in the RSPAN source switches.
RSPAN sessions can coexist with SPAN sessions within the limits described in the SPAN and
RSPAN Session Limits section on page 39-6.
For RSPAN configuration, you can distribute the source ports and the destination ports across
multiple switches in your network.
RSPAN does not support BPDU packet monitoring or other Layer 2 switch protocols.
The RSPAN VLAN is configured only on trunk ports and not on access ports. To avoid unwanted
traffic in RSPAN VLANs, make sure that all participating switches support the VLAN remote-span
feature. Access ports on the RSPAN VLAN are silently disabled.
You should create an RSPAN VLAN before configuring an RSPAN source or destination session.
If you enable VTP and VTP pruning, RSPAN traffic is pruned in the trunks to prevent the unwanted
flooding of RSPAN traffic across the network for VLAN-IDs that are lower than 1005.
Because RSPAN traffic is carried across a network on an RSPAN VLAN, the original VLAN
association of the mirrored packets is lost. Therefore, RSPAN can only support forwarding of traffic
from an IDS device onto a single user-specified VLAN.
39-16
OL-6696-01
Chapter 39
Purpose
Step 1
Step 2
Step 3
Specifies the RSPAN session and the source port (monitored port).
For session_number, specifies the session number identified with this
RSPAN session (1 through 6).
For interface-list, specifies the source port to monitor. Valid
interfaces include physical interfaces and port-channel logical
interfaces (port-channel port-channel-number).
For vlan-IDs, specifies the source VLAN or VLANs to monitor.
Valid VLANs are in the range from 1 to 4094.
For queue_ids, specifies either a set of CPU queue numerical
identifiers from 1 to 32, or a named queue.
(Optional) [, | -] Specifies a series or range of interfaces. Enter a
space after the comma; enter a space before and after the hyphen.
(Optional) Specifies the direction of traffic to monitor. If you do not
specify a traffic direction, the source interface sends both transmitted
(Tx) and received (Rx) traffic. Only received traffic can be monitored
on additional source ports.
Step 4
39-17
Chapter 39
Configuring RSPAN
Command
Purpose
Step 5
Switch(config)# end
Step 6
Step 7
This example shows how to clear any existing RSPAN configuration for session 1, configure RSPAN
session 1 to monitor multiple source interfaces, and configure the destination RSPAN VLAN.
Switch(config)#
Switch(config)#
Switch(config)#
Switch(config)#
Switch(config)#
Switch(config)#
Switch(config)#
no monitor session 1
monitor session 1 source interface fastEthernet3/10 tx
monitor session 1 source interface fastEthernet3/2 rx
monitor session 1 source interface fastEthernet3/3 rx
monitor session 1 source interface port-channel 102 rx
monitor session 1 destination remote vlan 901
end
Purpose
Step 1
Step 2
Step 3
Step 4
Switch(config)# end
39-18
OL-6696-01
Chapter 39
Command
Purpose
Step 5
Step 6
This example shows how to configure VLAN 901 as the source remote VLAN and port 5 as the
destination interface:
Switch(config)# monitor session 1 source remote vlan 901
Switch(config)# monitor session 1 destination interface gigabitEthernet1/2
Switch(config)# end
Purpose
Step 1
Step 2
39-19
Chapter 39
Configuring RSPAN
Step 3
Command
Purpose
Step 4
Switch(config)# end
Step 5
Step 6
This example shows how to configure VLAN 901 as the source remote VLAN and how to configure the
destination port for ingress traffic on VLAN 5 by using a security device that supports 802.1Q
encapsulation:
Switch(config)# monitor session 1 source remote vlan 901
Switch(config)# monitor session 1 destination interface gigabitEthernet1/2 ingress vlan 5
Switch(config)# end
39-20
OL-6696-01
Chapter 39
Purpose
Step 1
Step 2
Step 3
Switch(config)# end
Step 4
Step 5
This example shows how to remove port 1 as an RSPAN source for RSPAN session 1:
Switch(config)# no monitor session 1 source interface gigabitEthernet1/1
Switch(config)# end
This example shows how to disable received traffic monitoring on port 1, which was configured for
bidirectional monitoring:
Switch(config)# no monitor session 1 source interface gigabitEthernet1/1 rx
The monitoring of traffic received on port 1 is disabled, but traffic transmitted from this port continues
to be monitored.
39-21
Chapter 39
Configuring RSPAN
Purpose
Step 1
Step 2
Step 3
Step 4
Step 5
Switch(config)# end
Step 6
Step 7
To remove one or more source VLANs from the RSPAN session, use the no monitor session
session_number source vlan vlan-id rx global configuration command.
39-22
OL-6696-01
Chapter 39
This example shows how to clear any existing configuration on RSPAN session 2, configure RSPAN
session 2 to monitor received traffic on all ports belonging to VLANs 1 through 3, and send it to
destination remote VLAN 902. The configuration is then modified to also monitor received traffic on all
ports belonging to VLAN 10.
Switch(config)#
Switch(config)#
Switch(config)#
Switch(config)#
Switch(config)#
no monitor session 2
monitor session 2 source vlan 1 - 3 rx
monitor session 2 destination remote vlan 902
monitor session 2 source vlan 10 rx
end
Purpose
Step 1
Step 2
Step 3
39-23
Chapter 39
Step 4
Command
Purpose
Step 5
Step 6
Switch(config)# end
Step 7
Step 8
To monitor all VLANs on the trunk port, use the no monitor session session_number filter vlan global
configuration command.
This example shows how to clear any existing configuration on RSPAN session 2, configure RSPAN
session 2 to monitor traffic received on trunk port 4, and send traffic for only VLANs 1 through 5 and 9
to destination remote VLAN 902.
Switch(config)#
Switch(config)#
Switch(config)#
Switch(config)#
Switch(config)#
no monitor session 2
monitor session 2 source interface gigabitethernet1/1 rx
monitor session 2 filter vlan 1 - 5 , 9
monitor session 2 destination remote vlan 902
end
39-24
OL-6696-01
Chapter 39
Source VLANs:
RX Only:
None
TX Only:
None
Both:
None
Source RSPAN VLAN: None
Destination Ports: None
Encapsulation: DOT1Q
Ingress:Enabled, default VLAN=5
Filter VLANs:
None
Dest RSPAN VLAN: None
Ingress : Enabled, default VLAN=2
Learning : Disabled
39-25
Chapter 39
39-26
OL-6696-01
C H A P T E R
40
Note
To use the NetFlow feature, you must have the Supervisor Engine V-10GE (the functionality is
embedded in the supervisor engine), or the NetFlow Services Card (WS-F4531) and either a
Supervisor Engine IV or a Supervisor Engine V.
Note
For complete syntax and usage information for the commands used in this chapter, refer to the
Catalyst 4500 Series Switch Cisco IOS Command Reference and related publications at
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/index.htm. Refer to the
NetFlow Solutions Guide for more detailed information on NetFlow usage and management.
The following topics are included:
NoteNetFlow support has hardware limitations that restrict the platform support to a subset of all
NetFlow fields. Specifically, TCP Flags and the ToS byte (DSCP) are not supported., page 40-6
40-1
Chapter 40
NetFlow exports flow information in UDP datagrams in one of two formats. The version 1 format was
the initial released version, and version 5 is a later enhancement to add Border Gateway Protocol (BGP)
autonomous system (AS) information and flow sequence numbers. In version 1 and version 5 format, the
datagram consists of a header and one or more flow records. The first field of the header contains the
version number of the export datagram.
This section contains the following subsections:
Determining the Input and Output Interface and AS Numbers, page 40-4
Feature Interaction of Netflow Statistics with UBRL and Microflow Policing, page 40-5
NDE Versions
The Catalyst 4500 series switch supports NDE versions 1 and 5 for the captured statistics. NetFlow
aggregation requires NDE version 8.
Depending on the current flow mask, some fields in the flow records might not have values. Unsupported
fields contain a zero (0).
The following tables describe the supported fields for NDE version 5:
Bytes
Content
Description
01
version
23
count
47
SysUptime
811
unix_secs
1215
unix_nsecs
1619
flow_sequence
2021
engine_type
2123
engine_id
40-2
OL-6696-01
Chapter 40
Source IP address
47
dstaddr
Destination IP address
811
nexthop
1213 input
Full
Interface
srcaddr
Full
03
Destination
Source
Interface
Description
Destination
Source
Content
Source
Bytes
Destination
Flow masks:
X=Populated
A=Additional field
A1
2831 last
3233 srcport
X2
X2
3435 dstport
36
pad1
37
tcp_flags
38
prot
Layer 4 protocol
(for example, 6=TCP, 17=UDP)
39
tos
IP type-of-service byte
1415 output
1619 dPkts
2023 dOctets
2427 first
4041 src_as
4243 dst_as
4445 src_mask
4647 dst_mask
48
pad2
X
X
X
X
1. With the destination flow mask, the Next hop routers IP address field and the Output interfaces SNMP ifIndex field might not contain information
that is accurate for all flows.
2. In PFC3BXL or PFC3B mode, ICMP traffic contains the ICMP code and type values.
40-3
Chapter 40
IP protocol
Routing information, including next-hop address, origin and peer AS, source and destination prefix
mask
Determining the Output Interface and Output Related Inferred Fields, page 40-4
Determining the Input Interface and Input Related Inferred Fields, page 40-5
40-4
OL-6696-01
Chapter 40
Note
If load balancing is being applied by an upstream adjacent switch, one input interface must be
chosen arbitrarily out of the multiple input interfaces available. This action is necessary because the
input interface that would be used depends on the type of load balancing algorithm being deployed
by the adjacent upstream switch. It is not always feasible to know the algorithm. Therefore, all flow
statistics will be attributed to one input interface. Software selects the interface with the lowest IP
subnet number.
In an asymmetric routing scheme, where the traffic for an IP subnet might be received on an
interface that is different from the interface where packets are sent to this IP subnet, the inferences
noted previously for selecting an input interface, based on a reverse lookup, would be incorrect and
cannot be verified.
If PBR or VRF is enabled on the switch and the flow is destined to an address that resides in the
PBR or VRF range or is sourced from an address that resides in the PBR or VRF range, the
information will be incorrect. In this case, the input and output interface will most likely point to
the default route (if configured) or will have no value at all (NULL)
If VRF is enabled on the switch on some interfaces and the flow is sourced from a VRF interface,
the information will be incorrect. In this case, the input and output interface will most likely point
to the default route (if configured) or will have no value (NULL).
The Supervisor Engine V-10GE does a better job at this by providing the input interface information via
hardware. Having this information greatly improves the accuracy of the inferred fields.
VLAN Statistics
With NetFlow support, you can report Layer 2 output VLAN statistics, as well as VLAN statistics for
routed traffic in and out of a VLAN.
40-5
Chapter 40
The following example shows the CLI output for a specific VLAN:
cat4k-sup4-2# sh vlan counters or show vlan id 22 count
* Multicast counters include broadcast packets
Vlan Id
:22
L2 Unicast Packets
:38
L2 Unicast Octets
:2432
L3 Input Unicast Packets
:14344621
L3 Input Unicast Octets
:659852566
L3 Output Unicast Packets
:8983050
L3 Output Unicast Octets
:413220300
L3 Output Multicast Packets
:0
L3 Output Multicast Octets
:0
L3 Input Multicast Packets
:0
L3 Input Multicast Octets
:0
L2 Multicast Packets
:340
L2 Multicast Octets
:21760
Note
NetFlow support has hardware limitations that restrict the platform support to a subset of all NetFlow
fields. Specifically, TCP Flags and the ToS byte (DSCP) are not supported.
Configuring a NetFlow Minimum Prefix Mask for Router-Based Aggregation, page 40-9
Hw
Fw
Sw
Status
40-6
OL-6696-01
Chapter 40
Note
Enabling this feature does not impact the hardware-forwarding performance of the switch.
The effective size of the hardware flow cache table is 85,000 flows. (The hardware flow cache for the
Supervisor Engine V-10GE is 100,000 flows.) If more than 100,000 flows are active simultaneously,
statistics may be lost for some of the flows.
The effective size of the software flow table is 256, 000 flows. The NetFlow software manages the
consistency between the hardware and software tables, keeping the hardware table open by purging
inactive hardware flows to the software table.
User-configured timeout settings dictate when the flows are purged and exported through NDE from the
software cache. Hardware flow management ensures consistency between hardware flow purging and the
user-configured timeout settings.
Software-forwarded flows are also monitored. Moreover, statistics will overflow if any flow receives
traffic at a sustained rate exceeding 2 gigabits per second. Generally, this situation should not occur
because a port cannot transmit at a rate higher than 1 gigabit per second.
Note
By design, even if the timeout settings are high, flows will automatically age out as they approach their
statistics limit.
Purpose
40-7
Chapter 40
Purpose
{hostname
| ip-address} udp-port
<interface>
Purpose
Reduce the required bandwidth between the switch and workstations, because fewer NDE packets
are exported.
40-8
OL-6696-01
Chapter 40
To configure an aggregation cache, you must enter the aggregation cache configuration mode, and you
must decide which type of aggregation scheme you would like to configure: autonomous system,
destination prefix, protocol prefix, or source prefix aggregation cache. Once you define the aggregation
scheme, define the operational parameters for that scheme. More than one aggregation cache can be
configured concurrently.
To configure an aggregation cache, perform this task:
Command
Purpose
Step 1
Step 2
Router(config-flow-cache)#
cache timeout inactive 199
Step 3
Router(config-flow-cache)#
cache timeout active 45
Step 4
Router(config-flow-cache)#
export destination 10.42.41.1 9991
Step 5
Router(config-flow-cache)# enabled
Purpose
Purpose
40-9
Chapter 40
Note
The default value of the minimum mask is zero. The configurable range for the minimum mask is from
1 to 32. You should chose an appropriate value depending on the traffic. A higher value for the minimum
mask will provide more detailed network addresses, but it may also result in increased number of flows
in the aggregation cache.
To configure a minimum prefix mask for the Router-Based Aggregation feature, perform the tasks
described in the following sections. Each task is optional.
Purpose
Step 1
Step 2
Step 3
Purpose
Step 1
Step 2
Purpose
Step 1
Step 2
40-10
OL-6696-01
Chapter 40
Purpose
40-11
Chapter 40
0 export
0 export
0 export
0 export
0 export
Switch#
packets
packets
packets
packets
packets
were
were
were
were
were
sent up
dropped
dropped
dropped
dropped
to process level
due to no fib
due to adjacency issues
due to fragmentation failures
due to encapsulation fixup failures
SrcIPaddress
DstIf
DstIPaddress
Pr SrcP DstP
Pkts
SrcIf
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi5/48
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Switch#
SrcIPaddress
30.20.1.18
30.20.1.19
30.20.1.16
30.20.1.17
30.20.1.20
30.20.1.10
30.20.1.11
30.20.1.14
30.20.1.15
30.20.1.12
30.20.1.13
171.69.23.149
30.10.1.12
30.10.1.13
30.10.1.14
30.10.1.15
30.10.1.10
30.10.1.11
30.10.1.20
30.10.1.16
30.10.1.17
30.10.1.18
30.10.1.19
DstIf
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Gi6/1
Local
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
Gi6/2
DstIPaddress
30.10.1.18
30.10.1.19
30.10.1.16
30.10.1.17
30.10.1.20
30.10.1.10
30.10.1.11
30.10.1.14
30.10.1.15
30.10.1.12
30.10.1.13
172.20.64.200
30.20.1.12
30.20.1.13
30.20.1.14
30.20.1.15
30.20.1.10
30.20.1.11
30.20.1.20
30.20.1.16
30.20.1.17
30.20.1.18
30.20.1.19
Pr
11
11
11
11
11
11
11
11
11
11
11
06
11
11
11
11
11
11
11
11
11
11
11
Pkts
537K
537K
537K
537K
537K
539K
539K
539K
539K
539K
539K
759
539K
539K
539K
539K
539K
539K
537K
537K
537K
537K
537K
SrcP
4001
4001
4001
4001
4001
4001
4001
4001
4001
4001
4001
8214
4001
4001
4001
4001
4001
4001
4001
4001
4001
4001
4001
DstP
4001
4001
4001
4001
4001
4001
4001
4001
4001
4001
4001
0017
4001
4001
4001
4001
4001
4001
4001
4001
4001
4001
4001
40-12
OL-6696-01
Chapter 40
Sample NetFlow Minimum Prefix Mask Router-Based Aggregation Schemes, page 40-14
Enabling NetFlow on a per interface basis is not supported on a Catalyst 4500 switch.
This example shows how to enable NetFlow globally:
Switch# configure terminal
Switch(config)# ip flow ingress
This example shows how to enable NetFlow with support for inferred fields:
Switch# configure terminal
Switch(config)# ip flow ingress infer-fields
40-13
Chapter 40
Prefix Configuration
This example shows how to configure a prefix aggregation cache with an inactive timeout of 200
seconds, a cache active timeout of 45 minutes, an export destination IP address of 10.42.42.1, and a
destination port of 9992:
Switch(config)# ip flow-aggregation cache prefix
Switch(config-flow-cache)# cache timeout inactive 200
Switch(config-flow-cache)# cache timeout active 45
Switch(config-flow-cache)# export destination 10.42.42.1 9992
Switch(config-flow-cache)# enabled
40-14
OL-6696-01
Chapter 40
Both routes have a 27-bit subnet mask in the routing table on the switch.
Flows travelling from the 118.42.20.160 subnet to the 122.16.93.160 subnet whose source IP addresses
match with a mask of 27 bits and whose destination IP addresses match with a mask of 28 bits are
aggregated together in the cache statistics.
40-15
Chapter 40
40-16
OL-6696-01
A P P E N D I X
Acronyms
Table A-1 defines the acronyms used in this publication.
Table A-1
Acronyms
Acronym
Expansion
ACE
ACL
AFI
Agport
aggregation port
ALPS
AMP
APaRT
ARP
AV
attribute value
AVVID
BDD
BECN
BGP
BPDU
BRF
BSC
Bisync
BSTUN
BUS
BVI
CAM
content-addressable memory
CAR
CCA
CDP
CEF
CGMP
A-1
Appendix A
Table A-1
Acronyms
Acronyms (continued)
Acronym
Expansion
CHAP
CIR
CIST
CLI
command-line interface
CLNS
CMNS
COPS
COPS-DS
CoS
class of service
CPLD
CRC
CRF
CST
CUDD
DBL
DCC
dCEF
DDR
dial-on-demand routing
DE
discard eligibility
DEC
DFI
DFP
DISL
DLC
DLSw
DMP
DNS
DoD
Department of Defense
DOS
denial of service
DRAM
dynamic RAM
DSAP
DSCP
DSPU
DTP
DTR
DXI
A-2
OL-6696-01
Appendix A
Acronyms
Table A-1
Acronyms (continued)
Acronym
Expansion
EAP
EARL
EEPROM
EHSA
EHT
EIA
ELAN
EOBC
ESI
end-system identifier
FECN
FM
feature manager
FRU
FSM
GARP
GMRP
GVRP
HSRP
ICC
Inter-card Communication
ICD
ICMP
IDB
IDP
IFS
IGMP
IGRP
ILMI
IP
Internet Protocol
IPC
interprocessor communication
IPX
IS-IS
ISL
Inter-Switch Link
ISO
LAN
LANE
LAN Emulation
LAPB
A-3
Appendix A
Table A-1
Acronyms
Acronyms (continued)
Acronym
Expansion
LDA
LCP
LEC
LECS
LEM
LER
LES
LLC
LTL
MAC
MACL
MD5
Message Digest 5
MFD
MIB
MII
media-independent interface
MLS
Multilayer Switching
MLSE
MOP
MOTD
message-of-the-day
MLSE
MRM
MSDP
MST
MSTI
MST instance
MTU
MVAP
NBP
NCIA
NDE
NET
NetBIOS
NFFC
NMP
NSAP
NTP
NVRAM
nonvolatile RAM
A-4
OL-6696-01
Appendix A
Acronyms
Table A-1
Acronyms (continued)
Acronym
Expansion
OAM
ODM
OSI
OSPF
PACL
PAE
PAgP
PBD
PBR
PC
Personal Computer
PCM
PCR
PDP
PDU
PEP
PGM
PHY
physical sublayer
PIB
PIM
PoE
PPP
Point-to-Point Protocol
PRID
PVST+
QM
QoS manager
QoS
quality of service
RADIUS
RAM
random-access memory
RCP
RGMP
RIB
RIF
RMON
ROM
read-only memory
ROMMON
ROM monitor
RP
RPC
A-5
Appendix A
Table A-1
Acronyms
Acronyms (continued)
Acronym
Expansion
RPF
RPR
RSPAN
remote SPAN
RST
reset
RSVP
ReSerVation Protocol
SAID
SAP
SCM
SCP
SDLC
SGBP
SIMM
SLB
SLCP
SLIP
SMDS
SMF
SMP
SMRP
SMT
Station Management
SNAP
SNMP
SPAN
SSTP
STP
SVC
SVI
TACACS+
TARP
TCAM
TCL
TCP/IP
TFTP
TIA
TopN
TOS
type of service
A-6
OL-6696-01
Appendix A
Acronyms
Table A-1
Acronyms (continued)
Acronym
Expansion
TLV
type-length-value
TTL
Time To Live
TVX
valid transmission
UDLD
UDP
UNI
User-Network Interface
UTC
VACL
VCC
VCI
VCR
VINES
VLAN
virtual LAN
VMPS
VPN
VRF
VTP
VVID
voice VLAN ID
WFQ
WRED
WRR
weighted round-robin
XNS
A-7
Appendix A
Acronyms
A-8
OL-6696-01
I N D EX
A
abbreviating commands
Numerics
4-7
See ACEs
access list filtering, SPAN enhancement
10-4
39-13
access ports
802.1Q
trunks
2-5
14-6
configuring
tunneling
compatibility with other features
defaults
19-5
access VLANs
12-6
19-2
19-6
trunk restrictions
IP
12-5
35-2
35-8
ACLs
See MST
ACEs
802.1w
35-2
and SPAN
See MST
39-5
802.1X
See port-based authentication
35-6
35-21
802.1X authentication
35-20
31-6
RADIUS accounting
with port security
35-2
802.1s
35-2
Ethernet
12-3
31-16
ACEs
ACLs
802.1Q VLANs
encapsulation
12-8
accounting
19-4
described
19-9
31-7
31-6
35-3
35-20
35-9
31-5
31-10
802.3ad
See LACP
MAC extended
35-5
35-4
35-11
35-3
port
and voice VLAN
defined
35-4
35-2
IN-1
Index
limitations
processing
35-4
35-9
types supported
acronyms, list of
15-7, 15-8
16-2
understanding
35-2
15-6
A-1
BGP
29-13
addresses
1-8
37-1
adjacency tables
description
28-6
24-2
displaying statistics
24-9
advertisements, VTP
boot command
16-4
3-24
3-21
boot fields
alarms
major
7-2
minor
7-2
19-4
authentication
description
16-6
BPDU Guard
authentication server
and MST
31-3
RADIUS server
16-2
configuring
31-3
31-4
31-4
15-12
overview
15-4
BPDUs
and media speed
3-2
automatic QoS
pseudobridges and
See QoS
autonegotiation feature
forced 10/100Mbps
14-2
16-5
14-3
bridge ID
See STP bridge ID
4-7
Auto-QoS
configuring
3-21
See BGP
xxi
defined
3-19, 3-24
29-16
auto-sync command
14-16
See BPDUs
6-8
38-4
BSR
configuration example
BackboneFast
adding a switch (figure)
and MST
15-2
16-2
configuring
burst rate
29-44
burst size
29-27
25-21
15-15
IN-2
OL-6696-01
Index
configuring
30-2
Cisco IP phones
candidate switch
defined
sound quality
9-12
CIST
requirements
9-12
description
3-16
TACACS+
3-15
29-25
20-2
20-3
20-3
4-14
19-7
accessing
20-3
2-1
1-2, 20-1
getting commands
20-3
24-2
displaying statistics
modes
24-7
load balancing
overview
24-8
ROM monitor
24-4
2-6
2-4
in 802.1X authentication
24-1
31-2
clustering switches
24-4
18-1
9-11, 9-12
9-12
managing
17-7, 17-10
9-13
9-11
planning considerations
CLI
See CEF
9-13
command-line processing
command modes
See CGMP
Cisco IOS NSF-awareness support
through CLI
overview
See CDP
Cisco IP Phones
39-1
clients
24-6
CGMP
overview
9-13
2-5
software basics
software switching
2-3
monitoring environments
24-6
hardware switching
2-5
2-5
history substitution
managing clusters
40-8
CLI
20-3
adjacency tables
25-20
CEF
enabling
20-3
20-4
clearing
enabling on interfaces
overview
29-28
displaying configuration
monitoring
class-map command
See CoS
16-2
class of service
CDP
maintaining
30-1
2-3
2-5
commands
6-2
listing
2-5
command switch
Software Configuration GuideRelease 12.2(25)EW
OL-6696-01
IN-3
Index
requirements
clearing MFIB
9-11
clearing on interfaces
CPU port sniffing
See CIST
description
See CST
IST and
community ports
description
community VLANs
16-2
36-5
36-1
config-register command
3-22
3-9
default configuration
802.1X
configuration files
31-12
auto-QoS
3-6
29-16
IGMP filtering
3-10
18-17
configuration register
multi-VRF CE
boot fields
listing value
3-22
configuring
configuring
3-21 to 3-22
3-11
verifying configuration
3-19
settings at startup
39-6
default gateway
3-21
changing settings
19-9
28-3
modifying
28-2
36-4
configure as a PVLAN
3-11
default ports
3-20
3-22, 4-2
description command
2-5
31-13
4-9
console port
21-1
DHCP-based autoconfiguration
5-5
5-4
3-10
client side
DNS
definition
29-41
relay device
TFTP server
29-3
example
29-2
3-5
3-3
3-4
3-7
lease options
30-3
30-3
CoS-to-DSCP maps
3-2
3-5
server-side
3-3
configuring
priority
16-5
figure
39-10
16-2
MST and
36-1
description
4-14
CST
saving
25-20
3-4
counters
overview
3-4
3-2
relationship to BOOTP
3-2
IN-4
OL-6696-01
Index
DHCP snooping
configuring
definition
IP precedence
33-3
default configuration
33-4
monitoring
overview
duplex command
33-5
12-3
4-8
duplex mode
33-6
configuring interface
4-7
33-1
33-2
29-43
DTP
33-10
29-23
33-10
displaying configuration
29-2
mapping markdown
33-3
29-3
33-9
33-6
limit on hosts
11-9
reconfirming
11-7
troubleshooting
33-2
11-9
33-8
See DTP
29-2
disabled state
RSTP comparisons (table)
16-4
EAP frame
disabling
request/identity
38-4
response/identity
5-5
31-3
EAP frames
DNS
3-5
exchanging (figure)
documentation
organization
related
31-3
xxi
802.1Q tunneling
31-2
19-2
start
19-9
31-4
31-3
edge ports
19-9
description
16-7
EGP
DSCP-to-CoS maps
overview
29-47
1-8
EIGRP
DSCP values
configuring maps
31-21
EAPOL frames
double-tagged packets
configuring
31-4
xxiii
DSCP maps
31-20
overview
29-45
1-8
Embedded CiscoView
29-42
displaying information
9-16
IN-5
Index
9-14
9-13
enable command
enable mode
FastDrop
3-9, 3-21
clearing entries
2-5
encapsulation types
25-20
displaying entries
12-3
overview
25-19
25-10
FIB
See EIGRP
description
environmental monitoring
LED indications
SNMP traps
24-2
7-2
filtering
7-2
supervisor engine
in a VLAN
7-2
switching modules
non-IP traffic
7-2
35-12
flags
7-1
35-11
25-11
Flash memory
EtherChannel
channel-group group command
configuration guidelines
configuring
17-7, 17-10
17-5
security precautions
17-6 to 17-14
17-9
configuring Layer 3
17-6
17-7
command example
14-18
See FIB
17-12
17-3
overview
17-1
PAgP
Understanding
gateway
17-3
17-7
17-2
2-5
Guest-VLANs
17-12
31-13
31-17, 31-18
17-14
removing interfaces
17-13
37-2
lacp system-priority
modes
3-23
3-23
configuring Layer 2
3-24
18-8
hardware switching
See VLANs
Extensible Authentication Protocol over LAN
35-5
24-5
configuring
14-17
history
CLI
2-3
IN-6
OL-6696-01
Index
hop counts
IGMP profile
applying
16-7
host
18-18
configuration mode
configuring
18-8
18-17
IGMP snooping
11-9
configuration guidelines
enabling
See HSRP
monitoring
1-6
7-15
18-4
18-5
IP multicast and
HSRP
description
18-17
25-4
18-11
overview
18-1
IGRP
description
1-8
immediate-leave processing
enabling
ICMP
enabling
ping
IGMP
5-10
5-5
running IP traceroute
5-7
39-2
IEEE 802.1s
30-4
8-5
3-9, 4-1
See MST
IEEE 802.1w
See LACP
clearing counters
IGMP
description
configuring
25-3
18-3, 18-8
immediate-leave processing
18-3
Layer 2 modes
naming
18-17
default configuration
numbers
18-17
18-16
18-20
4-13
12-4
4-13
4-13
4-9
4-2
overview
4-1
restarting
4-14
IGMP groups
setting the maximum number
4-4
monitoring
IGMP filtering
monitoring
4-2
maintaining
18-1
4-9
4-14
configuring ranges
25-13
described
4-5
interfaces
IEEE 802.3ad
configuring
17-7
4-4
See MST
overview
39-12
inline power
5-7
IDS
enabling
18-7
18-19
OL-6696-01
IN-7
Index
See IGRP
enabling
See ICMP
See IGMP
Inter-Switch Link encapsulation
25-14
25-12
hardware forwarding
IP
configuring static routes
displaying statistics
18-4, 25-4
25-1
25-2
software forwarding
3-11
25-8
24-8
25-8
25-15
routing protocols
3-11
25-14
enabling sparse-mode
25-16
25-13
25-15
ip multicast-routing command
40-8
IP addresses
25-13
IP phones
candidate or member
command switch
9-12
9-12
ip pim command
25-14
26-4
40-7
IP routing tables
18-10
deleting entries
18-10
18-11
IP information
25-20
IP Source Guard
configuring
33-11
assigned
displaying
3-2
24-7
26-5
5-12
IP multicast
clearing table entries
25-20
25-12
default configuration
25-15
5-11
configuring
25-14
ip redirects command
5-11
18-17
29-24
40-8
30-1
30-2
24-6
29-16
overview
33-12
33-13, 33-14
33-10
IP statistics
displaying
24-8
IP traceroute
executing
5-7
overview
5-7
IP unicast
25-13
displaying statistics
24-8
IN-8
OL-6696-01
Index
ip unreachables command
assigning VLANs
5-10
IPX
configuring
12-5
36-8
encapsulation
12-3
19-4
isolated ports
defaults
modes
36-1
isolated VLANs
description
12-4
12-7
IST
setting
16-2
36-12
36-12
16-7
configuring
16-2
19-9
default configuration
defined
19-9
19-7
guidelines
19-10
Layer 2 switching
jumbo frames
and ethernet ports
overview
4-11
4-11
12-1
Layer 2 Traceroute
4-12
4-10
and ARP
5-9
and CDP
5-8
described
5-8
host-to-host paths
5-8
keyboard shortcuts
5-9
2-3
multicast traffic
unicast traffic
l2protocol-tunnel command
19-11
5-9
1-3, 5-8
usage guidelines
5-8
Layer 2 trunks
labels
configuring
29-3
overview
LACP
system ID
5-9
5-9
definition
36-9
12-9
36-1
description
36-7
12-5
disabling configuration
description
master
1-8
10-8
classification methods
12-8
29-2
Layer 2 frames
Layer 2 interfaces
12-3
Layer 3 packets
17-4
12-6
29-2
configuration guidelines
restrictions
35-8
35-8
LEDs
Software Configuration GuideRelease 12.2(25)EW
OL-6696-01
IN-9
Index
description (table)
7-2
configuring
16-4
load balancing
defined
24-7
9-11
managing
17-12
9-13
requirements
17-5, 24-6
per-destination
metro tags
24-7
login timer
9-12
19-2
MFIB
changing
CEF
5-4
logoutwarning command
25-5
displaying
5-4
loop guard
25-18
overview
and MST
25-11
modules
16-2
configuring
overview
14-18
member switch
26-3
15-9
15-2
checking status
5-1
powering down
7-15
monitoring
sticky
tunneling
5-3
33-10
VLAN filters
M-record
32-2
28-11
35-19
35-19
16-2
35-11
boundary ports
macros
BPDUs
16-2
configuring
mapping
DSCP values to transmit queues
29-43
enabling
mapping tables
configuring DSCP
hop count
29-45
16-13
16-7
16-9
16-7
instances
29-13
edge ports
16-5
16-9
displaying configurations
29-23
1-4, 16-2
16-6
configuration parameters
6-8
19-12
MST
32-2
main-cpu command
18-11
19-12
VLAN maps
35-11
described
18-20
multi-VRF CE
32-2
35-28
12-2
ACL information
IGMP snooping
14-5
building tables
19-12
IGMP filters
MAC addresses
allocating
802.1Q tunneling
40-10
40-10
configuring parameters
description
16-12
16-2
IN-10
OL-6696-01
Index
number supported
packet-forwarding process
16-5
16-2
16-7
16-7
message age
regions
16-7
native VLAN
16-5, 16-6
restrictions
16-8
specifying
to-SST interoperability
16-4
MSTP
19-4
12-6
NetFlow
aggregation
M-record
M-tree
M-tree
28-3
16-2
16-2
destination-prefix aggregation
16-2
configuration (example)
MTU size
4-12
40-10
IP
10-4
multicast
40-8
prefix aggregation
See IP multicast
configuration (example)
multicast packets
blocking
37-2
18-9
configuring
38-6
suppression on WS-X4014
38-7
statistics
suppression on WS-X4016
38-6
NetFlow statistics
1-4, 16-2
40-7
40-8
40-8
caveats on supervisor
40-6
configuring collection
40-6
implementing collection
and VTY
28-3
configuration example
default configuration
monitoring
28-7
28-3
28-11
9-12
display configuration
9-4
9-7
default configuration
28-3
9-9
28-11
network components
40-1
configure
28-1
displaying
overview of collection
40-6
Network Assistant
multi-VRF CE
components
40-11
40-10
switching
configuration (example)
40-10
source-prefix aggregation
40-13
multicast routers
defined
40-15
configuring
default
40-10
9-10
9-3
installation requirements
9-2
IN-11
Index
installing
launch
9-3
9-10
packets
9-4
9-2
and QoS
1-4, 16-2
overview
20-1
39-14
SPAN enhancement
39-14
PAgP
See NHRP
understanding
NFFC/NFFC II
IGMP snooping and
17-3
passwords
18-4
NHRP
support
29-15
network management
configuring
29-15
software processed
9-2
modifying
1-8
encrypting
35-11
25-9
25-10
setting TACACS+
3-15
normal-range VLANs
NSF-awareness support
6-2
26-2
overview
26-1
route maps
NVRAM
saving settings
3-10
26-5
26-3
features
See VLANs
3-18
3-14
configuration (example)
See NVRAM
3-14
3-15
non-RPF traffic
description
3-14
26-2
when to use
26-2
O
OIR
overview
4-13
14-20
overview
14-6
PE to CE routing, configuring
1-7
1-7
28-6
25-14
25-14
displaying statistics
25-15
25-20
OSPF
14-6
PIM
displaying information
See OSPF
description
enabling
33-10
25-14, 25-15
25-3
PIM-DM
25-3
PIM-SM
25-3
IN-12
OL-6696-01
Index
ping
configuration guidelines
31-13
executing
5-6
overview
5-5
ping command
PoE
5-6, 25-15
8-7
8-5
configuring Guest-VLAN
default configuration
enabling
8-6
police command
31-2
31-14
31-21
method lists
31-4
29-9
31-22
policies
topologies, supported
policing
See QoS policing
policy-map command
29-29, 29-31
31-3
31-13
29-5
31-18
31-2
29-46
policers
description
31-22
31-13
encapsulation
29-32
policed-DSCP map
31-2, 31-8
31-4
31-2
31-19
31-12
displaying statistics
8-1
31-15
disabling
7-15
31-17, 31-18
device roles
8-5
point-to-point
31-21
31-20
31-10
31-6
31-5
policy maps
attaching to interfaces
configuring
29-34
See QoS
port-channel interfaces
29-30
port ACLs
and voice VLAN
defined
8-4
8-4
described
8-3
types of
31-16
creating
35-4
overview
35-2
limitations
17-2
port-channel load-balance
35-4
command
17-12
command example
see PAgP
802.1X with voice VLAN
31-10
31-19
31-2
17-12
port-based authentication
client, defined
17-6
17-12
14-15
PortFast
Software Configuration GuideRelease 12.2(25)EW
OL-6696-01
IN-13
Index
and MST
inline
16-2
15-12
15-11
30-4
7-11
8-2
15-3
power management
and MST
16-2
7-12
enabling
15-12
7-12
overview
15-4
port priority
16-12
checking status
community
5-2
reconfirming
forwarding, resuming
isolated
7-7
7-1
redundancy
7-12
7-5
PVLAN types
7-14
36-1
fixed
7-4
variable
port security
7-3, 7-4
32-6
29-24
default configuration
32-3
configuring as a PVLAN
RADIUS accounting
31-7
36-5
36-1
31-6
32-3
port states
port trust state
See trust states
3-16
3-17
logging in
3-17
promiscuous ports
configuring PVLAN
description
power
2-5
3-17
configuring levels
exiting
14-5
30-3
privileges
changing default
32-2
32-2
description
36-6
priority
32-7
violations
primary VLANs
description
32-1
sticky learning
7-14
32-4
displaying
7-8
power supplies
32-1
described
power redundancy
37-3
36-1
secure
7-5
7-8
redundant mode
11-7
7-9
7-3
36-1
aging
37-1
7-12
7-4
14-13
ports
blocking
8-4
36-7
36-1
IN-14
OL-6696-01
Index
setting mode
36-12
basic model
14-4
burst size
protocol timers
auto-QoS
description
29-17
auto-QoS
16-5
29-16
DSCP maps
33-10
29-45
traffic shaping
31-10
PVLANs
29-44
trusted boundary
VLAN-based
802.1q support
36-3
36-3
configuring a VLAN
hierarchical policers
29-37
29-28
default configuration
36-7
host ports
definitions
36-8
36-12
overview
29-39
36-5
isolated VLANs
29-22
disabling on interfaces
29-34
enabling on interfaces
29-34
29-7, 29-11
36-11
promiscuous mode
36-12
setting
port-based
36-12
29-16, 29-24
29-15
29-39
29-14
traffic shaping
29-16
29-1
packet modification
priority
transmit rate
29-14
29-44
trust states
QoS
allocating bandwidth
trusted device
29-44
VLAN-based
29-15
29-24
29-39
auto-QoS
configuration and defaults display
configuration guidelines
displaying
29-16
IP phones
interface mode
29-35
29-3
flowcharts
36-1
36-1
described
29-24
36-5
configuration guidelines
configuring
29-24
configuring
pseudobridges
setting
29-5 to 29-9
configuration guidelines
setting
29-27
classification
28-2
pruning, VTP
PVACL
29-5
29-19
29-17
29-13
QoS labels
29-16
definition
29-19
29-18
29-17
29-3
29-46
IN-15
Index
DSCP-to-CoS
29-47
policed-DSCP
29-46
types
See RSTP
rcommand command
re-authentication of a client
29-13
QoS marking
configuring manual
description
enabling periodic
29-4
QoS policers
configuring
29-9
14-2
6-8
described
29-5, 29-9
NSF-awareness support
QoS policy
overview
attaching to interfaces
QoS transmit queues
29-44
synchronization
29-14
6-6
6-4
6-6
redundancy(SSO)
29-43
6-8
redundancy(RPR)
allocating bandwidth
maximum rate
6-2
understanding synchronization
29-28
6-8, 6-10
6-3
redundancy command
29-10
overview of configuration
configuring
6-7
definition
29-44
synchronization
29-43
reload command
29-13
6-4
6-7
related documentation
29-14
xxiii
3-21, 3-22
replication
29-14
description
Quality of service
25-8
reserved-range VLANs
See QoS
queueing
31-18
redundancy
29-27
QoS policing
burst
31-19
burst size
types of
9-13
See VLANs
29-5, 29-13
retransmission number
setting in 802.1X authentication
31-21
retransmission time
changing in 802.1X authentication
RADIUS server
configure to-Switch communication
configuring settings
31-15
4-4
3-19
2-6
root bridge
4-5
ranges of interfaces
configuring
1-7
ROM monitor
CLI
range macros
defining
RIP
description
31-16
31-15
31-20
4-4
configuring
14-9
selecting in MST
16-2
root guard
IN-16
OL-6696-01
Index
and MST
16-2
enabling
15-8
overview
SAID
15-2
routed packets
ACLs
scheduling
35-21
defined
26-3
PBR
14-12
secondary VLANs
26-2
description
description
35-2
36-6
36-2
permitting routing
35-20
36-11
route targets
32-1
28-3
servers, VTP
See RIP
RSPAN
configuration guidelines
destination ports
IDS
29-5
26-3
router ACLs
VPN
29-4
overview
route maps
defining
29-13
service-policy command
39-16
29-29
39-5
22-2, 29-34
service-provider networks
39-2
monitored ports
monitoring ports
received traffic
39-4
19-2
39-5
19-7
39-3
sessions
26-4
26-4
creating
39-17
defined
39-3
39-5
compatibility
port roles
port states
39-4
16-3
16-2
16-3
16-4
24-9
14-3
20-2, 20-3
20-4
20-3
RSTP
description
39-17
39-21
26-4
3-24
39-4
transmitted traffic
39-22
39-23
26-4
20-4
20-4
9-16
9-16
9-13
4-9
20-4
IN-17
Index
7-2
SmartPort macros
2-4
configuration guidelines
4-12, 4-13
configuring
5-2
40-11
6-12
3-19
24-5
interfaces
24-6
5-1, 14-5
25-7
SPAN
and ACLs
7-14
configuring
8-4
IDS
39-2
4-9
received traffic
3-9
defined
3-10
39-5
39-3
39-3
source ports
5-4
39-4
transmitted traffic
3-22
VLAN-based
4-14
39-4
sessions
39-5
39-7
39-6 to 39-10
destination ports
7-8
4-13
39-5
configuration guidelines
8-6
19-9
39-4
39-5
shutting down
interfaces
1-13
1-13
description
5-3
24-8
shutdown, command
13-4
software switching
5-3
8-7
13-8
19-11
13-1
upgrading
25-15
displaying ACLs
defined
software
25-15
13-2
support
26-5
default configuration
documentation
25-15
13-4
SNMP
tracing
40-8
13-4
13-2
displaying
24-8
4-2
4-14
default configuration
displaying status
overview
See SST
39-3
39-6
39-24
39-1
session limits
39-6
IN-18
OL-6696-01
Index
displaying PIM
NetFlow accounting
31-13
SPAN enhancements
configuration file
39-13
configuration example
defined
39-15
39-10
encapsulation configuration
ingress packets
39-12
32-2
32-2
15-12
32-2
disabling
38-4
displaying
15-11
32-4
Storm Control
15-8
38-4
enabling
14-13
38-3
hardware-based, implementing
15-14
spanning-tree vlan
overview
38-1
bridge ID
14-9
14-19
14-17
14-18
14-7 to 14-20
creating topology
14-15
14-13
defaults
14-4
14-6
disabling
14-19
enabling
14-7
14-10
14-12
forward-delay time
hello time
4-7
14-17
4-7
SST
19-7
14-18
14-1, 14-3
16-2
interoperability
16-4
static routes
14-6
14-15
port priority
root bridge
14-13
14-9
supervisor engine
3-11
3-12
statistics
displaying 802.1X
14-20
14-18
configuring interface
14-8
14-17
14-2
configuring
14-8
speed command
38-2
STP
14-9
command example
verifying
enabling
defined
configuring
32-2
configuring
15-15
14-15
description
disabling
39-14
32-2
32-2
saving addresses
39-12
command
40-8
sticky learning
25-20
configuring
31-22
6-14
3-8 to 3-13
6-14
IN-19
Index
default configuration
default gateways
reviewing configuration
3-1
settings at startup
3-11
environmental monitoring
ROM monitor
static routes
3-20
system images
7-1
3-19
startup configuration
3-18
specifying
3-11
synchronizing configurations
3-23
3-20
3-23
system MTU
6-10
SVIs
802.1Q tunneling
3-10
maximums
35-3
19-5
19-5
switched packets
and ACLs
35-20
TACACS+
switching, NetFlow
setting passwords
configuration (example)
configuring
40-11
tagged packets
40-7
802.1Q
3-15
40-8
19-3
Layer 2 protocol
switchport
19-7
show interfaces
4-12
Telnet
12-6, 12-8
accessing CLI
37-2
executing
12-8
19-6
telnet command
12-6
5-5
5-3
2-2
37-2
35-6
5-4
5-4
TFTP
12-6
switch ports
12-6
12-3
12-3
12-6
31-15
syslog messages
Token Ring
media not supported (note)
12-6
5-7
3-4
timer
12-6
3-5
7-2
system
10-4, 27-3
TOS
description
trace command
29-3
5-7
traceroute
See IP traceroute
See Layer 2 Traceroute
traceroute mac command
5-9
IN-20
OL-6696-01
Index
5-9
traffic
blocking flooded
UDLD
37-2
default configuration
traffic control
using ACLs (figure)
35-4
35-5
10-4
21-1, 34-1
configuring
with traceroute
37-1
unicast traffic
5-7
blocking
trunk ports
802.1X authentication not supported on
configuring PVLAN
31-13
37-2
unidirectional ethernet
enabling
36-9 to 36-11
22-2
example of setting
trunks
802.1Q restrictions
configuring
overview
12-5
UplinkFast
12-6
12-6
12-3
12-4
12-3
22-1
See UDLD
12-6
encapsulation
22-2
12-6
and MST
16-2
enabling
15-14
MST and
16-3
overview
15-5
12-6
2-5
user sessions
12-3
disconnecting
29-24
monitoring
trust states
configuring
31-4
29-44
troubleshooting
5-5
5-4
29-40
tunneling
19-1
Layer 2 protocol
VACLs
19-7
tunnel ports
802.1Q, configuring
See VLANs
19-2
type of service
35-7
virtual LANs
19-6
21-3
See IP unicast
described
enabling
unicast
transmit queues
defined
21-3
overview
29-14
transmit rate
disabling
21-2
19-5
OL-6696-01
IN-21
Index
See VTP
10-6, 10-7
VLAN trunks
10-7
overview
19-4
VMPS
See VMPS
VLAN maps
applying
reconfirming
35-16
configuration example
server overview
35-14
dynamic ports
reconfirmation interval
35-13
permitting packets
router ACLs and
using (figure)
default configuration
35-20
11-8
11-7
11-4
35-5
VLANs
11-4
allowed on trunk
configuring
fall-back VLAN
10-3
open
interface assignment
11-3
11-2
11-3
voice interfaces
10-8
39-23
39-22
10-4
10-3
configuring
30-1
Voice over IP
configuring
30-1
voice ports
configuring VVID
10-1
reserved range
11-1
secure
10-4
normal range
overview
multiple
10-3
name (default)
19-3
11-3
security modes
10-4
1-5
extended range
11-3
10-4
default configuration
11-9
VMPS server
12-6
configuration guidelines
overview
11-5
35-14
11-7
11-6
35-18
order of entries
11-8
configure switch
35-18
35-19
examples
11-1
denying packets
11-7
VMPS client
35-13
35-3
displaying
11-7
35-13
35-12
creating entries
11-8
11-7
reconfirming assignments
35-17
configuration guidelines
configuring
11-6
35-16, 35-24
defined
12-3
10-3
voice traffic
30-2
8-1, 30-4
IN-22
OL-6696-01
Index
using 802.1X
31-10
VPN
9-12
configuring routing in
forwarding
28-5
configuring
28-3
31-10
30-2
28-1
28-2
28-3
28-1
VTP
configuration guidelines
configuring
27-5
27-6 to 27-10
27-9
27-5
27-9
19-7
27-10
overview
27-1
27-3
VTP clients
configuring
27-8
VTP domains
description
27-2
VTP modes
27-2
VTP pruning
enabling
27-6
overview
27-3
VTP servers
configuring
27-7
VTP statistics
displaying
27-10
VTP version 2
enabling
overview
27-7
27-3
IN-23
Index
IN-24
OL-6696-01