RE: Concurrenty access to a log file!!!

2000-12-08 Thread Jerrad Pierce

If you use Apache's logging facilities (say for level debug). Apache will
handle the concurrency/serializing for you.

You might also look at using syslog

-Original Message-
From: Edmar Edilton da Silva [mailto:[EMAIL PROTECTED]]
Sent: Friday, December 08, 2000 2:46 PM
To: [EMAIL PROTECTED]
Subject: Concurrenty access to a log file!!!


Hi all,

I have installed on my machine the mod_perl module and 
exists a lots
perl scripts running under mod_perl. I am doing some tests and I need
that all call to these perl scripts write in a log file. How can there
are a lots scripts running to the same time, I need to control the
processes of write. Please, can anyone give me any hint about it? Is
there any doc on the Internet that I can use? Thanks for all help...


Edmar Edilton da Silva
Bacharel em Ciência da Computacão - UFV
  Mestrando em Ciência da Computacão - UNICAMP





-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: Concurrenty access to a log file!!!

2000-12-08 Thread Stas Bekman

On Fri, 8 Dec 2000, Edmar Edilton da Silva wrote:

 Hi all,
 
 I have installed on my machine the mod_perl module and exists a lots
 perl scripts running under mod_perl. I am doing some tests and I need
 that all call to these perl scripts write in a log file. How can there
 are a lots scripts running to the same time, I need to control the
 processes of write. Please, can anyone give me any hint about it? Is
 there any doc on the Internet that I can use? Thanks for all help...

http://perl.apache.org/guide/debug.html#Critical_Section


_
Stas Bekman  JAm_pH --   Just Another mod_perl Hacker
http://stason.org/   mod_perl Guide  http://perl.apache.org/guide 
mailto:[EMAIL PROTECTED]   http://apachetoday.com http://logilune.com/
http://singlesheaven.com http://perl.apache.org http://perlmonth.com/  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: Concurrenty access to a log file!!!

2000-12-08 Thread Marc Spitzer

I don't know if this helps but when you log something add the process ID to
the log message.  Then you should be able to trace what process is running
what, look at :
http://httpd.apache.org/docs/mod/mod_log_config.html#formats
to tell you how to set up custom log formats, %p gives you the pid, there
are some other things that could be useful to you as well.  And just use
Apache's standard logging.

marc

- Original Message -
From: Edmar Edilton da Silva [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, 8. December 2000 14:46
Subject: Concurrenty access to a log file!!!


 Hi all,

 I have installed on my machine the mod_perl module and exists a lots
 perl scripts running under mod_perl. I am doing some tests and I need
 that all call to these perl scripts write in a log file. How can there
 are a lots scripts running to the same time, I need to control the
 processes of write. Please, can anyone give me any hint about it? Is
 there any doc on the Internet that I can use? Thanks for all help...

 
 Edmar Edilton da Silva
 Bacharel em Ciência da Computacão - UFV
   Mestrando em Ciência da Computacão - UNICAMP
 





-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: Concurrenty access to a log file!!!

2000-12-08 Thread Stas Bekman

On Fri, 8 Dec 2000, Jerrad Pierce wrote:

 If you use Apache's logging facilities (say for level debug). Apache will
 handle the concurrency/serializing for you.

If I remember correctly only if the size of a single
warn/print(STDERR,...)  4k, if you are talking about manually logging
thru STDERR.



_
Stas Bekman  JAm_pH --   Just Another mod_perl Hacker
http://stason.org/   mod_perl Guide  http://perl.apache.org/guide 
mailto:[EMAIL PROTECTED]   http://apachetoday.com http://logilune.com/
http://singlesheaven.com http://perl.apache.org http://perlmonth.com/  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: Concurrenty access to a log file!!!

2000-12-08 Thread Jerrad Pierce

There's not Apache::: API for hooking into logging?

AFAIK (which isn't to say much) it seems children pass logging information
back to the
initial process in some queue, et voila?

And that 4k when likely be dependent on the kernel filehandle buffer.
Which yes, is 4k on your typical x86...
-Original Message-
From: Stas Bekman [mailto:[EMAIL PROTECTED]]
Sent: Friday, December 08, 2000 3:51 PM
To: Jerrad Pierce
Cc: mod_perl list
Subject: RE: Concurrenty access to a log file!!!


On Fri, 8 Dec 2000, Jerrad Pierce wrote:

 If you use Apache's logging facilities (say for level 
debug). Apache will
 handle the concurrency/serializing for you.

If I remember correctly only if the size of a single
warn/print(STDERR,...)  4k, if you are talking about manually logging
thru STDERR.



_
Stas Bekman  JAm_pH --   Just Another mod_perl Hacker
http://stason.org/   mod_perl Guide  http://perl.apache.org/guide 
mailto:[EMAIL PROTECTED]   http://apachetoday.com http://logilune.com/
http://singlesheaven.com http://perl.apache.org http://perlmonth.com/  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]