Linux Force DHCP client (dhclient) to renew ip address
Q. I'm using Ubuntu Linux. How to force Linux to reacquire a new IP address from the DHCP server? What is the command in Linux equivalent to Windows' "ipconfig /renew" Command?
A. You need to use Dynamic Host Configuration Protocol Client i.e. dhclient command. The client normally doesn't release the current lease as it is not required by the DHCP protocol. Some cable ISPs require their clients to notify the server if they wish to release an assigned IP address.
Linux renew ip command
The -r flag explicitly releases the current lease, and once the lease has been released, the client exits. For example, open terminal and type the command:
$ sudo dhclient -r
Now obtain fresh IP:
$ sudo dhclient
There is no need to restart network service. Above command should work with any Linux distro such as RHEL, Fedora, CentOS, Ubuntu and others. On a related note you can also try out the following commands:
# ifdown eth0
# ifup eth0
# /etc/init.d/network restart
OR
# /etc/init.d/networking restart
Subscribe to our free e-mail newsletter or RSS feed to get all updates.
You can Email this page to a friend.
Related Other Helpful FAQs:
- How do I find out my DHCP server address?
- Configuring Linux Static DHCP Clients by Sending Host Name
- Setting Up a CentOS / Red Hat Linux DHCP Client
- Configure Linux DHCP client ( dhclient ) to persistently look for an IP address lease
- Linux change ip address
Discussion on This FAQ
Leave a Reply
We encourage your comments, and suggestions. But please stay on topic, be polite, and avoid spam. Thank you very much for stopping by our site!
Tags: dhclient_command, dhcp protocol, dhcp server, dynamic host configuration protocol, host configuration protocol, ipconfig renew, renew ip, renew ip address, Ubuntu Linux



June 14th, 2008 (4 weeks ago) at 6:15 am
Resolution provided was short but very effective.
Helped me to resolve the issue.
Great work
Thanks
Rajesh