Setting primary IP for VPS (out of 2 available)
Posted
by
Flyer
on Server Fault
See other posts from Server Fault
or by Flyer
Published on 2012-11-23T22:31:58Z
Indexed on
2012/11/23
23:05 UTC
Read the original article
Hit count: 173
I've got a little problem. My VPS (Debian box) has 1 primary IP address, but now my hosting provider decided to assign me another one due to problems with first one. Let's say new IP is 91.222.152.20 and old one 91.221.190.170. How should I make 91.222.152.20 primary one, so that everything works on this address instead of 91.221.190.170 (like ftp, mysql etc) I tried editing /etc/newtwork/interfaces setting
iface eth1 inet static
address 91.222.152.20
netmask 255.255.252.0
network 91.222.152.0
broadcast 91.222.155.255
gateway 91.222.152.1
I know that network is 91.222.152.0/22 so I assume that above configuration should be right. Saved, rebooted and that ended pretty bad. Couldn't even ping box on old or new IP. Had to revert to working one. So question is. What am I doing wrong and how to do it right?
© Server Fault or respective owner