Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to expose on my local network a very simple Ruby server running on Linux.

server =, port)

My Linux VM runs on a NAT virtual network 192.168.73.X. The port I use is 1564 so I forwarded it using the "Virtual Network Editor" in VMware.

Then I use the as the hostname in my ruby code.

This works great and if I try to connect to my server from the host machine (including with the IP of my host machine

The problem is that I can't access it from an other computer on the network.

I'm guessing that the hostname needs to be changed but I have no idea what to put (except the IP of the host but ruby crashes when I do that). I also read that I needed to create a route in my linux but I can't figure out which one...

So I think that my question is: What route should I add to my linux in order to be able to put the IP address of the host in the host name?

Thank you for your help.

share|improve this question
up vote 1 down vote accepted

Ok I'm mad at myself... It was a simple Windows Firewall issue (the NAT was well configured and I didn't need to add a route).

To disable the firewall:

  1. Start
  2. Control Panel (small icons)
  3. Windows Firewall
  4. Turn Windows Firewall on or off (left column)

Thank everybody for the help.

share|improve this answer

If your virtual machine is NATed, then you have to connect to the host. And the host will redirect the traffic to the guest. No route, no firewall settings, nothing else. You have a vmare daemon which do the job.

If you fail to connect, this is because your host don't redirect the traffic.
Use netstat -anlptu to see if the vmvare daemon is binded to the 1564 port. If not, you have a misconfiguration problem with your vmware NAT.

SpacemanSpiff made me think about another problem: if your guest computer have several NICs, then you can have a routing problem. Not inside the host computer, but inside the guest.
Ensure your guest can reach computers on your local network. Use traceroute.
Either set the default route to the NATed NIC, either add a route to your local network via the NATed NIC.

share|improve this answer
The NAT is working fine I can connect on and it will work as long as I do it from the VM or the host machine. It just doesn't work with connection coming for other computer on the local network... I do think it's a route problem but I can't figure out the command I need to type to create the correct route. Thanks – Nicolas GUILLAUME Apr 15 '12 at 19:46
And I can ping my Gateway ( from the VM... – Nicolas GUILLAUME Apr 15 '12 at 19:51

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.