how to connect 2 Virtual Machines with Virtualbox?

Discussions related to using VirtualBox on Windows hosts.
Post Reply
Dely
Posts: 2
Joined: 17. Aug 2018, 07:00

how to connect 2 Virtual Machines with Virtualbox?

Post by Dely »

Hi,

I have created 2 virtual machines (both Windows 10 64bit). I would like to share random folders between these 2 virtual machines in the explorer. I also wish to make an SSH connection between the 2 virtual PCs. I have already tried to put both of them on NAT, and even Bridge, but that does not seem to work. I also gave both the working group "WS-WORKGROUP". How can I connect both virtual machines? That they can share files with each other and thus "see" each other? And that I can test the SSH connection between the 2 virtual machines.
BillG
Volunteer
Posts: 5102
Joined: 19. Sep 2009, 04:44
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows 10,7 and earlier
Location: Sydney, Australia

Re: how to connect 2 Virtual Machines with Virtualbox?

Post by BillG »

I would use bridged mode. Is the host on a LAN with a DHCP server? If it is, everything should simply work without any changes. The vms will get their network config from DHCP and behave just like the other LAN machines when you use bridged.
Bill
Dely
Posts: 2
Joined: 17. Aug 2018, 07:00

Re: how to connect 2 Virtual Machines with Virtualbox?

Post by Dely »

I have also 2 adapters :
LAN-CONNECTION (automatically assign an ip address)
and
Virtualbox Host-Only Network that has a static ip adres and a subnetmask. Can you choose here also for DHCP (automatically assign an ip address) ? Will it work then?
The "bridge" connection, i have to set it to both virtual machines?
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: how to connect 2 Virtual Machines with Virtualbox?

Post by socratis »

Dely wrote:LAN-CONNECTION (automatically assign an ip address) and Virtualbox Host-Only Network
You are confusing the host's network cards, with the guest's settings. What BillG was referring to was to go to the VM settings and change the network mode from the default "NAT" to "Bridged". Go to "VM Settings" » "Network" » "Adapter 1" » "Attached to", change that to Bridged and in the "Name" select your host's network card.

Do not change your host's networking options...
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
Post Reply