本文档讨论如何在Cisco Catalyst 2948G-L3和Catalyst 2900/3500XL或2970系列交换机之间配置交换机间链路(ISL)协议中继。将Catalyst 2948G-L3连接到交换机时,配置任务与将路由器连接到交换机时的配置任务相同。本文档中的配置示例使用Catalyst 2948G-L3作为路由器,并使用Catalyst 3500XL作为第2层(L2)交换机。为本文档之目的,您可以用Catalyst 2900XL或2970替代3500XL。
要在Catalyst 2948G-L3上使用VLAN的概念,必须使用网桥组。每个网桥组都是一个独立的 VLAN。这些网桥组对应于所连接交换机的 VLAN 编号。
尝试此配置之前,请确保在2900/3500XL或2970与2948G-L3之间连接交叉电缆。通常,在路由器和交换机之间使用直通电缆;但是,使用Catalyst 2948G-L3时,您使用交叉电缆连接到另一台交换机。这是交换机到交换机连接的交叉电缆。
本文档的读者应掌握以下这些主题的相关知识:
Catalyst 2940和2950/2955系列交换机不支持ISL封装。有关Catalyst交换机的ISL封装支持和其他中继要求的信息,请参阅实施中继的系统要求。
Catalyst 2948G-L3 已停产 (EoL)。 有关详细信息和推荐的更换产品,请参阅Cisco Catalyst 2948G-L3和4908G-L3交换机的EoL/EoS。
本文档中的信息基于以下软件版本:
适用于第3层(L3)交换机/路由器(CAT2948G-IN-M)的思科IOS®软件版本12.0(25)W5(27)
思科IOS软件版本12.0(5)WC9(C3500XL-C3H2S-M)(fc1)
本文档中的信息都是基于特定实验室环境中的设备编写的。本文档中使用的所有设备最初均采用原始(默认)配置。如果您使用的是真实网络,请确保您已经了解所有命令的潜在影响。
有关文件规则的更多信息请参见“ Cisco技术提示规则”。
此部分提供本文描述的功能的配置信息。
注:要查找有关本文档中命令的其他信息,请使用命令查找工具(仅注册客户)。
本文档使用以下网络设置:
如果希望所有三台PC都能相互ping通并拥有默认网关,则必须使用集成路由和桥接(IRB)的桥接。
在此场景中,Catalyst 2948G-L3是L3设备。由于它是第3层设备,因此不能在同一子网中有两个第3层接口。因此,您需要在接口上使用网桥组,并将它们与网桥虚拟接口(BVI)、BVI 2绑定在一起。
BVI 2 IP地址是VLAN 2或网桥组2中所有PC和设备的默认网关。
本文档使用以下配置:
2948G-L3 |
---|
Building configuration... Current configuration: ! version 12.0 no service pad service timestamps debug uptime service timestamps log uptime no service password-encryption ! hostname 2948G-L3 ! ! ip subnet-zero bridge irb ! ! ! interface FastEthernet1 !--- This interface is the ISL trunk to the switch. no ip address no ip directed-broadcast ! interface FastEthernet1.1 encapsulation isl 1 no ip redirects no ip directed-broadcast bridge-group 1 !--- Use bridge-group 1 for the trunk subinterface. !--- You can not use an IP address here because of the subnet !--- overlap that would occur due to BVI 1, which is in the !--- same subnet. ! interface FastEthernet1.2 encapsulation isl 2 no ip redirects no ip directed-broadcast bridge-group 2 ! interface FastEthernet2 no ip address no ip directed-broadcast bridge-group 2 !--- This port belongs to VLAN 2. ! interface FastEthernet3 no ip address no ip directed-broadcast bridge-group 2 !--- This port belongs to VLAN 2. ! interface FastEthernet4 no ip address no ip directed-broadcast bridge-group 1 !--- This port belongs to VLAN 1. ! interface BVI1 ip address 10.1.1.1 255.255.0.0 !--- This is the IP address of BVI 1. no ip directed-broadcast no ip route-cache cef ! interface BVI2 !--- This is the IP address of BVI 2. ip address 10.2.2.2 255.255.0.0 no ip directed-broadcast no ip route-cache cef ! ip classless ! bridge 1 protocol ieee !--- Choose IEEE as the Spanning Tree Protocol. bridge 1 route ip !--- Allow routing to occur for IP. bridge 2 protocol ieee bridge 2 route ip ! line con 0 transport input none line aux 0 line vty 0 4 login ! end |
2900/3500XL或2970 |
---|
!--- First, add VLAN 2 to the VLAN database for a 2900/3500XL !--- switch: 3500XL# vlan database 3500XL(vlan)# vlan 2 VLAN 2 added: Name: VLAN0002 3500XL(vlan)# exit APPLY completed. Exiting.... 3500XL# !--- The Catalyst 2970 gives you the option to configure VLANs !--- from the VLAN database or from global configuration mode: 2970# configure terminal Enter configuration commands, one per line. End with CNTL/Z. 2970(config)# vlan 2 2970(config-vlan)# end 2970# |
!--- The switchport configurations on the Catalyst 2900/3500XL !--- and on the 2970 are identical, for the purposes of this !--- document. Remember that the Catalyst 2970 has 10/100/1000 !--- ports (1000Base-T), so the interfaces in this output !--- would instead be labeled Gigabit Ethernet 0/1, 0/2, !--- and so forth. Current configuration: ! version 12.0 no service pad service timestamps debug uptime service timestamps log uptime no service password-encryption ! hostname 3500XL ! interface FastEthernet0/1 switchport mode trunk !--- This port is an ISL trunk. ! interface FastEthernet0/2 switchport access vlan 2 !--- This port is in VLAN 2. ! interface FastEthernet0/3 !--- This port is in the default VLAN 1. ! interface FastEthernet0/4 ! ! interface VLAN1 ip address 10.1.1.100 255.255.0.0 !--- This is the IP address of the management interface. no ip directed-broadcast no ip route-cache ! snmp-server engineID local 000000090200000AF484CC80 snmp-server community public RO ! line con 0 exec-timeout 0 0 transport input none stopbits 1 line vty 0 4 login line vty 5 15 login ! end |
此部分提供信息确认您的配置适当地工作。
命令输出解释程序工具(仅限注册用户)支持某些 show 命令,使用此工具可以查看对 show 命令输出的分析。
show interface fa0/1 switchport — 检验2900/3500XL或2970上中继的状态,并查看哪些VLAN处于活动状态。
3500XL# show interface fa0/1 switchport Name: Fa0/1 Switchport: Enabled Administrative mode: trunk Operational Mode: trunk 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: ALL Trunking VLANs Active: 1,2 Pruning VLANs Enabled: 2-1001 Priority for untagged frames: 0 Override vlan tag priority: FALSE Voice VLAN: none Appliance trust: none Self Loopback: No 3500XL#
show vlan — 检验2900/3500XL或2970上的端口是否已分配给正确的VLAN。
3500XL# show vlan VLAN Name Status Ports ---- -------------------------------- --------- ------------------------------- 1 default active Fa0/3, Fa0/4, Fa0/5, Fa0/6, Fa0/7, Fa0/8, Fa0/9, Fa0/10, Fa0/11, Fa0/12, Fa0/13, Fa0/14, Fa0/15, Fa0/16, Fa0/17, Fa0/18, Fa0/19, Fa0/20, Fa0/21, Fa0/22, Fa0/23, Fa0/24, Gi0/1, Gi0/2 2 VLAN0002 active Fa0/2 1002 fddi-default active 1003 token-ring-default active 1004 fddinet-default active 1005 trnet-default active VLAN Type SAID MTU Parent RingNo BridgeNo Stp BrdgMode Trans1 Trans2 ---- ----- ---------- ----- ------ ------ -------- ---- -------- ------ ------ 1 enet 100001 1500 - - - - - 0 0 2 enet 100002 1500 - - - - - 0 0 1002 fddi 101002 1500 - - - - - 0 0 1003 tr 101003 1500 - - - - - 0 0 1004 fdnet 101004 1500 - - - ieee - 0 0 1005 trnet 101005 1500 - - - ibm - 0 0 3500XL#
show interface bvi 1 — 验证2948G-L3 BVI接口和线路协议在2948G-L3上是否都处于打开状态。
2948G-L3# show interface bvi 1 BVI1 is up, line protocol is up Hardware is BVI, address is 0001.c75c.680a (bia 0000.0000.0000) Internet address is 10.1.1.1/16 MTU 1500 bytes, BW 10000 Kbit, DLY 5000 usec, rely 255/255, load 1/255 Encapsulation ARPA, loopback not set ARP type: ARPA, ARP Timeout 04:00:00 Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0 Queueing strategy: fifo Output queue 0/0 (size/max) 2948G-L3#
show bridge 1 — 检验网桥1是否正在转发。您还可以使用show spanning-tree命令验证生成树协议是否已启用并转发。
2948G-L3# show bridge 1 Total of 300 station blocks, 299 free Codes: P - permanent, S - self Bridge Group 1: Address Action Interface 00ee.1e9f.50c0 forward Fa1.1 2948G-L3#
本节提供有助于排除配置故障的提示和示例输出。
检验您是否可以ping通其它设备。
检验PC是否能ping通其他VLAN中的其它PC。
确保默认网关正确。在此场景中,默认网关是2948G-L3上各自的BVI。
2948G-L3# ping 10.1.1.100 Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 10.1.1.100, timeout is 2 seconds: !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 4/6/12 ms 2948G-L3# show arp Protocol Address Age (min) Hardware Addr Type Interface Internet 10.2.2.2 - 0030.40d6.4008 ARPA BVI2 Internet 10.1.1.1 - 0030.40d6.400a ARPA BVI1 Internet 10.1.1.100 1 00ee.1e9f.50c0 ARPA BVI1 2948G-L3#
版本 | 发布日期 | 备注 |
---|---|---|
1.0 |
30-Aug-2005 |
初始版本 |