network setup

jonic

New Member
Dec 4, 2009
7
0
1
First I want to congratulate you on your product - very well done.

Secondly I need some help with my network setup. I have from my ISP a public subnet that is routed through my main ip. So I proceeded to setup a test server trying to do this configuration using private ip-s just for test purposes.

I setup the network on the host as shown in the wiki in http://pve.proxmox.com/wiki/Network_Model. This is my interfaces file on the host:

Code:
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet static
        address  192.168.201.141
        netmask  255.255.255.0
        gateway  192.168.201.1
        post-up echo 1 > /proc/sys/net/ipv4/conf/eth0/proxy_arp


auto vmbr0
iface vmbr0 inet static
        address 10.10.10.1
        netmask 255.255.255.0
        bridge_ports none
        bridge_stp off
        bridge_fd 0

auto vmbr1
iface vmbr1 inet static
        address 10.10.10.2
        netmask 255.255.255.0
        gateway 10.0.0.1
        bridge_ports none
        bridge_stp off
        bridge_fd 0
Next I added a virtual container for Ubuntu Hardy (using the available template) - and used vmbr1 for the network device. This is my interfaces file on the guest:
Code:
auto lo
iface lo 
      inet loopback

auto eth0
iface eth0
      inet static 
      address 10.10.10.2  
      netmask 255.255.255.0   
      gateway 10.10.10.1
However I cannot access the internet on the guest, or even ping 10.10.10.1.

I guess I'm doing something wrong, but I don't know what. Any ideas?

Thank you,
Ioan
 
I have removed the gateway from vmbr1, still doesn't work (from guest I can't ping 10.10.10.1).

I have tried adding a manual route on the host:
Code:
route add -net 10.10.10.0 netmask 255.255.255.0 gw 10.10.10.1
No luck.

From the wiki I understand how to use the first ip from the subnet, meaning 10.10.10.1, but how do I use a second ip from this subnet?
 
Last edited:
10.x.x.x is a private IP - you will never we able to access the internet with that, unless you do some kind of NAT.
Ok, but I still should have been able to ping the host. As I said I was using the private subnet just in the test environment.


Anyway I solved my problem. I ditched the vmbr1 interface and I attached the vmr0 interface to the vm. Then I just set on the vm the ip 10.10.10.2 and things started working.

I didn't understand from the wiki what were the correct steps to use the vmbr interfaces - maybe some extra explanations are required. If you agree I could add what I learned to the wiki. (of course if this is the correct way to setup things).
 
Ok, but I still should have been able to ping the host. As I said I was using the private subnet just in the test environment.

Yes, because there are several other errors in your network setuo (duplicate gateways, duplicate routes).

I didn't understand from the wiki what were the correct steps to use the vmbr interfaces - maybe some extra explanations are required. If you agree I could add what I learned to the wiki. (of course if this is the correct way to setup things).

We will review any addition to the wiki.