Posted by: pkr_kancha October 9, 2017
To linux and devops gurus
Login in to Rate this Post:     1       ?         Liked by
Solution 1: Edit your hosts file on you local PC as admin

start --> CMD --> right click and run as admin --> cd drivers/etc --> notepad hosts --> add a line at the bottom describing your IP and hostname(alias). It should look like this:

192.168.78.xx (your Ip for VM) testVM(hostname)

save this file --> try pinging using hostname

Solution 2: modify your hosts file on VMs

from linux terminal --> vi /etc/hosts --> add IP of your another VM and hostname there

192.168.78.xx testVM1(hostname)

Hope this helps.
Read Full Discussion Thread for this article