![](/img/trans.png)
[英]solr installed on 8983 and solrcloud with 2 nodes on ports 8984 and 7574
[英]How to have the same SOLR core for both 8983 and 8984 ports
我將Apache SOLR 6.6.5用作在端口8983上運行的搜索引擎。我只想為solr啟用SSL,並按照本指南進行操作,以使其在帶有SSL的8984端口下工作。
在這里,我的問題是我看不到8984上已經在端口8983(不帶SSL的端口)下創建的任何內核。
http://mywebsite.com:8983/solr/#/ ==>這有3個核心
https://mywebsite.com:8984/solr/#/ ==>這沒有任何核心
如果有人可以提供針對8983和8984端口具有相同內核的解決方案,將不勝感激。
謝謝
以下是步驟。 確保zookeeper已安裝並且已啟動並正在運行。 通常zookeeper在端口2181上運行,因此我們的zk_host將為localhost:2181。
SOLRHOME是從solr-xyztar.gz中提取的目錄。
./bin/solr -c -d node1 -z localhost:2181
Here,
-c : Sepcifies cloud node
-d : Solr home directory store node logs and core data
-z : Zookeeper to maintain Config files
./bin/solr -c -d node2 -z localhost:2181
./bin/solr zk upconfig -z localhost:2181 -n core1_schema -d ~/core1_schema_dir Here, ~/core1_schema_dir : this dir will contain conf dir which you must have in your current core1 collection, so your managed-schema file path will be ~/core1_schema_dir/conf/managed-schema core1_schema : This is name we have given to the uploaded schema
curl " http://localhost:8983/solr/admin/collections?action=CREATE&name=core1&numShards=1&replicationFactor=2&maxShardsPerNode=1&collection.configName=core1_schema "
這將返回如下響應, { "responseHeader": { "QTime": 7494, "status": 0 }, "success": { "127.0.1.1:8983_solr": { "core": "core1_shard1_replica_n2", "responseHeader": { "QTime": 6093, "status": 0 } }, "127.0.1.1:8984_solr": { "core": "core1_shard1_replica_n1", "responseHeader": { "QTime": 5802, "status": 0 } } } }
如您所見,已在node2上創建了core1的復制。 現在,您將不得不為其他兩個內核重復步驟5和6。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.