Bug 450545

Summary: retain relay agent options when the client is in INIT or REBIND states
Product: Red Hat Enterprise Linux 5 Reporter: Frode Nordahl <frode>
Component: dhcpAssignee: David Cantrell <dcantrell>
Status: CLOSED ERRATA QA Contact: Alexander Todorov <atodorov>
Severity: low Docs Contact:
Priority: low    
Version: 5.2CC: atodorov, borgan, cward
Target Milestone: rcKeywords: OtherQA
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-09-02 10:13:13 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Patch that fixes some situations where relay agent information is not included in replies
none
dhcp-3.0.5-emergency-relay-agent-options-hologram.patch
none
dhcp.spec.patch
none
dhcp-3.0.5-19.el5.src.rpm
none
Log that displays errant behaviour in RHEL 5.3
none
Log that displays correct behaviour in RHEL 5.4 none

Description Frode Nordahl 2008-06-09 14:15:11 UTC
Description of problem:
We need fixes from version 3.0.6 to use ISC-DHCP with agent.circuit-id / agent.remote-id options in 
our DSL infrastructure.

Specifically this one from the 3.0.6 changelog:
Some bugs were fixed in the 'emergency relay agent options hologram' which is used to retain relay 
agent option contents from when the client was in INIT or REBIND states. This should solve problems 
where relay agent options were not echoed from the server, even when giaddr was set.

Would it be possible to get this backported, or to update the package to latest 3.0.x version from 
upstream?

Comment 1 David Cantrell 2008-09-26 04:05:13 UTC
Only in extreme circumstances (usually security related), do we like to rebase packages in RHEL.  Rebasing meaning updating the new package to a new base version.  The reason for this is that a lot of QA goes in to ensuring that the software we ship in RHEL interacts very well together.  Rebasing a new package invalidates that QA and we don't always have the resources to re-QA everything to rebase a package.  That's why RHEL packages get patches and never rebasing.

A backport for this fix is not impossible, just time consuming.  If you can help pinpoint the code that needs to be backported from 3.0.6, that would help a lot.

Comment 2 Frode Nordahl 2008-09-29 09:56:25 UTC
Created attachment 317945 [details]
Patch that fixes some situations where relay agent information is not included in replies

Comment 3 Frode Nordahl 2008-09-29 09:59:41 UTC
Hello, and thank you for the interest!

In the above patch I pulled the relevant portions from a diff between ISC DHCP 3.0.5 and ISC DHCP 3.0.6.

I have tested the ISC DHCP 3.0.5 RPM with this patch installed and it resolves the issue.

From the Release Notes:
- In the case where an "L2" DHCP Relay Agent (one that does not set giaddr)
  was directly attached to the same broadcast domain as the DHCP server,
  the RFC3046 relay agent information option was not being returned to the
  relay in the server's replies.  This was fixed; the dhcp server no longer
  requires the giaddr to reply with relay agent information.  Note that
  this also improves compatibility with L2 devices that "intercept" DHCP
  packets and expect relay agent information even in unicast (renewal)
  replies.  Thanks to a patch from Pekka Silvonen.

Comment 4 Frode Nordahl 2008-09-29 10:08:25 UTC
One more thing, we probably also need to run our DHCP servers with USE_SOCKETS instead of the default mode that relies on LPF.

This is a compile time option, and is probably not what most users want, but is it possible to prepare the RPM so that this can be accomplished with a simple rpmbuild --rebuild?

That would be awesome :-)

Comment 5 David Cantrell 2008-09-30 01:24:27 UTC
Created attachment 318030 [details]
dhcp-3.0.5-emergency-relay-agent-options-hologram.patch

Updated patch, applies against latest dhcp source for RHEL 5.

Comment 6 David Cantrell 2008-09-30 02:49:42 UTC
Created attachment 318035 [details]
dhcp.spec.patch

Patch to the spec file for this bug and to enable user-selected compile-time USE_LPF or USE_SOCKETS.

Comment 7 David Cantrell 2008-09-30 02:50:51 UTC
Created attachment 318036 [details]
dhcp-3.0.5-19.el5.src.rpm

Source RPM containing spec file modifications and the patch listed in this bug report.

Comment 8 David Cantrell 2008-09-30 02:52:28 UTC
Attached is a new source RPM containing the patch for this bug as well as the modification you wanted to the spec file to allow for easy recompiles choosing USE_SOCKETS over USE_LPF.  To use:

rpmbuild --with USE_SOCKETS -ba dhcp.spec
rpmbuild --with USE_LPF -ba dhcp.spec

The default is USE_LPF, so a simple 'rpmbuild -ba' will give you an LPF-enabled dhcp.

Comment 9 David Cantrell 2008-09-30 02:55:38 UTC
Requesting inclusion in RHEL 5.4.0.  Setting devel-ack.

PM:  This is an upstream fix that's been backported to the version of dhcp shipping in RHEL 5.
QA:  Asking reporter for a definite reproducer.

Dirty work for this bug has been done already.  Patches are all set and ready to go.  If QA can get a way to test it, I think it's reasonable for inclusion in 5.4.0.

Reporter, can you provide a detailed description of how to reproduce this bug on RHEL 5.2.0 and a way to verify it has been fixed by the patch listed in this bug report?

Comment 10 Frode Nordahl 2008-10-02 18:29:06 UTC
This really looks great, thanks alot!

Reproducing this bug involves a DSLAM (that has a L2 agent that adds relay agent information to packets). I will see if I can find some other way to reproduce it with standard tools.

Would it be helpful if I gave your QA team access to a RHEL 5.2.0 box in our LABB with access to the DSLAM to reproduce the bug?

Comment 11 David Cantrell 2008-12-13 23:47:41 UTC
QA,

Can I get a qa-ack on this?  The reporter has been very helpful with providing information and testing feedback with the patch I provided.  I would like to include the fix for them in 5.4.

Comment 13 Brock Organ 2009-01-30 22:43:21 UTC
Hi Frode,

Thank you for your help with this issue; Our QA team will be able to verify the
new rpmbuild functionality, but I request that during the testing cycle you
would explicitly verify the bad behavior is fixed in your environment ...

Regards,

Brock

Comment 14 David Cantrell 2009-02-21 02:37:56 UTC
Fixed in dhcp-3.0.5-19.el5 and later releases.

Comment 16 Chris Ward 2009-06-14 23:15:19 UTC
~~ Attention Partners RHEL 5.4 Partner Alpha Released! ~~

RHEL 5.4 Partner Alpha has been released on partners.redhat.com. There should
be a fix present that addresses this particular request. Please test and report back your results here, at your earliest convenience. Our Public Beta release is just around the corner!

If you encounter any issues, please set the bug back to the ASSIGNED state and
describe the issues you encountered. If you have verified the request functions as expected, please set your Partner ID in the Partner field above to indicate successful test results. Do not flip the bug status to VERIFIED. Further questions can be directed to your Red Hat Partner Manager. Thanks!

Comment 17 Alexander Todorov 2009-07-03 09:55:11 UTC
Frode,
a fix for this bug is included in RHEL 5.4 Beta which is available on RHN. If you have active subscriptions to RHN you should be able to download the bits. Please provide your test results.

Thanks,
Alexander.

Comment 18 Chris Ward 2009-07-03 18:03:32 UTC
~~ Attention - RHEL 5.4 Beta Released! ~~

RHEL 5.4 Beta has been released! There should be a fix present in the Beta release that addresses this particular request. Please test and report back results here, at your earliest convenience. RHEL 5.4 General Availability release is just around the corner!

If you encounter any issues while testing Beta, please describe the issues you have encountered and set the bug into NEED_INFO. If you encounter new issues, please clone this bug to open a new issue and request it be reviewed for inclusion in RHEL 5.4 or a later update, if it is not of urgent severity.

Please do not flip the bug status to VERIFIED. Only post your verification results, and if available, update Verified field with the appropriate value.

Questions can be posted to this bug or your customer or partner representative.

Comment 19 Chris Ward 2009-07-10 19:04:54 UTC
~~ Attention Partners - RHEL 5.4 Snapshot 1 Released! ~~

RHEL 5.4 Snapshot 1 has been released on partners.redhat.com. If you have already reported your test results, you can safely ignore this request. Otherwise, please notice that there should be a fix available now that addresses this particular request. Please test and report back your results here, at your earliest convenience. The RHEL 5.4 exception freeze is quickly approaching.

If you encounter any issues while testing Beta, please describe the issues you have encountered and set the bug into NEED_INFO. If you encounter new issues, please clone this bug to open a new issue and request it be reviewed for inclusion in RHEL 5.4 or a later update, if it is not of urgent severity.

Do not flip the bug status to VERIFIED. Instead, please set your Partner ID in the Verified field above if you have successfully verified the resolution of this issue. 

Further questions can be directed to your Red Hat Partner Manager or other appropriate customer representative.

Comment 20 Brock Organ 2009-07-13 19:44:17 UTC
Hi Frode,

We're hoping for testing feedback from you for this feature, but do have time and schedule limitations ... would you possibly be able to provide feedback to us in the next week?

Best Regards,

Brock

Comment 21 Frode Nordahl 2009-07-13 21:33:51 UTC
Hi there,

Sorry for the late response, I'm just back from vacation.

I installed RHEL 5.4 beta on a server today! I will perform tests and report back here in a day or two.

Best Regards,

Frode

Comment 22 Frode Nordahl 2009-07-15 11:57:37 UTC
Created attachment 353808 [details]
Log that displays errant behaviour in RHEL 5.3

Comment 23 Frode Nordahl 2009-07-15 11:58:23 UTC
Created attachment 353809 [details]
Log that displays correct behaviour in RHEL 5.4

Comment 24 Frode Nordahl 2009-07-15 12:06:41 UTC
Hello,

I have completed testing and can confirm that the DHCP RPM shipped with RHEL 5.4 Beta works as expected. I have also included log files that shows the effect of the fix.

The test was performed by setting up two servers, one with RHEL 5.4 Beta, and one with RHEL 5.3. I installed the stock DHCP package from RedHat on both and connected them to the lab network. When using the DHCP server in RHEL 5.3 the client is unable to renew its lease, and has to rebind every time the lease expires.

When using the DHCP server in RHEL 5.4 the client successfully renews its lease, showing that the patch works.

Thank you for your help getting this into the next release!

--
Frode Nordahl

Comment 25 Alexander Todorov 2009-07-15 12:19:02 UTC
Hi Frode,
thank you for testing and attached log files. 

I'm moving this bug to VERIFIED as per comment #24 so that our automated tools are happy.

Comment 27 errata-xmlrpc 2009-09-02 10:13:13 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2009-1331.html