Bridged Network from Windows 10 host to Ubuntu 18.04 guest in Virtualbox not working

10,008

Solution 1

I have a clue for you: Changing the network type on the VirtualBox side does not change how the VM "sees" it's network. The VM has the same virtual network interface, so the problem is on the host/network, not in the VM.

If you feel more comfortable with windows, try to install a windows VM with the bridged network, this will probably show you that the problem is on the host/network side.

  • Verify your firewall let the VM send and receive packets to the outside
  • Try a wired connection (if possible), your access point is perhaps refusing to give an IP address to your VM.
  • The last ressort will be to use NAT+Port forwarding.

Solution 2

Try this: put NAT mode, then do port-forwarding by forwarding the ports to the host's card. Of course you must have the address of the virtual machine and the host machine.

Port Forwarding Rules in VirtualBox

Share:
10,008

Related videos on Youtube

Tanckom
Author by

Tanckom

Updated on September 18, 2022

Comments

  • Tanckom
    Tanckom over 1 year

    I've been a Windows poweruser since forever and lately I got more interested in hosting and webservers. That's when the time has come to get my hands dirty with Linux and so I decided today to create a virtual machine running Ubuntu 18.04, installing apache on it and doing my first baby steps.

    Unfortunately, I can only reach the webserver on Ubuntu, not on the host machine or any other device connected to the internet. Some googling later, I found out that I have to switch network adapter to bridged.

    Now comes my issue. After i switched to bridged, the network connection is gone - and i tried to find a solution during the last 5h, by changing some stuff here and there or reinstalling the OS - without luck.

    Since I'm a fresh born baby with this OS, I wanted to hear from some Linux poweruser what the issue could be and how I could solve it?

    Error: Activation of Network connection failed

    ifconfig with bridged Network: enter image description here

    Virtual box Network settings:

    enter image description here

    /etc/network/interface file enter image description here

    • T Nierath
      T Nierath about 6 years
      Since you are running with a GUI you should use Network Manager (one of the icons on the upper right side) to configure your connection.
  • Luciano
    Luciano about 6 years
    the picture is not visible, sorry. Click on the link to see it
  • Tanckom
    Tanckom about 6 years
    Thanks, it works but seems to be a workaround since the ifconfig still shows as inet 10.0.2.15 I would like to set it up a way that my guest machine has it's own ip to fully work with apache
  • Luciano
    Luciano about 6 years
    Sorry I did not understand your problem now. You do not like that address? If you want to change it you have to change the VirtualBox settings.
  • A.B
    A.B about 6 years
    I concur. putting a wireless adapter in a bridge requires support from both the system, AND the AP. the card has to go from 3-mac-addresses mode to 4-mac-addresses mode ( networkengineering.stackexchange.com/questions/25100/… ). Same for the AP
  • Tanckom
    Tanckom about 6 years
    I would like to use a different IP than my host machine :)