How to Give your Linux Temporary IP Address

Submitted by str on Sat, 09/24/2011 - 00:39

In some odd cases like you are troubleshooting network problem or you want to join temporarily a different VLAN or subnet, it is very handy, useful and sometimes really required to change your Ubuntu box IP Address.

Use ifconfig
sudo Ifconfig eth0 netmask

Add route
sudo route add default gw

Where: is the IP Address that you want to use. is the subnet mask of the network you want to join is your gateway