Network between host OS (18.04) and guest (*nix) in VirtualBox


Blue Buffett

Tried setting up a network and running on a VM, but ran into some difficulties that I couldn't solve.

The host OS Ubuntu is 18.04, the guest OS is a nix based OS, I can include and load the necessary drivers, e.g. virtio, vmxnet3, e1000and anything else.

If I compile a guest OS VM with vmxnet3drivers loaded and run it on VMware Player(NAT network) , the network works fine and I can transfer files between host and guest OS using scp etc. Output on guest OS ifconfig:

enter image description here

If I compile the guest OS VM, load the virtiodriver and run it VirtualBox(with NAT networking again) , for some reason I can't get the network up and running. Output ifconfigon guest OS :

enter image description here

What I noticed of course is that there is no (ivp4) IP assigned to the vt0interface in VirtualBox . I can of course run it, ifconfig vt0 xxx.xxx.xxx.xxx netmask 255.255.255.0but I'm not sure if this solves the problem, at least it doesn't work when trying to ssh/scp to the VM.

enter image description here

I checked that the host PC (IP for MTU 1500, vs. 172.16.129.1 in the guest OS) has port 22 open;

sudo nmap -sS -p- 172.16.129.1

Starting Nmap 7.60 ( https://nmap.org ) at 2018-06-19 10:47 CEST
Nmap scan report for linux (172.16.129.1)
Host is up (0.000013s latency).
Not shown: 65532 closed ports
PORT     STATE SERVICE
22/tcp   open  ssh
902/tcp  open  iss-realsecure
1716/tcp open  xmsg

So basically, the only difference between these two virtual machines, apart from the obvious difference in the software used (VMware vs VirtualBox), is the drivers loaded for each virtual machine. The rest of the code used to compile the guest OS VM is exactly the same without any changes, so I'm confused.

I've also tried using the driver e1000and selecting an Intel NIC driver in VirtualBox, but that doesn't work either - the closest I've gotten in VirtualBox so far is to use that .virtio

Does anyone have any suggestions on what I could try, or know what I might be overlooking here? For example, is there a driver for vmxnet3VirtualBox ?

I could of course settle for a VMware solution, but I prefer to use VirtualBox because that's the other way I'm using it - I just tested VMware now to see if it works there.

Blue Buffett

Figured out I wasn't setting up VirtualBox correctly, hence why it wasn't working at all. I haven't set it up in Paravirtualization interfaceVirtualBox KVM, so virtiothe driver is not enabled. Now that it's all set, it all works like a magic charm - I'm probably attracted by the stupid fact that I don't have to do this in VMware Player.

Related


Network between host OS (18.04) and guest (*nix) in VirtualBox

Blue Buffett Tried setting up a network and running on a VM, but ran into some difficulties that I couldn't solve. The host OS Ubuntu is 18.04, the guest OS is a nix based OS, I can include and load the necessary drivers, e.g. virtio, vmxnet3, e1000and anythin

Access VirtualBox Mac OS guest on Windows 10 host network

Shahzad Latif | I have a Windows 10 host with an IP address of 192.168.8.101, a subnet mask of 255.255.255.0 and a gateway of 192.168.8.1. I also have Mac OS Sierra installed on VirtualBox on this Windows host. This guest macOS has an IP like 10.0.2.15 and a g

Access VirtualBox Mac OS guest on Windows 10 host network

Shahzad Latif | I have a Windows 10 host with an IP address of 192.168.8.101, a subnet mask of 255.255.255.0 and a gateway of 192.168.8.1. I also have Mac OS Sierra installed on VirtualBox on this Windows host. This guest macOS has an IP like 10.0.2.15 and a g

Access VirtualBox Mac OS guest on Windows 10 host network

Shahzad Latif | I have a Windows 10 host with an IP address of 192.168.8.101, a subnet mask of 255.255.255.0 and a gateway of 192.168.8.1. I also have Mac OS Sierra installed on VirtualBox on this Windows host. This guest macOS has an IP like 10.0.2.15 and a g

Access VirtualBox Mac OS guest on Windows 10 host network

Shahzad Latif | I have a Windows 10 host with an IP address of 192.168.8.101, a subnet mask of 255.255.255.0 and a gateway of 192.168.8.1. I also have Mac OS Sierra installed on VirtualBox on this Windows host. This guest macOS has an IP like 10.0.2.15 and a g

Access VirtualBox Mac OS guest on Windows 10 host network

Shahzad Latif | I have a Windows 10 host with an IP address of 192.168.8.101, a subnet mask of 255.255.255.0 and a gateway of 192.168.8.1. I also have Mac OS Sierra installed on VirtualBox on this Windows host. This guest macOS has an IP like 10.0.2.15 and a g

Access VirtualBox Mac OS guest on Windows 10 host network

Shahzad Latif | I have a Windows 10 host with an IP address of 192.168.8.101, a subnet mask of 255.255.255.0 and a gateway of 192.168.8.1. I also have Mac OS Sierra installed on VirtualBox on this Windows host. This guest macOS has an IP like 10.0.2.15 and a g

Setup Network on Virtualbox Guest to Access Host VPN

nixgadget I'm trying to get this setup going, but I'm having a lot of trouble. Host OS: Windows 8 64bit Guest OS: CentOS 6.5 64-bit I use the Cisco VPN client on the host to connect to many remote servers that I want to access from the Guest OS. Currently I ha

Setup Network on Virtualbox Guest to Access Host VPN

nixgadget I'm trying to get this setup going, but I'm having a lot of trouble. Host OS: Windows 8 64bit Guest OS: CentOS 6.5 64-bit I use the Cisco VPN client on the host to connect to many remote servers that I want to access from the Guest OS. Currently I ha

Networking with virtualbox (OS X host/Fedora guest)

Stefano Borini I'm having trouble setting up Virtualbox to allow Fedora 11 (guest) to leave the virtualbox machine and go through Mac OS X 10.5 (host). I only found this tutorial http://vre.upei.ca/dev/node/497 But it doesn't match what I found and assumes you

Connect to host from VirtualBox guest OS?

Naftuli Kay I essentially want to access my host from a guest in VirtualBox. Is there an IP address for my host that I can use from the guest? Are additional steps required to set this up? I want to access the host's Apache, FTP and SSH services. Naftuli Kay T

Networking with virtualbox (OS X host/Fedora guest)

Stefano Borini I'm having trouble setting up Virtualbox to allow Fedora 11 (guest) to leave the virtualbox machine and go through Mac OS X 10.5 (host). I only found this tutorial http://vre.upei.ca/dev/node/497 But it doesn't match what I found and assumes you

Connect to host from VirtualBox guest OS?

Naftuli Kay I essentially want to access my host from a guest in VirtualBox. Is there an IP address for my host that I can use from the guest? Are additional steps required to set this up? I want to access the host's Apache, FTP and SSH services. Naftuli Kay T

Transfer image clipboard between host and VirtualBox guest?

Xie Jilai Is there anyway to transfer clipboard contents in image format, JPEG, bitmap or other formats to or from a VirtualBox guest instance? dwarf In fact, VirtualBox's support for clipboard sharing still lacks official support for graphics. Currently, it o

Transfer image clipboard between host and VirtualBox guest?

Xie Jilai Is there anyway to transfer clipboard contents in image format, JPEG, bitmap or other formats to or from a VirtualBox guest instance? dwarf In fact, VirtualBox's support for clipboard sharing still lacks official support for graphics. Currently, it o

Unable to ping between two guest OS in Virtualbox

3lokh Host OS: Ubuntu 13.04 VMM: Virtualbox Guest OS1: Kali Linux Network Settings: Adapter 1 connected to NAT Guest OS2: Windows XP Network Settings: Adapter 1 connected to NAT Problem: Unable to ping between guest OSes. When I check the IP, both clients have

Unable to ping between two guest OS in Virtualbox

3lokh Host OS: Ubuntu 13.04 VMM: Virtualbox Guest OS1: Kali Linux Network Settings: Adapter 1 connected to NAT Guest OS2: Windows XP Network Settings: Adapter 1 connected to NAT Problem: Unable to ping between guest OSes. When I check the IP, both clients have

VirtualBox: Make the host OS and the guest OS talk to each other

acapa As I said in the title, I want to access the VM via ssh from the host OS and vice versa (both OS are ubuntu; host is 10.10, guest is 9.10) To do this, I configured a bridged NIC on the client machine, connected it to my physical eth0 NIC, and statically

VirtualBox guest OS accesses local server on host OS

motto On my Ubuntu host, I have a local web server. I installed VirtualBox and Debian as a guest. I want the Debian guest to be able to access the web server running on the Ubuntu host (e.g. I just type my browser http://localhost:8080/under Debian ). How can

VirtualBox: Make the host OS and the guest OS talk to each other

acapa As I said in the title, I want to access the VM via ssh from the host OS and vice versa (both OS are ubuntu; host is 10.10, guest is 9.10) To do this, I configured a bridged NIC on the client machine, connected it to my physical eth0 NIC, and statically

VirtualBox guest OS accesses local server on host OS

motto On my Ubuntu host, I have a local web server. I installed VirtualBox and Debian as a guest. I want the Debian guest to be able to access the web server running on the Ubuntu host (e.g. I just type my browser http://localhost:8080/under Debian ). How can

VirtualBox guest as Nginx host

Massin I installed VirtualBox 4.3.12 with Fedora 20 and nginx 1.4.7. The machine has a bridged network interface and can be pinged in two ways: from the host (Windows 7) using ping 192.168.0.15(IP address of the virtual machine) and from the guest machine ping

Host and guest are shared in Virtualbox

Mascarpone cheese Since Ubuntu 11.10 uses a new kernel, it's hard to get decent support for virtualization. VirtualBox doesn't support guest additions for ubuntu 11.10, so I definitely can't copy back and forth between the ubuntu desktop and windows, and FreeB