how to see /server-status when at MaxClients?

2002-05-10 Thread John E. Leon Guerrero

if a job hangs (due to database locking for instance), then a mod_perl child
will hang as well (absent some additional watchdog-type program.)  if enough
jobs hang to the point that we hit MaxClients, then it is too late to use
/server-status to see what jobs hung.

does anyone have a quick way to indentify the jobs that are currently
running?  i thought of getting a core and using gdb but i was hoping to find
a faster way.  it would be nice if we could reserve a couple of children for
administrative emergencies such as this.

thanks,
jlg

John Leon Guerrero -- http://www.live365.com





mod_perl restart vs. graceful

2002-04-08 Thread John E. Leon Guerrero

i'm interested in understanding the consequences of restart vs. graceful
better.

i've seen where the mod_perl guides recommend stopping and then restarting a
mod_perl apache rather than doing a graceful restart.  i only saw
indications that memory does not get cleaned up cleanly if this is done.

my operations group does graceful restarts for the sole purpose of rotating
logs.  their method has the beauty that apache continues to run after the
graceful (very important when automated jobs are playing with your website
at midnight when no employee is watching the system.)  we could change the
script to do a stop then restart, but we've seen where this method (done
manually) was not 100% reliable and would sometimes require a couple of
stops before we could really restart apache (never understood why this was
so.)  if there is sufficient reason to move to a hard stop/restart, then i
suppose we could make the job retry like 5 times and then email a pager if
there continues to be a problem.  i just need ammunition if i am to
jeapordize my operations group's sleep for yet another reason.

can anyone elaborate?  thank you,
jlg

John Leon Guerrero -- http://www.live365.com





general timeout for mod_perl scripts?

2002-04-01 Thread John E. Leon Guerrero

i would like to prevent any of my mod_perl scripts from running longer than
5 seconds.  is there an elegant way to make a general timeout that does not
require changing all my scripts?  i run both Registry and Mason scripts in
my environment.

thank you in advance,
jlg

John Leon Guerrero -- http://www.live365.com





RE: Blank pages

2002-03-04 Thread John E. Leon Guerrero

i ran into a number of similar problems that did not seem to be documented
anywhere else.  in my case, we had a number of scripts that would change
STDOUT in some fashion (usually so they could set $|) but then die due to
some error before resetting STDOUT back.  then any mod-perl script that the
child would serve would produce a blank page while static files would
continue
to be served cleanly.  when that child died, the problem would go away.  if
a
user refreshed and got another child, then it would appear as if the problem
went away.

i added the PID to the access logs and watched for any HTTP 200's with zero
length
body sizes and traced backwards to see who the common culprit was.  the only
caveat was that apache would sometimes log HTTP 200 when in fact the return
code
was HTTP 302 (redirect).  it is natural to have a zero length body size for
a
redirect.

good luck,
John E. Leon Guerrero

 -Original Message-
 From: Axel Andersson [mailto:[EMAIL PROTECTED]]
 Sent: Friday, March 01, 2002 5:40 AM
 To: [EMAIL PROTECTED]
 Subject: Blank pages


 Hi,
 I run a mod_perl/mysql site, which works fine most of the time. Some
 pages, however, come out completely blank. Reload.. and hey presto, it
 works. Now, I realize this could be practically anything, so I'm just
 asking if anyone has come across something similar.

 I use Apache::DBI 0.88 for database connections, Apache 1.3.23 and
 mod_perl/1.2. Strange thing is, nothing shows up in the error log, even
 using -w.

 Well, it's a longshot, but thanks anyway.

 Axel Andersson

 --
 [EMAIL PROTECTED]
 http://www.animanga.nu/morris/

 31. With intagible breath in center of forehead, as this reaches heart at
 the moment of sleep, have direction over dreams and over death itself.