Renew a dhcp lease with dhclient on Linux

Instead of killing the dhclient process in order to run dhclient again to get a new lease, just release the lease.

# /sbin/dhclient -r eth0

DHCPRELEASE on eth0 to 192.168.1.3 port 67

No need to kill it with pkill or killall. It’s already dead.

nuke

Now you can ask for another lease.

# /sbin/dhclient eth0

DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 8
DHCPOFFER from 192.168.1.1
DHCPREQUEST on eth0 to 255.255.255.255 port 67
DHCPACK FROM 192.168.1.1
bound to 192.168.1.2 — renewal in 601411 seconds.

Posted by admica   @   14 June 2010

Related Posts

Like this post? Share it!

Digg Twitter StumbleUpon Delicious Technorati Facebook RSS

0 Comments

No comments yet. Be the first to leave a comment !
Leave a Comment

Name

Email

Website

Previous Post
« Movie and Software Piracy does not cause lost revenues
Next Post
Zork I: The Great Underground Empire »
Powered by Wordpress   |   Lunated designed by ZenVerse