Page 1 of 4 123 ... LastLast
Results 1 to 10 of 36

Thread: VirtualBox wireless bridging

  1. #1
    Join Date
    Mar 2008
    Beans
    26

    VirtualBox wireless bridging

    I am trying to set up a VB WinXP guest. I am trying to bridge my wireless connection with a vbox interface to get online with the guest. My network card is an Intel 2200bg. I added the following lines to /etc/network/interfaces:

    auto br0
    iface br0 inet static
    address 192.168.1.150
    network 192.168.1.0
    netmask 255.255.255.0
    broadcast 192.168.1.255
    gateway 192.168.1.1
    bridge_ports all

    When I reboot, the network manager pops up repeatedly for my WPA key. I am sure I am typing it correctly. In the VB manual it says that it is not possible to bridge a wireless connection, but I have read posts from other people saying that they have done it. Could someone please help me with this?
    Last edited by Silvr2008; March 15th, 2008 at 05:15 AM. Reason: Typo

  2. #2
    Join Date
    May 2007
    Location
    Netherlands
    Beans
    321
    Distro
    Xubuntu 10.10 Maverick Meerkat

    Re: VirtualBox wireless bridging

    Check http://ubuntuforums.org/showpost.php...1&postcount=14 for the 'howto'. It should work.
    Throw Apples out the Windows, but make sure not to hit the Penguin.

  3. #3
    Join Date
    Mar 2008
    Beans
    209

    Re: VirtualBox wireless bridging

    Naw, that was written by a jerk. Just ask my wife.

    Please post if anything in it isn't clear. I did my best to make it newcomer friendly.

    Re the iptables part--that's been updated but only solved (for me) with Fedora. Actually, I don't think that I tested iptables with Ubuntu.

  4. #4
    Join Date
    Mar 2008
    Beans
    26

    Re: VirtualBox wireless bridging

    Thanks for your replys. I followed the howto and it did not work for me. Although when I sysctl net.ipv4.ip_forward=1 along with the instructions in the vbox manual, it did get it working with the NAT configuration. I wonder why it didnt mention that in the part specific to Ubuntu. Still no connection when I am trying with it attached to a host interface.

  5. #5
    Join Date
    Mar 2008
    Beans
    209

    Re: VirtualBox wireless bridging

    Ok, let's try to keep it on one thread (I see there's another where both you and I had replied.)

    I'll be busy till this evening, (EDT) but let's try to clarify.

    We are only worried about wireless bridging at this point, correct? (The other thread mentions a bridge, which my howto doesn't use for wireless.)

    When you say part specific to Ubuntu, did you mean my howto or the VBox docs. I found their distro specific docs to have problems, at least in Fedora, it might be that it's all being written by someone who uses something else.
    Anyway, I'll post more on this in the evening, but I'd just like to clarify is one thread for wired and the other for wireless?

  6. #6
    Join Date
    Mar 2008
    Beans
    209

    Re: VirtualBox wireless bridging

    I did a fresh install on Hardy today to see if there's anything I missed. The only thing I can think of is that this time (installing via apt-get from the repos) is that I did, this time (but not in the past) have to change the default emulated network card . The default is PCNet-PCII. I had to change that to PCNet-FASTIII.

    Also, I found it necessary to give both tap0 and the guest O/S static IP addresses. (Different addresses--I believe that's made clear on my page.)

    At any rate, it definitely worked.

  7. #7
    Join Date
    Oct 2007
    Beans
    1

    Angry Re: VirtualBox wireless bridging

    I'have similar issue.
    My PC I have eth0 (wireless) and eth1 (wired).
    Ubuntu 7.10 is the OS-Host and Windows is OS-guest, I run this script before launch VM on VBox :

    tunnel.sh
    ----
    sudo tunctl -t tap0 -u $2
    sudo chmod 666 /dev/net/tun
    sudo ifconfig $1 0.0.0.0 promisc
    sudo ifconfig tap0 0.0.0.0 promisc
    sudo brctl addbr br0
    sudo brctl addif br0 $1
    sudo brctl addif br0 tap0
    sudo dhclient br0
    ----

    where $1 is the phisical interface and $2 is the user who launch VM.

    So if I need tunnel in wired LAN I run :
    # sh tunnell.sh eth1 my_user

    and if I need tunnel in wireless LAN I run :
    # sh tunnell.sh eth0 my_user.

    In wired LAN this script work fine, in wireless LAN it doesn't work.
    Someone can help me ?
    thanks

  8. #8
    Join Date
    Mar 2008
    Beans
    209

    Re: VirtualBox wireless bridging

    Yes, the first post in this thread links to my page on it. I made.
    http://home.nyc.rr.com/computertaijutsu/vboxbridge.html

    It usually works. After reading Silvr2008's post, I checked my instructions last night, and it worked with Hardy without too much trouble. I found I had to make a couple of minor changes from my original instructions, which have now been added to the page.)

  9. #9
    Join Date
    Mar 2008
    Beans
    26

    Re: VirtualBox wireless bridging

    I reinstalled VirtualBox, this time via apt-get and followed your instructions and still no dice. One thing I thought was interesting was that I could not ping the IP of tap0 on the host machine, but if I changed the IP on the guest to the same IP as tap0, it would give me an error saying there is an IP conflict.

    Also, I no longer have the option to change the virtual interface to the type III card. Is it possible we are getting a different version or something? In the VB about it says I am on version 1.50_OSE which is the same as what I thought I had before though.

    I am a total newb to linux, but could it be that parprouted is simply not compatible with my Intel 2200bg NIC? I have had lots of problems running things with it.
    Last edited by Silvr2008; March 22nd, 2008 at 12:56 AM.

  10. #10
    Join Date
    Mar 2008
    Beans
    209

    Re: VirtualBox wireless bridging

    It shouldn't be incompatible with the card. I was using a later version of VBox though, I think.

    Let's go through the steps. You have a firewall or is it off? (For testing, we might want to temporarily turn it off, though Hardy's default firewall, at least, wasn't a problem.)

    We enable ip forwarding with sysctl as described. We create tap0 and you have rights to it (I think Ubuntu does that by default.

    ls -l /dev/net/tun
    and make sure that vboxusers have some rights.

    We create tap0 with you as the user. We set its address on the same subnet as the regular wireless NIC with the ip command as stated.
    We do parprouted eth1 tap0

    (You might, at least once, do parprouted -d eth1 tap0) Replace eth1 with whatever your system calls your wireless card. That -d is for debug and will cause parprouted to output to the terminal, so you might see something obvious. (You might not, too, at one point when it wasn't working for me, it was just giving its usual got ARP blah blah.)

    In VirtualBox, we chose Attached to Host Interface and gave it the name tap0. As I say in my howto, I changed the default card. However, when I was running a machine with the 2100, a close relative of yours, I didn't have to change it. I would try it with all choices available--I think there's those two and one more.

    We then gave the guest OS an address on the same subnet. (If any of this isn't clear, as you say you're a newcomer, don't be embarrassed to ask. I'm assuming you know what I mean by a subnet, that eth1, tap0 and the guest O/S will have address like 192.168.1 20, 192.168.1.21 and 192.168.1.22 all with a netmask of 255.255.255.0.)

    Did you use the OSE version (which is, I think, the one from apt. I'm using Hardy though, so it might be different.)

Page 1 of 4 123 ... LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •