So having tried all combinations of LUCENE_40, 41 and 42 we're still having no 
success in getting our indexes to load with Solr 4.2.1...

Any direction we can look into ? in our system the underlying data is very slow 
to re-index and would take an unreasonable amount of time at a customer site to 
wait for information to become available after an upgrade, so we're very 
hopeful there can be a way to upgrade a Lucene index "properly".

Thanks,
Elran

-----Original Message-----
From: Erick Erickson [mailto:erickerick...@gmail.com] 
Sent: Wednesday, May 22, 2013 2:25 PM
To: solr-user@lucene.apache.org
Subject: Re: Upgrade Solr index from 4.0 to 4.2.1

LUCENE_40 since your original index was built with 4.0.....

As for the other, I'll defer to people who actually know what they're talking 
about.

Best
Erick

On Wed, May 22, 2013 at 5:19 AM, Elran Dvir <elr...@checkpoint.com> wrote:
> My index is originally of version 4.0. My methods failed with this 
> configuration.
> So, I changed  solrconfig.xml  in my index to both versions: LUCENE_42 and 
> LUCENE_41.
> For each version in each method (loading and IndexUpgrader), I see the same 
> errors as before.
>
> Thanks.
>
> -----Original Message-----
> From: Elran Dvir
> Sent: Tuesday, May 21, 2013 6:48 PM
> To: solr-user@lucene.apache.org
> Subject: RE: Upgrade Solr index from 4.0 to 4.2.1
>
> Why LUCENE_42?Why not LUCENE_41?
> Do I still need to run IndexUpgrader or just loading will be enough?
>
> Thanks.
>
> -----Original Message-----
> From: Erick Erickson [mailto:erickerick...@gmail.com]
> Sent: Tuesday, May 21, 2013 2:52 PM
> To: solr-user@lucene.apache.org
> Subject: Re: Upgrade Solr index from 4.0 to 4.2.1
>
> This is always something that gives me a headache, but what happens if you 
> change <luceneMatchVersion> in solrconfig.xml to LUCENE_40? I'm assuming it's 
> LUCENE_42...
>
> Best
> Erick
>
> On Tue, May 21, 2013 at 5:48 AM, Elran Dvir <elr...@checkpoint.com> wrote:
>> Hi all,
>>
>> I have a 4.0 Solr (sharded/cored) index.
>> I upgraded Solr to 4.2.1 and tried to load the existing index with it. I got 
>> the following exception:
>>
>> May 21, 2013 12:03:42 PM org.apache.solr.common.SolrException log
>> SEVERE: null:org.apache.solr.common.SolrException: Unable to create core: 
>> other_2013-05-04
>>                 at 
>> org.apache.solr.core.CoreContainer.recordAndThrow(CoreContainer.java:1672)
>>                 at 
>> org.apache.solr.core.CoreContainer.create(CoreContainer.java:1057)
>>                 at 
>> org.apache.solr.core.CoreContainer$3.call(CoreContainer.java:634)
>>                 at 
>> org.apache.solr.core.CoreContainer$3.call(CoreContainer.java:629)
>>                 at 
>> java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:345)
>>                 at java.util.concurrent.FutureTask.run(FutureTask.java:177)
>>                 at 
>> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:482)
>>                 at 
>> java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:345)
>>                 at java.util.concurrent.FutureTask.run(FutureTask.java:177)
>>                 at 
>> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1121)
>>                 at 
>> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:614)
>>                 at java.lang.Thread.run(Thread.java:779)
>> Caused by: org.apache.solr.common.SolrException: Error opening new searcher
>>                 at org.apache.solr.core.SolrCore.<init>(SolrCore.java:822)
>>                 at org.apache.solr.core.SolrCore.<init>(SolrCore.java:618)
>>                 at 
>> org.apache.solr.core.CoreContainer.createFromLocal(CoreContainer.java:1021)
>>                 at 
>> org.apache.solr.core.CoreContainer.create(CoreContainer.java:1051)
>>                 ... 10 more
>> Caused by: org.apache.solr.common.SolrException: Error opening new searcher
>>                 at 
>> org.apache.solr.core.SolrCore.openNewSearcher(SolrCore.java:1435)
>>                 at 
>> org.apache.solr.core.SolrCore.getSearcher(SolrCore.java:1547)
>>                 at org.apache.solr.core.SolrCore.<init>(SolrCore.java:797)
>>                 ... 13 more
>> Caused by: org.apache.solr.common.SolrException: Error opening Reader
>>                 at 
>> org.apache.solr.search.SolrIndexSearcher.getReader(SolrIndexSearcher.java:172)
>>                 at 
>> org.apache.solr.search.SolrIndexSearcher.<init>(SolrIndexSearcher.java:183)
>>                 at 
>> org.apache.solr.search.SolrIndexSearcher.<init>(SolrIndexSearcher.java:179)
>>                 at 
>> org.apache.solr.core.SolrCore.openNewSearcher(SolrCore.java:1411)
>>                 ... 15 more
>> Caused by: org.apache.lucene.index.CorruptIndexException: codec mismatch: 
>> actual codec=Lucene40StoredFieldsIndex vs expected 
>> codec=Lucene41StoredFieldsIndex (resource: 
>> MMapIndexInput(path="/var/solr/multicore_solr/other_2013-05-04/data/index/_3gfk.fdx"))
>>                 at 
>> org.apache.lucene.codecs.CodecUtil.checkHeaderNoMagic(CodecUtil.java:140)
>>                 at 
>> org.apache.lucene.codecs.CodecUtil.checkHeader(CodecUtil.java:130)
>>                 at 
>> org.apache.lucene.codecs.compressing.CompressingStoredFieldsReader.<init>(CompressingStoredFieldsReader.java:102)
>>                 at 
>> org.apache.lucene.codecs.compressing.CompressingStoredFieldsFormat.fieldsReader(CompressingStoredFieldsFormat.java:113)
>>                 at 
>> org.apache.lucene.index.SegmentCoreReaders.<init>(SegmentCoreReaders.java:147)
>>                 at 
>> org.apache.lucene.index.SegmentReader.<init>(SegmentReader.java:56)
>>                 at 
>> org.apache.lucene.index.StandardDirectoryReader$1.doBody(StandardDirectoryReader.java:62)
>>                 at 
>> org.apache.lucene.index.SegmentInfos$FindSegmentsFile.run(SegmentInfos.java:783)
>>                 at 
>> org.apache.lucene.index.StandardDirectoryReader.open(StandardDirectoryReader.java:52)
>>                 at 
>> org.apache.lucene.index.DirectoryReader.open(DirectoryReader.java:88)
>>                 at 
>> org.apache.solr.core.StandardIndexReaderFactory.newReader(StandardIndexReaderFactory.java:34)
>>                 at 
>> org.apache.solr.search.SolrIndexSearcher.getReader(SolrIndexSearcher.java:169)
>>                 ... 18 more
>>
>> It seems the problem is with my stored fields. This is the configuration of 
>> all sored fields:
>> <field name="id" type="uuid" indexed="true" stored="true"
>> required="true" multiValued="false" /> <field name="marker"
>> type="string" indexed="false" stored="true"/> Field "id" is my unique key.
>>
>> So, I looked for a way to upgrade the version of the index.
>>
>> I tried Lucene's  IndexUpgrader as described here:
>> http://lucene.apache.org/core/4_2_1/core/org/apache/lucene/index/Inde
>> x Upgrader.html I issued this command: java -cp lucene-core-4.2.1.jar 
>> org.apache.lucene.index.IndexUpgrader -verbose 
>> ./other_2013-05-04/data/index I got similar exception:
>>
>> Exception in thread "main" java.io.IOException: background merge hit 
>> exception: _3ea8(5.0):C170283/17098 _3g2k(5.0):C18785/1858 
>> _3gfe(5.0):C1858/10 _3gfj(5.0):C3 _3gfg(5.0):C3 _3gfi(5.0):C2 _3gfh(5.0):C1 
>> _3gff(5.0):C1 _3gfk(5.0):C1 into _3gfm [maxNumSegments=1]
>>         at 
>> org.apache.lucene.index.IndexWriter.forceMerge(IndexWriter.java:1674)
>>         at 
>> org.apache.lucene.index.IndexWriter.forceMerge(IndexWriter.java:1610)
>>         at 
>> org.apache.lucene.index.IndexUpgrader.upgrade(IndexUpgrader.java:161)
>>         at
>> org.apache.lucene.index.IndexUpgrader.main(IndexUpgrader.java:109)
>> Caused by: org.apache.lucene.index.CorruptIndexException: codec mismatch: 
>> actual codec=Lucene40StoredFieldsIndex vs expected 
>> codec=Lucene41StoredFieldsIndex (resource: 
>> MMapIndexInput(path="/var/solr/multicore_solr/other_2013-05-04/data/index/_3ea8.fdx"))
>>         at 
>> org.apache.lucene.codecs.CodecUtil.checkHeaderNoMagic(CodecUtil.java:140)
>>         at org.apache.lucene.codecs.CodecUtil.checkHeader(CodecUtil.java:130)
>>         at 
>> org.apache.lucene.codecs.compressing.CompressingStoredFieldsReader.<init>(CompressingStoredFieldsReader.java:102)
>>         at 
>> org.apache.lucene.codecs.compressing.CompressingStoredFieldsFormat.fieldsReader(CompressingStoredFieldsFormat.java:113)
>>         at 
>> org.apache.lucene.index.SegmentCoreReaders.<init>(SegmentCoreReaders.java:147)
>>         at 
>> org.apache.lucene.index.SegmentReader.<init>(SegmentReader.java:56)
>>         at 
>> org.apache.lucene.index.ReadersAndLiveDocs.getMergeReader(ReadersAndLiveDocs.java:153)
>>         at 
>> org.apache.lucene.index.IndexWriter.mergeMiddle(IndexWriter.java:3630)
>>         at org.apache.lucene.index.IndexWriter.merge(IndexWriter.java:3296)
>>         at 
>> org.apache.lucene.index.ConcurrentMergeScheduler.doMerge(ConcurrentMergeScheduler.java:401)
>>         at
>> org.apache.lucene.index.ConcurrentMergeScheduler$MergeThread.run(Conc
>> u
>> rrentMergeScheduler.java:478)
>>
>> Am I doing something wrong? Am I missing something?
>> Is there a way to configure the stored fields to use Lucene40 index in Solr 
>> 4.2.1 as well? If so, upgrade may be unnecessary.
>>
>> Thanks.
>>
>
> Email secured by Check Point

Email secured by Check Point

Reply via email to