Tag Archives: ip

Linux: Change default IP address on host with multiple IP address

If you have a host with multiple IP address on it, and you need to change witch IP address it present it with on the Internet, you can change the Default IP address, by changing the source IP address on the default route

ip route change default via 192.168.0.254 src 192.168.0.10

Of course the Linux host need to listen on the IP address.
You can see the changes by this command

ip route list
default via 192.168.0.254 dev eth0 src 192.168.0.10