lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Shawn Heisey <apa...@elyograg.org>
Subject Re: 6.4.0 collection leader election and recovery issues
Date Thu, 02 Feb 2017 14:41:56 GMT
On 2/2/2017 7:23 AM, Ravi Solr wrote:
> When i try to rollback from 6.4.0 to my original version of 6.0.1 it now
> throws another issue. Now I cant go to 6.4.0 nor can I roll back to 6.0.1
>
> Could not load codec 'Lucene62'.  Did you forget to add
> lucene-backward-codecs.jar?
>     at org.apache.lucene.index.SegmentInfos.readCodec(SegmentInfos.java:429)
>     at
> org.apache.lucene.index.SegmentInfos.readCommit(SegmentInfos.java:349)
>     at
> org.apache.lucene.index.SegmentInfos.readCommit(SegmentInfos.java:284)
>
> Hope this doesnt cost me dearly. Any ideas at least on how to rollback
> safely.

This sounds like you did some indexing after the upgrade, or possibly
some index optimizing, so the parts of the index that were written (or
merged) by the newer version are now in a format that the older version
cannot use.  Perhaps the merge policy was changed, causing Solr to do
some automatic merges once it started up.  I am not aware of anything in
Solr that would write new segments without indexing input or a merge
policy change.

As far as I know, there is no straightforward way to go backwards with
the index format.  If you want to downgrade and don't have a backup of
your indexes from before the upgrade, you'll probably need to wipe the
index directory and completely reindex.

Solr will always use the newest default index format for new segments
when you upgrade.  Contrary to many user expectations, setting
luceneMatchVersion will *NOT* affect the index format, only the behavior
of components that do field analysis.

Downgrading the index format would involve writing a custom Lucene
program that changes the active index format to the older version, then
runs a forceMerge on the index.  It would be completely separate from
Solr, and definitely not straightforward.

Thanks,
Shawn


Mime
View raw message