Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
9.0
-
None
Description
There is a statement in the help message for "bin/solr create_core":
When a configSet is used, this can be run from remote (non-Solr) hosts. If pointing at a non-configSet directory, this must be run from the host that you wish to create the core on.
However, this is not case.
Suppose there is a solr server instance launched at 192.168.0.100:8983. On a different host (non-solr host), use the following command to create a new core:
SOLR_HOST=192.168.0.100 bin/solr create_core -c test -d _default -p 8983
an error message is output like the following:
ERROR: Error CREATEing SolrCore 'test': Unable to create core [test] Caused by: Can't find resource 'solrconfig.xml' in classpath or '/var/solr/data/test'
check the core status:
$ curl http://192.168.0.100:8983/solr/admin/cores
{
"responseHeader":
,
"initFailures":{"test":"org.apache.solr.common.SolrException:org.apache.solr.common.SolrException: Could not load conf for core test: Error loading solr config from /opt/solr-9.0.0/server/solr/test/conf/solrconfig.xml"},
"status":{}}
You can see that the core was created but can't be loaded by the solr server (because of no configuration files can be found in the conf sub-directory of the instance directory).
As a comparison, we can remotely create a new core using the following Solr API:
curl "http://192.168.0.100:8983/solr/admin/cores?action=CREATE&name=test&instanceDir=test&configSet=_default"
My question is how to fix this issue. Do we want to fixup the statement to match the real behavior or update the create_core tool to support remotely creating a core ?
Attachments
Issue Links
- is related to
-
SOLR-16757 Umbrella Ticket for Revamping Solr CLI's for the Future
- Open
- links to