CentOs Solr6.2.1單機安裝部署步驟
Solr體系結構圖
開始安裝:
到網站下載對應的版本,例如版本6.2.1,下載到/usr/local目錄下
# cd /usr/local
# tar -zxf solr-6.2.1.tgz
# cd /usr/local/solr-6.2.1
修改埠號為8983:
cat /usr/local/solr-6.2.1/server/solr/solr.xml
.....
<solr>
<solrcloud>
<str name="host">${host:192.168.18.68}</str>
<int name="hostPort">${jetty.port:8983}</int>
<str name="hostContext">${hostContext:solr}</str>
......
啟動服務
# /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!
驗證服務
# /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"}
訪問Web頁面
瀏覽器輸入 ip:port/sor
http://192.168.18.68:8983/solr/
預設沒有core,需要建立。
core是solr的一個索引庫,可以理解為一個資料庫,core可以根據需要,建立多個.
第一次建立core的時候會報錯,例如建立名字為test的core,Add Core時會報錯
Unable to create core [new_core] Caused by: Can't find resource 'solrconfig.xml' in classpath..
解決方法:
需要在/usr/local/solr-6.2.1/server/solr目錄裡建立一個資料庫目錄,名為test,然後需要把basic_configs裡的conf目錄複製到資料庫目錄裡:
[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
需要重啟服務:
[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!
再次建立成功:
至此,單機安裝完畢
開始安裝:
到網站下載對應的版本,例如版本6.2.1,下載到/usr/local目錄下
# cd /usr/local
# tar -zxf solr-6.2.1.tgz
# cd /usr/local/solr-6.2.1
修改埠號為8983:
cat /usr/local/solr-6.2.1/server/solr/solr.xml
.....
<solr>
<solrcloud>
<str name="host">${host:192.168.18.68}</str>
<int name="hostPort">${jetty.port:8983}</int>
<str name="hostContext">${hostContext:solr}</str>
......
啟動服務
# /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!
驗證服務
# /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"}
訪問Web頁面
瀏覽器輸入 ip:port/sor
http://192.168.18.68:8983/solr/
預設沒有core,需要建立。
core是solr的一個索引庫,可以理解為一個資料庫,core可以根據需要,建立多個.
第一次建立core的時候會報錯,例如建立名字為test的core,Add Core時會報錯
Unable to create core [new_core] Caused by: Can't find resource 'solrconfig.xml' in classpath..
解決方法:
需要在/usr/local/solr-6.2.1/server/solr目錄裡建立一個資料庫目錄,名為test,然後需要把basic_configs裡的conf目錄複製到資料庫目錄裡:
[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
需要重啟服務:
[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!
再次建立成功:
至此,單機安裝完畢
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/15498/viewspace-2148927/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- Centos安裝tmux步驟CentOSUX
- zookeeper安裝部署步驟
- Centos 7 安裝VNC步驟CentOSVNC
- MHA安裝和部署步驟
- vnc安裝步驟,如何在Linux(CentOS 7)下vnc安裝步驟VNCLinuxCentOS
- hadoop 單機版部署步驟Hadoop
- CentOS 7 安裝MongoDB詳細步驟CentOSMongoDB
- Centos7Nginx+PHP安裝步驟CentOSNginxPHP
- VMware 虛擬機器安裝CentOS映象詳細步驟虛擬機CentOS
- 簡單oracle安裝步驟Oracle
- Nsca安裝簡單步驟
- centos 8的特點和安裝步驟CentOS
- CentOS 7上安裝WordPress詳細步驟CentOS
- CentOS 7.4安裝redis 4.0詳細步驟CentOSRedis
- CentOS 6.5下Redis安裝詳細步驟CentOSRedis
- centos7安裝教程詳解 centos7安裝詳細步驟CentOS
- vnc安裝步驟,vnc安裝步驟詳解VNC
- CentOS安裝MySQL5.5的完整步驟DSITCentOSMySql
- CentOS 7.4下安裝nginx的詳細步驟CentOSNginx
- CentOS7上安裝WordPress詳細步驟CentOS
- 管家婆簡單安裝步驟
- doris編譯和安裝部署詳細步驟編譯
- Linux平臺HBase單機版安裝和配置步驟Linux
- CentOS下使用yum方式安裝percona xtrabackup步驟CentOS
- centos下svn的安裝及配置詳細步驟CentOS
- xftp安裝步驟,xftp安裝的2大步驟FTP
- 單機CentOS 安裝 TiDBCentOSTiDB
- STF 安裝步驟
- php安裝步驟PHP
- oracle 安裝步驟Oracle
- 如何安裝印表機驅動 印表機驅動安裝步驟
- Linux環境下MySQL安裝部署操作步驟LinuxMySql
- [ 安裝 ] Zeppelin安裝步驟!
- linux下安裝redis 單節點安裝操作步驟LinuxRedis
- Redis 4.0.2單機安裝部署Redis
- Homestead 虛擬機器安裝步驟虛擬機
- docker下使用centos6.6 安裝vasp5.4步驟DockerCentOS
- CentOS7安裝Gitlab13詳細步驟CentOSGitlab