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 am sending requests to a specific server on a cloud:

wget --header="Host: example.com" http://x.x.x.x:80/
curl -i -H"Host: example.com" http://x.x.x.x:80/

And it returns exactly as expected (a simple static file). However, when I try and access it in a browser, the request times out. I can't imagine it would be a user agent header issue, but then again, I don't really know what else it would be.

It isn't going to a load balancer or anything, should be going directly to the site. Any ideas on why this might be happening? I have my hosts file set to go to that specific IP address.

Thanks

share|improve this question
    
Most likely, the browser is ignoring the hosts file and is not connecting to the IP address you are expecting it to. –  David Schwartz Jul 11 '12 at 16:08
    
what does curl -i example.com return? –  vartec Jul 11 '12 at 16:21
    
Is the browser configured to use a proxy? –  Aaron Copley Jul 11 '12 at 16:35
add comment

2 Answers

You need to look at the server to find out.

Can you see a request coming in to the webserver? (is there a tcp socket opened?)

What does the web server software log about the connection? Can you make it more verbose if it's not saying enough.

Failing that, tell us more about your webserver and its config.

share|improve this answer
add comment

Thanks everyone. It turns out there was an setting overriding the request, sending it to a new port that wasn't opened by the firewall...

share|improve this answer
add comment

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.