Feb 16, 2009
VMWare Fusion Airport Bridged Interface
Today I needed that my bridged interface for my Linux Virtual Machine in VMWare Fusion was bind to the Airport network card instead of the wired ethernet card. I wanted that may wireless hosts could access my VM in the wireless network from other hosts.
By the way this was an Ad-Hoc network created with Internet Sharing option in Mac OS X system preferences, so that I can share internet to my home.
In order to VMWare Fusion start to bind your virtual bridge interfaces you need to edit the file at:
/Library/Application\ Support/VMware\ Fusion/boot.sh
Locate in the file the following code:
# vmnet-bridge puts itself in background (daemon mode) # Bridge to host network interface 'en0'. #"$LIBDIR/vmnet-bridge" -d /var/run/vmnet-bridge-vmnet0.pid vmnet0 en0 # Bridge to the primary host network interface (which can change over time). "$LIBDIR/vmnet-bridge" -d /var/run/vmnet-bridge-vmnet0.pid vmnet0 ''
And change to this:
# vmnet-bridge puts itself in background (daemon mode) # Bridge to host network interface 'en0'. "$LIBDIR/vmnet-bridge" -d /var/run/vmnet-bridge-vmnet0.pid vmnet0 en1 # Bridge to the primary host network interface (which can change over time). # "$LIBDIR/vmnet-bridge" -d /var/run/vmnet-bridge-vmnet0.pid vmnet0 ''
Notice I’ve change the en0 interface (the wired NIC) to en1 (the Airport).
Restart VMWare services, including vmnet-bridge by issuing the following command:
sudo /Library/Application\ Support/VMware\ Fusion/boot.sh --restart
Yeahh.. Now my VM discovered an IP address on the wireless network. (DHCP was running on the Airport interface since I was using Internet Sharing in Mac OS X Leopard).
Buzz
Twitter
LinkedIn
Facebook
Flickr
You saved my life! I’ve been fighting with this for MONTHS and could never figure it out. You are a ROCKSTAR!!!
[Reply]
Ahh perfect article! EXACTLY what i needed.Thank you so much..
For some reason though I couldn’t get that last command to work to restart the services.. until i just copied and paste
Figures , i’m a terminal noob anyway.
Thanks again
[Reply]
Thanks very much. I guess at this time there is no way to use both interfaces? I have 2 VM’s and I would like one to use en0, and the other to use en1.
[Reply]
braceta Reply:
April 2nd, 2009 at 3:47 pm
Good question! I believe you can’t do it..
In VMware Fusion GUI there is no option to select which physical bridged interface is associated with your Virtual Machine..
If you find out, please, let me know!
Cheers
[Reply]
Found this KB article in the VMware Communities: http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1001875
You can add more lines and specify more vmnets, like this:
“$LIBDIR/vmnet-bridge” -d /var/run/vmnet-bridge-vmnet2.pid vmnet2 en1
[Reply]
I left off the rest of the steps. You need to modify the .vmx file for your VM in a text editor and add the following as the last line:
ethernet1.connectionType = “custom”
ethernet1.vnet = “vmnet2″
Really, though, go to the knowledge base article and follow its steps.
[Reply]
braceta Reply:
July 14th, 2009 at 10:46 pm
Thanks for the help Mark! Really great info! You rule!
[Reply]
You’re a life saver, thanks!
[Reply]