资源描述
精品文档
实验一
Switch1:
S2328G_01>en 14
Password:
S2328G_01#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
S2328G_01(config)#vlan 10
S2328G_01(config-vlan)#name sales
S2328G_01(config-vlan)#exit
S2328G_01(config)#interface fastethernet 0/5
S2328G_01(config-if-FastEthernet 0/5)#switchport access vlan 10
S2328G_01(config-if-FastEthernet 0/5)#show vlan id 10
VLAN Name Status Ports
---- -------------------------------- --------- --------------------------------
---
10 sales STATIC Fa0/5, Fa0/24
S2328G_01(config-if-FastEthernet 0/5)#exit
S2328G_01(config)#vlan 20
S2328G_01(config-vlan)#name technical
S2328G_01(config-vlan)#exit
S2328G_01(config)#interface fastethernet 0/15
S2328G_01(config-if-FastEthernet 0/15)#switchport access vlan 20
S2328G_01(config-if-FastEthernet 0/15)#show vlan id 20
VLAN Name Status Ports
---- -------------------------------- --------- --------------------------------
---
20 technical STATIC Fa0/15, Fa0/24
S2328G_01(config-if-FastEthernet 0/15)#exit
S2328G_01(config)#interface fastethernet 0/24
S2328G_01(config-if-FastEthernet 0/24)#switchport mode trunk
S2328G_01(config-if-FastEthernet 0/24)#$ 0/24 switchport
Interface Switchport Mode Access Native Protected VLAN lists
------------------------ ---------- --------- ------ ------ --------- ----------
FastEthernet 0/24 enabled TRUNK 1 1 Disabled ALL
S2328G_01(config-if-FastEthernet 0/24)#
Switch2:
S2328G_02>en 14
Password:
S2328G_02#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
S2328G_02(config)#vlan 10
S2328G_02(config-vlan)#name sales
S2328G_02(config-vlan)#exit
S2328G_02(config)#interface fastethernet 0/5
S2328G_02(config-if-FastEthernet 0/5)#switchport access vlan 10
S2328G_02(config-if-FastEthernet 0/5)#show vlan id 10
VLAN Name Status Ports
---- -------------------------------- --------- --------------------------------
---
10 sales STATIC Fa0/5, Fa0/24
S2328G_02(config-if-FastEthernet 0/5)#exit
S2328G_02(config)#interface fastethernet 0/24
S2328G_02(config-if-FastEthernet 0/24)#switchport mode trunk
S2328G_02(config-if-FastEthernet 0/24)#$ 0/24 switchport
Interface Switchport Mode Access Native Protected VLAN lists
------------------------ ---------- --------- ------ ------ --------- ----------
FastEthernet 0/24 enabled TRUNK 1 1 Disabled ALL
S2328G_02(config-if-FastEthernet 0/24)#
测试结果:
PC1 ping PC3
PC1:
C:\Documents and Settings\nbu>ping 192.168.10.30
Pinging 192.168.10.30 with 32 bytes of data:
Reply from 192.168.10.30: bytes=32 time=1ms TTL=128
Reply from 192.168.10.30: bytes=32 time<1ms TTL=128
Reply from 192.168.10.30: bytes=32 time<1ms TTL=128
Reply from 192.168.10.30: bytes=32 time<1ms TTL=128
Ping statistics for 192.168.10.30:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 1ms, Average = 0ms
PC2:
C:\Documents and Settings\nbu>ping 192.168.10.30
Pinging 192.168.10.30 with 32 bytes of data:
Request timed out.
Request timed out.
Request timed out.
Request timed out.
Ping statistics for 192.168.10.30:
Packets: Sent = 4, Received = 0, Lost = 4 (100% loss),
C:\Documents and Settings\nbu>
实验二:
实验代码:
S3760_02(config)#configure terminal
% Unknown command.
S3760_02(config)#vlan 10
S3760_02(config-vlan)#exit
S3760_02(config)#vlan 20
S3760_02(config-vlan)#exit
S3760_02(config)#interface fastethernet 0/1
S3760_02(config-if-FastEthernet 0/1)#switchport access vlan 10
S3760_02(config-if-FastEthernet 0/1)#exit
S3760_02(config)#interface fastethernet 0/2
S3760_02(config-if-FastEthernet 0/2)#switchport access vlan 20
S3760_02(config-if-FastEthernet 0/2)#exit
S3760_02(config)#interface vlan 10
S3760_02(config-if-VLAN 10)#ip address 192.168.10.1 255.255.255.0
S3760_02(config-if-VLAN 10)#no shutdown
S3760_02(config-if-VLAN 10)#exit
S3760_02(config)#interface vlan 20
S3760_02(config-if-VLAN 20)#ip address 192.168.20.1 255.255.255.0
S3760_02(config-if-VLAN 20)#no shutdown
S3760_02(config-if-VLAN 20)#exit
S3760_02(config)#
测试结果:
C:\Documents and Settings\nbu>ping 192.168.20.2
Pinging 192.168.20.2 with 32 bytes of data:
Reply from 192.168.20.2: bytes=32 time=8ms TTL=127
Reply from 192.168.20.2: bytes=32 time<1ms TTL=127
Reply from 192.168.20.2: bytes=32 time<1ms TTL=127
Reply from 192.168.20.2: bytes=32 time<1ms TTL=127
Ping statistics for 192.168.20.2:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 8ms, Average = 2ms
实验三
Switch1
S2328G_01>en 14
Password:
S2328G_01#spanning-tree
Translating "spanning-tree"...
% Unrecognized host or address, or protocol not running.
S2328G_01#spanning-tree priority 4096
% Unknown command.
S2328G_01#spanning-tree
Translating "spanning-tree"...
% Unrecognized host or address, or protocol not running.
S2328G_01#spanning-tree mode stp
% Unknown command.
S2328G_01#exit
S2328G_01 CON0 is now available
Press RETURN to get started
S2328G_01>en 14
Password:
S2328G_01#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
S2328G_01(config)#spanning-tree
Enable spanning-tree.
S2328G_01(config)#*Mar 2 17:50:27: %SPANTREE-5-TOPOTRAP: Topology Change Tra
or instance 0.
S2328G_01(config)#spanning-tree mode stp
S2328G_01(config)#spanning-tree priority 4096
S2328G_01(config)#show spanning-*Mar 2 17:51:25: %SPANTREE-5-TOPOTRAP: Topol
Change Trap.
StpVersion : STP
SysStpStatus : ENABLED
MaxAge : 20
HelloTime : 2
ForwardDelay : 15
BridgeMaxAge : 20
BridgeHelloTime : 2
BridgeForwardDelay : 15
MaxHops: 20
TxHoldCount : 3
PathCostMethod : Long
BPDUGuard : Disabled
BPDUFilter : Disabled
LoopGuardDef : Disabled
BridgeAddr : 001a.a948.0247
Priority: 4096
TimeSinceTopologyChange : 0d:0h:1m:3s
TopologyChanges : 1
DesignatedRoot : 1000.001a.a948.0247
RootCost : 0
RootPort : 0
S2328G_01(config)#
Switch2
S2328G_02>en 14
Password:
S2328G_02#con
S2328G_02#configure tem
S2328G_02#configure ter
S2328G_02#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
S2328G_02(config)#spanning-tree
S2328G_02(config)#spanning-tree mode stp
.a948.0247.ged: New Root Port is FastEthernet 0/24. New Root Mac Address is 001
S2328G_02(config)#show spanning-tree
StpVersion : STP
SysStpStatus : ENABLED
MaxAge : 20
HelloTime : 2
ForwardDelay : 15
BridgeMaxAge : 20
BridgeHelloTime : 2
BridgeForwardDelay : 15
MaxHops: 20
TxHoldCount : 3
PathCostMethod : Long
BPDUGuard : Disabled
BPDUFilter : Disabled
LoopGuardDef : Disabled
BridgeAddr : 001a.a948.02a7
Priority: 32768
TimeSinceTopologyChange : 0d:0h:3m:36s
TopologyChanges : 1
DesignatedRoot : 1000.001a.a948.0247
RootCost : 200000
RootPort : 1
S2328G_02(config)#*Mar 2 18:08:53: %SPANTREE-5-TOPOTRAP: Topology Change Trap.
Switch3
S3760_01>en 14
Password:
S3760_01#con
S3760_01#configure tem
S3760_01#configure ter
S3760_01#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
S3760_01 (config)#spanning-tree
S3760_01 (config)#spanning-tree mode stp
.a948.0247.ged: New Root Port is FastEthernet 0/24. New Root Mac Address is 001
S3760_01 (config)#show spanning-tree
StpVersion : STP
SysStpStatus : ENABLED
MaxAge : 20
HelloTime : 2
ForwardDelay : 15
BridgeMaxAge : 20
BridgeHelloTime : 2
BridgeForwardDelay : 15
MaxHops: 20
TxHoldCount : 3
PathCostMethod : Long
BPDUGuard : Disabled
BPDUFilter : Disabled
LoopGuardDef : Disabled
BridgeAddr : 001a.a948.02a7
Priority: 32768
TimeSinceTopologyChange : 0d:0h:3m:36s
TopologyChanges : 1
DesignatedRoot : 1000.001a.a948.0247
RootCost : 200000
RootPort : 2
S3760_01 (config)#*Mar 2 18:08:53: %SPANTREE-5-TOPOTRAP: Topology Change Trap.
实验四:
Switch 1
% Incomplete command.
S2328G_02(config)#vlan 10
S2328G_02(config-vlan)#name sales
S2328G_02(config-vlan)#exit
S2328G_02(config)#interface fastethernet 0/5
S2328G_02(config-if-FastEthernet 0/5)#switchport access vlan 10
S2328G_02(config-if-FastEthernet 0/5)#end
S2328G_02#*Mar 2 18:42:05: %SYS-5-CONFIG_I: Configured from console by console
S2328G_02#show vlan i*Mar 2 18:42:20: %LINK-3-UPDOWN: Interface FastEthernet 0/
1, changed state to up.
*Mar 2 18:42:20: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet 0
/1, changed state to up.
d*Mar 2 18:42:21: %LINK-3-UPDOWN: Interface FastEthernet 0/2, changed state to
up.
*Mar 2 18:42:21: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet
0/2, changed state to up.
*Mar 2 18:42:24: %SPANTREE-5-TOPOTRAP: Topology Change Trap for instance 0.
*Mar 2 18:42:25: %SPANTREE-5-TOPOTRAP: Topology Change Trap for instance 0.
VLAN Name Status Ports
---- -------------------------------- --------- --------------------------------
---
1 VLAN0001 STATIC Fa0/1, Fa0/2, Fa0/3, Fa0/4
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/25
Gi0/26
10 sales STATIC Fa0/5
S2328G_02#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
S2328G_02(config)#interface aggergateport 1
^
% Invalid input detected at '^' marker.
S2328G_02(config)#switchport mode trunk
^
% Invalid input detected at '^' marker.
S2328G_02(config)#exit
S2328G_02#*Mar 2 18:43:55: %SYS-5-CONFIG_I: Configured from console by console
S2328G_02#interface range fastethernet 0/1-2
% Unknown command.
S2328G_02#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
S2328G_02(config)#interface aggregateport 1
S2328G_02(config-if-AggregatePort 1)#switchport mode trunk
S2328G_02(config-if-AggregatePort 1)#exit
S2328G_02(config)#interface range fastethernet 0/1-2
S2328G_02(config-if-range)#port-group 1
S2328G_02(config-if-range)#en*Mar 2 18:47:13: %LINK-5-CHANGED: Interface FastEt
hernet 0/1, changed state to administratively down.
*Mar 2 18:47:13: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet 0
/1, changed state to down.
*Mar 2 18:47:13: %LINK-3-UPDOWN: Interface AggregatePort 1, changed state to up
.
d*Mar 2 18:47:13: %LINEPROTO-5-UPDOWN: Line protocol on Interface AggregatePort
1, changed state to up.
*Mar 2 18:47:13: %LINK-5-CHANGED: Interface FastEthernet 0/2, changed state to
administratively down.
*Mar 2 18:47:13: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet 0
/2, changed state to down.
*Mar 2 18:47:16: %SPANTREE-5-TOPOTRAP: Topology Change Trap for instance 0.
S2328G_02#*Mar 2 18:47:22: %SYS-5-CONFIG_I: Configured from console by console
S2328G_02#end
Translating "end"...
% Unrecognized host or address, or protocol not running.
S2328G_02#show aggregateport 1 summary
AggregatePort MaxPorts SwitchPort Mode Ports
------------- -------- ---------- ------ ----------------------------------
Ag1 8 Enabled TRUNK Fa0/1 ,Fa0/2
S2328G_02#
Switch2
Password:
S2328G_01#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
S2328G_01(config)#vlan 10
S2328G_01(config-vlan)#name sales
S2328G_01(config-vlan)#exit
S2328G_01(config)#interface fastehernet 0/5
^
% Invalid input detected at '^' marker.
S2328G_01(config)#interface fastethernet 0/5
S2328G_01(config-if-FastEthernet 0/5)#switchport access vlan 10
S2328G_01(config-if-FastEthernet 0/5)#end
S2328G_01#*Mar 2 18:30:03: %SYS-5-CONFIG_I: Configured from console by
S2328G_01#show vlan id 10
VLAN Name Status Ports
---- -------------------------------- --------- -----------------------
---
10 sales STATIC Fa0/5
S2328G_01#exit
S2328G_01 CON0 is now available
Press RETURN to get started
S2328G_01>en 14
Password:
S2328G_01#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
S2328G_01(config)#interface aggergateport 1
^
% Invalid input detected at '^' marker.
S2328G_01(config)#interface aggregateport 1
S2328G_01(config-if-AggregatePort 1)#switchport mode trunk
S2328G_01(config-if-AggregatePort 1)#exit
S2328G_01(config)#interface range fastethernrt 0/1-2
^
% Invalid input detected at '^' marker.
S2328G_01(config)#interface range fastethernet 0/1-2
S2328G_01(config-if-range)#port-group 1
S2328G_01(config-if-range)#*Mar 2 18:33:00: %LINK-5-CHANGED: Interface
rnet 0/1, changed state to administratively down.
e*Mar 2 18:33:00: %LINEPROTO-5-UPDOWN: Line protocol on Interface Fast
0/1, changed state to down.
*Mar 2 18:33:00: %LINK-3-UPDOWN: Interface AggregatePort 1, changed st
.
*Mar 2 18:33:00: %LINEPROTO-5-UPDOWN: Line protocol on Interface Aggre
1, changed state to up.
n*Mar 2 18:33:00: %LINK-5-CHANGED: Interface FastEthernet 0/2, changed
administratively down.
*Mar 2 18:33:00: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastE
/2, changed state to down.
S2328G_01#*Mar 2 18:33:11: %SYS-5-CONFIG_I: Configured from console by
S2328G_01#end
Translating "end"...
% Unrecognized host or address, or protocol not running.
S2328G_01#show arrregateport 1 summary
^
% Invalid input detected at '^' marker.
S2328G_01#*Mar 2 18:33:52: %LINK-3-UPDOWN: Interface FastEthernet 0/5,
state to down.
*Mar 2 18:33:52: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastE
/5, changed state to down.
p.ar 2 18:33:55: %LINK-3-UPDOWN: Interface FastEthernet 0/5, changed s
*Mar 2 18:33:55: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastE
/5, changed state to up.
S2328G_01#show aggregateport 1 summary
AggregatePort MaxPorts SwitchPort Mode Ports
------------- -------- ---------- ------ ------------------------------
Ag1 8 Enabled TRUNK Fa0/1 ,Fa0/2
S2328G_01#
测试结果:
两条:
C:\Documents and Settings\nbu>ping 192.168.10.30
Pinging 192.168.10.30 with 32 bytes of data:
Reply from 19
展开阅读全文