Red Hat Bugzilla – Bug 874735
[RFE] Network interface collection/facts do not support multiple address per interface
Last modified: 2016-11-03 16:26:23 EDT
Description of problem: in hwprobe.py, the code that gathers network interface information ignores multiple addresses on an interface. At least on rhel6.4, we can gather that information (either get_ipv6_addresses() or the new get_ipv4_addresses()), but we can not express that relation in the schema for facts. ie. on a system with multiple address on eth0, we will show something like: net.interface.eth0.ipv4_address: 10.13.129.193 net.interface.eth0.ipv4_broadcast: 10.13.129.255 Only one address is shown per interface, and that address happens to be the last one collected (and there doesn't seem to be any stable order to that).
need to know who is using these facts, and if changing it, or adding new facts with related info (for example, something like net.interface.eth0.ipv4_net_addrinfo = {'127.0.0.1', '255.255.255.0'}) Is anyone parsing or using the infomation currently in these facts. Would changing this break stuff?
This request was not resolved in time for the current release. Red Hat invites you to ask your support representative to propose this request, if still desired, for consideration in the next release of Red Hat Enterprise Linux.
Acking 7.1
This feature request was not implemented and delivered to QE by the rhel-7.1.0 Dev Freeze date of 10/27/2014. Deferring for consideration in next release.
A new fact should be created (such as net.interface.eth0.ipv4_net_addrinfo_list) that has the new format and the existing fact should remain the same. In that way, if someone is using the existing fact the format will not change on them.
Verifying Version... [root@jsefler-rhel7 ~]# rpm -q subscription-manager subscription-manager-1.17.8-1.el7.x86_64 [root@jsefler-rhel7 ~]# rpm -q subscription-manager --changelog | grep 874735 - 874735: Support fact collection of multiple ips per interface [root@jsefler-rhel7 ~]# subscription-manager facts --list | egrep net.*.list -B1 net.interface.eth0.ipv4_address: 10.16.7.221 net.interface.eth0.ipv4_address_list: 10.16.7.221 net.interface.eth0.ipv4_broadcast: 10.16.7.255 net.interface.eth0.ipv4_broadcast_list: 10.16.7.255 net.interface.eth0.ipv4_netmask: 22 net.interface.eth0.ipv4_netmask_list: 22 net.interface.eth0.ipv6_address.global: 2620:52:0:1007:5054:ff:fecc:250e net.interface.eth0.ipv6_address.global_list: 2620:52:0:1007:5054:ff:fecc:250e net.interface.eth0.ipv6_address.link: fe80::5054:ff:fecc:250e net.interface.eth0.ipv6_address.link_list: fe80::5054:ff:fecc:250e net.interface.eth0.ipv6_netmask.global: 64 net.interface.eth0.ipv6_netmask.global_list: 64 net.interface.eth0.ipv6_netmask.link: 64 net.interface.eth0.ipv6_netmask.link_list: 64 -- net.interface.lo.ipv4_address: 127.0.0.1 net.interface.lo.ipv4_address_list: 127.0.0.1 net.interface.lo.ipv4_broadcast: Unknown net.interface.lo.ipv4_broadcast_list: Unknown net.interface.lo.ipv4_netmask: 8 net.interface.lo.ipv4_netmask_list: 8 net.interface.lo.ipv6_address.host: ::1 net.interface.lo.ipv6_address.host_list: ::1 net.interface.lo.ipv6_netmask.host: 128 net.interface.lo.ipv6_netmask.host_list: 128 -- net.interface.virbr0.ipv4_address: 192.168.122.1 net.interface.virbr0.ipv4_address_list: 192.168.122.1 net.interface.virbr0.ipv4_broadcast: Unknown net.interface.virbr0.ipv4_broadcast_list: Unknown net.interface.virbr0.ipv4_netmask: 24 net.interface.virbr0.ipv4_netmask_list: 24 VERIFIED: All of the facts above whose names end in "_list" are the new facts introduced by this RFE. Notice that all of them are currently a list of 1 value which is equivalent to the prior fact and occur for each of the ipv4 and ipv6 network devices I currently have defined (eth0,lo,virbr0). A list of 1 is expected when there is only one net interface address configured. Admittedly I am not an expert at networking. But I'll do my best to configure a second address for one of my devices and list the facts again to demonstrate a list.... 1. call "route -n" and look for the line with Flag UG and take note of the gateway for setting below (10.16.7.254) 2. start application "gnome-control-center network&" On my "Wired" network I clicked the gear icon button chose "Identity" in the left list to find the Name of the interface (eth0) chose "IPv4" in the left list changed Addresses from "Automatic (DHCP)" to "Manual" set Address 192.168.1.1 set Netmask 255.255.255.0 set Gateway 10.16.7.254 click the + button to add another ip address set Address 192.168.1.2 set Netmask 255.255.255.0 set Gateway 10.16.7.254 click Apply 3. systemctl restart network.service 4. subscription-manager facts --list [root@jsefler-rhel7 ~]# subscription-manager facts --list | egrep net.*.list -B1 net.interface.eth0.ipv4_address: 192.168.1.2 net.interface.eth0.ipv4_address_list: 192.168.1.1, 192.168.1.2 net.interface.eth0.ipv4_broadcast: 192.168.1.255 net.interface.eth0.ipv4_broadcast_list: 192.168.1.255, 192.168.1.255 net.interface.eth0.ipv4_netmask: 24 net.interface.eth0.ipv4_netmask_list: 24, 24 net.interface.eth0.ipv6_address.global: 2620:52:0:1007:dacd:b06d:84f4:7415 net.interface.eth0.ipv6_address.global_list: 2620:52:0:1007:dacd:b06d:84f4:7415 net.interface.eth0.ipv6_address.link: fe80::f336:9661:f817:da4d net.interface.eth0.ipv6_address.link_list: fe80::f336:9661:f817:da4d net.interface.eth0.ipv6_netmask.global: 64 net.interface.eth0.ipv6_netmask.global_list: 64 net.interface.eth0.ipv6_netmask.link: 64 net.interface.eth0.ipv6_netmask.link_list: 64 -- net.interface.lo.ipv4_address: 127.0.0.1 net.interface.lo.ipv4_address_list: 127.0.0.1 net.interface.lo.ipv4_broadcast: Unknown net.interface.lo.ipv4_broadcast_list: Unknown net.interface.lo.ipv4_netmask: 8 net.interface.lo.ipv4_netmask_list: 8 net.interface.lo.ipv6_address.host: ::1 net.interface.lo.ipv6_address.host_list: ::1 net.interface.lo.ipv6_netmask.host: 128 net.interface.lo.ipv6_netmask.host_list: 128 -- net.interface.virbr0.ipv4_address: 192.168.122.1 net.interface.virbr0.ipv4_address_list: 192.168.122.1 net.interface.virbr0.ipv4_broadcast: Unknown net.interface.virbr0.ipv4_broadcast_list: Unknown net.interface.virbr0.ipv4_netmask: 24 net.interface.virbr0.ipv4_netmask_list: 24 VERIFIED: All of the net.interface.eth0.ipv4_*_list facts now show a comma delimited list of configured addresses (2) where the last list value equals the prior non-list fact value PS. I don't know how to add a second ipv6 net interface address. NEEDINFO
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHSA-2016-2592.html