Subject: Re: Re: Re: qemu, bridge and wireless
To: Joel CARNAT <joel@carnat.net>
From: Quentin Garnier <cube@cubidou.net>
List: pkgsrc-users
Date: 09/24/2007 23:56:05
--ppnyhArmEF+be6aR
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mon, Sep 24, 2007 at 11:25:42PM +0200, Joel CARNAT wrote:
> On Sat, Sep 22 2007 - 18:43, Quentin Garnier wrote:
[...]
> > Sure.  You affect an IP address to one of the tap interface and you make
> > it the default route for the VMs.
> >=20
>=20
> Using PF, the VM now can go to the Internet.
> The thing is I'm not able to ping/TSE from the "real" workstation to the
> VM. Is this expected as I am using on a tap interface ?
>=20
> Here's what I did :
> # ifconfig
> wpi0: flags=3D8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
>         status: active
> tap0: flags=3D8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> mtu 15=
00
> 	media: Ethernet autoselect
> 	inet 192.168.0.1 netmask 0xffffff00 broadcast 192.168.0.25
> bridge0: flags=3D41<UP,RUNNING> mtu 1500
> tap2: flags=3D8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> mtu 15=
00
> 	media: Ethernet autoselect

If you fiddle with the output of the commands, you're sure to leave
important stuff aside.  I mean, who gives a shit about the specific
address on your wpi interface?  It's probably in the mail headers
anyway.

> # brconfig
> bridge0: flags=3D41<UP,RUNNING>
> 	Configuration:
> 		priority 32768 hellotime 2 fwddelay 15 maxage 20
> 		ipfilter disabled flags 0x0
> 	Interfaces:
> 		tap2 flags=3D2<DISCOVER>
> 			port 7 priority 128
> 		tap0 flags=3D2<DISCOVER>
> 			port 5 priority 128
> 	Address cache (max cache: 100, timeout: 1200):
> # qemu command (running Windows XP, NIC configured as 192.168.0.20)
> qemu -m 512 -boot c -net tap,fd=3D3,ifname=3Dtap2 -net nic,macaddr=3Dde:a=
d:be:ef:00:02 win.img

What does tcpdump say?  Note that you only need one tap interface per
VM, and to affect an address on one of them, anyway.

--=20
Quentin Garnier - cube@cubidou.net - cube@NetBSD.org
"See the look on my face from staying too long in one place
[...] every time the morning breaks I know I'm closer to falling"
KT Tunstall, Saving My Face, Drastic Fantastic, 2007.

--ppnyhArmEF+be6aR
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (NetBSD)

iQEVAwUBRvgyddgoQloHrPnoAQIOXwf9FdjeJ6UCBikBZAC5SK+Jyx24bxpokROd
DEqgsWypeZ1s7wbXykQuTy1D4HQgkE5j3dYmekGNLCKrc06f/nB5AHRg+w5/mifg
Evg106L6GEslurVmBjU0EIutUP0X+DiZlOAjhZew1DrL2O/vc2h31zJ0jLsdbg+r
ufnWvpsvN3auSRml5TMiPm0q1GUsBhLWqXL6P3yuhLEmT+NG7coogitnRkPyNS3W
F5EvhvLCkA8XSbfYMvwlWQ3mJiQDBHnV1+7Pj85VtkXJiwHQkc/IA5duyMx44QG1
/xhgvcFL9Lpf6OPFT7Q/t9alkQeEY4GfRRp/eHeocywcO5TKWMNI6w==
=px8h
-----END PGP SIGNATURE-----

--ppnyhArmEF+be6aR--