Reputation: 583
How can I connect two VMs within a network? I chose the option internal network for both of them, but no IP address was assigned to each VM.
This is what I obtained when doing the command ifconfig
:
NB: I am using virtualbox as hypervisor and 2 VMs (UBUNTU OS)
Upvotes: 1
Views: 12710
Reputation: 1
I'm not sure if this is what you're asking for, but I recently established a connection between two VM(both are Ubuntu), for chatting! I made both have their network settings attached to "bridged adapter", so their IPs were shown with "ifconfig". After that I used "netcat" tool for the connection.
Upvotes: 0
Reputation: 110
I prefer using the "NAT Network" type when connecting two guests to one another, since it essentially combines the features of the NAT and Internal Network options. If that sounds like what you want, these steps should get you there, otherwise you can skip them.
If you want to stick with the internal network option, I believe you can simply set the IP manually from your guest OS - in Ubuntu go to System Settings→Network, select your adapter (most likely called "Wired"), then hit Options, and enter your desired IP configuration under "IPv4 Settings." After that point the guest machines should be able to find each other at their self-defined IP addresses. (I seem to remember that working for me before, but it's been a while since I've tried it, so let me know if that doesn't work.)
You can read more here and here.
Upvotes: 0