Why is TCP/IP networking working so strangely with Linux guests?

Discussions about using Linux guests in VirtualBox.

Why is TCP/IP networking working so strangely with Linux guests?

Postby GeorgeRT » 6. Mar 2019, 05:57

I have a Windows 10 laptop that has a wireless network connection. I have a few Oracle VirtualBox VMs. Each VM is running Ubuntu 18.04. Their /etc/hosts files map their host names to their forwarding IP addresses (as configured in Oracle VirtualBox in the Network Adapter section). If I use ssh, ssh-keyscan, or nmap with their IP addresses from a different Linux VM, the result is consistent with the remote IP address being substituted with So if I do this ssh@ from the server at, it will connect to In fact, it will say "last connected from" once I connect. If I am on the VM at, and I do this "nmap -Pn", I will see the results of "nmap -Pn". The ssh-keyscan results do have an IP address that changes based on what IP address I use with an ssh-keyscan command. But all the rest of the output does not change. Why are the remote IP addresses "resolving" to I have seen DNS names resolve incorrectly. I have not seen IP addresses "resolve" to

This problem is 100% reproducible, and I have never had normal TCP/IP networking working on the VMs among themselves. They have access to the internet (after I run a "sudo ip route add..." command). I have tried many different network adapter settings for the VMs of Oracle VirtualBox (using the GUI).
Posts: 13
Joined: 21. Jan 2017, 16:31

Re: Why is TCP/IP networking working so strangely with Linux guests?

Postby ghr » 9. Mar 2019, 18:04

Sounds complicated... What I did is this (and I get networking from the VM to host/outside world):
  • make fresh Ubuntu 18.04 VM
  • edit /etc/samba/smb.conf by adding 'client max protocol = NT1' below the 'workgroup =' line
  • use command 'testparm' to check your edits
  • sudo systemctl restart smbd
In this way I can connect to the outside world, e.g. Ubuntu 14 or Windows 10. I cannot tell if this will work for you though because my setups allow even DOS VMs to connect.
Setting up a share inside the VM is more/too complicated; I can get that to work but the method seems overdone...
Posts: 335
Joined: 25. May 2007, 22:46
Primary OS: MS Windows 7
VBox Version: PUEL
Guest OSses: DOS, Win3x, Win95, WinXP, Ubuntu, OS/2

Return to Linux Guests

Who is online

Users browsing this forum: No registered users and 12 guests