robin6621 发表于 2017-12-5 09:40:20

H3C_PPPOE配置模板 V5 or V7

--------------pppoe拨号V7模板-------------------------------



# 配置拨号访问组1以及对应的拨号访问控制条件。

<RouterA> system-view

dialer-group 1 rule ip permit          # 在Dialer1接口上使能共享DDR。

interface dialer 1

dialer bundle enable      

dialer-group 1                               # 将Dialer1接口与拨号访问组1关联。

ip address ppp-negotiate               # 配置Dialer1接口通过协商获取IP地址。

dialer timer idle 0                         # 配置PPPoE Client工作在永久在线模式。

ppp ipcp dns request               # 配置从对端请求DNS 

ppp ipcp dns admit-any            # 配置接受任何DNS

dialer timer autodial 1   

ppp chap password cipher k3t8y6r3??? ?   # 配置本地被Router B以CHAP方式认证时Router A发送的CHAP用户名和密码。   

ppp chap user 500000016949 ????????      #如果您无法配置那么将cipher改为simple

ppp pap local-user 500000016949 password simple k3t8y6r3   #这两种方式最好都写上

quit

interface G0/0            # 配置PPPoE会话。

pppoe-client dial-bundle-number 1

quit



interface G0/1                     # 配置局域网接口的IP地址。

ip address 192.168.1.1 255.255.255.0

quit

ip route-static 0.0.0.0 0 dialer 1               # 配置缺省路由。

配置完成之后要在相应的拨号口上开启NAT转换,才能正常上网,如下

acl advanced 3000?? -----------如果无法配置此条,就将命令修改为acl number

rule 0 permit ip source 192.168.1.0 0.0.0.255??? ---------如果内网还有其他网段,就再自行添加

quit

interface dialer 1????????? -----------------在拨号口应用nat地址转换

?nat outbound 3000

quit

4、将内网口ip地址

interface GigabitEthernet 0/2

ip add 192.168.1.1 255.255.255.0

dhcp select server //设置dns

5、配置DHCP服务器

dhcp enable

dhcp server ip-pool 1

network 192.168.1.0 mask 255.255.255.0

dns-list 192.168.1.1

gateway-list 192.168.1.1

quit



--------------pppoe拨号V5模板---------------------------------


          dialer-rule 1 ip permit               //创建dialer-rule 1 ;

      interface Dialer 1                     //进入Dialer 1 接口模式;

   link-protocol ppp                //封装PPP
ppp chap user DianXin         

//ADSL拨号的用户名,由运营商提供;

ppp chap password cipher DianXin2012

//ADSL 拨号的密码,由运营商提供;

ppp pap local-user Rayda password cipher DianXin2012

tcp mss 1024                  //Tcp的最大分片单元;

ip address ppp-negotiate      //IP 地址的获取方式;

dialer user DianXin

dialer-group 1               //引用dialer-rule 1

dialer bundle 1

nat outbound

quit

interface Ethernet2/0

pppoe-client dialer-bundle-number 1

//将Dialer 1 绑定到Ethernet2/0接口上面;

quit

ip route-static 0.0.0.0 0.0.0.0 Dialer 1 preference 60

//配置默认路由;

save




页: [1]
查看完整版本: H3C_PPPOE配置模板 V5 or V7