OpenVZ Forum


Home » General » Support » virtual ethernet device
Re: virtual ethernet device [message #21340 is a reply to message #21335] Fri, 05 October 2007 13:17 Go to previous message
maximiliano is currently offline  maximiliano
Messages: 8
Registered: September 2007
Junior Member
Yes, the reason was beacouse I need install and run Heartbeat Service in one VPS (101), but to run this service I needed one Interface (eg. eth0) with the correct configuration (ip - mask - bcast).

I found some information about this in:

http://wiki.openvz.org/Virtual_Ethernet_device#Making_a_veth -device_persistent

Simple configuration with virtual ethernet device
[edit] Start a VE

[host-node]# vzctl start 101

[edit] Add veth device to VE

[host-node]# vzctl set 101 --veth_add veth101.0,00:12:34:56:78:9A,eth0,00:12:34:56:78:9B --save

Configure devices in VE0

[host-node]# ifconfig veth101.0 0
[host-node]# echo 1 > /proc/sys/net/ipv4/conf/veth101.0/forwarding
[host-node]# echo 1 > /proc/sys/net/ipv4/conf/veth101.0/proxy_arp
[host-node]# echo 1 > /proc/sys/net/ipv4/conf/eth0/forwarding
[host-node]# echo 1 > /proc/sys/net/ipv4/conf/eth0/proxy_arp

Configure device in VE

[host-node]# vzctl enter 101
[ve-101]# /sbin/ifconfig eth0 0
[ve-101]# /sbin/ip addr add 192.168.0.101 dev eth0
[ve-101]# /sbin/ip route add default dev eth0

Add route in VE0

[host-node]# ip route add 192.168.0.101 dev veth101.0


I hope that this can help.

Best Regards
Maximiliano C.
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: NFS Problem
Next Topic: Clearing bean counters
Goto Forum:
  


Current Time: Wed Aug 27 03:25:31 GMT 2025

Total time taken to generate the page: 0.14867 seconds