Is flock() necessary on a simple file append?
| From: | Kevin Grigorenko | Date: | Sun, 24 Oct 2004 22:11:19 +0000 |
| Subject: | Is flock() necessary on a simple file append? | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-200201@lists.php.net to get a copy of this message | ||
Hi,
I am appending to a file one line of text on every page hit, so there could
be many occurrences of this append simultaneously. I am not opening for
write ("w") but for append ("a"). Do I need to use flock() to be sure there
are no issues? I am running on Solaris.
Thanks,
Kevin