WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-users

Re: [Xen-users] Xen with NAT networking.

To: Huagang XIE <huagangxie@xxxxxxxxx>
Subject: Re: [Xen-users] Xen with NAT networking.
From: Mark Pryor <tlviewer@xxxxxxxxx>
Date: Wed, 9 Feb 2011 15:18:01 -0800 (PST)
Cc: xen-users@xxxxxxxxxxxxxxxxxxx
Delivery-date: Wed, 09 Feb 2011 15:19:07 -0800
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1297293481; bh=dr4P4ldN1gvmV/YHK2QsnkTC3lICpT78d0Nqvow5pSk=; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=qXRRtJAzOOjhcxp7cTSmuVpqMjERMzoFB6xw+zOIzyN2BveVTAQHaXJtwUOXOtyyllSvBdmSZoa3VzqGPU/cQpWdA7sVYsnj2uCyh9vHfG09SKWIWfotoCd9/7ovAQbnaxsZhSEastHIsqbkCkcnfZ5Upi6UQ8+3t6Z+J33jR2o=
Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=3IOmhV3r0Ib/RBqzYIjFXJYpp4EzxZb1PLYuj1BooaPJrFt3BW+OH6V7+oJxB7Fqy7ar6yuy/eTkUB9IPsx+jY0LbVF3StsM3L2Z8EY1ccgxPEnVakSUy2jO6S6pCz/vIp4HrRn2hAZ6nxj66K/0ZnJ6DAWi5y5Lc+ACBvlxh2E=;
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <AANLkTinCBxn2EBqpiJrfKCT=iB2o0MBuUfQZ3pAkOOJu@xxxxxxxxxxxxxx>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx

--- On Wed, 2/9/11, Huagang XIE <huagangxie@xxxxxxxxx> wrote:

> From: Huagang XIE <huagangxie@xxxxxxxxx>
> Subject: [Xen-users] Xen with NAT networking.
> To: xen-users@xxxxxxxxxxxxxxxxxxx
> Date: Wednesday, February 9, 2011, 2:34 PM
> Hello there,
> 
> I was trying to setup a XEN NAT. I think I follow all the
> instructions
> but still failed.
> 
> In NAT environment,  the tap.x is the gateway for the
> guest os, right?
> but the xen always set the
> gateway to vif.x, and the guest os will never be able to
> communicate outside.
> 

Gateway is at 10.0.0.254
so set your guest with
network 10.0.0.0
netmask 255.255.255.0

address 10.0.0.5   <--- your choice

whatever address you choose on the above network, must be set in both 
ifcfg-eth0 and in your domU config

vif = ['ip=10.0.0.5,mac=00:16:3e:aa:bb:cc']

> 
> Does anyone here successfully configure a NAT networking
> with XEN? I
> am using Xen 3.4.3 and also trying 4.0.1 under Centos 5.
> 

yes, but in addition to above comments add:

echo 'net.ipv4.ip_forward = 1' >> /etc/sysctl.conf

-- 
Mark






_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users

<Prev in Thread] Current Thread [Next in Thread>