一、实验拓扑
二、实验要求
1、R5为ISP,只能进行IP地址配置,其所有地址均配为公有IP地址;
2、R1和Rs间使用PPP的PAP认证,Rs为主认证方;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、配置IP地址
2、私网通,公网通---配置静态路由协议,测试公网通
3、配置R1-R5的ppp的pap认证,R5为主认证方
4、R2与R5之间使用ppp的CHAP认证,R5为主认证方;
5、R3与R5之间使用HDLC封装;
6、配置GRE
7、配置MGRE
(1)配置NHRP协议,构建公共隧道
(2)配置NHRP 协议使分支机构将自己的隧道地址和公网地址发给总部
(3)配置RIPV2,传递两端的私网路由,实现总部和分部,分部和分部之间的互通
(4)在中心站点上开启伪广播功能
(5)关闭中心和分支站点的RIP的水平分割机制
四、实验步骤与配置
1、IP配置
(R1)int g0/0/0
ip add 192.168.1.1 24
int s4/0/0
ip add 15.1.1.1 24
(R2)int g0/0/0
ip add 192.168.2.2 24
int s4/0/0
ip add 25.1.1.2 24
(R3)int s4/0/0
ip add 35.1.1.3 24
int g0/0/0
ip add 192.168.3.3 24
(R4)int g0/0/0
ip add 192.168.4.4 24
int g0/0/1
ip add 192.168.4.4 24
(LSP)[lsp]interface LoopBack 0
[lsp-LoopBack0]ip add 5.5.5.5 24
[lsp-LoopBack0]q
[lsp]int s3/0/1
[lsp-Serial3/0/1]ip add 25.1.1.5 24
[lsp-Serial3/0/1]int s4/0/0
[lsp-Serial4/0/0]ip add 35.1.1.5 24
[lsp-Serial4/0/0]int s4/0/1
[lsp-Serial4/0/1]ip add 15.1.1.5 24
[lsp-Serial4/0/1]int g0/0/0
[lsp-GigabitEthernet0/0/0]ip add 45.1.1.5 24
2、静态路由配置
[r1]ip route-static 0.0.0.0 0 15.1.1.5
[r2]ip route-static 0.0.0.0 0 25.1.1.5
[r3]ip route-static 0.0.0.0 0 35.1.1.5
[r4]ip route-static 0.0.0.0 0 45.1.1.5
3、PPP认证+HDLC
r1-r5
r2-r5
r3-r5
4、MGRE+GRE隧道配置
GRE
MGRE
5、路由协议
访问R5环回
五、实验排错
1. 接口与IP
- 物理Down:检查连线、执行 undo shutdown
- 协议Down:核对两端IP同网段、链路封装一致
- 排查命令: display ip interface brief
2. PPP认证(PAP/CHAP)
- 协议Down:两端均配置 link-protocol ppp
- 认证失败:核对用户名/密码一致,确认R5为主认证方
- 排查命令: display interface Serial x/x/x
3. HDLC封装(AR4↔R5)
- 协议Down:两端GE0/0/0均配置 link-protocol hdlc ,封装必须统一
4. 静态路由(公网互通)
- 公网不通:检查R5回程路由、AR1-AR4默认路由下一跳指向R5
- 排查命令: display ip routing-table
5. GRE隧道(核心)
- 隧道UP/协议Down(高频):
(1). 两端必须配置 tunnel-protocol gre
(2). 源目IP严格对称
(3). 隧道IP同网段
- 排查命令: display interface Tunnel 0/0/0
6. NHRP协议
- 注册失败:两端 nhrp network-id 一致,核对总部/分部映射命令
- RIP不通:开启 nhrp multicast enable
7. RIP协议
- 私网不通:宣告私网+隧道网段、关闭自动汇总、隧道口关闭水平分割
- 排查命令: display rip 1 route