路由课程设计

配置vlan及IP,access和trunk接口
Border
en
conf t
int g0/0
ip add 10.10.0.10 255.255.255.252
no shu
int g0/1
ip add 10.10.0.6 255.255.255.252
no shu
int s0/0/0
ip add 202.192.99.1 255.255.255.252
no shu
int s0/0/1
ip add 10.10.0.1 255.255.255.252
no shu


Core1
en
conf t
ip routing
int g1/0/1
no sw
ip add 10.10.0.17 255.255.255.252
no shu
int g1/0/2
no sw
ip add 10.10.0.21 255.255.255.252
no shu
int g1/0/3
no sw
ip add 10.10.0.25 255.255.255.252
no shu
int g1/0/24
no sw
ip add 10.10.0.9 255.255.255.252
no shu
int range g1/0/22-23
sw tr enca dot
sw mo tr


Core2
en
conf t
ip routing
int g1/0/1
no sw
ip add 10.10.0.29 255.255.255.252
no shu
int g1/0/2
no sw
ip add 10.10.0.33 255.255.255.252
no shu
int g1/0/3
no sw
ip add 10.10.0.37 255.255.255.252
no shu
int g1/0/24
no sw
ip add 10.10.0.5 255.255.255.252
no shu
int range g1/0/22-23
sw tr enca dot
sw mo tr


F1MS
en
conf t
ip routing
vlan 101
int g1/0/3
no sw
ip add 10.10.10.1 255.255.255.0
no shu
int g1/0/23
no sw
ip add 10.10.0.30 255.255.255.252
no shu
int g1/0/24
no sw
ip add 10.10.0.18 255.255.255.252
no shu
int vlan 101
ip add 10.10.11.1 255.255.255.0
no shu
int range g1/0/1-2
sw mo ac
sw ac vlan 101


F2MS
en
conf t
ip routing
vlan 201
int g1/0/23
no sw
ip add 10.10.0.34 255.255.255.252
no shu
int g1/0/24
no sw
ip add 10.10.0.22 255.255.255.252
no shu
int vlan 201
ip add 10.10.21.1 255.255.255.0
no shu
int range g1/0/1-2
sw mo ac
sw ac vlan 201

F3MS
en
conf t
ip routing
vlan 301
vlan 302
vlan 303
vlan 304
int g1/0/23
no sw
ip add 10.10.0.38 255.255.255.252
no shu
int g1/0/24
no sw
ip add 10.10.0.26 255.255.255.252
no shu
int vlan 301
ip add 10.10.31.1 255.255.255.0
no shu
int vlan 302
ip add 10.10.32.1 255.255.255.0
no shu
int vlan 303
ip add 10.10.33.1 255.255.255.0
no shu
int vlan 304
ip add 10.10.34.1 255.255.255.0
no shu
int g1/0/1
sw mo ac
sw ac vlan 301
int g1/0/2
sw mo ac
sw ac vlan 302
int g1/0/3
sw mo ac
sw ac vlan 303
int g1/0/4
sw mo ac
sw ac vlan 304


F1P1
en
conf t
vlan 101
int vlan 101
ip add 10.10.11.2 255.255.255.0
no shu
int range f0/1-20
sw mo ac
sw ac vlan 101
int g0/1
sw mo ac
sw ac vlan 101

F1P2
en
conf t
vlan 101
int vlan 101
ip add 10.10.11.3 255.255.255.0
no shu
int range f0/1-20
sw mo ac
sw ac vlan 101
int g0/1
sw mo ac
sw ac vlan 101


F2P1
en
conf t
vlan 201
int vlan 201
ip add 10.10.21.2 255.255.255.0
no shu
int range f0/1-20
sw mo ac
sw ac vlan 201
int g0/1
sw mo ac
sw ac vlan 201


F2P2
en
conf t
vlan 201
int vlan 201
ip add 10.10.21.3 255.255.255.0
no shu
int range f0/1-20
sw mo ac
sw ac vlan 201
int g0/1
sw mo ac
sw ac vlan 201

F3P1
en
conf t
vlan 301
int vlan 301
ip add 10.10.31.2 255.255.255.0
no shu
int range f0/1-20
sw mo ac
sw ac vlan 301
int g0/1
sw mo ac
sw ac vlan 301


F3P2
en
conf t
vlan 302
int vlan 302
ip add 10.10.32.2 255.255.255.0
no shu
int range f0/1-20
sw mo ac
sw ac vlan 302
int g0/1
sw mo ac
sw ac vlan 302

F3P3
en
conf t
vlan 303
int vlan 303
ip add 10.10.33.2 255.255.255.0
no shu
int range f0/1-20
sw mo ac
sw ac vlan 303
int g0/1
sw mo ac
sw ac vlan 303

F3P4
en
conf t
vlan 304
int vlan 304
ip add 10.10.34.2 255.255.255.0
no shu
int range f0/1-20
sw mo ac
sw ac vlan 304
int g0/1
sw mo ac
sw ac vlan 304


FRT
en
conf t
int s0/0/0
ip add 10.10.0.2 255.255.255.252
no shu
int g0/0
ip add 10.10.41.1 255.255.255.0
no shu


ISP
en
conf t
int s0/0/0
ip add 202.192.99.2 255.255.255.252
no shu
int g0/1
ip add 202.194.64.1 255.255.255.0
no shu

配置OSPF
Border
en
conf t
ip route 0.0.0.0 0.0.0.0 s0/0/0
route ospf 1
route 1.1.1.1
net 10.10.0.8 0.0.0.3 area 0
net 202.192.99.0 0.0.0.3 area 0
net 10.0.0.4 0.0.0.3 area 0
net 10.10.0.0 0.0.0.3 area 0
default o


Core1
en
conf t
route ospf 1
route 2.2.2.1
net 10.10.0.8 0.0.0.3 area 0
net 10.10.0.16 0.0.0.3 area 0
net 10.10.0.20 0.0.0.3 area 0
net 10.10.0.24 0.0.0.3 area 0

Core2
en
conf t
route ospf 1
route 2.2.2.2
net 10.10.0.4 0.0.0.3 area 0
net 10.10.0.28 0.0.0.3 area 0
net 10.10.0.32 0.0.0.3 area 0
net 10.10.0.36 0.0.0.3 area 0

F1MS
en
conf t
route ospf 1
route 3.3.3.1
net 10.10.0.16 0.0.0.3 area 0
net 10.10.0.28 0.0.0.3 area 0
net 10.10.10.0 0.0.0.255 area 0
net 10.10.11.0 0.0.0.255 area 0

F2MS
en
conf t
route ospf 1
route 3.3.3.2
net 10.10.0.20 0.0.0.3 area 0
net 10.10.0.32 0.0.0.3 area 0
net 10.10.21.0 0.0.0.255 area 0


F3MS
en
conf t
route ospf 1
route 3.3.3.3
net 10.10.0.24 0.0.0.3 area 0
net 10.10.0.36 0.0.0.3 area 0
net 10.10.31.0 0.0.0.255 area 0
net 10.10.32.0 0.0.0.255 area 0
net 10.10.33.0 0.0.0.255 area 0
net 10.10.34.0 0.0.0.255 area 0

FRT
en
conf t
route ospf 1
route 5.5.5.1
net 10.10.0.0 0.0.0.3 area 0
net 10.10.41.0 0.0.0.255 area 0


配置NAT
Border
en
conf t
ip nat inside source static 10.10.10.11 202.192.99.3
ip nat pool HAHA 202.192.99.10 202.192.99.60 netmask 255.255.255.192
access-list 1 permit any
ip nat inside source list 1 pool HAHA overload
int s0/0/0
ip nat outside
int g0/0
ip nat inside
int s0/0/1
ip nat inside

配置DHCP
FRT
en
conf t
ip dhcp excluded-add  10.10.41.1 10.10.41.9
ip dhcp pool F4
net 10.10.41.0 255.255.255.0
default-route 10.10.41.1
domain-name ujn.edu
dns- 10.10.10.12


DHCP中继
F1MS
en
conf t
int vlan 101
ip help 10.10.10.11


F2MS
en
conf t
int vlan 201
ip help 10.10.10.11


F3MS
en
conf t
int vlan 301
ip help 10.10.10.11
int vlan 302
ip help 10.10.10.11
int vlan 303
ip help 10.10.10.11
int vlan 304
ip help 10.10.10.11


配置以太链路聚合
Core1
en
conf t
int range g1/0/22-23
channel-pro pagp
channel-gr 1 mo desirable
Core2
en
conf t
int range g1/0/22-23
channel-pro pagp
channel-gr 1 mo desirable


配置远程控制ACL-telnet-ssh

可路由设备
en
conf t
access-list 99 permit 10.10.32.0 0.0.0.255
enable password enable
line vty 0 15
password vty
access-class 99 in

不可路由设备
F1P1||F1P2
en
conf t
ip default-gateway 10.10.11.1
access-list 99 permit 10.10.32.0 0.0.0.255
enable password enable
line vty 0 15
password vty
access-class 99 in

F2P1||F2P2
en
conf t
ip default-gateway 10.10.21.1
access-list 99 permit 10.10.32.0 0.0.0.255
enable password enable
line vty 0 15
password vty
access-class 99 in

F3P1
en
conf t
ip default-gateway 10.10.31.1
access-list 99 permit 10.10.32.0 0.0.0.255
enable password enable
line vty 0 15
password vty
access-class 99 in

F3P2
en
conf t
ip default-gateway 10.10.32.1
access-list 99 permit 10.10.32.0 0.0.0.255
enable password enable
line vty 0 15
password vty
access-class 99 in

F3P3
en
conf t
ip default-gateway 10.10.33.1
access-list 99 permit 10.10.32.0 0.0.0.255
enable password enable
line vty 0 15
password vty
access-class 99 in

F3P4
en
conf t
ip default-gateway 10.10.34.1
access-list 99 permit 10.10.32.0 0.0.0.255
enable password enable
line vty 0 15
password vty
access-class 99 in

FSW
en
conf t
ip default-gateway 10.10.41.1
access-list 99 permit 10.10.32.0 0.0.0.255
enable password enable
line vty 0 15
password vty
access-class 99 in


配置ppp协议
Border
en
conf t
hostname border
username fr pass ppp
int s0/0/1
encap ppp
ppp authen chap

FR
en
conf t
hostname fr
username border pass ppp
int s0/0/0
encap ppp
ppp authen chap


配置路由身份认证(端口认证)
//**************参考指令************
en
conf t
int s0/0/0
ip ospf authentication
ip ospf authentication-key ospf
//********************************
F1MS||F2MS||F3MS
en
conf t
int g1/0/23
ip ospf authentication
ip ospf authentication-key ospf
int g1/0/24
ip ospf authentication
ip ospf authentication-key ospf

Core1||Core2
en
conf t
int g1/0/1
ip ospf authentication
ip ospf authentication-key ospf
int g1/0/2
ip ospf authentication
ip ospf authentication-key ospf
int g1/0/3
ip ospf authentication
ip ospf authentication-key ospf
int g1/0/24
ip ospf authentication
ip ospf authentication-key ospf


FRT
en
conf t
int s0/0/0
ip ospf authentication
ip ospf authentication-key ospf

Border
en
conf t
int s0/0/1
ip ospf authentication
ip ospf authentication-key ospf
int s0/0/0
ip ospf authentication
ip ospf authentication-key ospf
int g0/0
ip ospf authentication
ip ospf authentication-key ospf
int g0/1
ip ospf authentication
ip ospf authentication-key ospf


禁止驻外办事处访问总部内网,允许访问总部www服务和外网
创建ACL
access-list 110 permit ip host 10.10.41.2 10.10.32.0 0.0.0.255
access-list 110 permit tcp 10.10.41.0 0.0.0.255 10.10.10.0 0.0.0.255 eq 80
access-list 110 permit tcp 10.10.41.0 0.0.0.255 10.10.10.0 0.0.0.255 eq 443
access-list 110 deny ip 10.10.41.0 0.0.0.255 10.10.0.0 0.0.255.255
access-list 110 permit ip any any
应用ACL
int s0/0/1
ip access-group 110 in

SSH远程访问网络设备。

F1P1
en
conf t
host F1P1
username admin pass ssh
ip domain-name ujn.edu.cn
crypto key generate rsa
1024

ip ssh version 2
line vty 0 15
transport input ssh
login

F1P2
en
conf t
host F1P2
username admin pass ssh
ip domain-name ujn.edu.cn
crypto key generate rsa
1024

ip ssh version 2
line vty 0 15
transport input ssh
login

F2P1
en
conf t
host F2P1
username admin pass ssh
ip domain-name ujn.edu.cn
crypto key generate rsa
1024

ip ssh version 2
line vty 0 15
transport input ssh
login

F2P2
en
conf t
host F2P2
username admin pass ssh
ip domain-name ujn.edu.cn
crypto key generate rsa
1024

ip ssh version 2
line vty 0 15
transport input ssh
login

F3P1
en
conf t
host F3P1
username admin pass ssh
ip domain-name ujn.edu.cn
crypto key generate rsa
1024

ip ssh version 2
line vty 0 15
transport input ssh
login

F3P2
en
conf t
host F3P2
username admin pass ssh
ip domain-name ujn.edu.cn
crypto key generate rsa
1024

ip ssh version 2
line vty 0 15
transport input ssh
login


F3P3
en
conf t
host F3P3
username admin pass ssh
ip domain-name ujn.edu.cn
crypto key generate rsa
1024

ip ssh version 2
line vty 0 15
transport input ssh
login

F3P4
en
conf t
host F3P4
username admin pass ssh
ip domain-name ujn.edu.cn
crypto key generate rsa
1024

ip ssh version 2
line vty 0 15
transport input ssh
login

//****可路由设备ssh和密码配置****************
en
conf t
host ***
username admin pass ssh
ip domain-name ujn.edu.cn
crypto key generate rsa
1024
access-list 99 permit 10.10.32.0 0.0.0.255
enable password enable
ip ssh version 2
line vty 0 15
password vty
access-class 99 in
transport input ssh
login
//***************************

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
二、实验要求: 1、 内网为一个企业的内部网络。其中,PC1是总经理机器,PC2是业务部机器, PC3为财务部机器,PC2和PC3分属两个VLAN,PC1可以同时访问财务部和业务部。 2、 二层交换机1和三层交换机1之间实现聚合;二层交换机2和三层交换机1之间实现RSTP。 3、 PC4为FTP服务器,只允许管理人员总经理访问,其他工作人员不允许访问。 4.该内网只有一个合法的上网地址,pc5为外网上的web服务器,作路由使得内外网之间可以通信,并且在Router1上作NAPT,使得只有pc1所在的网段和pc4可以登录外网,且pc4向外网提供ftp服务。 三、实验步骤 二层交换机1的配置: S2126G-1>enable 14 Password: S2126G-1#conf Enter configuration commands, one per line. End with CNTL/Z. S2126G-1(config)# S2126G-1(config)#hostname % Incomplete command. S2126G-1(config)#hostname wde 2008-06-26 17:09:29 @5-CONFIG:Configured from outband wde(config)#vlan 10 2008-06-26 17:09:34 @5-CONFIG:Configured from outband wde(config-vlan)#end 2008-06-26 17:09:38 @5-CONFIG:Configured from outband wde#conf Enter configuration commands, one per line. End with CNTL/Z. wde(config)#interface range fastethernet 0/3-6 2008-06-26 17:10:26 @5-CONFIG:Configured from outband wde(config-if-range)# wde(config-if-range)#switchport access vlan 20 2008-06-26 17:11:02 @5-CONFIG:Configured from outband %Warning : Access VLAN does not exist. Creating vlan 20 wde(config-if-range)#exit 2008-06-26 17:11:08 @5-CONFIG:Configured from outband wde(config)#interface aggregateport 1 2008-06-26 17:15:43 @5-CONFIG:Configured from outband wde(config-if)#switchport mode trunk 2008-06-26 17:16:04 @5-CONFIG:Configured from outband wde(config-if)#exit 2008-06-26 17:16:08 @5-CONFIG:Configured from outband wde(config)#interface range fastethernet 0/1-2 2008-06-26 17:16:48 @5-CONFIG:Configured from outband wde(config-if-range)#port-group 1 2008-06-26 17:17:12 @5-CONFIG:Configured from outband wde(config-if-range)#exit 2008-06-26 17:17:16 @5-CONFIG:Configured from outband wde(config)# Press RETURN to get started!
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值