Page MenuHomeVyOS Platform

PPPoE server: dual-stack IPv4/IPv6 provisioning with Prefix Delegation not working
Closed, InvalidPublicBUG

Description

From the docs:

https://docs.vyos.io/en/latest/configuration/service/pppoe-server.html#dual-stack-ipv4-ipv6-provisioning-with-prefix-delegation

set service pppoe-server authentication local-users username test password 'test'
set service pppoe-server authentication mode 'local'
set service pppoe-server client-ip-pool start '192.168.0.1'
set service pppoe-server client-ip-pool stop '192.168.0.10'
set service pppoe-server client-ipv6-pool delegate '2001:db8:8003::/48' delegation-prefix '56'
set service pppoe-server client-ipv6-pool prefix '2001:db8:8002::/48' mask '64'
set service pppoe-server name-server '10.1.1.1'
set service pppoe-server name-server '2001:db8:4860::8888'
set service pppoe-server interface 'eth2'
set service pppoe-server gateway-address '10.100.100.1'
[email protected]# run sh pppoe-server sessions
ifname | username |     ip      | ip6 | ip6-dp |    calling-sid    | rate-limit | state  |  uptime  | rx-bytes | tx-bytes
--------+----------+-------------+-----+--------+-------------------+------------+--------+----------+----------+----------
 ppp0   | test     | 192.168.0.6 |     |        | 00:50:56:bf:c5:6d |            | active | 00:02:15 | 230 B    | 204 B

No IPv6 addresses assigned.

The Client side uses:

set interfaces pppoe pppoe0 authentication password 'test'
set interfaces pppoe pppoe0 authentication user 'test'
set interfaces pppoe pppoe0 dhcpv6-options pd 0 interface eth0 address '65535'
set interfaces pppoe pppoe0 dhcpv6-options pd 0 interface eth0 sla-id '0'
set interfaces pppoe pppoe0 dhcpv6-options pd 0 length '56'
set interfaces pppoe pppoe0 ipv6 address autoconf
set interfaces pppoe pppoe0 source-interface 'eth0.202'

Details

Difficulty level
Unknown (require assessment)
Version
1.3.0-rc3
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Unspecified (possibly destroys the router)

Event Timeline

c-po assigned this task to Unknown Object (User).Apr 8 2021, 9:09 PM
c-po created this task.
Unknown Object (User) added a comment.Apr 8 2021, 10:02 PM

It looks like the same nature of this issue https://phabricator.vyos.net/T3393
@c-po , could you try to test fast solution

configure
set system sysctl custom net.ipv6.conf.default.addr_gen_mode value 0
commit

Even when setting above command I have no IPv6 address assigned.

This is on the PPPoE server:

[email protected]# ip -d link show ppp0
7: ppp0: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1492 qdisc pfifo_fast state UNKNOWN mode DEFAULT group default qlen 3
    link/ppp  promiscuity 0 minmtu 0 maxmtu 0
    ppp addrgenmode eui64 numtxqueues 1 numrxqueues 1 gso_max_size 65536 gso_max_segs 65535
[edit]
[email protected]#  cat /proc/sys/net/ipv6/conf/default/addr_gen_mode
0
Unknown Object (User) added a comment.EditedApr 9 2021, 10:23 AM

Thanks. I think the main issue is missing required modules in the generated pppoe server config file

 sudo cat /run/accel-pppd/pppoe.conf 
### generated by accel_pppoe.py ###
[modules]
log_syslog
pppoe
shaper
chap-secrets
ippool
auth_pap
auth_chap_md5
auth_mschap_v1
auth_mschap_v2

Required

ipv6pool
ipv6_nd
ipv6_dhcp

These option enables by the foloowing CLI command::

set service pppoe-server ppp-options ipv6 allow

After these changes, I see all works as expected

vyos@vyos# run show pppoe-server sessions 
ifname | username |     ip      |            ip6           |       ip6-dp       |    calling-sid    | rate-limit | state  |  uptime  | rx-bytes | tx-bytes 
--------+----------+-------------+--------------------------+--------------------+-------------------+------------+--------+----------+----------+----------
 ppp0   | test     | 192.168.0.1 | 2001:db8:8002:0:200::/64 | 2001:db8:8003::/56 | 50:00:00:02:00:00 |            | active | 00:01:00 | 972 B    | 1.3 KiB

From the client side:

vyos@vyos# run show interfaces 
Codes: S - State, L - Link, u - Up, D - Down, A - Admin Down
Interface        IP Address                        S/L  Description
---------        ----------                        ---  -----------
eth0             2001:db8:8003::ffff/64            u/u  
eth1             -                                 u/u  
eth2             -                                 u/u  
eth3             -                                 u/u  
lo               127.0.0.1/8                       u/u  
                 ::1/128                                
pppoe0           192.168.0.1/32                    u/u  
                 2001:db8:8002:0:200::/64
Unknown Object (User) added a comment.Apr 9 2021, 10:43 AM

Add PR with improvements to documentation https://github.com/vyos/vyos-documentation/pull/503