Quantcast

shareSchema="true" - location of schema.xml?

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

shareSchema="true" - location of schema.xml?

Satish Talim
I have 1000's of cores and to reduce the cost of loading unloading
schema.xml, I have my solr.xml as mentioned here -
http://wiki.apache.org/solr/CoreAdmin
namely:

<solr>
  <cores adminPath="/admin/cores" shareSchema="true">
    ...
  </cores>
</solr>

However, I am not sure where to keep the common schema.xml file? In which
case, do I need the schema.xml in the conf folder of each and every core?

My folder structure is:

     multicore (contains solr.xml)
        |_ core0
             |_ conf
             |    |_ schema.xml
             |    |_ solrconfig.xml
             |    |_ other files
           core1
             |_ conf
             |    |_ schema.xml
             |    |_ solrconfig.xml
             |    |_ other files
             |
           exampledocs (contains 1000's of .csv files and post.jar)

Satish
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shareSchema="true" - location of schema.xml?

François Schiettecatte
Satish

You don't say which platform you are on but have you tried links (with ln on linux/unix) ?

François

On Aug 31, 2011, at 12:25 AM, Satish Talim wrote:

> I have 1000's of cores and to reduce the cost of loading unloading
> schema.xml, I have my solr.xml as mentioned here -
> http://wiki.apache.org/solr/CoreAdmin
> namely:
>
> <solr>
>  <cores adminPath="/admin/cores" shareSchema="true">
>    ...
>  </cores>
> </solr>
>
> However, I am not sure where to keep the common schema.xml file? In which
> case, do I need the schema.xml in the conf folder of each and every core?
>
> My folder structure is:
>
>     multicore (contains solr.xml)
>        |_ core0
>             |_ conf
>             |    |_ schema.xml
>             |    |_ solrconfig.xml
>             |    |_ other files
>           core1
>             |_ conf
>             |    |_ schema.xml
>             |    |_ solrconfig.xml
>             |    |_ other files
>             |
>           exampledocs (contains 1000's of .csv files and post.jar)
>
> Satish

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shareSchema="true" - location of schema.xml?

Erick Erickson
Would it work to just (relative) path the schema
file for your cores with the "schema" parameter?

Best
Erick

2011/8/31 François Schiettecatte <[hidden email]>:

> Satish
>
> You don't say which platform you are on but have you tried links (with ln on linux/unix) ?
>
> François
>
> On Aug 31, 2011, at 12:25 AM, Satish Talim wrote:
>
>> I have 1000's of cores and to reduce the cost of loading unloading
>> schema.xml, I have my solr.xml as mentioned here -
>> http://wiki.apache.org/solr/CoreAdmin
>> namely:
>>
>> <solr>
>>  <cores adminPath="/admin/cores" shareSchema="true">
>>    ...
>>  </cores>
>> </solr>
>>
>> However, I am not sure where to keep the common schema.xml file? In which
>> case, do I need the schema.xml in the conf folder of each and every core?
>>
>> My folder structure is:
>>
>>     multicore (contains solr.xml)
>>        |_ core0
>>             |_ conf
>>             |    |_ schema.xml
>>             |    |_ solrconfig.xml
>>             |    |_ other files
>>           core1
>>             |_ conf
>>             |    |_ schema.xml
>>             |    |_ solrconfig.xml
>>             |    |_ other files
>>             |
>>           exampledocs (contains 1000's of .csv files and post.jar)
>>
>> Satish
>
>
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shareSchema="true" - location of schema.xml?

Satish Talim
In reply to this post by François Schiettecatte
I am experimenting Solr on Windows, for now.

Satish

2011/8/31 François Schiettecatte <[hidden email]>

> Satish
>
> You don't say which platform you are on but have you tried links (with ln
> on linux/unix) ?
>
> François
>
> On Aug 31, 2011, at 12:25 AM, Satish Talim wrote:
>
> > I have 1000's of cores and to reduce the cost of loading unloading
> > schema.xml, I have my solr.xml as mentioned here -
> > http://wiki.apache.org/solr/CoreAdmin
> > namely:
> >
> > <solr>
> >  <cores adminPath="/admin/cores" shareSchema="true">
> >    ...
> >  </cores>
> > </solr>
> >
> > However, I am not sure where to keep the common schema.xml file? In which
> > case, do I need the schema.xml in the conf folder of each and every core?
> >
> > My folder structure is:
> >
> >     multicore (contains solr.xml)
> >        |_ core0
> >             |_ conf
> >             |    |_ schema.xml
> >             |    |_ solrconfig.xml
> >             |    |_ other files
> >           core1
> >             |_ conf
> >             |    |_ schema.xml
> >             |    |_ solrconfig.xml
> >             |    |_ other files
> >             |
> >           exampledocs (contains 1000's of .csv files and post.jar)
> >
> > Satish
>
>
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shareSchema="true" - location of schema.xml?

rkuris
I have 300 cores so I feel your pain :-)

What we do is use a relative path for the file.  It works if you use ../../common/schema.xml for each core, then just create a common directory off your solr home and put your schema file there.

I found this works great with solrconfig.xml and all of it's dependencies as well.

Another choice is to look at the sharedLib parameter, which adds some directory to your classpath.  I played with this for a little bit and couldn't get it working, so I went with the relative path solution.
Loading...