Example Analysis of Solr6.2.1 stand-alone installation and deployment in CentOs
This article mainly introduces the example analysis of installation and deployment of Solr6.2.1 stand-alone in CentOs. It is very detailed and has certain reference value. Friends who are interested must finish it!
Solr architecture diagram
Start the installation:
Go to the website http://lucene.apache.org/solr/downloads.html to download the corresponding version, such as version 6.2.1, and download it to the / usr/local directory
# cd / usr/local
# tar-zxf solr-6.2.1.tgz
# cd / usr/local/solr-6.2.1
Modify the port number to 8983:
Cat / usr/local/solr-6.2.1/server/solr/solr.xml
.
${host:192.168.18.68}
${jetty.port:8983}
${hostContext:solr}
.
Start the service
# / usr/local/solr-6.2.1/bin/solr start
Waiting up to 30 seconds to see Solr running on port 8983 [/]
Started Solr server on port 8983 (pid=113190). Happy searching!
Verification service
# / usr/local/solr-6.2.1/bin/solr status
Found 1 Solr nodes:
Solr process 113190 running on port 8983
{
"solr_home": "/ usr/local/solr-6.2.1/server/solr"
"version": "6.2.1 43ab70147eb494324a1410f7a9f16a896a59bc6f-shalin-2016-09-15 05:20:53"
"startTime": "2017-12-20T02:05:04.303Z"
"uptime": "0 days, 0 hours, 5 minutes, 8 seconds"
"memory": "44 MB (9) of 490.7 MB"}
Visit the Web page
Browser input ip:port/sor
Http://192.168.18.68:8983/solr/
There is no core by default and needs to be created.
Core is an index library of solr, which can be understood as a database. Core can create multiple databases as needed.
An error will be reported when creating a core for the first time, for example, an error will be reported when creating a core,Add Core named test
Unable to create core [new_core] Caused by: Can't find resource 'solrconfig.xml' in classpath..
Solution:
You need to create a database directory called test in the / usr/local/solr-6.2.1/server/solr directory, and then copy the conf directory in basic_configs to the database directory:
[root@alpha-solr-68 local] # mkdir-p / usr/local/solr-6.2.1/server/solr/test
[root@alpha-solr-68 local] # cp-r / usr/local/solr-6.2.1/server/solr/configsets/basic_configs/conf / usr/local/solr-6.2.1/server/solr/test
You need to restart the service:
[root@alpha-solr-68 local] # / usr/local/solr-6.2.1/bin/solr stop
Sending stop command to Solr running on port 8983... Waiting 5 seconds to allow Jetty process 113190 to stop gracefully.
[root@alpha-solr-68 local] #
[root@alpha-solr-68 local] #
[root@alpha-solr-68 local] # / usr/local/solr-6.2.1/bin/solr start
Waiting up to 30 seconds to see Solr running on port 8983 [/]
Started Solr server on port 8983 (pid=114488). Happy searching!
Created successfully again:
At this point, the stand-alone installation is complete.
The above is all the contents of the article "sample Analysis of Solr6.2.1 stand-alone installation and deployment in CentOs". Thank you for reading! Hope to share the content to help you, more related knowledge, welcome to follow the industry information channel!