5.2路由器和交换机的配置 (1)路由器的配置 interface FastEthernet0/0
ip address 192.168.80.2 255.255.255.0 ip nat inside duplex auto speed auto !
interface FastEthernet0/1 no ip address duplex auto speed auto shutdown !
interface Serial0/0
ip address 192.168.90.1 255.255.255.0 ip nat outside !
router ospf 100
log-adjacency-changes
network 192.168.80.0 0.0.0.255 area 0 !
ip nat inside source list 10 interface Serial0/0 overload ip classless
ip route 0.0.0.0 0.0.0.0 Serial0/0 ip route 0.0.0.0 0.0.0.0 192.168.90.2 ! ! ! ! ! ! !
line con 0 line vty 0 4 login ! ! ! end
(2)核心层交换机的配置 interface FastEthernet0/1 no switchport
ip address 192.168.70.2 255.255.255.0 duplex auto speed auto !
interface FastEthernet0/2 no switchport
ip address 192.168.60.2 255.255.255.0 duplex auto speed auto !
interface FastEthernet0/3 no switchport
ip address 192.168.50.2 255.255.255.0 duplex auto speed auto !
interface FastEthernet0/4 !
interface FastEthernet0/5 !
interface FastEthernet0/6 !
interface FastEthernet0/7 !
interface FastEthernet0/8 !
interface FastEthernet0/9 !
interface FastEthernet0/10 !
interface FastEthernet0/11 !
interface FastEthernet0/12 !
interface FastEthernet0/13 !
interface FastEthernet0/14