Nevermind, I forgot to assign a static ip to my hvm. All is fine now.
On Wed, Jan 25, 2012 at 12:50 PM, Bryan Emmanuel
<piusvelte@gmail.com>wrote:
> All,
>
> I''m trying to resolve the network bridging my on laptop.
I''ve recently
> installed Debian Squeeze 64bit with Xen 4.0. As I''m on a laptop
and switch
> between eth0 and wlan0 for my connection, I''ve setup a dummy
interface and
> setup xen to bridge using that, yet my first virtual machine does not have
> internet connectivity. Here are more details:
>
>
> /etc/network/interfaces
>
> auto lo
> iface lo inet loopback
>
> allow-hotplug eth0
>
> allow-hotplug wlan0
>
> auto dummy0
> iface dummy0 inet static
> address 192.168.101.1
> netmask 255.255.255.0
>
> ######
> /etc/modules
>
> loop
> alias dummy0 dummy
>
> ######
> /etc/network/if-up.d/iptables
>
> #!/bin/bash
> echo "Interface up, begin iptable setup"
> GATEWAYDEV=`ip route | grep default | awk {''print $5''}`
> if test -z "$GATEWAYDEV"; then
> echo "No gateway device found"
> else
> # iptables-save to view all iptables info
> echo "Delete existing POSTROUTING chains"
> iptables -D POSTROUTING -t nat -o wlan0 -s 192.168.101.0/24 -j MASQUERADE
> iptables -D POSTROUTING -t nat -o eth0 -s 192.168.101.0/24 -j MASQUERADE
> echo "Maquerading using $GATEWAYDEV"
> iptables -A POSTROUTING -t nat -o $GATEWAYDEV -s 192.168.101.0/24 -j
> MASQUERADE
> fi
> echo "Enabling IP forwarding"
> echo "1" > /proc/sys/net/ipv4/ip_forward
> echo "Done"
>
> ######
> /etc/xen/xend-config.sxp
>
> (network-script ''network-bridge bridge=xenbr0
netdev=dummy0'')
> (vif-script vif-bridge)
>
> ######
> My hvm was created using convirt and is configured to use the xenbr0:
>
> vif=[''mac=00:16:3e:59:27:b8,bridge=xenbr0'']
>
> ######
> Here''s the output from iptables-save with the virtual machine
running...
>
> # Generated by iptables-save v1.4.8 on Wed Jan 25 12:46:47 2012
> *filter
> :INPUT ACCEPT [1659:13129323]
> :FORWARD ACCEPT [0:0]
> :OUTPUT ACCEPT [1055:13036380]
> -A FORWARD -m state --state RELATED,ESTABLISHED -m physdev --physdev-out
> vif1.0 -j ACCEPT
> -A FORWARD -m physdev --physdev-in vif1.0 -j ACCEPT
> COMMIT
> # Completed on Wed Jan 25 12:46:47 2012
> # Generated by iptables-save v1.4.8 on Wed Jan 25 12:46:47 2012
> *nat
> :PREROUTING ACCEPT [73457:13273698]
> :POSTROUTING ACCEPT [2201:213665]
> :OUTPUT ACCEPT [2201:213665]
> -A POSTROUTING -s 192.168.101.0/24 -o eth0 -j MASQUERADE
> COMMIT
> # Completed on Wed Jan 25 12:46:47 2012
>
> ######
> ...and brctl show...
>
> xenbr0 8000.4ed134c56d80 no pdummy0
>
> ######
> The hvm guest is Windows 7 64bit, and shows no network connection.
>
> What am I missing, or should I check to resolve the lack of network
> connection?
>
> Thank you!
> Bryan
>
>
>
>
_______________________________________________
Xen-users mailing list
Xen-users@lists.xensource.com
http://lists.xensource.com/xen-users