0

I'm trying to read a file, using a URL, however I keep getting a 504 Gateway Timeout.

The user submits an form, and I need to grab some information from a rather large xml file (45mb), using an XmlTextReader. However each time the request is made, it comes back with a 504 Gateway Timeout on one server, however it works fine on another server. The 504 error is thrown after about 20 seconds, however on the other server, where it does work, the file is read much faster than that.

XmlTextReader reader = new XmlTextReader(localUrl);

The strange issue is that IIS is not even logging this request. I've gone through the logs and I can find the entry in the system that works, however in the system that doesn't work, there is no request in the IIS logs. Making it look like its not even hitting IIS.

Lex
  • 879
  • 3
  • 16
  • 27
  • 2
    proxy? can you open up a browser directly on that server and would that download the file, given the same URL, running as the same user? – Cee McSharpface Feb 10 '17 at 13:16
  • Thank for that, I completely forgot to check the name it was running under. Once I logged in with the user the apppool is running under, I found that the proxy settings were different from the other server. After updating that, it started to work. – Lex Feb 10 '17 at 13:35

1 Answers1

0

It seems the problem is that the user the AppPool is running under had its proxy settings set up incorrectly, therefore it was unable to make the call that it needed to make.

Once I corrected the proxy settings for that user, it started to work.

Lex
  • 879
  • 3
  • 16
  • 27