Issue

NAT Troubleshooting

posted in Hypervisor
Tuesday, October 15 2013, 06:49 AM
Pablo
Pablo
Offline
0
Hi

I want to have a XEN the following scenario:

Dom0 Connected to physical em1 with its respective IP

DomsU and Dom0 Connected through a private IP subnet, 10.0.0.0/24. All of them being able to connect one to each other, and using Dom0 as gateway, with NAT funcionality, have internet access.

I have correctly configured in /etc/xen/xend-configure.sxp
(network-script network-nat)
(vif-script vif-nat)


On the VMs configuration files I give them an IP within the subnet:
vif = [ 'ip=10.0.0.2,mac=00:16:3E:F4:82:8F' ]

But there is still a problem. When I do ifconfig on Dom0 I get a vifU.0 interface. I get as many vifU.0 interfaces as VMs I'm running.

So for example,
Dom0 - em1: 192.168.2.115
Dom0 - vif1.0: 10.0.0.1
Dom1 - eth0: 10.0.0.2
Dom2 - eth0: 10.0.0.3

With this scenario, Dom1 has connectivity to the Internet and of course with Dom0, but not with Dom2. Dom0 has connectivy with Dom1.

However, Dom2 doesn't have any connectivity at all, and on Dom0, if I ifconfig -a I can see that there is an interface vif2.0 that is down and is not configured.

I am a beginner to Xen. However, it doesn't make sense in my head that for the whole subnet I do have a vifU.0 interface in Dom0. Dom0 should just have one interface to the private network, and all of the DomU could see each other within the private network perfectly.

This configuration, of vifU.0 looks more to me as a bridge configuration rather than the NAT. Am I correct? Do you have any hint?

Thanks.

Accepted Answer

Pablo
Pablo
Offline
Wednesday, October 16 2013, 09:49 PM - #permalink
0
Hi Lars.

Thanks for your help.

I was a bit confused with NAT networking since in my opinion is not very well explained.

I ended up creating a VLAN bridging all the interfaces and then add ip forwarding at Dom0. This options suits me best.

I don't really understand how all the vifU.0 could need also an IP within the subnet formed by the DomU and vifU.0

Anyway....problem solved. Thanks.
Like
The reply is currently minimized Show
Responses (1)
  • Accepted Answer

    Lars Kurth
    Lars Kurth
    Offline
    Wednesday, October 16 2013, 11:05 AM - #permalink
    0
    Pablo,
    check out

    • http://wiki.xenproject.org/wiki/XenNetworking
    • http://wiki.xenproject.org/wiki/Xen_FAQ_Networking
    • http://wiki.xenproject.org/wiki/Xen_Common_Problems#Networking

    If this does answer the question above, please mark the issue as resolved, otherwise let me know and we will have a closer look. We will need more info, such as distro, version of xen, ...
    Lars
    The reply is currently minimized Show
Your Reply