From owner-freebsd-emulation Fri Sep 15 16:47:17 2000 Delivered-To: freebsd-emulation@freebsd.org Received: from guardian.sftw.com (guardian.sftw.com [209.157.37.25]) by hub.freebsd.org (Postfix) with ESMTP id 6F13537B423; Fri, 15 Sep 2000 16:47:14 -0700 (PDT) Received: from yoda.sftw.com (yoda.sftw.com [209.157.37.211]) by guardian.sftw.com (8.9.3/8.9.3) with ESMTP id QAA71050; Fri, 15 Sep 2000 16:47:14 -0700 (PDT) (envelope-from nsayer@sftw.com) Received: from sftw.com (localhost [127.0.0.1]) by yoda.sftw.com (8.11.0/8.11.0) with ESMTP id e8FNlDp06874; Fri, 15 Sep 2000 16:47:13 -0700 (PDT) (envelope-from nsayer@sftw.com) Message-ID: <39C2B501.58EC338E@sftw.com> Date: Fri, 15 Sep 2000 16:47:13 -0700 From: Nick Sayer Reply-To: nsayer@kfu.com X-Mailer: Mozilla 4.75 [en] (X11; U; Linux 2.2.12 i386) X-Accept-Language: en MIME-Version: 1.0 To: freebsd-emulation@freebsd.org Cc: archie@freebsd.org Subject: Re: vmnet, bridging and netgraph References: <39C29F98.F3A0FF53@sftw.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-emulation@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Nick Sayer wrote: > > Holy crap! It works! Not quite. I was a bit overenthusiastic. There are a couple issues: 1. You pretty much have to do the ngctl steps in the vmware.sh file at startup, because they have to run as root. Adding an suid binary to do this stuff at run time would be a little overkill, IMHO. 2. The kernel spits out lots of these: arp: 209.157.37.4 is on xl0 but got reply from 00:bd:5a:e6:4d:91 on vmnet1 This is because ARP checks the source of the packet and sees the wrong interface. When ng_bridge is sending packets to an upper hook, it should make the packet look like it was received on the interface belonging to the upper hook in question. Either that or the arp code has not yet been sufficiently disconnected from the interfaces to let the upper and lower hooks work the way ng_bridge wants them to. Archie? :-) 3. The promisc flag on vmnet1 does not seem to persist. Given how it works, this may not matter. 4. I forgot the need to sent setpromisc 1 and setautosrc 0 messages when setting this whole thing up. 5. I don't yet have a correct list of modules to load in vmware.sh to make this work. I have tried loading just netgraph.ko, but this fails the _first_ time I do all of the hookups, but not the second. Archie? :-) 6. There is a long standing bug in tap(?) that for some bizarre reason keeps my win2k guest from being able to do DHCP. The DHCP server sends its reply to 255.255.255.255, and somehow tap never gets it. I'm not sure why not. Real win2k machines have no problem DHCPing from this server. 7. Those of you using ed interfaces may notice that there is a couple #ifdef BRIDGE sections in the driver. Not sure what for. > > For those of you who have an up-to-date install, you can hose out all of > the bridge stuff in your vmware.sh file and just change the exec line at > the bottom of /usr/local/bin/vmware into this: > > ETHER= your ethernet interface (e.g. xl0) > > ngctl mkpeer vmnet1: bridge lower link0 > ngctl name vmnet1:lower vmnet_bridge > ngctl connect vmnet_bridge: ${ETHER}: link1 lower > ngctl connect vmnet_bridge: ${ETHER}: link1 upper > > /usr/local/lib/vmware/bin/vmware "$@" > > ngctl shutdown vmnet_bridge: > > No more having to change the kernel, no more worries about having the > bridge turned on when vmware isn't running. It's all gravy. > > Note that this will probably NOT work if your primary Ethernet interface > is a wi0 card. That's because those cards can't transmit Ethernet frames > with source addresses different than their own. Sorry. Blame Lucent. > They don't want you to avoid buying an access point to do > wireless-to-LAN bridges. > > THREE CHEERS FOR ARCHIE!!!! HUZZAH! HUZZAH! HUZZAH! > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-emulation" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-emulation" in the body of the message