OpenVZ Forum


Home » General » Support » Newbie Question about network..
Re: Newbie Question about network.. [message #38823 is a reply to message #38822] Thu, 04 February 2010 14:04 Go to previous messageGo to previous message
Paparaciz
Messages: 302
Registered: August 2009
Senior Member
you wroted that:
Usable secondary addresses: 174.142.167.217-222
Mask : 255.255.255.248

who gave you this ip addresses?
they are not public, they are private ip addresses
http://en.wikipedia.org/wiki/Private_network#Private_IPv4_ad dress_spaces

as i see you have only one public ip address

so if you want to have internet inside VE do following config:
remove all the eth aliases (eth0:0 - eth0:x), leave only eth0

add private ip address to VE (for example 174.142.167.217)
then do

echo 1 > /proc/sys/net/ipv4/ip_forward
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE

that's all
if you want to have VE with public ip addresses ask them from your provider and assign them to VE.

if you want assign services for your VE and you have only one public ip just forward port to you VE in HN.

further reading:
http://wiki.openvz.org/Using_NAT_for_container_with_private_ IPs
http://wiki.openvz.org/Common_Networking_HOWTOs
http://wiki.openvz.org/Containers/Networking

and of course read the
http://download.openvz.org/doc/OpenVZ-Users-Guide.pdf

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: NIS Server in Open-vz
Next Topic: Access Internet from private IP CT
Goto Forum:
  


Current Time: Sat Aug 17 19:19:25 GMT 2024

Total time taken to generate the page: 0.02639 seconds