Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
DescriptionPavel Šimerda (pavlix)
2013-01-02 09:20:37 UTC
One of the many use cases:
1) initramfs networkmanager uses a DHCP daemon to learn network configuration parameters
2) initramfs networkmanager addresses, routes and DNS configuration
3) initramfs networkmanager is requested to stop
4) initramfs networkmanager stops all daemons including dhclient
Now, there are addresses and routes configured but no daemon running. If the system doesn't start networkmanager for some reason, addresses and routes will be used forever, which violates RFC 2131.
We need some kernel features to be able to both dispose the addresses in time when no daemon is running and take over the addresses gracefully when new networkmanager instance is started.
Desired options:
1) A valid lifetime value that would be used by kernel to remove expired IPv4 addresses and would be readable and writable through netlink. It is important that by reading the value, networkmanager can distinguish dynamic routes from static routes.
I didn't test the readability for IPv6 but it definitely didn't work for IPv4.
2) A similar option for routes.
I don't know how this currently works for IPv6 routes from router advertisements.
I know it is possible to set the routing protocol field for routes but I'm not sure if it's helpful.
For addresses, I tested this with ipv6 and it works nice:
# ip a a fc00::2/7 dev eth1x valid_lft 10 preferred_lft 5
Is this the same you have on mind for ipv4?
Lifetime is transferred over Netlink via IFA_CACHEINFO. Apparently "ip" tool does not mind sending this even for ipv4 address. So this only need to be implemented in kernel. I'll try to cook a patch.
Comment 3Pavel Šimerda (pavlix)
2013-01-11 15:15:29 UTC
(In reply to comment #2)
> Is this the same you have on mind for ipv4?
Yes, that's exactly what we need. I currently only plan to use the valid lifetime.
(In reply to comment #2)
> Lifetime is transferred over Netlink via IFA_CACHEINFO. Apparently "ip" tool
> does not mind sending this even for ipv4 address. So this only need to be
> implemented in kernel. I'll try to cook a patch.
Sounds good to me.
We found out that userspace will not get netlink notification in case ipv4 addr changes. Since no change was possible before 5c766d642bcaff, I have to do a follow-up patch for this.