11.05.2016 Views

Apache Solr Reference Guide Covering Apache Solr 6.0

21SiXmO

21SiXmO

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

This section describes how to run a two-node <strong>Solr</strong>Cloud cluster with no initial collections and a single-node<br />

external ZooKeeper. The commands below assume you have already created the keystore described above.<br />

Configure ZooKeeper<br />

ZooKeeper does not support encrypted communication with clients like <strong>Solr</strong>. There are several related<br />

JIRA tickets where SSL support is being planned/worked on: ZOOKEEPER-235; ZOOKEEPER-236;<br />

ZO<br />

OKEEPER-733; and ZOOKEEPER-1000.<br />

Before you start any <strong>Solr</strong>Cloud nodes, you must configure your solr cluster properties in ZooKeeper, so that<br />

<strong>Solr</strong> nodes know to communicate via SSL.<br />

This section assumes you have created and started a single-node external ZooKeeper on port 2181 on localhost<br />

- see Setting Up an External ZooKeeper Ensemble<br />

The urlScheme cluster-wide property needs to be set to https before any <strong>Solr</strong> node starts up. The example<br />

below uses the zkcli tool that comes with the binary <strong>Solr</strong> distribution to do this:<br />

*nix command<br />

server/scripts/cloud-scripts/zkcli.sh -zkhost localhost:2181 -cmd clusterprop -name<br />

urlScheme -val https<br />

Windows command<br />

server\scripts\cloud-scripts\zkcli.bat -zkhost localhost:2181 -cmd clusterprop -name<br />

urlScheme -val https<br />

If you have set up your ZooKeeper cluster to use a chroot for <strong>Solr</strong>, make sure you use the correct zkhost string<br />

with zkcli, e.g. -zkhost localhost:2181/solr.<br />

Run <strong>Solr</strong>Cloud with SSL<br />

Create <strong>Solr</strong> home directories for two nodes<br />

Create two copies of the server/solr/ directory which will serve as the <strong>Solr</strong> home directories for each of your<br />

two <strong>Solr</strong>Cloud nodes:<br />

*nix commands<br />

mkdir cloud<br />

cp -r server/solr cloud/node1<br />

cp -r server/solr cloud/node2<br />

Windows commands<br />

mkdir cloud<br />

xcopy /E server\solr cloud\node1\<br />

xcopy /E server\solr cloud\node2\<br />

Start the first <strong>Solr</strong> node<br />

Next, start the first <strong>Solr</strong> node on port 8984. Be sure to stop the standalone server first if you started it when<br />

<strong>Apache</strong> <strong>Solr</strong> <strong>Reference</strong> <strong>Guide</strong> <strong>6.0</strong><br />

528

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!