-
Notifications
You must be signed in to change notification settings - Fork 790
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use the same options for acquiring, renewing lease #755
Use the same options for acquiring, renewing lease #755
Conversation
09caea6
to
762e176
Compare
Can you squash? |
Currently, hostname is set in the original DHCPREQUEST but not the renewal. With some DHCP server implementations (such as FreeBSD dhcpd), this leads to the hostname being cleared in the lease table. This behavior is inconsistent with other DHCP clients such as dhclient which set the hostname on the renewal request as well. To fix, use the same options for acquire and renew. This is compatible with RFC 2131 (see table 5). Signed-off-by: Akhil Velagapudi <4@4khil.com>
762e176
to
c78e1e4
Compare
Squashed |
@akhilles Should we also do the same for Release()? If the DHCP server doesn't respect ClientID for renew, I'll bet it doesn't respect it for Release either? |
The DHCP server is respecting client ID on renew, but it doesn't know what to do with the other options (and it's not well-defined in the RFC from what I can tell). So, it basically does an upsert and replaces all options with what's in the renewal request. I think it's because both request and renew use It seems like you're only allowed to set client ID for
|
Thanks for the explanation! |
Currently, hostname is set in the original DHCPREQUEST but not the
renewal. With some DHCP server implementations (such as FreeBSD dhcpd),
this leads to the hostname being cleared in the lease table.
This behavior is inconsistent with other DHCP clients such as dhclient
which set the hostname on the renewal request as well. To fix, use the
same options for acquire and renew.
This is compatible with RFC 2131 (see table 5).