Ubuntu release/renew DHCP IP of a specific interface from CLI

To renew the DHCP lease on the wlp0s20f3 interface in Ubuntu Desktop, you can use the dhclient command. Here’s how:

Open a terminal and type the following command:

sudo dhclient -r wlp0s20f3

This command sends a DHCP release message to the DHCP server, effectively releasing the current DHCP lease on the specified interface.

Then, to obtain a new DHCP lease, type the following command:

sudo dhclient wlp0s20f3

This command requests a new DHCP lease for the specified interface.

After running these commands, your network interface should have a renewed DHCP lease, and it should be able to connect to the network using the new lease.

Leave a comment