I just tried to optimise my index, using the lucli command line client, and got:
--------8<--------
lucli> optimize
Starting to optimize index.
java.io.IOException: Cannot overwrite:
/mnt/sdb1/lucene-index/index-1/_2lhqi.fnm
at
org.apache.lucene.store.FSDirectory.createOutput(FSDirectory.java:322)
at org.apache.lucene.index.FieldInfos.write(FieldInfos.java:255)
at
org.apache.lucene.index.SegmentMerger.mergeFields(SegmentMerger.java:176)
at
org.apache.lucene.index.SegmentMerger.merge(SegmentMerger.java:88)
at
org.apache.lucene.index.IndexWriter.mergeSegments(IndexWriter.java:707)
at
org.apache.lucene.index.IndexWriter.mergeSegments(IndexWriter.java:684)
at
org.apache.lucene.index.IndexWriter.optimize(IndexWriter.java:543)
at lucli.LuceneMethods.optimize(LuceneMethods.java:192)
at lucli.Lucli.handleCommand(Lucli.java:223)
at lucli.Lucli.<init>(Lucli.java:148)
at lucli.Lucli.main(Lucli.java:175)
--------8<--------
It isn't a permissions issue - there are read+write permissions on
_2lhqi.fnm for the user. Does that mean that I have a file called
_2lhqi.fnm, which shouldn't be there - possibly from a previous attempt to
optimise the index, which got interrupted?
Bearing in mind that the index is 4 million documents, I'm reluctant to
re-index everything. If temporary files persist after an interrupted
optimize(), what's the wise/expedient thing to do under these circumstances?
smime.p7s
Description: S/MIME cryptographic signature
