How to create new core in Solr 5?

前端 未结 6 1300
挽巷
挽巷 2021-02-04 02:35

Currently we are using Apache Solr 4.10.3 OR Heliosearch Distribution for Solr [HDS] as a search engine to i

相关标签:
6条回答
  • 2021-02-04 02:45

    Use provided solr script with solr user privileges to create Solr cores, e.g.

    cd /opt/solr
    sudo -u solr ./bin/solr create -c testcore1
    

    Run bin/solr --help for syntax guidance.

    For any other issues, please check your Solr logs (e.g. /var/solr/logs/solr.log).

    Related: SOLR-7826: Permission issues when creating cores with bin/solr as root user.

    0 讨论(0)
  • 2021-02-04 02:53
    {SOLR_INSTALLATION}/server/solr/configsets\basic_configs\conf
    

    you can find the example schema.xml and solrconfig.xml. if you want to create the new core {SOLR_INSTALLATION}/server/solr/{new core name} folder and create conf folder with required schema and solrconfig.xml and blank core.properties file. you can find the examples for schema and config in

    {SOLR_INSTALLATION}/example/example-DIH/solr
    
    0 讨论(0)
  • 2021-02-04 02:55

    Create using the web interface Go to bin directory and issue

       ./solr start -e cloud -noprompt
    

    Which will start solr. Go to http://localhost:8983 (this is assuming you are running on localhost)

    Click on core admin and they "Add Core"

    0 讨论(0)
  • 2021-02-04 02:56

    You can find your solrconfig.xml and schema.xml inside the collection directory. Go to /usr/lib/ambari-infra-solr/server/solr and u will see a folder with same name as of collection and with schema and config files. Inside the conf folder there will be a managed-schema file and other files that you have been searching for.

    As for this error Error CREATEing SolrCore 'testcore1': Unable to create core [testcore1] Caused by: Could not find configName for collection testcore1 found:null This error must be coming when you are creating solr collection from UI. For that go to location where solr.cmd is located and type the below code ./solr create -c -d -s -r

    0 讨论(0)
  • 2021-02-04 03:01

    In Solr 5.4.0 , create new core using command from Solr-5.x.x folder (Solr Installation folder) like following,

    $ bin/solr create -c <name>
    

    See this documentation of Apache Solr 5.4 https://cwiki.apache.org/confluence/display/solr/Running+Solr

    0 讨论(0)
  • 2021-02-04 03:03

    In Solr 5, creation of cores is supported by the bin/solr script provided in the distribution. Try

    bin/solr create -help
    

    for a quick introduction.

    From the above help doc, you may find:

    bin/solr create [-c name] [-d confdir] [-n configName] [-shards #] [-replicationFactor #] [-p port]
    
    0 讨论(0)
提交回复
热议问题