lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cristian Vat <>
Subject problem during index merge
Date Wed, 20 Oct 2010 18:45:39 GMT

I've been running into a problem during a merge. Would appreciate
knowing what to look for since the exception doesn't seem too

I get:
--- Nested Exception --- background merge hit exception: _2p:c695204
_2q:c93106 into _2r [optimize] [mergeDocStores]
	at org.apache.lucene.index.IndexWriter.optimize(
	at org.apache.lucene.index.IndexWriter.optimize(
	at org.apache.lucene.index.IndexWriter.optimize(
	...application code...
Caused by: org.apache.lucene.index.CorruptIndexException: docs out of
order (64570 <= 64570 )
	at org.apache.lucene.index.FormatPostingsDocsWriter.addDoc(
	at org.apache.lucene.index.SegmentMerger.appendPostings(
	at org.apache.lucene.index.SegmentMerger.mergeTermInfos(
	at org.apache.lucene.index.SegmentMerger.mergeTerms(
	at org.apache.lucene.index.SegmentMerger.merge(
	at org.apache.lucene.index.IndexWriter.mergeMiddle(
	at org.apache.lucene.index.IndexWriter.merge(
	at org.apache.lucene.index.ConcurrentMergeScheduler.doMerge(
	at org.apache.lucene.index.ConcurrentMergeScheduler$

I have two indexes, first I delete some documents from the second one
and then use IndexWriter.addIndexesNoOptimize() and
IndexWriter.optimize() to add all of the first index to the second
Everything works fine if I don't call optimize()
Using lucene 2.9.3. I get the same problem on windows and linux with
different java versions.

Also, the same code ran without problems for some months, but today
with the indexes I have it consistently fails.

I opened the target index with Luke and ran Check Index and I do get
an error but I don't know exactly what causes it:
 test: terms, freq, prox...ERROR [term fulltext:instructions: doc
260628: pos -405712460 is out of bounds]
java.lang.RuntimeException: term fulltext:instructions: doc 260628:
pos -405712460 is out of bounds
	at org.apache.lucene.index.CheckIndex.testTermIndex(
	at org.apache.lucene.index.CheckIndex.checkIndex(
	at org.apache.lucene.index.CheckIndex.checkIndex(
	at org.getopt.luke.Luke$ Source)

Thanks for any help.
Cristian Vat

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

View raw message