I have troubles creating my first collection within Apache Solr.
What I use is:
Version: Cloudera Enterprise Trial 4.8.1 (#74 built by jenkins on 20140130-0818 git: b86b260a322d131e5ff7e3aa62cb3b996f12198c)
I use the Cloudera manager as a cluster & service installer. Within the Cloudera Manager all looks fine -- up and running without any errors. However, when I access HUE and click on the Solr I see the following message:
"There're currently no collections defined."
When I click on "Import" I receive the following:
All available collections from the Solr URL in hue.ini have been imported.
All available cores from the Solr URL in hue.ini have been imported.
Within the Cloudera Manager, Hue Configuration (View&Edit) I entered the following within the "Hue Server Configuration Safety Valve for hue_safety_valve_server.ini":
## URL of the Solr Server
However without any success, despite after that there's a checkbox with nothing as a description next to it appearing in "Import Collections and Cores" inside Hue, ready to be selected under the Collections option. Under the "Cores" it still shows "All available cores from the Solr URL in hue.ini have been imported."
When I access the Solr Admin interface at http://node1.cluster:8983/solr, clicking on "Core Admin/Add Core" just freezes (stays in "loading state"), once I push the "Add Core" button!
How do I create my first collection, I tried copying some example data under /var/lib/solr directory, however unsuccessfully. Also, I intend to use the HDFS to upload my collection into. What're the paths I should specify? I'll greatly appreciate any help!!
Forgot the versions info:
Unfortunately there is no way to create a collection from the UI, it has to be done manually. The steps are as follows:
- On any host running a solr instance run:
solrctl --zk zookeeper_host1:2181,zookeeper_host2:2181/solr instancedir --generate /path/to/configs
NOTE: /path/to/configs will be generated with example Solr configuratuions. "--zk" should have every Zookeeper host in your cluster in a comma separated list, then "/solr" after the last entry.
- Then go to /path/to/configs/conf and check out the configs. The main ones of interest are schema.xml and solrconfig.xml.
- Once you have changed the configs to meet your needs, run:
solrctl --zk zookeeper_host1:2181,zookeeper_host2:2181/solr instancedir --create <collection_name> /path/to/configs
- Then run:
solrctl --zk zookeer_host1:2181,zookeeper_host2:2181/solr collection --create <collection_name>
Then you will have a collection. See the blog and doc link below for more details.
Hope this helps.