Register now or log in to join your professional community.
Ip changing in linux
Hi,You can execute following commands to release and renew ip in linux:
sudo dhclient -v -r eth0 --> to release ip
sudo dhclient -v eth0 --> to renew ip or ifconfig eth0 downifconfig eth0 up
ifconfig eth0 downRunning the above command would take the eth0 interface (the first network card) down. Which is the same as releasing the IP address from that network card.
ifconfig eth0 up
typing in the above command would bring that interface back up.
or dhclient eth0
Renews the IP address assigned to it by DHCP.
use ifdown eth0 to bring it down and ifup eth0 to bring it back up.