lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Malo Pichot <>
Subject windows locking file problem
Date Fri, 19 Jun 2009 07:15:16 GMT

I know a similar subject has been discussed in this list and this is not
a "windows file system" list ;-) But may be someone have encountered the
"thing"... and perhaps solved it !

I have a web application that index many documents so I have a quite
large Lucene (2.2) index (~ 350 Mo) managed by a FSDirectory. The
indexation (I mean writing in indeces) is done by batches. Each batch
works first in a RAMDirectory, wich is merged with the main index in a
third one (a temporary FSDirectory). When the merge is done, the
application have to replace the main index (untouched until this time).
Here comes the problem ! To replace, the application close the searcher,
then the FSDirectory itself. After that, the application delete all
files of the main index and then copy all files of the temporary index
in place, before re-open the FSDirectory, generate searcher, etc.

All that is good in Linux environment, and in Windows most of the time.
Yeap ! sometimes, windows FS refuses the deletion of the main index
files. Th only way I found to force windows FS unlocking those files is
to stop the servlets server (Tomcat). I can't shutdown Tomcat during the
indexation work.

I don't know how to solved that :-(

Does anyone get inspiration ?


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message