cisco press ccna portable command guide 2nd edition 640 802 phần 5 pot

38 378 0
cisco press ccna portable command guide 2nd edition 640 802 phần 5 pot

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

Thông tin tài liệu

VLAN Trunking Protocol (VTP) 127 TIP: With the switchport trunk encapsulation negotiate command set, the preferred trunking method is ISL. CAUTION: The 2960 series switch supports only dot1q trunking. VLAN Trunking Protocol (VTP) VTP is a Cisco proprietary protocol that allows for VLAN configuration (addition, deletion, or renaming of VLANs) to be consistently maintained across a common administrative domain. Using Global Configuration Mode 3560Switch(config-if) # ss ss ww ww ii ii tt tt cc cc hh hh pp pp oo oo rr rr tt tt tt tt rr rr uu uu nn nn kk kk ee ee nn nn cc cc aa aa pp pp ss ss uu uu ll ll a a aa tt tt ii ii oo oo nn nn nn nn ee ee gg gg oo oo tt tt ii ii aa aa tt tt ee ee Specifies that the interface negotiate with the neighboring interface to become either an ISL or dot1q trunk, depending on the capabilities or configuration of the neighboring interface Switch(config)#vv vv tt tt pp pp mm mm oo oo dd dd ee ee cc cc ll ll ii ii ee ee nn nn tt tt Changes the switch to VTP client mode. Switch(config)#vv vv tt tt pp pp mm mm oo oo dd dd ee ee ss ss ee ee rr rr vv vv ee ee rr rr Changes the switch to VTP server mode. Switch(config)#vv vv tt tt pp pp mm mm oo oo dd dd ee ee tt tt rr rr aa aa nn nn ss ss pp pp aa aa rr rr ee ee nn nn tt tt Changes the switch to VTP transparent mode. NOTE: By default, all Catalyst switches are in server mode. Switch(config)#nn nn oo oo vv vv tt tt pp pp mm mm oo oo dd dd ee ee Returns the switch to the default VTP server mode. Switch(config)#vv vv tt tt pp pp dd dd oo oo mm mm aa aa ii ii nn nn domain-name Configures the VTP domain name. The name can be from 1 to 32 characters long. NOTE: All switches operating in VTP server or client mode must have the same domain name to ensure communication. Switch(config)#vv vv tt tt pp pp pp pp aa aa ss ss ss ss ww ww oo oo rr rr dd dd password Configures a VTP password. In Cisco IOS Software Release 12.3 and later, the password is an ASCII string from 1 to 32 characters long. If you are using a Cisco IOS Software release earlier than 12.3, the password length ranges from 8 to 64 characters long. 128 VLAN Trunking Protocol (VTP) NOTE: Only VLANs included in the pruning-eligible list can be pruned. VLANs 2 through 1001 are pruning eligible by default on trunk ports. Reserved VLANs and extended-range VLANs cannot be pruned. To change which eligible VLANs can be pruned, use the interface-specific switchport trunk pruning vlan command: Switch(config-if)#ss ss ww ww ii ii tt tt cc cc hh hh pp pp oo oo rr rr tt tt tt tt rr rr uu uu nn nn kk kk pp pp rr rr uu uu nn nn ii ii nn nn gg gg vv vv ll ll aa aa nn nn rr rr ee ee mm mm oo oo vv vv ee ee 44 44 ,, ,, 22 22 00 00 33 33 00 00 ! Removes VLANs 4 and 20-30 Switch(config-if)# ss ss ww ww ii ii tt tt cc cc hh hh pp pp oo oo rr rr tt tt tt tt rr rr uu uu nn nn kk kk pp pp rr rr uu uu nn nn ii ii nn nn gg gg vv vv ll ll aa aa nn nn ee ee xx xx cc cc ee ee pp pp tt tt 44 44 00 00 55 55 00 00 ! All VLANs are added to the pruning list except for 40-50 Using VLAN Database Mode CAUTION: The VLAN database mode has been deprecated and will be removed in some future Cisco IOS release. Recommended practice dictates using only the VLAN configuration mode. NOTE: To communicate with each other, all switches must have the same VTP password set. Switch(config)#vv vv tt tt pp pp vv vv 22 22 mm mm oo oo dd dd ee ee Sets the VTP domain to Version 2. This command is for Cisco IOS Software Release 12.3 and later. If you are using a Cisco IOS Software release earlier than 12.3, the command is vtp version 2. NOTE: VTP Versions 1 and 2 are not interoperable. All switches must use the same version. The biggest difference between Versions 1 and 2 is that Version 2 has support for Token Ring VLANs. Switch(config)#vv vv tt tt pp pp pp pp rr rr uu uu nn nn ii ii nn nn gg gg Enables VTP pruning. NOTE: By default, VTP pruning is disabled. You need to enable VTP pruning on only 1 switch in VTP server mode. Switch## ## vv vv ll ll aa aa nn nn dd dd aa aa tt tt aa aa bb bb aa aa ss ss ee ee Enters VLAN database mode. Switch(vlan)## ## vv vv tt tt pp pp cc cc ll ll ii ii ee ee nn nn tt tt Changes the switch to VTP client mode. Switch(vlan)## ## vv vv tt tt pp pp ss ss ee ee rr rr vv vv ee ee rr rr Changes the switch to VTP server mode. Switch(vlan)## ## vv vv tt tt pp pp tt tt rr rr aa aa nn nn ss ss pp pp aa aa rr rr ee ee nn nn tt tt Changes the switch to VTP transparent mode. NOTE: By default, all Catalyst switches are in server mode. VLAN Trunking Protocol (VTP) 129 Switch(vlan)## ## vv vv tt tt pp pp dd dd oo oo mm mm aa aa ii ii nn nn dd dd oo oo mm mm aa aa ii ii nn nn nn nn aa aa mm mm ee ee Configures the VTP domain name. The name can be from 1 to 32 characters long. NOTE: All switches operating in VTP server or client mode must have the same domain name to ensure communication. Switch(vlan)## ## vv vv tt tt pp pp pp pp aa aa ss ss ss ss ww ww oo oo rr rr dd dd pp pp aa aa ss ss ss ss ww ww oo oo rr rr dd dd Configures a VTP password. In Cisco IOS Software Release 12.3 and later, the password is an ASCII string from 1 to 32 characters long. If you are using a Cisco IOS release earlier than 12.3, the password length ranges from 8 to 64 characters long. NOTE: All switches must have the same VTP password set to communicate with each other. Switch(vlan)## ## vv vv tt tt pp pp vv vv 22 22 mm mm oo oo dd dd ee ee Sets the VTP domain to Version 2. This command is for Cisco IOS Release 12.3 and later. If you are using a Cisco IOS release earlier than 12.3, the command is vtp version 2. NOTE: VTP Versions 1 and 2 are not interoperable. All switches must use the same version. The biggest difference between Versions 1 and 2 is that Version 2 has support for Token Ring VLANs. Switch(vlan)## ## vv vv tt tt pp pp pp pp rr rr uu uu nn nn ii ii nn nn gg gg Enables VTP pruning. NOTE: By default, VTP pruning is disabled. You need to enable VTP pruning on only one switch in VTP server mode. NOTE: Only VLANs included in the pruning-eligible list can be pruned. VLANs 2 through 1001 are pruning eligible by default on trunk ports. Reserved VLANs and extended-range VLANs cannot be pruned. To change which eligible VLANs can be pruned, use the interface-specific switchport trunk pruning vlan command: Switch(config-if)## ## ss ss ww ww ii ii tt tt cc cc hh hh pp pp oo oo rr rr tt tt tt tt rr rr uu uu nn nn kk kk pp pp rr rr uu uu nn nn ii ii nn nn gg gg vv vv ll ll aa aa nn nn rr rr ee ee mm mm oo oo vv vv ee ee 44 44 ,, ,, 22 22 00 00 33 33 00 00 Removes VLANs 4 and 20 through 30. Switch(config-if)## ## ss ss ww ww ii ii tt tt cc cc hh hh pp pp oo oo rr rr tt tt tt tt rr rr uu uu nn nn kk kk pp pp rr rr uu uu nn nn ii ii nn nn gg gg vv vv ll ll aa aa nn nn ee ee xx xx cc cc ee ee pp pp tt tt 44 44 00 00 55 55 00 00 All VLANs are added to the pruning list except for 40 through 50. Switch(vlan)## ## ee ee xx xx ii ii tt tt Applies changes to the VLAN database, increases the revision number by 1, and exits back to privileged mode. 130 Inter-VLAN Communication Using an External Router: Router-on-a-Stick Verifying VTP NOTE: If trunking has been established before VTP is set up, VTP information is propagated throughout the switch fabric almost immediately. However, because VTP information is advertised only every 300 seconds (5 minutes), unless a change has been made to force an update, it can take several minutes for VTP information to be propagated. Inter-VLAN Communication Using an External Router: Router-on-a-Stick Switch#ss ss hh hh oo oo ww ww vv vv tt tt pp pp ss ss tt tt aa aa tt tt uu uu ss ss Displays general information about VTP configuration Switch#ss ss hh hh oo oo ww ww vv vv tt tt pp pp cc cc oo oo uu uu nn nn tt tt ee ee rr rr ss ss Displays the VTP counters for the switch Router(config)## ## ii ii nn nn tt tt ee ee rr rr ff ff aa aa cc cc ee ee ff ff aa aa ss ss tt tt ee ee tt tt hh hh ee ee rr rr nn nn ee ee tt tt 00 00 / / // 00 00 Moves to interface configuration mode. Router(config-if)## ## dd dd uu uu pp pp ll ll ee ee xx xx ff ff uu uu ll ll ll ll Sets the interface to full duplex. Router(config-if)## ## nn nn oo oo ss ss hh hh uu uu tt tt dd dd oo oo ww ww nn nn Enables the interface. Router(config-if)## ## ii ii nn nn tt tt ee ee rr rr ff ff aa aa cc cc ee ee ff ff aa aa ss ss tt tt ee ee tt tt hh hh ee ee rr rr nn nn ee ee tt tt 00 00 / / // 00 00 11 11 Creates subinterface 0/0.1 and moves to subinterface configuration mode. Router(config-subif)## ## dd dd ee ee ss ss cc cc rr rr ii ii pp pp tt tt ii ii oo oo nn nn MM MM aa aa nn nn aa aa gg gg ee ee mm mm ee ee nn nn tt tt VV VV L L LL AA AA NN NN 11 11 (Optional) Sets the locally significant description of the subinterface. Router(config-subif) ## ## ee ee nn nn cc cc aa aa pp pp ss ss uu uu ll ll aa aa tt tt ii ii oo oo nn nn dd dd oo oo tt tt 11 11 qq qq 11 11 nn nn aa aa tt tt ii ii vv vv ee ee Assigns VLAN 1 to this subinterface. VLAN 1 will be the native VLAN. This subinterface will use the 802.1q trunking protocol. Router(config-subif)## ## ii ii pp pp aa aa dd dd dd dd rr rr ee ee ss ss ss ss 11 11 99 99 22 22 11 11 66 66 88 88 11 11 11 11 22 22 5 5 55 55 55 22 22 55 55 55 55 22 22 55 55 55 55 00 00 Assigns the IP address and netmask. Router(config-subif)## ## ii ii nn nn tt tt ee ee rr rr ff ff aa aa cc cc ee ee ff ff aa aa ss ss tt tt ee ee tt tt hh hh ee ee rr rr nn nn ee ee tt tt 00 00 / / // 00 00 11 11 00 00 Creates subinterface 0/0.10 and moves to subinterface configuration mode. Router(config-subif)## ## dd dd ee ee ss ss cc cc rr rr ii ii pp pp tt tt ii ii oo oo nn nn AA AA cc cc cc cc oo oo uu uu nn nn tt tt ii ii nn nn gg gg VV VV L L LL AA AA NN NN 11 11 00 00 (Optional) Sets the locally significant description of the subinterface. Router(config-subif) ## ## ee ee nn nn cc cc aa aa pp pp ss ss uu uu ll ll aa aa tt tt ii ii oo oo nn nn dd dd oo oo tt tt 11 11 qq qq 11 11 00 00 Assigns VLAN 10 to this subinterface. This subinterface will use the 802.1q trunking protocol. Inter-VLAN Communication Tips 131 NOTE: The subnets of the VLANs are directly connected to the router. Routing between these subnets does not require a dynamic routing protocol. In a more complex topology, these routes need to either be advertised with whatever dynamic routing protocol is being used or be redistributed into whatever dynamic routing protocol is being used. NOTE: Routes to the subnets associated with these VLANs appear in the routing table as directly connected networks. Inter-VLAN Communication Tips • Although most routers support both ISL and dot1q encapsulation, some switch models only support dot1q (the 2950 and 2960 series, for example). • If you need to use ISL as your trunking protocol, use the command encapsulation isl x, where x is the number of the VLAN to be assigned to that subinterface. • Recommended best practice is to use the same number of the VLAN number for the subinterface number. It is easier to troubleshoot VLAN 10 on subinterface fa0/0.10 than on fa0/0.2. • The native VLAN (usually VLAN 1) cannot be configured on a subinterface for Cisco IOS Software releases that are earlier than 12.1(3)T. Native VLAN IP addresses therefore need to be configured on the physical interface. Other VLAN traffic is configured on subinterfaces: Router(config)#interface fastethernet 0/0 Router(config-if)#encapsulation dot1q 1 native Router(config-if)#ip address 192.168.1.1 255.255.255.0 Router(config-if)#interface fastethernet 0/0.10 Router(config-subif)#encapsulation dot1q 10 Router(config-subif)#ip address 192.168.10.1 255.255.255.0 Router(config-subif)## ## ii ii pp pp aa aa dd dd dd dd rr rr ee ee ss ss ss ss 11 11 99 99 22 22 11 11 66 66 88 88 11 11 00 00 11 11 2 2 22 55 55 55 55 22 22 55 55 55 55 22 22 55 55 55 55 00 00 Assigns the IP address and netmask. Router(config-subif)## ## ee ee xx xx ii ii tt tt Returns to interface configuration mode. Router(config-if)## ## ee ee xx xx ii ii tt tt Returns to global configuration mode. Router(config)## ## 132 Configuration Example: Inter-VLAN Communication Configuration Example: Inter-VLAN Communication Figure 13-1 illustrates the network topology for the configuration that follows, which shows how to configure inter-VLAN communication using commands covered in this chapter. Some commands used in this configuration are from previous chapters. Figure 13-3 Network Topology for Inter-VLAN Communication Configuration L2Switch1 192.168.10.10/24 WS1 Sales VLAN 10 fa0/2-4 192.168.10.0/24 192.168.20.20/24 WS2 Engineering VLAN 20 fa0/5-8 192.168.20.0/24 192.168.30.30/24 WS3 Marketing VLAN 30 fa0/9-12 192.168.30.0/24 Internet Native VLAN 1 fa0/2-4 192.168.1.0/24 VLAN 1 192.168.1.2/24 IEEE 802.1q Trunk s0/0/0 192.31.7.6/30 Lo 0 198.133.219.1/24 s0/0/0 DCE 192.31.7.5/30 fa0/0 – no IP address fa0/00.1 – VLAN 1 (Native) - 192.168.1.1/24 fa0/0.10 – VLAN 10 - 192.168.10.1/24 fa0/0.20 – VLAN 20 - 192.168.20.1/24 fa0/0.30 – VLAN 30- 192.168.30.1/24 CORP ISP 2960 fa0/1 Configuration Example: Inter-VLAN Communication 133 ISP Router Router>ee ee nn nn aa aa bb bb ll ll ee ee Moves to privileged mode Router>#cc cc oo oo nn nn ff ff ii ii gg gg uu uu rr rr ee ee tt tt ee ee rr rr mm mm ii ii nn nn aa aa ll ll Moves to global configuration mode Router(config)#hh hh oo oo ss ss tt tt nn nn aa aa mm mm ee ee II II SS SS PP PP Sets the host name ISP(config)#ii ii nn nn tt tt ee ee rr rr ff ff aa aa cc cc ee ee ll ll oo oo oo oo pp pp bb bb aa aa cc cc kk kk 00 00 Moves to interface configuration mode ISP(config-if)#dd dd ee ee ss ss cc cc rr rr ii ii pp pp tt tt ii ii oo oo nn nn ss ss ii ii mm mm uu uu ll ll aa aa tt tt ee ee dd dd aa aa dd dd dd dd r r rr ee ee ss ss ss ss rr rr ee ee pp pp rr rr ee ee ss ss ee ee nn nn tt tt ii ii nn nn gg gg rr rr ee ee mm mm oo oo tt tt ee ee ww ww ee ee bb bb ss ss ii ii tt tt ee ee Sets the locally significant interface description ISP(config-if)#ii ii pp pp aa aa dd dd dd dd rr rr ee ee ss ss ss ss 11 11 99 99 88 88 11 11 33 33 33 33 22 22 11 11 99 99 11 11 2 2 22 55 55 55 55 22 22 55 55 55 55 22 22 55 55 55 55 00 00 Assigns the IP address and netmask ISP(config-if)#ii ii nn nn tt tt ee ee rr rr ff ff aa aa cc cc ee ee ss ss ee ee rr rr ii ii aa aa ll ll 00 00 // // 00 00 // // 00 00 Moves to interface configuration mode ISP(config-if)#dd dd ee ee ss ss cc cc rr rr ii ii pp pp tt tt ii ii oo oo nn nn WW WW AA AA NN NN ll ll ii ii nn nn kk kk tt tt oo oo tt tt h h hh ee ee CC CC oo oo rr rr pp pp oo oo rr rr aa aa tt tt ee ee RR RR oo oo uu uu tt tt ee ee rr rr Sets the locally significant interface description ISP(config-if)#ii ii pp pp aa aa dd dd dd dd rr rr ee ee ss ss ss ss 11 11 99 99 22 22 33 33 11 11 77 77 55 55 22 22 55 55 55 55 . . 22 22 55 55 55 55 22 22 55 55 55 55 22 22 55 55 22 22 Assigns the IP address and netmask ISP(config-if)#cc cc ll ll oo oo cc cc kk kk rr rr aa aa tt tt ee ee 55 55 66 66 00 00 00 00 00 00 Assigns a clock rate to the interface—the DCE cable is plugged into this interface ISP(config-if)#nn nn oo oo ss ss hh hh uu uu tt tt dd dd oo oo ww ww nn nn Enables the interface ISP(config-if)#ee ee xx xx ii ii tt tt Returns to global configuration mode ISP(config-if)#rr rr oo oo uu uu tt tt ee ee rr rr ee ee ii ii gg gg rr rr pp pp 11 11 00 00 Creates Enhanced Interior Gateway Routing Protocol (EIGRP) routing process 10 ISP(config-router)#nn nn ee ee tt tt ww ww oo oo rr rr kk kk 11 11 99 99 88 88 11 11 33 33 33 33 22 22 11 11 99 99 00 00 Advertises directly connected networks (classful address only) ISP(config-router)#nn nn ee ee tt tt ww ww oo oo rr rr kk kk 11 11 99 99 22 22 33 33 11 11 77 77 00 00 Advertises directly connected networks (classful address only) ISP(config-router)#nn nn oo oo aa aa uu uu tt tt oo oo ss ss uu uu mm mm mm mm aa aa rr rr yy yy Disables auto summarization ISP(config-router)#ee ee xx xx ii ii tt tt Returns to global configuration mode ISP(config)#ee ee xx xx ii ii tt tt Returns to privileged mode ISP#cc cc oo oo pp pp yy yy rr rr uu uu nn nn nn nn ii ii nn nn gg gg cc cc oo oo nn nn ff ff ii ii gg gg ss ss tt tt aa aa rr rr tt tt uu uu pp pp cc cc oo oo nn nn ff ff ii ii gg gg Saves the configuration to NVRAM 134 Configuration Example: Inter-VLAN Communication CORP Router Router>ee ee nn nn aa aa bb bb ll ll ee ee Moves to privileged mode. Router>#cc cc oo oo nn nn ff ff ii ii gg gg uu uu rr rr ee ee tt tt ee ee rr rr mm mm ii ii nn nn aa aa ll ll Moves to global configuration mode. Router(config)#hh hh oo oo ss ss tt tt nn nn aa aa mm mm ee ee CC CC OO OO RR RR PP PP Sets the host name. CORP(config)#nn nn oo oo ii ii pp pp dd dd oo oo mm mm aa aa ii ii nn nn ll ll oo oo oo oo kk kk uu uu pp pp Turns off Domain Name System (DNS) resolution to avoid wait time due to DNS lookup of spelling errors. CORP(config)#ii ii nn nn tt tt ee ee rr rr ff ff aa aa cc cc ee ee ss ss ee ee rr rr ii ii aa aa ll ll 00 00 // // 00 00 // // 00 00 Moves to interface configuration mode. CORP(config-if)#dd dd ee ee ss ss cc cc rr rr ii ii pp pp tt tt ii ii oo oo nn nn ll ll ii ii nn nn kk kk tt tt oo oo II II SS SS PP PP Sets the locally significant interface description. CORP(config-if)#ii ii pp pp aa aa dd dd dd dd rr rr ee ee ss ss ss ss 11 11 99 99 22 22 33 33 11 11 77 77 66 66 22 22 55 55 55 55 . . 22 22 55 55 55 55 22 22 55 55 55 55 22 22 55 55 22 22 Assigns the IP address and netmask. CORP(config-if)#nn nn oo oo ss ss hh hh uu uu tt tt dd dd oo oo ww ww nn nn Enables the interface. CORP(config-if)#ee ee xx xx ii ii tt tt Returns to global configuration mode. CORP(config)#ii ii nn nn tt tt ee ee rr rr ff ff aa aa cc cc ee ee ff ff aa aa ss ss tt tt ee ee tt tt hh hh ee ee rr rr nn nn ee ee tt tt 00 00 // // 0 0 00 Enters interface configuration mode. CORP(config-if)#dd dd uu uu pp pp ll ll ee ee xx xx ff ff uu uu ll ll ll ll Enables full-duplex operation to ensure trunking takes effect between here and L2Switch1. CORP(config-if)#nn nn oo oo ss ss hh hh uu uu tt tt dd dd oo oo ww ww nn nn Enables the interface. CORP(config-if)#ii ii nn nn tt tt ee ee rr rr ff ff aa aa cc cc ee ee ff ff aa aa ss ss tt tt ee ee tt tt hh hh ee ee rr rr nn nn ee ee tt tt 00 00 // // 0 0 00 11 11 Creates a virtual subinterface and moves to subinterface configuration mode. CORP(config-subif)#dd dd ee ee ss ss cc cc rr rr ii ii pp pp tt tt ii ii oo oo nn nn MM MM aa aa nn nn aa aa gg gg ee ee mm mm ee ee nn nn tt tt VV VV LL LL A A AA NN NN 11 11 –– –– NN NN aa aa tt tt ii ii vv vv ee ee VV VV LL LL AA AA NN NN Sets the locally significant interface description. CORP(config-subif)#ee ee nn nn cc cc aa aa pp pp ss ss uu uu ll ll aa aa tt tt ii ii oo oo nn nn dd dd oo oo tt tt 11 11 qq qq 11 11 nn nn aa aa tt tt i i ii vv vv ee ee Assigns VLAN 1 to this subinterface. VLAN 1 will be the native VLAN. This subinterface will use the 802.1q trunking protocol. CORP(config-subif)#ii ii pp pp aa aa dd dd dd dd rr rr ee ee ss ss ss ss 11 11 99 99 22 22 11 11 66 66 88 88 11 11 11 11 22 22 55 55 5 5 55 22 22 55 55 55 55 22 22 55 55 55 55 00 00 Assigns the IP address and netmask. CORP(config-subif)#ii ii nn nn tt tt ee ee rr rr ff ff aa aa cc cc ee ee ff ff aa aa ss ss tt tt ee ee tt tt hh hh ee ee rr rr nn nn ee ee tt tt 00 00 // // 0 0 00 11 11 00 00 Creates a virtual subinterface and moves to subinterface configuration mode. Configuration Example: Inter-VLAN Communication 135 CORP(config-subif)#dd dd ee ee ss ss cc cc rr rr ii ii pp pp tt tt ii ii oo oo nn nn SS SS aa aa ll ll ee ee ss ss VV VV LL LL AA AA NN NN 11 11 00 00 Sets the locally significant interface description. CORP(config-subif)#ee ee nn nn cc cc aa aa pp pp ss ss uu uu ll ll aa aa tt tt ii ii oo oo nn nn dd dd oo oo tt tt 11 11 qq qq 11 11 00 00 Assigns VLAN 10 to this subinterface. This subinterface will use the 802.1q trunking protocol. CORP(config-subif)#ii ii pp pp aa aa dd dd dd dd rr rr ee ee ss ss ss ss 11 11 99 99 22 22 11 11 66 66 88 88 11 11 00 00 11 11 22 22 5 5 55 55 55 22 22 55 55 55 55 22 22 55 55 55 55 00 00 Assigns the IP address and netmask. CORP(config-subif)#ii ii nn nn tt tt ee ee rr rr ff ff aa aa cc cc ee ee ff ff aa aa ss ss tt tt ee ee tt tt hh hh ee ee rr rr nn nn ee ee tt tt 00 00 // // 0 0 00 22 22 00 00 Creates a virtual subinterface and moves to subinterface configuration mode. CORP(config-subif)#dd dd ee ee ss ss cc cc rr rr ii ii pp pp tt tt ii ii oo oo nn nn EE EE nn nn gg gg ii ii nn nn ee ee ee ee rr rr ii ii nn nn gg gg VV VV L L LL AA AA NN NN 22 22 00 00 Sets the locally significant interface description. CORP(config-subif)#ee ee nn nn cc cc aa aa pp pp ss ss uu uu ll ll aa aa tt tt ii ii oo oo nn nn dd dd oo oo tt tt 11 11 qq qq 22 22 00 00 Assigns VLAN 20 to this subinterface. This subinterface will use the 802.1q trunking protocol. CORP(config-subif)#ii ii pp pp aa aa dd dd dd dd rr rr ee ee ss ss ss ss 11 11 99 99 22 22 11 11 66 66 88 88 22 22 00 00 11 11 22 22 5 5 55 55 55 22 22 55 55 55 55 22 22 55 55 55 55 00 00 Assigns the IP address and netmask. CORP(config-subif)#ii ii nn nn tt tt ee ee rr rr ff ff aa aa cc cc ee ee ff ff aa aa ss ss tt tt ee ee tt tt hh hh ee ee rr rr nn nn ee ee tt tt 00 00 // // 0 0 00 33 33 00 00 Creates a virtual subinterface and moves to subinterface configuration mode. CORP(config-subif)#dd dd ee ee ss ss cc cc rr rr ii ii pp pp tt tt ii ii oo oo nn nn MM MM aa aa rr rr kk kk ee ee tt tt ii ii nn nn gg gg VV VV LL LL AA AA N N NN 33 33 00 00 Sets the locally significant interface description. CORP(config-subif)#ee ee nn nn cc cc aa aa pp pp ss ss uu uu ll ll aa aa tt tt ii ii oo oo nn nn dd dd oo oo tt tt 11 11 qq qq 33 33 00 00 Assigns VLAN 30 to this subinterface. This subinterface will use the 802.1q trunking protocol. CORP(config-subif)#ii ii pp pp aa aa dd dd dd dd 11 11 99 99 22 22 11 11 66 66 88 88 33 33 00 00 11 11 22 22 55 55 55 55 22 22 5 5 55 55 55 22 22 55 55 55 55 00 00 Assigns the IP address and netmask. CORP(config-subif)#ee ee xx xx ii ii tt tt Returns to interface configuration mode. CORP(config-if)#ee ee xx xx ii ii tt tt Returns to global configuration mode. CORP(config)#rr rr oo oo uu uu tt tt ee ee rr rr ee ee ii ii gg gg rr rr pp pp 11 11 00 00 Creates EIGRP routing process 10 and moves to router configuration mode. CORP(config-router)#nn nn ee ee tt tt ww ww oo oo rr rr kk kk 11 11 99 99 22 22 11 11 66 66 88 88 11 11 00 00 Advertises the 192.168.1.0 network. CORP(config-router)#nn nn ee ee tt tt ww ww oo oo rr rr kk kk 11 11 99 99 22 22 11 11 66 66 88 88 11 11 00 00 00 00 Advertises the 192.168.10.0 network. CORP(config-router)#nn nn ee ee tt tt ww ww oo oo rr rr kk kk 11 11 99 99 22 22 11 11 66 66 88 88 22 22 00 00 00 00 Advertises the 192.168.20.0 network. 136 Configuration Example: Inter-VLAN Communication L2Switch1 (Catalyst 2960) CORP(config-router)#nn nn ee ee tt tt ww ww oo oo rr rr kk kk 11 11 99 99 22 22 11 11 66 66 88 88 33 33 00 00 00 00 Advertises the 192.168.30.0 network. CORP(config-router)#nn nn ee ee tt tt ww ww oo oo rr rr kk kk 11 11 99 99 22 22 33 33 11 11 77 77 00 00 Advertises the 192.31.7.0 network. CORP(config-router)#nn nn oo oo aa aa uu uu tt tt oo oo ss ss uu uu mm mm mm mm aa aa rr rr yy yy Turns off automatic summarization at the classful boundary. CORP(config-router)#ee ee xx xx ii ii tt tt Returns to global configuration mode. CORP(config)#ee ee xx xx ii ii tt tt Returns to privileged mode. CORP#cc cc oo oo pp pp yy yy rr rr uu uu nn nn nn nn ii ii nn nn gg gg cc cc oo oo nn nn ff ff ii ii gg gg ss ss tt tt aa aa rr rr tt tt uu uu pp pp cc cc oo oo nn nn ff ff ii ii gg gg Saves the configuration in NVRAM. Switch>ee ee nn nn aa aa bb bb ll ll ee ee Moves to privileged mode. Switch#cc cc oo oo nn nn ff ff ii ii gg gg uu uu rr rr ee ee tt tt ee ee rr rr mm mm ii ii nn nn aa aa ll ll Moves to global configuration mode. Switch(config)#hh hh oo oo ss ss tt tt nn nn aa aa mm mm ee ee LL LL 22 22 SS SS ww ww ii ii tt tt cc cc hh hh 11 11 Sets the host name. L2Switch1(config)#nn nn oo oo ii ii pp pp dd dd oo oo mm mm aa aa ii ii nn nn ll ll oo oo oo oo kk kk uu uu pp pp Turns off DNS resolution. L2Switch1(config)#vv vv ll ll aa aa nn nn 11 11 00 00 Creates VLAN 10 and enters VLAN configuration mode. L2Switch1(config-vlan)#nn nn aa aa mm mm ee ee SS SS aa aa ll ll ee ee ss ss Assigns a name to the VLAN. L2Switch1(config-vlan)#ee ee xx xx ii ii tt tt Returns to global configuration mode. L2Switch1(config)#vv vv ll ll aa aa nn nn 22 22 00 00 Creates VLAN 20 and enters VLAN configuration mode. L2Switch1(config-vlan)#nn nn aa aa mm mm ee ee EE EE nn nn gg gg ii ii nn nn ee ee ee ee rr rr ii ii nn nn gg gg Assigns a name to the VLAN. L2Switch1(config-vlan)#vv vv ll ll aa aa nn nn 33 33 00 00 Creates VLAN 30 and enters VLAN configuration mode. Note that you do not have to exit back to global configuration mode to execute this command. L2Switch1(config-vlan)#nn nn aa aa mm mm ee ee MM MM aa aa rr rr kk kk ee ee tt tt ii ii nn nn gg gg Assigns a name to the VLAN. L2Switch1(config-vlan)#ee ee xx xx ii ii tt tt Returns to global configuration mode. [...]... Switch(config)#spanning-tree vlan 5 forward-time 20 Changes the forward-delay timer to 20 seconds on VLAN 5 s Switch(config)#spanning-tree vlan 5 max-age 25 Changes the maximum-aging timer to 25 seconds on VLAN 5 NOTE: For the hello-time command, the range is 1 to 10 seconds The default is 2 seconds For the forward-time command, the range is 4 to 30 seconds The default is 15 seconds For the max-age command, the range... Switch(config)#spanning-tree vlan 5 priority 12288 Configures the switch priority of VLAN 5 to 12288 NOTE: With the priority keyword, the range is 0 to 61440 in increments of 4096 The default is 32768 The lower the priority, the more likely the switch will be chosen as the root switch Only the following numbers can be used as a priority value: 0 4096 8192 12288 16384 20480 2 457 6 28672 32768 36864 40960 450 56 49 152 53 248 57 344... 57 344 61440 CAUTION: Cisco recommends caution when using this command Cisco further recommends that the spanning-tree vlan x root primary or the spanning-tree vlan x root secondary command be used instead to modify the switch priority Spanning Tree Protocol 143 Configuring STP Timers s Switch(config)#spanning-tree vlan 5 hello-time 4 Changes the hello-delay timer to 4 seconds on VLAN 5 s Switch(config)#spanning-tree... L2Switch1(config)#interface vlan 1 Creates the virtual interface for VLAN 1 and enters interface configuration mode 138 Configuration Example: Inter-VLAN Communication i L2Switch1(config-if)#ip address 192.168.1.2 255 . 255 . 255 .0 Assigns the IP address and netmask n L2Switch1(config-if)#no shutdown Enables the interface e L2Switch1(config-if)#exit Returns to global configuration mode i L2Switch1(config)#ip default-gateway... priority of less than 1, this command fails s Switch(config)#spanning-tree vlan 5 root primary Switch recalculates timers along with priority to allow the switch to become the root switch for VLAN 5 TIP: The root switch should be a backbone or distribution switch s Switch(config)#spanning-tree vlan 5 root primary diameter 7 Configures the switch to be the root switch for VLAN 5 and sets the network diameter... EtherChannel — Interface modes in EtherChannel — Guidelines for configuring EtherChannel — Configuring Layer 2 EtherChannel — Verifying EtherChannel — Configuration example: EtherChannel Spanning Tree Protocol Enabling Spanning Tree Protocol s Switch(config)#spanning-tree vlan 5 Enables STP on VLAN 5 n Switch(config)#no spanning-tree vlan 5 Disables STP on VLAN 5 140 Spanning Tree Protocol NOTE: If more VLANs... instance of spanning tree for each VLAN This is a Cisco proprietary protocol • Per-VLAN Spanning Tree Plus (PVST+)—Also Cisco proprietary Has added extensions to the PVST protocol • Rapid PVST+—This mode is the same as PVST+ except that it uses a rapid convergence based on the 802. 1w standard • Multiple Spanning Tree Protocol (MSTP)—IEEE 802. 1s Extends the 802. 1w Rapid Spanning Tree (RST) algorithm to... fa0/9-12 172.16.20.0/24 fa0 /5- 8 172.16.10.0/24 WS1 Marketing VLAN 20 fa0/12 fa0/2 Accounting VLAN 10 fa0/6 fa0/1 ALSwitch1 (2960) fa0/2 fa0/1 Core (2960) WS3 fa0 /5- 8 172.16.10.0/24 Accounting VLAN 10 fa0/6 172.16.20.3/24 WS4 fa0/9-12 172.16.20.0/24 Marketing VLAN 20 fa0/12 ALSwitch2 (2960) fa0/1 fa0/2 172.16.10.3/24 fa0/4 fa0/3 FEC IEEE 802. 1q Trunk Figure 14 -5 FEC IEEE 802. 1q Trunk EtherChannel Network... Configuring the Root Switch s Switch(config)#spanning-tree vlan 5 root Modifies the switch priority from the default 32768 to a lower value to allow the switch to become the root switch for VLAN 5 NOTE: If all other switches have extended system ID support, this switch resets its priority to 2 457 6 If any other switch has a priority set to below 2 457 6 already, this switch sets its own priority to 4096 less... seconds The default is 15 seconds For the max-age command, the range is 6 to 40 seconds The default is 20 seconds CAUTION: Cisco recommends caution when using this command Cisco further recommends that the spanning-tree vlan x root primary or the spanning-tree vlan x root secondary command be used instead to modify the switch timers Verifying STP s Switch#show spanning-tree Displays STP information s . 11 11 99 99 22 22 33 33 11 11 77 77 55 55 22 22 55 55 55 55 . . 22 22 55 55 55 55 22 22 55 55 55 55 22 22 55 55 22 22 Assigns the IP address and netmask ISP(config-if)#cc cc ll ll oo oo cc cc kk kk . 11 11 99 99 22 22 33 33 11 11 77 77 66 66 22 22 55 55 55 55 . . 22 22 55 55 55 55 22 22 55 55 55 55 22 22 55 55 22 22 Assigns the IP address and netmask. CORP(config-if)#nn nn oo oo . 11 11 99 99 22 22 11 11 66 66 88 88 11 11 00 00 11 11 2 2 22 55 55 55 55 22 22 55 55 55 55 22 22 55 55 55 55 00 00 Assigns the IP address and netmask. Router(config-subif)## ## ee ee xx xx ii ii tt tt Returns

Ngày đăng: 14/08/2014, 13:21

Từ khóa liên quan

Mục lục

  • CCNA Portable Command Guide, Second Edition

    • Part V: Switching

      • Chapter 13 VLAN Trunking Protocol and Inter-VLAN Routing

        • VLAN Trunking Protocol (VTP)

        • Verifying VTP

        • Inter-VLAN Communication Using an External Router: Router-on-a-Stick

        • Inter-VLAN Communication Tips

        • Configuration Example: Inter-VLAN Communication

        • Chapter 14 STP and EtherChannel

          • Spanning Tree Protocol

          • EtherChannel

          • Part VI: Extending the LAN

            • Chapter 15 Implementing a Wireless LAN

              • Wireless Access Point Configuration: Linksys 300N Access Point

Tài liệu cùng người dùng

  • Đang cập nhật ...

Tài liệu liên quan