Switch_2960 1 台;Swithc_3560 1 台;PC 3 台;直连线
en
conf t
vlan 2
exit
vlan 3
exit
interface fa 0/1
switch access vlan 2
exit
interface fa 0/2
switch access vlan 3
exit
inter fa 0/24
switchport mode trunk
end
show vlan
en
conf t
vlan 2
exit
vlan 3
exit
interface fa 0/1
switchport access vlan 2
exit
inter fa 0/2
switchport access vlan 3
exit
inter fa 0/24
switch mode trunk
end
show vlan
pc 2 台;Router-PT 可扩展路由 2 台;Switch_2960 2 台;DCE 串口线;直连线;交叉线
en
conf t
inter fa 1/0
ip address 192.168.1.1 255.255.255.0
no shutdown
exit
inter serial 2/0
ip address 192.168.3.1 255.255.255.0
clock rate 64000
no shutdown
exit
ip route 192.168.2.0 255.255.255.0 192.168.3.2
exit
en
conf t
inter fa 1/0
ip address 192.168.2.1 255.255.255.0
no shutdown
exit
inter serial 2/0
ip address 192.168.3.2 255.255.255.0
no shutdown
exit
ip route 192.168.1.0 255.255.255.0 192.168.3.1
exit
en
conf t
int f0/0
no shutdown
ip address 192.168.1.1 255.255.255.0
exit
int f0/1
no shutdown
ip address 192.168.2.1 255.255.255.0
exit
router ospf 1
network 192.168.1.0 0.0.0.255 area 0
network 192.168.2.0 0.0.0.255 area 0
exit
exit
en
conf t
int f0/0
no shutdown
ip address 192.168.2.2 255.255.255.0
exit
int f0/1
no shutdown
ip address 192.168.3.1 255.255.255.0
exit
router ospf 1
network 192.168.2.2 0.0.0.255 area 0
network 192.168.3.1 0.0.0.255 area 0
exit
exit
en
conf t
int f0/0
no shutdown
ip address 192.168.3.2 255.255.255.0
exit
int f0/1
no shutdown
ip address 192.168.4.1 255.255.255.0
exit
router ospf 1
network 192.168.3.2 0.0.0.255 area 0
network 192.168.4.1 0.0.0.255 area 0
exit
exit
en
conf t
inter fa 0/1
ip address 192.168.1.1 255.255.255.0
no shutdown
exit
inter fa 0/0
ip address 192.168.2.1 255.255.255.0
no shutdown
exit
router ospf 1
network 192.168.1.0 0.0.0.255 area 0
network 192.168.2.0 0.0.0.255 area 0
exit
exit
en
conf t
inter fa 0/0
ip address 192.168.2.2 255.255.255.0
no shutdown
exit
inter fa 0/1
ip address 192.168.3.1 255.255.255.0
no shutdown
exit
interface serial 0/0/0
ip address 192.168.4.1 255.255.255.0
clock rate 64000
no shutdown
exit
router ospf 1
network 192.168.2.0 0.0.0.255 area 0
network 192.168.3.0 0.0.0.255 area 0
network 192.168.4.0 0.0.0.255 area 0
exit
exit
en
conf t
inter fa 0/0
ip address 192.168.5.1 255.255.255.0
no shutdown
exit
interface serial 0/0/0
ip address 192.168.4.2 255.255.255.0
no shutdown
exit
router ospf 1
network 192.168.4.0 0.0.0.255 area 0
network 192.168.5.0 0.0.0.255 area 0
exit
exit
en
conf t
int f0/0
no shutdown
ip address 192.168.1.1 255.255.255.0
exit
int f0/1
no shutdown
ip address 192.168.2.1 255.255.255.0
exit
router rip
network 192.168.1.1
network 192.168.2.1
exit
exit
en
conf t
int f0/0
no shutdown
ip address 192.168.2.2 255.255.255.0
exit
int f0/1
no shutdown
ip address 192.168.3.1 255.255.255.0
exit
router rip
network 192.168.3.1
network 192.168.2.2
exit
exit
en
conf t
int f0/0
no shutdown
ip address 192.168.3.2 255.255.255.0
exit
int f0/1
no shutdown
ip address 192.168.4.1 255.255.255.0
exit
router rip
network 192.168.3.2
network 192.168.4.1
exit
exit
enable
configure terminal
int f0/0
no shutdown
ip address 192.168.1.1 255.255.255.0
ip dhcp pool xiao1
network 192.168.1.0 255.255.255.0
default-router 192.168.1.1
exit
int f0/1
no shutdown
ip address 192.168.2.1 255.255.255.0
ip dhcp pool xiao2
network 192.168.2.0 255.255.255.0
default-router 192.168.2.1
exit
ip dhcp excluded-address 192.168.1.1
ip dhcp excluded-address 192.168.2.1
exit
enable
configure terminal
int f0/0
no shutdown
ip address 192.168.1.1 255.255.255.0
ip dhcp pool xiao1
network 192.168.1.0 255.255.255.0
default-router 192.168.1.1
exit
ip dhcp excluded-address 192.168.1.1
int f0/1
no shutdown
ip address 192.168.2.1 255.255.255.0
exit
router rip
network 192.168.1.1
network 192.168.2.1
exit
exit
enable
configure terminal
int f0/0
no shutdown
ip address 192.168.2.2 255.255.255.0
exit
int f0/1
no shutdown
ip address 192.168.3.1 255.255.255.0
ip dhcp pool xiao2
network 192.168.3.0 255.255.255.0
default-router 192.168.3.1
exit
ip dhcp excluded-address 192.168.3.1
router rip
network 192.168.3.1
network 192.168.2.2
exit
exit
enable
configure terminal
int f0/0
no shutdown
ip address 192.168.55.33 255.255.255.224
ip dhcp pool xiao1
network 192.168.55.32 255.255.255.224
default-router 192.168.55.33
exit
ip dhcp excluded-address 192.168.55.33
int f0/1
no shutdown
ip address 192.168.66.2 255.255.255.0
exit
router rip
version 2
network 192.168.55.33
network 192.168.66.2
no auto-summary
exit
exit
enable
configure terminal
int f0/1
no shutdown
ip address 192.168.55.65 255.255.255.224
ip dhcp pool xiao1
network 192.168.55.64 255.255.255.224
default-router 192.168.55.65
exit
ip dhcp excluded-address 192.168.55.65
int f0/0
no shutdown
ip address 192.168.66.3 255.255.255.0
exit
router rip
version 2
network 192.168.55.65
network 192.168.66.3
no auto-summary
exit
exit
enable
configure terminal
int f0/1
no shutdown
ip address 192.168.55.97 255.255.255.224
ip dhcp pool xiao1
network 192.168.55.96 255.255.255.224
default-router 192.168.55.97
exit
ip dhcp excluded-address 192.168.55.97
int f0/0
no shutdown
ip address 192.168.66.4 255.255.255.0
exit
router rip
version 2
network 192.168.55.97
network 192.168.66.4
no auto-summary
exit
exit
en
conf t
int f0/0
no shutdown
ip address 192.168.66.1 255.255.255.0
exit
int f0/1
no shutdown
ip address 192.168.88.1 255.255.255.0
exit
router rip
version 2
network 192.168.66.1
network 192.168.88.1
no auto-summary
exit
exit
en
conf t
int f0/0
no shutdown
ip address 192.168.99.1 255.255.255.0
ip dhcp pool xiao1
network 192.168.99.0 255.255.255.0
default-router 192.168.99.1
exit
ip dhcp excluded-address 192.168.99.1
int f0/1
no shutdown
ip address 192.168.88.2 255.255.255.0
exit
router rip
version 2
network 192.168.99.1
network 192.168.88.2
no auto-summary
exit
exit
en
conf t
hostname RO
int fastEthernet 0/0
ip address 192.168.0.1 255.255.255.0
no shutdown
exit
snmp-server community xiaoxiaoran rw
exit
en
conf t
int vlan1
ip address 192.168.0.2 255.255.255.0
no shutdown
exit
snmp-server community xiaoxiaoran rw
exit
.1.3.6.1.2.1.1.5.0