【发布时间】:2014-01-25 13:07:17
【问题描述】:
我不小心删除了我的程序的 Lucence 索引文件夹。当我运行我的程序时,它显示为...
Exception in thread "main" org.apache.lucene.index.IndexNotFoundException: no segments* file found in org.apache.lucene.store.MMapDirectory@M:\fbl\org.fazlan.lucene.ms.demo\src\main\resources\index2 lockFactory=org.apache.lucene.store.NativeFSLockFactory@cb17ecc: files: [write.lock, _0.fdt, _0.fdx]
at org.apache.lucene.index.SegmentInfos$FindSegmentsFile.run(SegmentInfos.java:801)
at org.apache.lucene.index.StandardDirectoryReader.open(StandardDirectoryReader.java:52)
at org.apache.lucene.index.DirectoryReader.open(DirectoryReader.java:66)
at org.apache.lucene.index.IndexReader.open(IndexReader.java:291)
at org.fazlan.lucene.demo.Searcher.<init>(Searcher.java:28)
at org.fazlan.lucene.demo.FileIndexApplication.main(FileIndexApplication.java:50)
我能做什么?我在互联网上搜索但找不到任何解决方案?有没有办法用删除的段文件重建索引?
【问题讨论】: