CCNA第五天(某市工商管理局信息网络)

某市工商管理局信息网络

问题描述

项目背景:
1. 市局A终端用户包括90个普通用户,县局B终端用户包括:20个普通用户,县局C终端用包括:40个普通用户,县局D终端用户包括:20个普通用户,县局E终端用户包括:18个普通用户。
2. 服务器提供Web、DNS服务。所有服务器都在市局网络中心。
3. 使用ospf

拓扑结构

这里写图片描述

实验思路

  1. 首先分配IP和网段
  2. 选用二层交换机系统和三层交换机系统混合
  3. 启用ospf

IP及网段配置

电脑IP掩码网关DNS
PC0192.168.2.1255.255.255.0192.168.2.254192.168.10.1
PC1192.168.3.1255.255.255.0192.168.3.254192.168.10.1
PC2192.168.3.1255.255.255.0192.168.3.254192.168.10.1
PC3192.168.4.1255.255.255.0192.168.4.254192.168.10.1
PC4192.168.5.1255.255.255.0192.168.5.254192.168.10.1
PC5192.168.1.1255.255.255.0192.168.1.254192.168.10.1
PC6192.168.1.1255.255.255.0192.168.1.254192.168.10.1
PC7192.168.1.1255.255.255.0192.168.1.254192.168.10.1
PC8192.168.1.1255.255.255.0192.168.1.254192.168.10.1
PC9192.168.1.1255.255.255.0192.168.1.254192.168.10.1
server0192.168.10.1255.255.255.0192.168.10.254192.168.10.1
server1192.168.10.2255.255.255.0192.168.10.254192.168.10.1
路由器F0/0F0/1Se0/0/0
Router4192.168.1.254/24200.200.201.1/30200.200.202.1
Router6192.168.10.254/24200.200.202.2/30

具体配置

三层交换机
Switch(config)#vtp mode server
Device mode already VTP SERVER.
Switch(config)#
Switch(config)#vtp domain aaa
Domain name already set to aaa.
Switch(config)#
Switch(config)#vtp password PASSWORD
Password already set to PASSWORD


Switch(config)#ip routing 


Switch(config)#int f0/5
Switch(config-if)#sw ac vlan 6
Switch(config-if)#int vlan 2
Switch(config-if)#
%LINK-5-CHANGED: Interface Vlan2, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan2, changed state to up

Switch(config-if)#ip add 192.168.2.254 255.255.255.0
Switch(config-if)#int vlan 3
Switch(config-if)#
%LINK-5-CHANGED: Interface Vlan3, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan3, changed state to up

Switch(config-if)#ip add 192.168.3.254 255.255.255.0
Switch(config-if)#int vlan 4
Switch(config-if)#
%LINK-5-CHANGED: Interface Vlan4, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan4, changed state to up

Switch(config-if)#ip add 192.168.4.254 255.255.255.0
Switch(config-if)#int vlan 5
Switch(config-if)#
%LINK-5-CHANGED: Interface Vlan5, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan5, changed state to up

Switch(config-if)#ip add 192.168.5.254 255.255.255.0
Switch(config-if)#int vlan 6
Switch(config-if)#
%LINK-5-CHANGED: Interface Vlan6, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan6, changed state to up

Switch(config-if)#ip add 200.200.202.2 255.255.255.252
Switch(config-if)#^Z
Switch#
%SYS-5-CONFIG_I: Configured from console by console


Switch(config)#int range f0/1-5
Switch(config-if-range)#switchport mode trunk 


%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/1, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan2, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan3, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan4, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan5, changed state to up


Switch(config)#router ospf 1
Switch(config-router)#network 192.168.2.0 0.0.0.255 area 1
Switch(config-router)#network 192.168.3.0 0.0.0.255 area 1
Switch(config-router)#network 192.168.4.0 0.0.0.255 area 1
Switch(config-router)#network 192.168.5.0 0.0.0.255 area 1
Switch(config-router)#network 200.200.202.0 0.0.0.3 area 0
Router4
Router(config)#int f0/0
Router(config-if)#ip add 192.168.1.254 255.255.255.0
Router(config-if)#no sh

Router(config-if)#int s0/0/0
Router(config-if)#ip add 200.200.202.1 255.255.255.252
Router(config-if)#no sh

Router(config-if)#int f0/1
Router(config-if)#ip add 200.200.201.1 255.255.255.252
Router(config-if)#no sh


Router(config)#router ospf 1
Router(config-router)#network 192.168.1.0 0.0.0.255 area 0
Router(config-router)#network 200.200.202.0 0.0.0.3 area 0
Router(config-router)#network 200.200.201.0 0.0.0.3 area 0

Router6
Router(config-if)#int s0/0/0
Router(config-if)#ip add 200.200.202.2 255.255.255.252
Router(config-if)#no sh

Router(config-if)#int f0/1
Router(config-if)#ip add 192.168.10.254 255.255.255.0
Router(config-if)#no sh

Router(config)#router ospf 1
Router(config-router)#network 192.168.10.0 0.0.0.255 area 2
Router(config-router)#network 200.200.202.0 0.0.0.3 area 1
Switch7(举一个例子)Switch6-11相似
Switch(config)#vtp mode client
Setting device to VTP CLIENT mode.
Switch(config)#
Switch(config)#vtp domain aaa
Changing VTP domain name from NULL to aaa
Switch(config)#
Switch(config)#vtp password PASSWORD
Setting device VLAN database password to PASSWORD

Switch(config)#int f0/2
Switch(config-if)#switchport mode trunk 

S
Switch(config-if)#int f0/1
Switch(config-if)#switchport access vlan 2

得到结果

Router>show ip route 
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
       i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
       * - candidate default, U - per-user static route, o - ODR
       P - periodic downloaded static route

Gateway of last resort is not set

C    192.168.1.0/24 is directly connected, FastEthernet0/0
O IA 192.168.2.0/24 [110/2] via 200.200.201.2, 00:00:04, FastEthernet0/1
O IA 192.168.3.0/24 [110/2] via 200.200.201.2, 00:00:04, FastEthernet0/1
O IA 192.168.4.0/24 [110/2] via 200.200.201.2, 00:00:04, FastEthernet0/1
O IA 192.168.5.0/24 [110/2] via 200.200.201.2, 00:00:04, FastEthernet0/1
O IA 192.168.20.0/24 [110/65] via 200.200.202.2, 00:00:40, Serial0/0/0
     200.200.201.0/30 is subnetted, 1 subnets
C       200.200.201.0 is directly connected, FastEthernet0/1
     200.200.202.0/30 is subnetted, 1 subnets
C       200.200.202.0 is directly connected, Serial0/0/0
Router>
Switch>show ip route 
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
       i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
       * - candidate default, U - per-user static route, o - ODR
       P - periodic downloaded static route

Gateway of last resort is not set

O    192.168.1.0/24 [110/2] via 200.200.201.1, 00:00:37, Vlan6
C    192.168.2.0/24 is directly connected, Vlan2
C    192.168.3.0/24 is directly connected, Vlan3
C    192.168.4.0/24 is directly connected, Vlan4
C    192.168.5.0/24 is directly connected, Vlan5
O IA 192.168.20.0/24 [110/66] via 200.200.201.1, 00:00:37, Vlan6
     200.200.201.0/30 is subnetted, 1 subnets
C       200.200.201.0 is directly connected, Vlan6
     200.200.202.0/30 is subnetted, 1 subnets
O       200.200.202.0 [110/65] via 200.200.201.1, 00:00:37, Vlan6
Switch>
Router>show ip ro
Router>show ip route 
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
       i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
       * - candidate default, U - per-user static route, o - ODR
       P - periodic downloaded static route

Gateway of last resort is not set

O    192.168.1.0/24 [110/65] via 200.200.202.1, 00:01:33, Serial0/0/0
O IA 192.168.2.0/24 [110/66] via 200.200.202.1, 00:00:58, Serial0/0/0
O IA 192.168.3.0/24 [110/66] via 200.200.202.1, 00:00:58, Serial0/0/0
O IA 192.168.4.0/24 [110/66] via 200.200.202.1, 00:00:58, Serial0/0/0
O IA 192.168.5.0/24 [110/66] via 200.200.202.1, 00:00:58, Serial0/0/0
C    192.168.20.0/24 is directly connected, FastEthernet0/0
     200.200.201.0/30 is subnetted, 1 subnets
O       200.200.201.0 [110/65] via 200.200.202.1, 00:00:58, Serial0/0/0
     200.200.202.0/30 is subnetted, 1 subnets
C       200.200.202.0 is directly connected, Serial0/0/0
Router>
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值