>From: "Sergey Rusakov" <[EMAIL PROTECTED]> > 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?
This is OS dependent. Most unix type systems perform an atomic seek-to-end-of-file along with the write when you have opened in append mode, so as long as the writes are small enough to complete in one operation concurrency is not an issue. It doesn't work over NFS when writing from multiple machines and it probably doesn't work the same way on Windows. Les Mikesell [EMAIL PROTECTED]