lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Amanda Shuman <amanda.shu...@gmail.com>
Subject Re: How to get a solr core to persist
Date Wed, 15 Nov 2017 09:32:19 GMT
Ah, also, this is what the admin console says for location of core docs
when I created the core at command line:

CWD:/opt/solr-5.3.1/serverInstance:/var/solr/data/[corename]Data:
/var/solr/data/[corename]/dataIndex:/var/solr/data/[corename]/data/index


------
Dr. Amanda Shuman
Post-doc researcher, University of Freiburg, The Maoist Legacy Project
<http://www.maoistlegacy.uni-freiburg.de/>
PhD, University of California, Santa Cruz
http://www.amandashuman.net/
http://www.prchistoryresources.org/
Office: +49 (0) 761 203 4925


On Wed, Nov 15, 2017 at 10:28 AM, Amanda Shuman <amanda.shuman@gmail.com>
wrote:

> Hi Shawn,
>
> Thanks a million for your response! I really do appreciate it... this
> helps clarify how things should be set up.
>
> As for why things are set up the way they are and the webapps location...
> honestly I think my predecessor did not really understand solr at all...
> I'm trying to pick up the pieces now on the back-end. (On the bright side,
> I did figure out how to modify the search relevance critieria in the config
> files for our core, but I'm more of a front-end developer and that seemed a
> lot more intuitive to me.)
>
> It does seem that the solr home is currently in /var/solr/data (not
> server/solr) because when I created a new core at command line, that's
> where it went. We start/restart solr using /etc/init.d/ rather than
> bin/solr.
>
> If can ask a few very small follow-up questions to this:
>
> "If you do a manual core creation, the core.properties file must NOT
> exist, but the conf directory *must* exist with the proper contents."
>
> 1) so does this mean that on the back-end I should first create my new
> core, e.g., core1 and then within that place a conf folder with all the
> files? Same for the data folder? If so, is it fine to just use the existing
> config files that I've previously worked on (i.e. the config for search
> that I already modified)? I presume this won't be an issue.
>
> 2) does it matter if I create this core through the admin console or at
> command line?
>
> Thanks again!
> Amanda
>
> ------
> Dr. Amanda Shuman
> Post-doc researcher, University of Freiburg, The Maoist Legacy Project
> <http://www.maoistlegacy.uni-freiburg.de/>
> PhD, University of California, Santa Cruz
> http://www.amandashuman.net/
> http://www.prchistoryresources.org/
> Office: +49 (0) 761 203 4925 <+49%20761%202034925>
>
>
> On Tue, Nov 14, 2017 at 3:15 PM, Shawn Heisey <apache@elyograg.org> wrote:
>
>> 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
>>
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message