当前位置:网站首页>MGRE综合实验
MGRE综合实验
2022-08-02 07:18:00 【羊腿大大】

配置需求:
1,R5为ISP,只能进行IP地址配置;其所有地址均配为公有IP地址
2,R1和R5间使用PPP的PAP认证,R5为主认证方;
R2于R5之间使用PPP的chap认证,R5为主认证方;
R3于R5之间使用HDLC封装。
3,R1/R2/R3构建一个MGRE环境,R1为中心站点;R1、R4间为点到点的GRE。
4,整个私有网络基于RIP全网可达
5,所有Pc设置私有IP为源IP,可以访问R5环回。
实验配置:
1.网段分配
AR1-AR4内部地址依次为192.168.1.0/24-192.168.4.0/24
与AR5之间的网段依次为15.0.0.1/24-45.0.0.1/24
因为要配置MGRE和GRE,所以AR1、AR2和AR3之间的虚拟通道ip为192.168.5.0/24
AR1和AR4之间的虚拟通道ip为192.168.6.0/24
配置IP地址
R1:

R2:

R3:

R4:
R5:

在搭建MGRE环境之前要先将公网做通在每台路由器上做缺省指向ISP
[r1]ip route-static 0.0.0.0 0 15.0.0.2
[r2]ip route-static 0.0.0.0 0 25.0.0.2
[r3]ip route-static 0.0.0.0 0 35.0.0.02
[r4]ip route-static 0.0.0.0 0 45.0.0.2
PAP:
AR5作为主认证方提供用户和密码:
[isp]aaa
[isp-aaa]local-user ytdd password cipher 123456
Info: Add a new user.
[isp-aaa]local-user ytdd service-type ppp
开启pap认证:
[isp]int s3/0/0
[isp-Serial3/0/0]ppp authentication-mode pap
AR1找AR5进行认证:
[r1]int s4/0/0
[r1-Serial4/0/0]ppp pap local-user ytdd password cipher 123456
关闭接口进行验证:
[r1-Serial4/0/0]shutdown
Jul 12 2022 01:01:18-08:00 r1 %%01PPP/4/PHYSICALDOWN(l)[0]:On the interface Seri
al4/0/0, PPP link was closed because the status of the physical layer was Down.
Jul 12 2022 01:01:18-08:00 r1 %%01IFNET/4/LINK_STATE(l)[1]:The line protocol PPP
on the interface Serial4/0/0 has entered the DOWN state.
Jul 12 2022 01:01:18-08:00 r1 %%01IFNET/4/LINK_STATE(l)[2]:The line protocol PPP
Jul 12 2022 01:01:18-08:00 r1 %%01IFPDT/4/IF_STATE(l)[3]:Interface Serial4/0/0 h
as turned into DOWN state.
Jul 12 2022 01:01:18-08:00 r1 %%01RM/4/IPV4_DEFT_RT_CHG(l)[4]:IPV4 default Route
is changed. (ChangeType=Delete, InstanceId=0, Protocol=Static, ExitIf=Unknown,
Nexthop=15.0.0.2, Neighbour=0.0.0.0, Preference=1006632960, Label=NULL, Metric=0
[r1-Serial4/0/0]undo shutdown

CHAP:
同上:提供用户和密码
[isp]int s 3/0/1
[isp-Serial3/0/1]ppp authentication-mode chap
AR2找AR5进行认证:
[r2]int s4/0/0
[r2-Serial4/0/0]ppp chap user ytdd
[r2-Serial4/0/0]ppp chap password cipher 123456
验证:

HDLC:

AR5上串口一个up一个down,说明两个接口都需要改成HDLC
[isp-Serial4/0/0]link-protocol hdlc

2.搭建MGRE环境

后续网路因为基于RIP全网可达,所以要开启伪广播
[r1-Tunnel0/0/0]nhrp entry multicast dynamic
创建tunnel隧道
[r2]int t
[r2]int Tunnel 0/0/0
[r2-Tunnel0/0/0]
[r2-Tunnel0/0/0]ip add 192.168.5.2 24
开 gre p2mp
[r2-Tunnel0/0/0]tunnel-protocol gre p2mp
[r2-Tunnel0/0/0]source Serial 4/0/0
进入到100的域中
[r2-Tunnel0/0/0]nhrp network-id 100
进行注册
[r2-Tunnel0/0/0]nhrp entry 192.168.5.1 15.0.0.1 register
AR3:
[r3]
[r3]int t0/0/0
[r3-Tunnel0/0/0]
[r3-Tunnel0/0/0]
[r3-Tunnel0/0/0]ip add 192.168.5.3 24
[r3-Tunnel0/0/0]tunnel-protocol gre p2mp
[r3-Tunnel0/0/0]source Serial 4/0/0
[r3-Tunnel0/0/0]nhrp network-id 100
[r3-Tunnel0/0/0]nhrp entry 192.168.5.1 15.0.0.1 register
3.搭建GRE环境
[r1]int t0/0/1
[r1-Tunnel0/0/1]ip add 192.168.6.1 24
[r1-Tunnel0/0/1]tunnel-protocol gre
出接口:
[r1-Tunnel0/0/1]source 15.0.0.1
目标(真实的物理接口)
[r1-Tunnel0/0/1]description 45.0.0.1
[r4]int t0/0/0
[r4-Tunnel0/0/0]
[r4-Tunnel0/0/0]ip add 192.168.6.2 24
[r4-Tunnel0/0/0]tunnel-protocol gre
[r4-Tunnel0/0/0]source 45.0.0.01
[r4-Tunnel0/0/0]description 15.0.0.01
4.配置RIP在整个私有网段
[r1]rip
[r1-rip-1]v 2
[r1-rip-1]ne
[r1-rip-1]network 192.168.1.0
[r1-rip-1]n
[r1-rip-1]network 192.168.5.0
[r1-rip-1]n
[r1-rip-1]network 192.168.6.0
。。。。。。
检查RIP路由表发现一些路由没得
关闭水平分割:[r1-Tunnel0/0/0]undo rip split-horizon
5.做nat,在四台设备出接口上做nat
[r1]acl 2000
[r1-acl-basic-2000]rule permit source 192.168.0.0 0.0.255.255
[r1-acl-basic-2000]q
[r1]int s4/0/0
[r1-Serial4/0/0]nat outbound 2000
[r2]acl 2000
[r2-acl-basic-2000]rule permit source 192.168.0.0 0.0.255.255
[r2-acl-basic-2000]q
[r2]int s4/0/0
[r2-Serial4/0/0]nat outbound 2000
[r3]
[r3]acl 2000
[r3-acl-basic-2000]rule permit source 192.168.0.0 0.0.255.255
[r3-acl-basic-2000]q
[r3]int s4/0/0
[r3-Serial4/0/0]nat outbound 2000
[r4]
[r4]acl 2000
[r4-acl-basic-2000]rule permit source 192.168.0.0 0.0.255.255
[r4-acl-basic-2000]q
[r4]int g0/0/0
[r4-GigabitEthernet0/0/0]nat outbound 2000
边栏推荐
- 类型“DropDownList”的控件“ContentPlaceHolder1_ddlDepartment”必须放在具有 runat=server 的窗体标记内。
- Modify apt-get source to domestic mirror source
- HCIP 第十天
- 修改apt-get源为国内镜像源
- MPLS和BGP的综合实验
- 埋点开发流程
- (2022牛客多校五)C-Bit Transmission(思维)
- 2022-2023 十大应用开发趋势
- Xilinx Constraint Study Notes - Timing Constraints
- Metasploit (MSF) Basic Super Detailed Edition
猜你喜欢

(2022 Niu Ke Duo School 5) D-Birds in the tree (tree DP)

Mysql报错2003 解决办法 Can‘t connect to MySQL server on ‘localhost‘ (10061)

MySQL-锁机制

FormData upload binary file, object, object array

FormData上传二进制文件、对象、对象数组

Neural network

regular expression

正则表达式

Mysql error 2003 solution Can 't connect to Mysql server on' localhost '(10061).

研发创新编码器霍尔板,引领企业高质量发展
随机推荐
主流定时任务解决方案全横评
59: Chapter 5: Develop admin management services: 12: MongoDB usage scenarios; (non-core data, non-core data with a relatively large amount of data, small private files such as face photos;)
【Unity3D】初学加密技巧(反破解)
OC-错误提示
2022-2023 十大应用开发趋势
Modify apt-get source to domestic mirror source
DeadLock的可视化分析
如何保护智能家居不受黑客攻击
停止精神内耗 每日分享
View zombie processes
Chain Of Responsibility
有点奇怪!访问目的网址,主机能容器却不行
MySQL-慢查询日志
2022年防止网络攻击的15个网络安全实践,你学会了吗?
OC-范畴
2022年数据泄露平均成本高达435万美元,创历史新高!
Buried development process
OC-NSDictionary
Transimpedance amplifier
WebForm DropDownList分别绑定年月