I suppose that the question is actually if there is a
way to log when CGI (using ActivePerl) goes bad under
NT. Correct? I guess this is another "it depends" question.
To the best of my (limited) knowledge, this is much more of
a webserver issue than it is an OS issue. Since IIS is somewhat
tied up to NT (and vice-versa), consider the following:
- IIS The webserver spawns the process, which gobles
memory, CPU, the machine crawls to a halt, and before the script
can timeout, or write a bad line to the error logs, the server is dead. Sounds familiar? I've never
found a way around it, except for:
- Apache Acording to the documentation it runs as "experimental"
on the NT boxes, but it kicks IIS but when it comes to respecting the
process it spawned. Instead of using up all of the servers' CPU and memory,
it will promptly timeout the process, and return a 500 to the browser (after a
while). Since we are on the webserver comparison issue, may I also note that
Apache on NT implements SSI correctly, and not that sorry excuse for server-side
includes that MS named SSINC.DLL
Bottom line? There's probably some way to do it with IIS, but I'd drop it in favor
of a better webserver if possible. If it isn't possible, there must be some way to shorten
the timeout period by tweaking the registry or something of the sort. I prefered not to go
there. Trying to implement this from within the CGI sounds even more troublesome. If you're
going to open each and every script, you might as well track down the faulty one and remove
the infinite loop.
My US$0.02.
#!/home/bbq/bin/perl
# Trust no1!
-
Are you posting in the right place? Check out Where do I post X? to know for sure.
-
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
<u> <ul>
-
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible janitor
intervention).
-
Want more info? How to link
or How to display code and escape characters
are good places to start.
|