route ips to main server, assign ips to vpses

  • Thread starter Thread starter ataomega
  • Start date Start date
A

ataomega

Guest
hello.
i have a dedicated server , all ips are routed to main server and i assigned ips to vpses , they work fine.

i just bought another dedicated server from another datacenter. they said :
we cannot route these ips to your servers main ip, due to datacenter policy
use bridge network on your vpses.


any solution please? please tell me what to do.
at first they add all ips to server, but i asked to remove them and just route them to server so i can assign ips to vps.
 
Last edited by a moderator:
i have another server, all ips are routed to it, and i easily set ips to vpses and works.

but this server, ips are not routed to server. if i add ips to eth0 , and in creating vps select bridge network , and set ip to vps, will it work?

please help me, how to assign ips to vpses when routing ips to main server is not possible?

at first all ips were added to eth0 and pinging ok. but i removed them create a vps and add ip but : ping : reply from main datacenter's gateway : destination host unreachable
 
ok, ips are not added to main server.

i created a centos openvz vps with one of ips , network type : virtual network (venet)

its started and running but not pinging : destination host unreachable

how to and where configure it? should i configure it inside VM?

thanks for your reply
 
may i select bridge ethernet (veth) in creating vps , and then inside the vm add ip manually? please explain how to fix. thanks a lot
 
ips are not added to main node.

i create a vps with bridge ethernet network type but inside vm there is not any interface to configure except lo

then created a vps with virtual network venet , and set ip, but not pinging. inside i've set gateway in network file, but not any chances.

any solution please? could you please take a look at it? i will give you root password.

thanks a lot
 
i create a vps with bridge ethernet network type but inside vm there is not any interface to configure except lo

Thats the right approach. You need to create a correct network setup yourself - like you would do on a physical host.
 
you mean just create a vps with bridge ethernet network , and inside vm setup network? could you please tell me how to do that? there is not any interfaces to add ips to it, should i setup interfaces myself?
 
there is just 1 interface : "lo" should i configure it or create another interface? i'm new to linux networking
 
there is just 1 interface : "lo" should i configure it or create another interface? i'm new to linux networking

Again, you need to setup the network exactly like you would do that on a physical host. So yes, you need to create/configure interface 'eth0'.
 
created a vps with bridge network
ifconfig eth0 212.113.33.35 up
created and edited file : /etc/sysconfig/network-scripts/ifcfg-eth0 :
DEVICE=eth0
IPADDR=212.113.33.35
NETMASK=255.255.255.0
NETWORK=212.113.33.0
ONBOOT=yes
NAME=eth0
GATEWAY=213.186.121.67

cat /etc/sysconfig/network
NETWORKING="yes"
HOSTNAME="ibs.186.121.239.utel.net.ua"
GATEWAY=213.186.121.67

service network restart
Shutting down interface eth0: [ OK ]
Shutting down loopback interface: [ OK ]
Bringing up loopback interface: [ OK ]
Bringing up interface eth0: [ OK ]


ping 8.8.8.8
connect: Network is unreachable

ifconfig
eth0 Link encap:Ethernet HWaddr 7E:E4:E9:16:4C:D8
inet addr:212.113.33.35 Bcast:212.113.33.255 Mask:255.255.255.0
inet6 addr: fe80::7ce4:e9ff:fe16:4cd8/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:906 errors:0 dropped:0 overruns:0 frame:0
TX packets:18 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:81203 (79.2 KiB) TX bytes:936 (936.0 b)

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)

cat /etc/resolv.conf
search 186.121.239.utel.net.ua
nameserver 8.8.8.8
nameserver 8.8.4.4

but again not working.

ping from 212.113.33.35 :
reply from 213.186.121.67 : destination host unreachable

what to do now? help please
 
BTW, I am sure your data-center can provide a working network config (that is unrelated to proxmox ve)
 
i have another ip (213.186.121.240) in same range as main server's ip and gateway. i changed vps ip to 213.186.121.240

now pinging vps from out side : ping from 213.186.121.240 : request timed out

cat ifcfg-eth0
DEVICE=eth0
IPADDR=213.186.121.240
NETMASK=255.255.255.0
NETWORK=213.186.121.0
ONBOOT=yes
NAME=eth0
GATEWAY=213.186.121.67

ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
From 213.186.121.67: icmp_seq=2 Redirect Host(New nexthop: 213.186.121.65)
From 213.186.121.67: icmp_seq=3 Redirect Host(New nexthop: 213.186.121.65)
From 213.186.121.67: icmp_seq=4 Redirect Host(New nexthop: 213.186.121.65)
^C
--- 8.8.8.8 ping statistics ---
4 packets transmitted, 0 received, 100% packet loss, time 3009ms

any solution please?
 
i've created another vps with virtual network veneth with ip : 213.186.121.240

pinging vps from outside : request timed out

pinging from inside vps :
ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
From 213.186.121.67: icmp_seq=2 Redirect Host(New nexthop: 213.186.121.65)
From 213.186.121.67: icmp_seq=3 Redirect Host(New nexthop: 213.186.121.65)
From 213.186.121.67: icmp_seq=4 Redirect Host(New nexthop: 213.186.121.65)
From 213.186.121.67: icmp_seq=5 Redirect Host(New nexthop: 213.186.121.65)
From 213.186.121.67: icmp_seq=6 Redirect Host(New nexthop: 213.186.121.65)
From 213.186.121.67: icmp_seq=7 Redirect Host(New nexthop: 213.186.121.65)
From 213.186.121.67: icmp_seq=8 Redirect Host(New nexthop: 213.186.121.65)
From 213.186.121.67: icmp_seq=9 Redirect Host(New nexthop: 213.186.121.65)
^C
--- 8.8.8.8 ping statistics ---
9 packets transmitted, 0 received, 100% packet loss, time 8056ms
 
route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
213.186.121.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth0
0.0.0.0 213.186.121.67 0.0.0.0 UG 0 0 0 eth0