On 11/14/2017 2:14 AM, Amanda Shuman wrote:
We have just one solr core, which resides in the webapp foIder (in solr
5.3.1 this is at /opt/solr-5.3.1/server/webapps/[corename]/  -- the data
folder is in the same place at /data).

Why is your core there? That is not a typical location, and does explain the restart behavior you're seeing.

Usually core directories go in the solr home. If you start solr using "bin/solr start" directly without any options, the solr home will be in server/solr, not server/webapp. How are you starting Solr?

"Could not create a new core in
/opt/solr-5.3.1/server/webapps/[corename]/as another core is already
defined there"

When Solr starts, it begins searching the coreRootDirectory (which defaults to the solr home) for cores. When it locates a core.properties file, that location becomes the instanceDir for a core.

If you do a manual core creation, the core.properties file must NOT exist, but the conf directory *must* exist with the proper contents. The core creation will create that file. If it already exists, then Solr will refuse to create the core, just as you have seen.

The program directory location you have mentioned (/opt/solr-5.3.1) sounds like somebody did a service installation. The default solr home when you install the service (and start Solr with /etc/init.d/XXXX rather than bin/solr) is /var/solr/data. This location can be overridden, but that's the default.

Instead of having your core in webapp, move it to the solr home, wherever that is. Then when you start Solr, it will find the core.

If a service installation has been done, then you should not start Solr with "bin/solr" -- you should start the installed service.

Thanks,
Shawn

Reply via email to