Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm on a private network but I need to access on an external site hosted in a Virtual Machine. When I was in the public network I edited the hosts file(%windir%\Windows\System32\drivers\etc\hosts) present in my Windows O.S. and add an entry with , so then I can see the site. But now this does not works, because I have an error returned by the browser: "DNS error: host not found"

Someone know what is the procedure to follow in order to access to the site?

Thanks in advance!!!

share|improve this question
    
You should add the external IP of the server along with the name you use to connect to it. If this doesn't work, the issue is probably related to some other, networking or configuration issue. Can you please provide more details about the environment? –  Vick Vega Mar 30 '11 at 14:52
    
What you mean for: "You should add the external IP of the server along with the name you use to connect to it." ? I have already added the external IP along with the name. The environement is a Windows 7 O.S. and all other information that I usually use for access to the site are present in my original post. Thanks! –  carlo Mar 30 '11 at 14:55
    
Can you ping the name you added? –  Vick Vega Mar 30 '11 at 15:04
    
NO, I'm not able. –  carlo Mar 30 '11 at 15:11
    
Can be various reasons, IP is not actually available to connect to. Firewall, server down, e.t.c –  Vick Vega Mar 30 '11 at 15:20

1 Answer 1

up vote 0 down vote accepted

check if you can reach the site from your private network.

run ->  cmd
telnet my_site_on_public_vm port_where_you_run
example
telnet 1.1.1.1  80

if there is an error you just established that you can't reach the site even via ip address. so you need to work on it.

to fix your dns problem is exactly what you have done before - add the ip name of the site into the hosts file.

ps: ping is not the tool you want to use for the simple reason that the server my refuse ping requests because it has a firewall or there is a firewall blocking ping in between

share|improve this answer
    
Ping can tell you if the DNS was looked up correctly, but a firewall can be configured to drop ICMP and allow HTTP for example, so it is not a fully definitive test. –  Nate Jul 1 '11 at 22:50
    
then use telnet my.host.configured.into.etc.hosts port (this will validate the /etc/hosts host) - i understand your point about ping but ping does just half of job ... –  silviud Jul 14 '11 at 14:38

Your Answer

 
discard

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.