I am very confused about second ip routed on a dedicated server a on the last 2-3 datacenters that i got a dedicated server i just ask for a second ip routed on my server and they just add it without accessing my server and i was able to ping it and use it as ns2.
I got one server a few days ago from online.net and i got 1 ip and i ask for a second ip routed on my server and they told me to get one failover ip and add it on my server from the client panel.
I did it but i was not able to ping or use that ip so i contact them and they told me to create a file:
as i did and i add all the info there...
Then when i try to run ifup eth0:0 or service network restart i got this:
eth0:0 is not present, initialization will be delayed
Then i just check on the path /etc/sysconfig/network-scripts/ and no eth0 file is there... and my main server ip was on a file named em1...
Any ideas how can i fix this so i can ping that ip?
if i run ifconfig i can see the em1 only interface that is working using main sever ip and lo ...
Is it better to use range ip's option in one file or to use ifcfg-em1:0 and ifcfg-em1:1 and ifcfg-em1:2 ?
It's better to use the range file if the IP addresses are contiguous, so you don't have to do as much configuration. You can also have multiple range files if need be.
By the way, if the IP's are routed to you, it doesn't matter what interface the IP's are bound to, they will still work. It's better to stick to em1 which is the interface you receive the packets on though, to keep the configuration clean.
You may also want to use a subnet mask of 255.255.255.255, to ensure that outbound traffic uses your primary IP address. It varies from kernel/distro, but sometimes the most recently configured IP address ends up being used by default on outbound traffic.
ASTUTE HOSTING: Advanced, customized, and scalable solutions with AS54527 Premium Canadian Optimized Network (Level3, PEER1, Shaw, Tinet) MicroServers.io: Enterprise Dedicated Hardware with IPMI at VPS-like Prices using AS63213 Affordable Bandwidth (Cogent, HE, Tinet) Dedicated Hosting, Colo, Bandwidth, and Fiber out of Vancouver, Seattle, LA, Toronto, NYC, and Miami