Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I am trying to use wget to debug and issue I am having. I have a remote machine from one server trying to reach query.json and it works fine, connects and downloads fine. I have another remote machine trying to reach the same location and I get this:

[root@test ~]# wget http://testsite.com/query.json
--20:49:55--  http://testsite.com/query.json
Resolving testsite.com... aaa.bbb.ccc.ddd
Connecting to testsite.com|aaa.bbb.ccc.ddd|:80... connected.
HTTP request sent, awaiting response... 404 Not Found
20:49:55 ERROR 404: Not Found.

I have turned off the firewall temporary and that does not help. It looks like it is connecting to the machine (I have verified with traceroute that both machines are making it to the server), it just cant find the file, but I am sure it is there because it works with my other remote machine. Anyone know what could be causing this?

Thanks.

share|improve this question
    
Silly question: If you open that url in a browser, do you get a 404? –  Doc Aug 1 '12 at 22:10
add comment

1 Answer

up vote 0 down vote accepted

Check the HTTP server error logs - these often give more detail. Compare successful and unsuccessful entries in the HTTP server access logs.

share|improve this answer
    
The error log does not show any new logs. The access log shows a POST every time it is contacted by the working machine. Nothing shows up in the log when contacted by the non-working machine. –  yellavon Aug 7 '12 at 22:26
    
Even though the logs did not show an error, the access log allowed me to see it wasn't even hitting the machine. I found out in /etc/hosts I was resolving an incorrect hostname to the IP. Even though the message was sent to the correct IP, I guess the DNS did not like the incorrect hostname that may have been in the headers. –  yellavon Aug 8 '12 at 21:23
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.