3
3
3da2018-10-20 13:43:05
IIS
3da, 2018-10-20 13:43:05

Where are CGI script logs written in IIS?

I am using IIS to run CGI scripts written in python. (namely hgweb.cgi)
But if something goes wrong while executing the script, IIS logs very limited information to the log:

2018-10-20 10:14:52 W3SVC1 ::1 POST /hgweb.cgi/ cmd=unbundle 9000 - ::1 mercurial/proto-1.0+(Mercurial+4.1.3) - localhost:9000 502 2 1 295

Error 502. But what caused it? Most likely the CGI script will output an error to stderr. But where can you see it?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
3
3da, 2018-10-20
@3da

My solution:
https://docs.python.org/2.0/lib/node246.html
I redirected stderr to stdout and put a try catch in the script. It looks like a hack, but it works.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question