Rename bug?
Leslie Mikesell
les at chinet.UUCP
Sat Jun 4 07:10:10 AEST 1988
In article <22180 at labrea.Stanford.EDU> karish at denali.stanford.edu (Chuck Karish) writes:
>
> In article <5730 at chinet.UUCP> les at chinet.UUCP (Leslie Mikesell) writes:
> This leaves an interval between unlink("xx") and link("TMP4653","xx")
> when an attempt to open("xx") will fail. I work with a system that
>Why not have each program that uses the shared files lock them
>while they're in use?
Well, some of the programs are "cat", "pg", "compress", "uucp" and a print
spooler as well as my interactive access program. But the real reason
I didn't consider locks is that the 10 minute updates cannot be deferred
until no one happens to be reading the previous copy. I suppose I could
make a copy each time someone reads a file which would limit the time the
file needs to be locked, but that would cause a real performance problem.
This is currently running on a 3B2 (actually 2 of them with the files
duplicated over RFS) and the updating machine stays pretty busy now.
Trying the open() twice seemed like the only reasonable thing to do,
although it does take a bit longer to respond to invalid requests.
How do other people deal with files that are frequently updated?
Les Mikesell
More information about the Comp.unix.questions
mailing list