Figured out solution while back: You need to configure your network card option to not be a shared network with your native OS, but instead its own network. For Parallels on OSX I use WiFi Bridged as my VM network option, and this then gives my VM a ip address from the same pool and on the same subnet as my desktop.
Originally posted by l0g1x with karma: 1526 on 2016-01-24
This answer was ACCEPTED on the original site
Post score: 1
Original comments
Comment by gvdhoorn on 2016-01-25:
Not saying this isn't a valid workaround, but in my experience even host only or nat networks when used for host <-> VM comms give the VM an IP. Obviously NAT setups come with their own issues, but as long as the ROS Master listens on the 'host only' IP, I'd expect things to work (it's just IP).
Comment by gvdhoorn on 2016-01-25:
Also: I've re-opened the question, as even though we feel it has been answered now, it would be nice if future readers could still comment on it and / or provide additional answers.
Comment by l0g1x on 2016-01-27:
As far as parallels goes, if the network is specified as 'shared' meaning the VM does not have its own IP address on the same subnet as the machine hosting the VM then I dont think you would be able to ping the VM from a separate desktop unless you maybe setup some port forwarding on parallels
Comment by l0g1x on 2016-01-27:
I dont see any way to setup the port forwarding however. The scenario described above is what happened to me. I could ping my desktop computer from my VM, but could not ping the VM from my desktop. It makes sense to me that it would act that way as the desktop would have no route to get to the VM
Comment by gvdhoorn on 2016-01-27:
According to Network Settings in the user guide (of v6, but ok), 'shared networking' is essentially NAT, so that would require port forwarding (not nice). 'Host only' should work though, as it uses plain IP.
Comment by gvdhoorn on 2016-01-27:\
It makes sense to me that it would act that way as the desktop would have no route to get to the VM
I don't have real experience with Parallels, but depending on the way 'host only' is configured at the IP level, adding routes between the two networks could work (but then, why use 'host only').
Comment by l0g1x on 2016-01-27:
Yes, Host only is what I had to use and it worked. Here is the doc for Port Forwarding. I havent tried it myself though, so it seems possible for both shared and host only. It would be port 11311 right?
Comment by gvdhoorn on 2016-01-30:\
For Parallels on OSX I use WiFi Bridged as my VM network option
and
Yes, Host only is what I had to use and it worked.
I'm confused: my comment was triggered by your answer, where you wrote that you had to use bridged networking. That is different from host only.
Comment by l0g1x on 2016-02-02:
Sorry! I misinterpreted what you said when you said "Host only' should work though, as it uses plain IP." By 'plain ip' i thought you meant that the VM would get a ip from dhcp, as if it where an actual machine. Sorry about that!
Comment by l0g1x on 2016-02-02:
So to correct myself, I have never tried to setup my VM as 'Host only' and then setup port forwarding. I have only had success in specifying a bridged wifi network that allowed for my VM to then have an IP on the same subnet (192.168.x.x ) as my desktop i was trying to communicate with.
Comment by gvdhoorn on 2016-02-02:
With Host Only you cannot use port-forwarding afaik. It might be possible to setup routes between the host only network and your normal network, but that would depend on the VM solution you're using. Bridging definitely works.
Comment by gvdhoorn on 2016-02-02:
In any case: I'm glad you got things to work, but I'm not sure what you did is really related to the issue you reported.