lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael McCandless <>
Subject Re: CorruptIndexException when opening Index during first commit
Date Thu, 16 May 2013 17:47:07 GMT
Unfortunately this is expected behavior.

We tried to fix it in LUCENE-2812, but this fix was too dangerous and
could sometimes erase a good index (if transient IOExcs are happening,
e.g. due to file descriptor exhaustion) so we reverted back in
LUCENE-4738, so that indexExists will return true, and trying to open
an IndexReader will throw CorruptIndexException, when the first-commit
has started but not yet finished.

Mike McCandless

On Thu, May 16, 2013 at 10:45 AM, Geoff Cooney <> wrote:
> Hi,
> We're occasionally seeing a CorruptIndexException when a searcher is opened
> on a new index.
> When we see the exception, it looks like what is happening is that the
> searcher is opening the index after prepareCommit for segments_1 but before
> the commit is completed.  Because there is no prior commit to fall back to,
> lucene throws the CorruptIndexException.  Does this sounds feasible and is
> it a bug?  My expectation is that lucene would treat the index as
> nonexistent until the first commit is completed.
> We're running lucene 3.5.
> Cheers,
> Geoff

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

View raw message