0

I can't figure out from documentation what all these options mean in real world:

$  sh zkcli.sh -cmd upconfig -zkhost  <host:port> -confname <name for configset> -solrhome 
<solrhome> -confdir <path to directory with configset>

I mean options like -zkhost, -confname, -solrhome and -confdir. I'm asking this, because I'm not sure, for example, what <host:port> I should provide for -zkhost option, when my Zookeeper configuration file has this contents:

....
clientPort=2181
server.1=127.0.0.1:2222:2223
server.2=127.0.0.1:3333:3334
...

Should it be -zkhost 127.0.0.1:2181 or -zkhost 127.0.0.1:2181,127.0.0.1:2182,.... <host:port> in documentation looks rather vague and does not seem to be self-explanatory, when it comes to real world cases.

Besides, I'm not sure what -solrhome option means. Should it point to the root folder where Solr with all its sources is located or should it point to its bin directory - I don't know. Again documentation is rather silent and does not provide a concrete example. etc, etc.

I wish someone could share a real world example and explain what all these options mean and where they point to. And I hope someone can provide an example (which takes into account the first example with real world options) which demonstrates how to create a core/collection, using rest api. That would be a tremendous help for many newbies. Thanks!

Jacobian
  • 10,122
  • 29
  • 128
  • 221
  • 1
    May be this could help you. http://stackoverflow.com/questions/31790202/solrcloud-5-and-zookeeper-config-upload/31795397#31795397 – Aneesh Mon N Aug 29 '15 at 17:07
  • @Aneesh Mon N. Thanks for that. That is very useful! I guess, the last question I'm left with is how to use rest api to create a new core/collection based on all previous configuration, that we undertook. Say, in your answer you have this option - /opt/myname/solr-5.2.1/server/solr/pats/conf . In this case how curl command should look like so that the created core/collection would have this configuration stored in pats/conf ? – Jacobian Aug 29 '15 at 17:18
  • And btw, I see in Zookeeper that my config was uploaded. So there is only one last step to take - create a new core/collection with this configuration. How can it be implemented using rest api? – Jacobian Aug 29 '15 at 17:20
  • The problem I face is that all my configuration files are now located in zookeeper and I want to point to them while creating a core/collection. So, I see that I uploaded configs/default/conf/... to the zookeeper. How can I use this fact in `bin/solr create -c ` command? Thanks! – Jacobian Aug 29 '15 at 17:29
  • Pheew, I did it, I figured out how the final command should look like. It should be `bin/solr create -c test_collection -n default_cfg -shards 2 -replicationFactor 2`. Where default_cfg equals to `-confname` from the previous step. – Jacobian Aug 29 '15 at 17:51
  • Sorry. I was away. But you got it already...! Good work. – Aneesh Mon N Aug 29 '15 at 17:56
  • Thanks! You answer helped me a lot! – Jacobian Aug 29 '15 at 17:59
  • Good to know. Thanks – Aneesh Mon N Aug 29 '15 at 18:01
  • I will update my answers with collection creation steps as we'll – Aneesh Mon N Aug 29 '15 at 18:06
  • Thanks! That will be extremely useful for `Solr` newbies like me. – Jacobian Aug 29 '15 at 18:08

0 Answers0