ok I got it to work, just needed to add the correct routes inside the VE to use venet0:1 for one subnet and venet0:0 as the default gateway.
(centos VE)
# vzctl set 113 --ipadd a.b.c.d --ipadd e.f.g.h --save
# vzctl enter 113
and then configure routes so that:
# cat /etc/sysconfig/network-scripts/route-venet0
e.f.g.h/24 dev venet0:1
# cat /etc/sysconfig/network
NETWORKING="yes"
HOSTNAME="vps-name"
GATEWAY="localhost"
GATEWAYDEV="venet0:0"
EDIT: seams that this last modification does not survive restart.
I had to either add:
route add default venet0:0
to /etc/rc.local
or modify /etc/vz/dists/scripts/functions with:
FAKEGATEWAY=localhost
FAKEGATEWAYNET=255.255.255.255
[Updated on: Wed, 18 June 2008 13:41]
Report message to a moderator