On Tue, 11 Jun 2002, Sergey Rusakov wrote: > open(ERRORLOG, '>>/var/log/my_log'); > print ERRORLOG "some text\n"; > close ERRORLOG; > > This bit of code runs in every apache child. > I worry abount concurent access to this log file under heavy apache load. Is > there any problems on my way?
You are correct to worry. You should use flock() to prevent your log file from becoming corrupted. See "perldoc -f flock()" for more details. -sam