当前位置: 首页 > news >正文

PPPOE实验

一、实验拓扑

  • 实验要求

1、如图,私网内部配置为 192.168.1.0/24 网段,R2 上配置 Loopback0 口模拟互联网地址

2、配置 R2 为 PPPoE Server,为 R1 提供 PPPoE 拨号服务,并为 R1 自动分配公网 IP 地址

3、配置 R1 为 PPPoE Client,自动进行拨号,永久在线,并能够自动获得公网 IP 地址

4、在 R1 上配置默认路由,并配置 EASY IP,使 PC1可以访问互联网

  • 实验思路

1、IP地址配置

2、配置 R2 为 PPPoE Server,为R1提供PPPoE 拨号服务,并为 R1 自动分配公网IP地址

3、配置 R1 为 PPPoE Client,自动进行拨号,永久在线,并能够自动获得公网 IP 地址

4、建立PPPoE会话

5、配置NAT,使内部用户可以上网

6、配置到PPPoE Server的静态路由

7、测试

  • 实验配置

1、IP地址配置

[PPPoE Client]int g0/0/0
[PPPoE Client-GigabitEthernet0/0/0]ip add 192.168.1.254 24

[PPPoE Server]int l0
[PPPoE Server-LoopBack0]ip add 202.1.1.1 32

2、配置 R2 为 PPPoE Server,为 R1 提供 PPPoE 拨号服务,并为 R1 自动分配公网 IP 地址

步骤 1:创建用于拨号验证的用户,服务类型为 PPP

[PPPoE Server-LoopBack0]aaa
[PPPoE Server-aaa]local-user  xsq password  cipher  xsq123
[PPPoE Server-aaa]local-user xsq service-type ppp

步骤 2:创建并配置VT(Virtual-Template,虚拟模版)----提供逻辑上点到点的连接,在虚拟模版上配置公网接口的IP

[PPPoE Server]interface Virtual-Template 1
[PPPoE Server-Virtual-Template1]ppp authentication-mode  chap  //配置客户端的PPP验证方式
[PPPoE Server-Virtual-Template1]ip add 100.1.1.2 24   //配置Server方作为认证方,使用chap认证方式
[PPPoE Server-Virtual-Template1]remote address  pool aa   //调用地址池,为Client分配公网地址

步骤 3:创建用于动态分配给客户端的 IP 地址池

[PPPoE Server]ip pool aa
[PPPoE Server-ip-pool-aa]network 100.1.1.0 mask 24
[PPPoE Server-ip-pool-aa]gateway-list  100.1.1.2

步骤 4:在以太网接口启动PPPoE Server功能

[PPPoE Server]int g0/0/0
[PPPoE Server-GigabitEthernet0/0/0]pppoe-server bind  virtual-template  1

3、配置 R1 为 PPPoE Client,并能够自动获得公网 IP 地址

步骤 1:创建虚拟拨号接口,并配置验证,地址协商等相关参数

[PPPoE Client]int Dialer 1
[PPPoE Client-Dialer1]dialer user  xsq        //指定对端用户名,必须与对端配置的PPP用户名一致
[PPPoE Client-Dialer1]dialer bundle  1   //设定拨号程序捆绑包,出发本机PPPOE的程序
[PPPoE Client-Dialer1]ppp chap  user  xsq
[PPPoE Client-Dialer1]ppp chap  password  cipher  xsq123   //配置本地作为被认证方,以及账号密码信息
[PPPoE Client-Dialer1]ip address  ppp-negotiate   //配置由对端分配IP地址
[PPPoE Client-Dialer1]dialer timer  idle  0   //配置拨号永久在线----模拟器配置影响实验效果

4、建立PPPoE会话

[PPPoE Client]int g0/0/1
[PPPoE Client-GigabitEthernet0/0/1]pppoe-client dial-bundle-number 1  //指定PPPoE会话所对应的Dialer bundle

5、配置NAT,使内部用户可以上网

[PPPoE Client]acl 2000
[PPPoE Client-acl-basic-2000]rule  permit  source  192.168.1.0 0.0.0.255
[PPPoE Client-acl-basic-2000]q
[PPPoE Client]interface Dialer 1
[PPPoE Client-Dialer1]nat outbound  2000

6、配置到PPPoE Server的静态路由

[PPPoE Client]ip route-static 0.0.0.0 0 Dialer 1

7、测试:

在 R1 上检查,发现已经拨号成功,并获得了公网 IP 地址,PC1 也可以访问互联网

客户端查看会话信息

服务器短查看会话信息

http://www.dtcms.com/a/572711.html

相关文章:

  • 【LeetCode 经典题解】:队列与栈的双向模拟——从原理到代码详解
  • 学习笔记5
  • 多线程 忙等待和线程等待的区别
  • 网站建设运维合同汽车城网站建设方案
  • 建立网站需要什么设备网站制作对公司的作用
  • C++类与对象:从入门到精通
  • UniApp 全局通知功能实现
  • uni-app开发安卓app时控制屏幕常亮不息屏
  • uniapp 小程序引入 uview plus 框架,获得精美的UI框架
  • 在被窝里使用笔记本电脑,容易损坏键盘?
  • Unix Domain Socket:构建高效本地进程间通信的完整指南
  • 如何创建“国学助手”GPT?
  • AWS Elastic Beanstalk中安装tesseract5.3.4版本
  • 实战:用Elasticsearch构建爬虫数据搜索引擎
  • 微网站建设及微信公众号长春自助建站软件
  • 修改图片网站卖房app十大排行榜
  • python-爬虫之beautifulsoup
  • Ubuntu 24.04 安装 FreeSWITCH 完整教程
  • LeetCode(python)——49.字母异位词分组
  • Redis 性能优化与故障排查指南
  • 24.java openCV4.x 入门-Imgproc之轮廓凸包与凹陷检测(形状识别)
  • IDEA 插件推荐
  • 虚拟 DOM(Virtual DOM)的工作原理及其性能优化机制
  • git详细使用教程
  • 北京工程工程建设交易信息网站和城乡建设部网站
  • soular零基础学习,如何通过工作台聚合TikLab所有工具链
  • 建立企业网站电商网站建设开题报告
  • css font-size 的妙用
  • Jenkins安装部署
  • 阿里云 CDN + 静态资源(图片 / JS/CSS)缓存优化