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.
Bug 1204095 - dhclient refuses to renew address if there's other interface on the same subnet
Summary: dhclient refuses to renew address if there's other interface on the same subnet
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: dhcp
Version: 6.7
Hardware: All
OS: Linux
high
high
Target Milestone: rc
: ---
Assignee: Jiri Popelka
QA Contact: Release Test Team
URL:
Whiteboard:
: 1229285 (view as bug list)
Depends On:
Blocks: 1254457 1269889
TreeView+ depends on / blocked
 
Reported: 2015-03-20 11:44 UTC by Harald Hoyer
Modified: 2016-05-10 20:51 UTC (History)
6 users (show)

Fixed In Version: dhcp-4.1.1-50.P1.el6
Doc Type: Bug Fix
Doc Text:
Cause When there are (at least) two network interfaces on one machine connected to the same subnet and (at least) one of them is obtaining IP address via dhcp. Consequence During address renewal dhclient thinks the address is already in use by some other machine and declines it. Fix Bug in dhclient-script was fixed. Result dhclient correctly renews address and continues using it.
Clone Of:
Environment:
Last Closed: 2016-05-10 20:51:47 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2016:0803 0 normal SHIPPED_LIVE dhcp bug fix and enhancement update 2016-05-10 22:38:15 UTC

Description Harald Hoyer 2015-03-20 11:44:43 UTC
# rpm -qf /sbin/dhclient-script 
dhclient-4.1.1-48.P1.el6.x86_64


Running dhclient with an existing lease file will fail, because:

    BOUND|RENEW|REBIND|REBOOT)
        if [ -z "${interface}" ] || [ -z "${new_ip_address}" ]; then
            exit_with_hooks 2
        fi

        if arping -D -q -c2 -I ${interface} ${new_ip_address}; then
            dhconfig
            exit_with_hooks 0
        else
            # DAD failed, i.e. address is already in use
            exit_with_hooks 1
        fi
        ;;


arping will get the answer from its own interface. Newer dhclient-script versions have:

    BOUND|RENEW|REBIND|REBOOT)
        if [ -z "${interface}" ] || [ -z "${new_ip_address}" ]; then
            exit_with_hooks 2
        fi
        if arping -D -q -c2 -I ${interface} ${new_ip_address}; then
            dhconfig
            exit_with_hooks 0
        else  # DAD failed, i.e. address is already in use
            ARP_REPLY=$(arping -D -c2 -I ${interface} ${new_ip_address} | grep reply | awk '{print toupper($5)}' | cut -d "[" -f2 | cut -d "]" -f1)
            OUR_MACS=$(ip link show | grep link | awk '{print toupper($2)}' | uniq)
            if [[ "${OUR_MACS}" = *"${ARP_REPLY}"* ]]; then
                # the reply can come from our system, that's OK (#1116004#c33)
                dhconfig
                exit_with_hooks 0
            else
                exit_with_hooks 1
            fi
        fi
        ;;

Comment 3 Jiri Popelka 2015-03-20 11:58:08 UTC
(In reply to Harald Hoyer from comment #0)
> Newer dhclient-script versions have:

Yes, that was added (rhel7.1) due to bug #1116004.
Could you check whether it fixes your problem,
so we could use the same solution in rhel-6 ?

Comment 4 Jiri Popelka 2015-08-18 10:31:57 UTC
*** Bug 1229285 has been marked as a duplicate of this bug. ***

Comment 11 errata-xmlrpc 2016-05-10 20:51:47 UTC
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/RHEA-2016-0803.html


Note You need to log in before you can comment on or make changes to this bug.