????êμ?é??3?£o????D?Díí???
ó2?t?·?3£o6ì¨PC?ú£?3ì¨?????ú£?3ì¨?·óé£?3?ù??2???£?7?ù?±í¨???£
èí?t?·?3£owindows xp 2ù×÷?μí3 3????????£
êμ?é2??è£o
1.°′????í?á??ó?????ú£??·óé?÷£?PC?úμ?êy?Y???£
Pc1?----¨¤Sw1 7o????ú Pc2?----¨¤Sw2 7o????ú
Pc3?----¨¤Sw1 17o????ú Pc4?----¨¤Sw2 17o????ú
Pc5?----¨¤Sw3 5o????ú pc6?----¨¤Sw3 12o????ú
Sw1 24o????ú?----¨¤Sw2 24o????ú
Sw1 23o????ú?----¨¤Router1 e0/0???ú
Router1 e1/1???ú?----¨¤Router2 e0/0???ú
Router2 e1/2???ú?----¨¤Router3 e1/1???ú
Router3 e0/0???ú?----¨¤Switch3 24o????ú
2.switch1μ?????è???£o
switch>enable
switch#config terminal
switch(config)#hostname sw1
sw1(config)#no ip domain-lookup
sw1(config)#line console 0
sw1(config-line)#exec-timeout 0 0
sw1(config-line)#logging synchronous
sw1(config-line)#enable password 123
sw1(config)#exit
sw1(config)#vlan database
sw1(vlan)#VTP domain abc.com
sw1(vlan)#vtp password cisco
sw1(vlan)#exit
sw1#config terminal
sw1(config)#interface f0/23
sw1(config-line)#switch mode trunk
sw1(config-line)#no shutdown
sw1(config-line)#interface f0/24
sw1(config-line)#switch mode trunk
sw1(config-line)#no shutdown
sw1(config-line)#exit
sw1(config)#vlan 2,3
sw1(config)#interface range f0/1-10
sw1(config-if-range)#switchport access vlan 2
sw1(config-if-range)#interface range f0/11-22
sw1(config-if-range)#switch port access vlan 3
3.switch2????è???£o
switch>enable
switch#config terminal
switch(config)#hostname sw2
sw2(config)#no ip domain-lookup
sw2(config)#line vty 0 4
sw2(config-line)#login
sw2(config-line)#password cisco
sw2(config-line)#exit
sw2(config)#line console 0
sw2(config-line)#exec-timeout 0 0
sw2(config-line)#logging synchronous
sw2(config-line)#exit
sw2#vlan database
sw2(vlan)#vtp mode client(Dé?a?ú?D?avtp client)
sw2(vlan)#vtp domain benet.com
sw2(vlan)#vtp password 123
sw2(vlan)#exit
sw2#config terminal
sw2(config)#interface range f0/1 - 10
sw2(config-if-range)#switchport access vlan 2
#p#
sw2(config-if-range)#interface range f0/11 - 22
sw2(config-if)#switchport access vlan 3
sw2(config-if)#interface f0/24
de4(config-if)#no showdown
sw2(config-if)#switchport mode trunk
sw2(config-if)#exit
4.switch3????è???£o
switch>enable
switch#config terminal
switch(config)#hostname sw3
sw3(configig)#no ip domain-lookup
sw3(config)#line vty 0 4
sw3(config-line)#login
sw3(config-line)#password 123
sw3(config-line)#exit
sw3(config)#line console 0
sw3(config-line)#exec-timeout 0 0
sw3(config-line)#logging synchronous
sw3(config-line)#exit
sw3(config)#vlan 2,3
sw3(config)#interface range f0/1 - 5
sw3(config-if)#switchport access vlan 2
sw3(config-if)#interface range f0/6 - 15
sw3(config-if)#switchport access vlan 3
sw3(config-if)#interface range f0/16 - 26
sw3(config-if)#switchport access vlan 4
sw3(config-if)#interface f0/24
sw3(config-if)#no shutdown
sw3(config-if)#switchport mode trunk
sw3(config-if)#exit
5£orouter1????è???£o
router>enable
router#config terminal
router(config)#hostname r1
r1(config)#no ip domain-lookup
r1(config)#line vty 0 4
r1(config-line)#login
r1(config-line)#password cisco
r1(config-line)#enable password 123
r1(config)#line console 0
r1(config-line)#exec-timeout 0 0
r1(config-line)#logging synchronous
r1(config-line)#exit
r1(config)#int E0/0
r1(config-if)#ip address 192.168.1.254 255.255.255.128
r1(config-if)#no shutdown
r1(config)#interface E1/1
r1(config-if)#ip address 192.168.2.193 255.255.255.128
r1(config-if)#no shutdown
r1(config-if)#interface E0/0.2
r1(config-subif)#encapsulation dot1q 2
r1(config-subif)#ip address 192.168.1.62 255.255.255.128
r1(config-subif)#interface E0/0.3
r1(config-subif)#encapsulation dot1q 3
r1(config-subif)#ip address 192.168.1.126 255.255.255.128
r1(config-subif)#exit
r1(config)#ip route 192.168.2.192 255.255.255.252 192.168.2.192
r1(config)#ip route 192.168.2.0 255.255.255.192 192.168.2.194
r1(config)#ip route 192.168.2.64 255.255.255.192 192.168.2.194
6£?Router2????è???£o
router>enable
router#config termind
router(config)#hostname r2
r2(config)#no ip domain-lookup
r2(config)#line vty 0 4
r2(config-line)#login
r2(config-line)#password cisco
r2(config-line)#enable password 123
r2(config-line)#exit
r2(config)#line console 0
r2(config-line)#exec-timeout 0 0
r2(config-line)#logging synchronous
r2(config-line)#exit
r2(config)#int E0/0
r2(config-if)#ip address 192.268.2.194 255.255.255.252
r2(config-if)#no shutdown
r2(config-if)#interface E1/2
r2(config-if)#ip address 192.268.2.197 255.255.255.252
r2(config-if)#no shutdown
r2(config)#ip route 192.168.1.0 255.255.255.128 192.168.2.193
r2(config)#ip route 192.168.2.0 255.255.255.192 192.168.2.198
r2(config)#exit
7.router3????è???£o
router>enable
router#config terminal
router(config)#hostname r3
r3(config)#no ip domain-lookup
r3(config)#line vty 0 4
r3(config-line)#login
r3(config-line)#password cisco
r3(config-line)#enable password 123
r3(config-line)#exit
r3(config)#line console 0r3(config-line)#exec-timeout 0 0
r3(config-line)#logging synchronous
r3(config-line)#exit
r3(config)#interface E0/0
r3(config-if)#ip address 193.368.2.198 255.255.255.252
r3(config-if)#no shutdown
r3(config-if)#interface E1/3
r3(config-if)#ip address 193.368.2.254 255.255.255.192
r3(config-if)#no shutdown
r3(config)#ip route 0.0.0.0 0.0.0.0 192.168.2.197
r3(config)#exit
8.??PC?úéè??IP μ??·,2¢?é?¤?¥í¨?£
PC1: 192.168.1.1 PC2: 192.168.1.2 PC3: 192.168.1.129
PC4: 192.168.1.130 PC5: 192.168.2.1 PC6:192.168.2.65
?ú??ì¨PC?úé?′ò?a?°??DD?±???°?ò£?ó?ping ?üá??à?¥2a?éí???ê?·??????yè·.