Page MenuHomeVyOS Platform

'system static-host-mapping' only allows one IP address per hostname, it should allow one IPv4 and one IPv6 simultaneously
Closed, DuplicatePublicENHANCEMENT

Description

The hosts manpage says a single hostname can have just one entry in /etc/hosts:

For each host a single line should be present with the following information:

But this is inacurate as it can have one IPv4 and one IPv6 entry (line). Programs using getaddrinfo(3) will prefer IPv6 by default (can be changed in /etc/gai.conf), others that directly parse the hosts file (pdns-recursor) will use their own methods.

The 'inet' node should be changed to multi, the host_name.py script modified to support multiple 'inet' lines and a check added that allows only one IPv4 and IPv6 address.

Details

Version
-
Is it a breaking change?
Perfectly compatible
Issue type
Feature (new functionality)

Event Timeline

jjakob triaged this task as Wishlist priority.
jjakob created this object in space S1 VyOS Public.
jjakob changed the subtype of this task from "Task" to "Enhancement".
erkin removed a subscriber: Global Notifications.
Viacheslav changed the task status from Open to Needs testing.Oct 25 2021, 7:14 PM
dmbaturin set Issue type to Feature (new functionality).Nov 8 2024, 10:50 AM