Re: Multiple schemas in the same SolrCloud ?
You can simply have multiple collections, each independent of each other on the schema but could run on the same instance/jvm if you want. On Wed, Oct 9, 2013 at 12:36 PM, xinwu wrote: > Hi all, > > I want to use the multiple schemas in the same solrCloud, is it allowed? > > If it is allowed,how? > > > These schemas may have no relation. > > Thank You. > > Dai. > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/Multiple-schemas-in-the-same-SolrCloud-tp4094279.html > Sent from the Solr - User mailing list archive at Nabble.com. > -- Anshum Gupta http://www.anshumgupta.net
Re: Multiple schemas in the same SolrCloud ?
I remember I must put the "-Dbootstrap_confdir=/opt/Solr_home/collection1/conf -Dcollection.configName=solrConfig " in the catalina.sh . Is it means that solrCloud must have one ,and only one, schema? -- View this message in context: http://lucene.472066.n3.nabble.com/Multiple-schemas-in-the-same-SolrCloud-tp4094279p4094281.html Sent from the Solr - User mailing list archive at Nabble.com.
Re: Multiple schemas in the same SolrCloud ?
You can have more information from here: https://cwiki.apache.org/confluence/display/solr/Using+ZooKeeper+to+Manage+Configuration+Files 2013/10/9 xinwu > I remember I must put the > "-Dbootstrap_confdir=/opt/Solr_home/collection1/conf > -Dcollection.configName=solrConfig " in the catalina.sh . > > Is it means that solrCloud must have one ,and only one, schema? > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/Multiple-schemas-in-the-same-SolrCloud-tp4094279p4094281.html > Sent from the Solr - User mailing list archive at Nabble.com. >
Re: Multiple schemas in the same SolrCloud ?
On 10/9/2013 1:17 AM, xinwu wrote: I remember I must put the "-Dbootstrap_confdir=/opt/Solr_home/collection1/conf -Dcollection.configName=solrConfig " in the catalina.sh . Is it means that solrCloud must have one ,and only one, schema? Those bootstrap options are intended to be used ONCE, and on only one of your Solr instances, not all of them. What that does is take the configuration in the confdir and upload it to zookeeper, giving it the name you chose. You can have many configurations with different names in zookeeper. Each collection is associated with a config name. A better way than the bootstrap options is the zkcli script in cloud-scripts on the example. The "upconfig" command can be used to upload or change your configurations. http://wiki.apache.org/solr/SolrCloud#Command_Line_Util Thanks, Shawn
Re: Multiple schemas in the same SolrCloud ?
Thank you,kamaci. -- View this message in context: http://lucene.472066.n3.nabble.com/Multiple-schemas-in-the-same-SolrCloud-tp4094279p4094594.html Sent from the Solr - User mailing list archive at Nabble.com.
Re: Multiple schemas in the same SolrCloud ?
Thank you ,Shawn. I solved that problem by using the "-Dbootstrap_conf=true" configuration instead of the "-Dbootstrap_confdir=/opt/Solr_home/collection1/conf -Dcollection.configName=solrConfig" on startup. But,another problem showed up. I had two collections (collection1,collection2) when I started my Solr. Collection1 and Collection2 had different schema. Then I created two other collections in my project which had the same schema with the collection2. But these two new collections only had "data" directory, which means there was no 'conf' directory. And when I started my solr again,some errors showed up because of the missing of 'conf' directory. How should I do? Thanks. -- View this message in context: http://lucene.472066.n3.nabble.com/Multiple-schemas-in-the-same-SolrCloud-tp4094279p4094607.html Sent from the Solr - User mailing list archive at Nabble.com.
Re: Multiple schemas in the same SolrCloud ?
On 10/10/2013 2:45 AM, xinwu wrote: > I solved that problem by using the "-Dbootstrap_conf=true" configuration > instead of the "-Dbootstrap_confdir=/opt/Solr_home/collection1/conf > -Dcollection.configName=solrConfig" on startup. You do not need this bootstrap option either. Once your configurations are loaded into zookeeper, nothing further is needed - the information is there. > But,another problem showed up. > > I had two collections (collection1,collection2) when I started my Solr. > Collection1 and Collection2 had different schema. > > Then I created two other collections in my project which had the same schema > with the collection2. > But these two new collections only had "data" directory, which means there > was no 'conf' directory. > > And when I started my solr again,some errors showed up because of the > missing of 'conf' directory. This is expected, because the bootstrap options (especially bootstrap_conf) are not intended for extended use. SolrCloud doesn't use conf directories. All that is in zookeeper. The bootstrap options are one way of converting configurations from non-SolrCloud to SolrCloud. Once that's done, it does not need to be done again. The other way of converting and maintaining SolrCloud configuration information, which in my opinion is better, is with the zkcli utility included in example/cloud-scripts. This is the definition that most closely describes what bootstrapping means with respect to SolrCloud. Solr is not a development environment, but the general notion applies: http://en.wikipedia.org/wiki/Bootstrapping#Software_development Thanks, Shawn
Re: Multiple schemas in the same SolrCloud ?
On this topic, once you've uploaded you collection's configuration in ZK, how can you update it? Upload the new one with the same config name ? -- View this message in context: http://lucene.472066.n3.nabble.com/Multiple-schemas-in-the-same-SolrCloud-tp4094279p4094729.html Sent from the Solr - User mailing list archive at Nabble.com.
Re: Multiple schemas in the same SolrCloud ?
Use $solrzip/example/cloud-scripts/zkcli.sh to upload a new set of configuration files. Upayavira On Thu, Oct 10, 2013, at 04:57 PM, maephisto wrote: > On this topic, once you've uploaded you collection's configuration in ZK, > how > can you update it? > Upload the new one with the same config name ? > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/Multiple-schemas-in-the-same-SolrCloud-tp4094279p4094729.html > Sent from the Solr - User mailing list archive at Nabble.com.
Re: Multiple schemas in the same SolrCloud ?
you can try this way: start zookeeper server first. upload your configurations to zookeeper and link them to your collection using zkcli just like shawn said let's say you have conf1 and conf2, you can link them to collection1 and collection2 remove the bootstrap stuff and start solr server. after you have solr running, create collection1 and collection2 via core admin, you don't have conf because all your core specified configurations are in zookeeper or you could use core discovery and have collection name specified in core.properties, see : http://wiki.apache.org/solr/Core%20Discovery%20%284.4%20and%20beyond%29 On 10 October 2013 23:57, maephisto wrote: > On this topic, once you've uploaded you collection's configuration in ZK, > how > can you update it? > Upload the new one with the same config name ? > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/Multiple-schemas-in-the-same-SolrCloud-tp4094279p4094729.html > Sent from the Solr - User mailing list archive at Nabble.com. > -- All the best Liu Bo
Re: Multiple schemas in the same SolrCloud ?
Thank you,Shawn. Thank you,everyone. All your answers help me a lot.Thanks. -- View this message in context: http://lucene.472066.n3.nabble.com/Multiple-schemas-in-the-same-SolrCloud-tp4094279p4094850.html Sent from the Solr - User mailing list archive at Nabble.com.
Re: Multiple schemas in the same SolrCloud ?
Thanks! My only doubt is: upload a new set of configuration files to the same configuration name like so: Initial configuration: zkcli.sh -zkhost localhost:9983 -cmd upconfig -confdir conf_initial/ -confname my_custom_config and afterwards, to change it do: zkcli.sh -zkhost localhost:9983 -cmd upconfig -confdir conf_changed/ -confname my_custom_config Is this correct? If so, what happens afterwards, will ZK distribute this changes to all cores and reload them? -- View this message in context: http://lucene.472066.n3.nabble.com/Multiple-schemas-in-the-same-SolrCloud-tp4094279p4094895.html Sent from the Solr - User mailing list archive at Nabble.com.
Re: Multiple schemas in the same SolrCloud ?
Here is a topic you should read it: http://lucene.472066.n3.nabble.com/Reloading-config-to-zookeeper-td4021901.html 2013/10/11 maephisto > Thanks! > My only doubt is: upload a new set of configuration files to the same > configuration name like so: > > Initial configuration: > zkcli.sh -zkhost localhost:9983 -cmd upconfig -confdir conf_initial/ > -confname my_custom_config > and afterwards, to change it do: > zkcli.sh -zkhost localhost:9983 -cmd upconfig -confdir conf_changed/ > -confname my_custom_config > > Is this correct? > If so, what happens afterwards, will ZK distribute this changes to all > cores > and reload them? > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/Multiple-schemas-in-the-same-SolrCloud-tp4094279p4094895.html > Sent from the Solr - User mailing list archive at Nabble.com. >
Re: Multiple schemas in the same SolrCloud ?
Hi,kamaci. Is that means I just need to upload new config files ,and do not need to reload every node in solrCloud ,when I want to change my configurations? -- View this message in context: http://lucene.472066.n3.nabble.com/Multiple-schemas-in-the-same-SolrCloud-tp4094279p4094908.html Sent from the Solr - User mailing list archive at Nabble.com.
Re: Multiple schemas in the same SolrCloud ?
Upload the new configuration and the use the collection API to reload you collection https://cwiki.apache.org/confluence/display/solr/Collections+API#CollectionsAPI-ReloadaCollection -- View this message in context: http://lucene.472066.n3.nabble.com/Multiple-schemas-in-the-same-SolrCloud-tp4094279p4094978.html Sent from the Solr - User mailing list archive at Nabble.com.