Thanks Bill.
To be honest, I don't know why we use windows, it does make some things
quite difficult. It's just that they've had it running on a windows box
for a long time, and the switching cost is too high. Not in terms of money
but other things. Eventually, we might switch, but until then, it's
windows with all its problems.
I don't know what people "normally" do in this kind of situation on
Windows. However, I found a solution which works fine. I use a different
index file name during indexing, which is not accessed from the web
search. When indexing is finished, I open a lock file in blocked exclusive
mode, and copy the files across. This means the open blocks until
exclusive access is granted. The search on the web site opens this lock
file in unblocked shared mode before every query, such that several users
can use the site at the same time, but not at the same as the file is
copied. If the file is being copied, the unblocked open returns false, and
I give an error page which reloads itself after a few seconds.
This does the job, but if anyone else has a better suggestion, I am
listening.
Jonas
Received on Tue Aug 31 07:22:48 2004