基于PPPoE上网模式下配置IPv6,配置Dialer接口用于PPP协商获取IPv6地址,建立PPPoE会话,以及配置DHCPv6 PD客户端功能。

1. 配置Dialer接口

[Huawei] system-view
[Huawei] interface dialer 1
[Huawei-Dialer1] dialer user arweb
[Huawei-Dialer1] dialer bundle 1
[Huawei-Dialer1] ppp chap user t53201758****     ##运营商ISP提供PPPOE宽带用户名
[Huawei-Dialer1] ppp chap password cipher huawei123     ##运营商ISP提供PPPoE宽带密码
[Huawei-Dialer1] ip address ppp-negotiate
[Huawei-Dialer1] quit

2. 建立PPPoE会话

[Huawei] interface gigabitethernet 2/0/4
[Huawei-GigabitEthernet2/0/4] pppoe-client dial-bundle-number 1
[Huawei-GigabitEthernet2/0/4] quit

3. 配置DHCPv6 PD客户端功能

<Huawei>system-view 
Enter system view, return user view with Ctrl+Z.
[Huawei]ipv6
[Huawei]interface Dialer 1
[Huawei-Dialer1]ipv6 enable 
[Huawei-Dialer1]ipv6 address auto link-local 
[Huawei-Dialer1]dhcpv6 client pd myper     ## myper为自定义名称,注意与Vlanif1一致

检查配置,确保无误

[Huawei-Dialer1]dis this
[V200R010C10SPC700]
#
interface Dialer1
 link-protocol ppp
 ppp chap user t5320175*****
 ppp chap password cipher huawei123
 ppp pap local-user t53201758**** password cipher ************
 ppp ipcp dns admit-any
 ppp ipcp dns request
 ipv6 enable
 tcp adjust-mss 1200
 ip address ppp-negotiate
 dialer user arweb
 dialer bundle 1
 dialer number 1 autodial
 dialer-group 1
 ipv6 address auto link-local
 ipv6 address auto global default
 undo ipv6 nd ra halt
 nat outbound 2999 
 dhcpv6 client pd myper
#
return
[Huawei-Dialer1]quit

4. 配置局域网接口以路由通告形式向主机分配地址前缀

[Huawei]interface Vlanif 1
[Huawei-Vlanif1]ipv6 enable 
[Huawei-Vlanif1]ipv6 address auto link-local 
[Huawei-Vlanif1]undo ipv6 nd ra halt
[Huawei-Vlanif1]ipv6 nd autoconfig managed-address-flag 
[Huawei-Vlanif1]ipv6 nd autoconfig other-flag 
[Huawei-Vlanif1]ipv6 address myper ::1:0:0:0:1/64     ## myper为自定义名称,注意与Dialer1一致
[Huawei-Vlanif1]quit
[Huawei]display dhcpv6 client 
Dialer1 is in DHCPv6-PD client mode.
DHCPv6-PD client is in BOUND state.
Preferred server DUID   : 000100067B1633FB745AAAC3F809
  Reachable via address : FE80::765A:AAFF:FEC3:F809
IA PD IA ID 0x00000181 T1 86400 T2 138240
  Prefix name  : myper
  Obtained     : 2025-03-18 09:14:27
  Renews       : 2025-03-19 09:14:27
  Rebinds      : 2025-03-19 23:38:27
  Prefix       : 240E:346:F65:9500::/56
文章作者: Lukey
本文链接:
版权声明: 本站所有文章除特别声明外,均采用 CC BY-NC-SA 4.0 许可协议。转载请注明来自 三多运维
运维归档 VLAN
喜欢就支持一下吧