Page MenuHomeVyOS Platform

router-advert: support RDNSS lifetime option
Closed, ResolvedPublicFEATURE REQUEST

Description

Summary

In order to avoid the frequent expiry of the RDNSS options on links with a relatively high rate of packet loss, it is very effective to manually change the RDNSS lifetime option to a larger value.

However, vyos currently does not support changing the RDNSS lifetime option.
In the original radvd, the RDNSS lifetime parameter can be set as shown below. The same should be possible in vyos.

interface eth1 {
    RDNSS 2001:db8:100::6464 {
        AdvRDNSSLifetime 7200;
    };
}

This feature request discusses the issues to be considered and how to implement the RDNSS lifetime option into vyos. I would like to receive feedback from the community.

I can implement the changes required for this feature. This is my first contribution to vyos, and I sincerely hope that this feature will be adopted into mainstream vyos.

Comparison of Implementation Approaches

There are two possible approaches to implementing this functionality in the vyos cli.

Approach A: Specify RDNSS lifetime as a common parameter

This approach is compatible with the current implementation of rendering methods (e.g. data/templates/router-advert/radvd.conf.tmpl).

set service router-advert interface eth1 name-server '2001:db8:100::6464'
set service router-advert interface eth1 name-server '2001:db8:200::6464'
set service router-advert interface eth1 name-server lifetime 1800

In this approach, radvd.conf is expected to render as follows.

interface eth1 {
    RDNSS 2001:db8:100::6464 2001:db8:200::6464 {
        AdvRDNSSLifetime 1800;
    };
}

Approach B: Specify lifetime for each DNS server

RFC8106 recommends the use of multiple RDNSS options in a single RA if different lifetimes are to be specified for different DNS servers.

The RDNSS option contains one or more IPv6 addresses of RDNSSes. All of the addresses share the same Lifetime value. If it is desirable to have different Lifetime values, multiple RDNSS options can be used.

In other words, it is desirable to be able to set the lifetime for each DNS server as shown below.

set service router-advert interface eth1 name-server '2001:db8:100::6464' lifetime 1800
set service router-advert interface eth1 name-server '2001:db8:200::6464' lifetime 3600

In this approach, radvd.conf is expected to render as follows.

interface eth1 {
    RDNSS 2001:db8:100::6464 {
        AdvRDNSSLifetime 1800;
    };
    RDNSS 22001:db8:200::6464 {
        AdvRDNSSLifetime 3600;
    };
}

Concerns

If you need to specify a different lifetime for each DNS server, you can send multiple RDNSS options to one RA by using the following configuration in radvd.conf.

interface eth1 {
    RDNSS 2001:db8:100::6464 {
        AdvRDNSSLifetime 7200;
    };
    RDNSS 22001:db8:200::6464 {
        AdvRDNSSLifetime 3600;
    };
}

However, depending on the implementation of the client device, the second and subsequent RDNSS options may be ignored.
In fact, on my devices (macOS 11, iOS 15), the second and later RDNSS options are ignored, and I could not install the alternative DNS server information to my device.

Approach B is superior in terms of configuration flexibility, but Approach A should be chosen for interoperability with client devices.
Of course, it is important to report and contribute to the various client OS development communities, but it takes a very long time.
I think it is better to adopt Approach A for realistic improvement of vyos functionality.

References

Details

Difficulty level
Easy (less than an hour)
Version
-
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Perfectly compatible
Issue type
Improvement (missing useful functionality)

Event Timeline

yas-nyan renamed this task from router-advert: support advertising specific routes to router-advert: support RDNSS lifettime option.Jun 21 2022, 1:37 PM
yas-nyan renamed this task from router-advert: support RDNSS lifettime option to router-advert: support RDNSS lifetime option.
c-po triaged this task as Normal priority.
c-po changed Difficulty level from Unknown (require assessment) to Easy (less than an hour).
c-po changed Is it a breaking change? from Unspecified (possibly destroys the router) to Perfectly compatible.

Implemented as: set service router-advert interface eth0 name-server-lifetime <value> which will be option A