Solved

502 Bad Gateway error when trying to download a file from my local web server

Posted on 2004-08-13
6
2,884 Views
Last Modified: 2012-05-05
This is weird.  When clicking on a link to download a file on a local web server (one on our lan) and the file resides on the web server itself, I get:
 "CGI Error  The specified CGI application misbehaved by not returning a complete set of http headers. The headers are:  (nothing listed)"
When I sniffed the packets the http code was a "502 bad gateway error"
After looking this up, it mentions things about gateway/proxy.  This server does neither of those functions, and the file I am trying to download is on the same server that IIS5.0 is running on.  Permissions to this file have not changed and it worked a week ago.  

Help!!
0
Comment
Question by:ttruka
  • 3
  • 2
6 Comments
 
LVL 16

Expert Comment

by:Sohel Rana
ID: 11796800
Hi:

According to the Internet Errors and FAQs :
http://www.griffin.peachnet.edu/oit/wwwfaqs.htm#502

---------------------
502 - Bad gateway - A server (not necessarily a Web server) is acting as a gateway (or a type of routing device) to fulfill the request by the client (e.g. your Web browser) to access the requested Web page. An invalid response was received from an upstream server it accessed to fulfill the request. This usually does not mean that the upstream server is down (no response to the gateway), but rather that the upstream server and the gateway do not agree on the protocol for exchanging data. Given that Internet protocols are quite clear, it often means that one or both machines have been incorrectly or incompletely programmed.
The first thing to try when you receive this error is simply to wait a few minutes and try again.  If you are unsuccessful the second time there is nothing you can do other than to contact the person responsible for the website to let them know that you received the error.

---------------------

rsdn

0
 

Author Comment

by:ttruka
ID: 11796871
I am the one responsible for the web site.  IIS 5.0, the file I am trying to download, and the web page files themselves are all on the same box.  There is no redirect at all for this link.
Confused.
0
 
LVL 10

Expert Comment

by:avidya
ID: 11798964
Hi,

do you have an cgi handeling your downloads and do you have read/write rights for the directory the cgi ?

if so, try just plain html for the download and see if that works.

The past weeks there where several security patches and fixes, maybe you have installed them and the are influensing your websites behavior?
0
Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

 
LVL 10

Accepted Solution

by:
avidya earned 250 total points
ID: 12116224
Hi,

Would you be so kind respond to the suggestions?
0
 

Author Comment

by:ttruka
ID: 12116280
Sorry!!  Somtimes I get too focused and forget to thank whoever helped.  The suggestions you provided were correct.  I did not have the correct permissions granted to the directory.  After I set that up, everything worked great!!

Sorry again!

Thanks so much for your help.

0
 
LVL 10

Expert Comment

by:avidya
ID: 12116314
Hi ttruka,

No harm done, glad to be of help
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Boost your ability to deliver ambitious and competitive web apps by choosing the right JavaScript framework to best suit your project’s needs.
Color can increase conversions, create feelings of warmth or even incite people to get behind a cause. If you want your website to really impact site visitors, then it is vital to consider the impact color has on them.
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to count occurrences of each item in an array.

773 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question