Right now I have a website setup using (WHM/Cpanel) on the 1.2.3.2 address. The problem is whenever I initiate a connection from the web server (PHP curl script for example) it is always sourced from the 1.2.3.1 address. I have called and talked to the support for my VPS and they say this is impossible and I need to move the site to the other address. For reasons that are not important here I would like to avoid doing that. Is there any way to get the venet0:1 interface to be the default interface for outgoing connections?

2 Answers
2

You may want to check out This question from last week. I think it's exactly what you're looking for.

Long story short, Linux doesn't handle multiple IPs on the same subnet well. But the tools in ipconfig2 help out a bunch. So using them instead of the more commonly known ifconfig/route commands is what you need.

...where xxx.xxx.xxx.xxx is your normal default gateway from route -n. Do this at a console as you'll lose network routing, and be prepared to put it back if it doesn't work to whatever route -n normally says.

What is odd though is that if you look at the routing table (just added it to my post) it is referring to an IP subnet that is not on either of the other two interfaces. The 2 interfaces have public IP addresses and this is clearly an internal one.
–
EzraSep 20 '10 at 23:07