OpenVZ Forum


Home » General » Support » Server4you Server and Connecting to the Internet and from the Internet
Re: Server4you Server and Connecting to the Internet and from the Internet [message #11770 is a reply to message #11750] Thu, 05 April 2007 16:24 Go to previous messageGo to previous message
mh720 is currently offline  mh720
Messages: 7
Registered: August 2006
Junior Member
I'm going to take a guess here, are the two IP addresses from your provider on DIFFERENT subnets? If so, give this a try (works for me). Please report back so that I can update the wiki.


Example with hwnode on 1.2.3.0/24 and VE somwhere on 2.3.4.0/29 with a gateway of 2.3.4.1:


Configure hwnode subnet normally. Then to add the second subnet for the VE:

node# route add -net 2.3.4.0/29 eth0
node# ip rule add from 2.3.4.0/29 table 1
node# ip route add default dev eth0 via 2.3.4.1 table 1

Then do your 'vzctl set veid --ipadd 2.3.4.2 --save' as normal.


That should be it. You can 'man ip' to read more about 'Route tables'. If you add yet another subnet, you might use table 2.


I believe I originally read about this on
https://wiki.openvz.org/Source_based_routing


-mike

[Updated on: Thu, 05 April 2007 16:27]

Report message to a moderator

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: How to setup bonding in a VPS?
Next Topic: *SOLVED* Wiki Update for Debian Installation
Goto Forum:
  


Current Time: Wed Jul 10 11:30:21 GMT 2024

Total time taken to generate the page: 0.02579 seconds