Does DHCP client receive DHCP NAK if any of the parameters are wrong in DHCP Release?

StackOverflow https://stackoverflow.com/questions/1803870

  •  05-07-2019
  •  | 
  •  

Question

I am building a dhcp client using C on Ubuntu 9.04. Now I send a dhcp release to the dhcp server, it sends no ack as expected. I was wondering if it sends any DHCP NAK if any of the parameters are wrong.

There is one more problem. After sending DHCP Release my internet is still working. Also when I do ifconfig it still shows the ip address of eth0. But when I do dhclient -r internet does not work and ifconfig does not show the ip address of eth0.

Was it helpful?

Solution

Are you using tcpdump to inspect the packet traffic while you debug the handshake? That should show you if your server's implementation sends a NAK. RFC 2123: Dynamic Host Configuration Protocol indicates that there is a DHCPNAK.

DHCPNAK -- Server to client indicating client's notion of network address is incorrect (e.g., client has moved to new subnet) or client's lease as expired.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top