perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sebastiaan Hoogeveen <s.hoogev...@nederhost.nl>
Subject Re: changing apache process name?
Date Tue, 01 Sep 2009 20:28:12 GMT

On 1 sep 2009, at 19:43, mcvella wrote:

> I am wondering if anyone knows if there is a way to configure what  
> it shown
> as the running apache process name.  I am not sure if this is  
> technically a
> mod_perl question.  The problem is that the process name is partially
> truncated, so we are unable to determine exactly what perl app is  
> running
> for a given apache process.
>
> For example, here is one running apache process as seen in top:
>
> 31122 www       16   0 76624  61m 6428 S    6  0.4   0:04.03
> /opt/myapp/www/cgi-perl/sig -f /opt/c2/preview/tmp/httpd.conf
>
> there is more to the perl app name than 'sig', (for example, it  
> could be
> signal.pl or signoff.pl) but it is truncated.
>
> Is there any way to configure apache to show more characters in its  
> process
> names?


Not sure if this would fix your problem, but you can just set $0 from  
within the mod_perl module to whatever you'd like to show up in the  
process list, just as with a regular perl script. It probably depends  
on the OS you're running whether this works as it should; I can  
confirm that it works on Linux.

You could probably use some wrapper code or write a handler to set $0  
to the name of the script or module that is executed.

Kind regards,

-- 
Sebastiaan Hoogeveen
<s.hoogeveen@nederhost.nl>

NederHost is ingeschreven bij de Kamer van Koophandel onder dossier  
34099781.




Mime
View raw message