OpenVZ Forum


Home » General » Support » using network aliases
using network aliases [message #2011] Tue, 14 March 2006 12:05 Go to next message
bhazeltn is currently offline  bhazeltn
Messages: 5
Registered: March 2006
Junior Member
I'm trying to assign eth0:2 to a vps, but I can't seem to figure it out

mainserv bradley # ifconfig eth0:2
eth0:2    Link encap:Ethernet  HWaddr xx:xx:xx:xx:xx:xx  
          inet addr:xxx.xxx.xxx.xxx  Bcast:xxx.xxx.xxx.xxx Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          Interrupt:11 Base address:0xc000 


mainserv bradley # vzctl set 101 --netdev_add eth0:2
Unable to add netdev eth0:2: No such process


Is there a way to do this?
Re: using network aliases [message #2012 is a reply to message #2011] Tue, 14 March 2006 13:31 Go to previous messageGo to next message
kir is currently offline  kir
Messages: 1645
Registered: August 2005
Location: Moscow, Russia
Senior Member

No, you can only give a real network device to a VPS.

BTW why do you need this?


Kir Kolyshkin
http://static.openvz.org/userbars/openvz-developer.png
Re: using network aliases [message #2013 is a reply to message #2012] Tue, 14 March 2006 15:51 Go to previous messageGo to next message
bhazeltn is currently offline  bhazeltn
Messages: 5
Registered: March 2006
Junior Member
It is a dedicated server that I don't have physical access too that has one network card buy multiple IP's, some that I wish to map directly to the vps
Re: using network aliases [message #2014 is a reply to message #2013] Tue, 14 March 2006 15:57 Go to previous messageGo to next message
kir is currently offline  kir
Messages: 1645
Registered: August 2005
Location: Moscow, Russia
Senior Member

Well that's pretty straightforward.

What you need to do is
(1) remove those extra IPs from eth0 interface (leaving just the one address for the server itself);
(2) add those IPs to the appropriate VPSs, i.e.
vzctl set NNN --ipadd a.b.c.d --save


Kir Kolyshkin
http://static.openvz.org/userbars/openvz-developer.png
Re: using network aliases [message #2015 is a reply to message #2013] Tue, 14 March 2006 16:07 Go to previous messageGo to next message
bhazeltn is currently offline  bhazeltn
Messages: 5
Registered: March 2006
Junior Member
that's simple enough. I had alredy assinged the IP to the VPS, but, this was helpful. thanks
Re: using network aliases [message #2016 is a reply to message #2014] Tue, 14 March 2006 16:44 Go to previous messageGo to next message
bhazeltn is currently offline  bhazeltn
Messages: 5
Registered: March 2006
Junior Member
Ok, now I'm stumped again.
I removed eth0:2 from my network config. The IP was already assigned to the vps. The vps starts fine. I go to ping the IP and I get no response.

I do have /etc/sysctl.conf set up according to the quick install directions (however they are not in the gentoo howto)

I'm using Gentoo, which I figure probably makes this crap out on me
Re: using network aliases [message #2017 is a reply to message #2016] Tue, 14 March 2006 17:53 Go to previous message
bhazeltn is currently offline  bhazeltn
Messages: 5
Registered: March 2006
Junior Member
I sorted it out, it took some playing, but I got it to work.

The primary and secondary address I have use a different default gateway, I just had to make the vps know this
Previous Topic: Question about memory resource parameters
Next Topic: iptables in vps or on the host node
Goto Forum:
  


Current Time: Sat Jul 13 19:20:50 GMT 2024

Total time taken to generate the page: 0.02292 seconds