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

[Xen-users] Failed to setup NAT

To: xen-users@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-users] Failed to setup NAT
From: YAO <yffbrave@xxxxxxxxx>
Date: Fri, 17 Jun 2011 16:59:04 +0800
Delivery-date: Fri, 17 Jun 2011 21:37:39 -0700
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=lmCf9Yr8av/U73QnJFHTawBM9KVM2R8OfJGJXqVJVSk=; b=DLM7TFg14FFTj5yxgogCal7VcoGzp/D95lNLoDm6n8K+XMmsJKd3qLe6iM8zLLfGeW jB42YdklorkGQ+UtBjzVRRlX+0BrRVC3qMjH/ablCMqj4Roi8eg50kyAgNMU3KwJJemt 9Ube+dUufRLTICrkZFJ7SH13pq7ZU0LsgFjcM=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=muzsUg4preGsNjOh7o+vr8Px/yJRvZFru8eDUD+y+yXc9KS0rps9OOrYzByexhlfCn 21x9dFEDeWM+0eRmp7sheolJeCdEy3hRIZaYoPBs2X6KLe/9xxC6x/yEOJR6//QP4TBI cJ4AY67SI4nQGnCZeHgmHveNakqksckon7EKc=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
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
I'm using Xen 4.1 and here's what I did:
1.comment network-script and vif-script about bridge in /etc/xen/xend-config.sxp, uncomment the lines about nat
2.set vm config, add something like vif = [ 'mac=00:16:3e:00:00:11, ip=10.0.0.1' ]
3.set /etc/network/interfaces in domU, add lines as follows:
auto eth0
iface eth0 inet static 
address 10.0.0.1 
gateway 10.0.0.254 
netmask 255.255.255.0

But it didn't work!

Here's the output of "ifconfig -a" in dom0

tap10.0   Link encap:Ethernet  HWaddr a6:8a:1b:92:be:af  
          BROADCAST MULTICAST  MTU:1500  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:500 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

vif10.0   Link encap:Ethernet  HWaddr fe:ff:ff:ff:ff:ff  
          BROADCAST MULTICAST  MTU:1500  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:32 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

the vif10.0 didn't get an ip!
The same thing happened in domU whose eth0 didn't get ip, too. Strangely, eth0 was renamed to eth9, I don't know why.

So, where did I make mistake? How to setup NAT network in the new toolstack?

By the way, can I use bridge mode if I have only one IP?
_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users
<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-users] Failed to setup NAT, YAO <=