Exolution uses Elasticsearch for indexing. Elasticsearch can be installed on any machine on the network. Exolution will work with an existing instance of Elasticsearch 6.*, 7.* and 8.*. Skip this section if you plan to use an existing instance of Elasticsearch.
Install Elasticsearch
- Download Elasticsearch 8.11, and extract it to the root of a drive. The Elasticsearch indexes will be created under \elasticsearch-8.11\data\ directory, so make sure the Elasticsearch install drive has enough space to store indexes.
- Open a command prompt with administrative privilege and go to \elasticsearch-8.7\bin.
- Run command elasticsearch-service.bat install. This will install Elasticsearch as a Windows service
- Run command elasticsearch-service.bat manager. This will open the management tab for Elasticsearch service.
a. On the General tab set Startup Type to Automatic.
b. On the Java tab, update Initial Memory Pool and Maximum Memory Pool values to appropriate. - Open Run (WinKey + R), type services.msc and click Ok, it will open the Services window.
- Find Elasticsearch 8.7 (elasticsearch-service-x64) and open properties.
a. On the Recovery tab change values of First Failure, Second Failure, and Subsequent Failures to Restart the Service - Start Elasticsearch service.
Configure Elasticsearch
If the Elasticsearch service is installed on a machine other than the Exolution server then configure Elasticsearch to make it accessible to Exolution Server by following the steps below. If Elasticsearch is installed on the Exolution Server, then skip the Configure Elasticsearch section.
- Open the file \elasticsearch-8.7\config\elasticsearch.yml in a text file editor. The Notepad may not show the formatting properly, so try using a different text file editor.
- Add the following lines at the end of elasticsearch.yml
# ---------------------------------- For backward compatibility -----------------------------------
#persist setting
indices.id_field_data.enabled: true - Save and close elasticsearch.yml
- Restart Elasticsearch service
Configure Elasticsearch disk space
By default, Elasticsearch makes all the indexes read-only when the total free space on the Elasticsearch index directory falls below 15% of the total drive size. Once the indexes become read-only, they need to update one-by-one. In order to change the threshold, place the following code at the end of the Elasticsearch configuration file elasticsearch.yml
#---------------------------------Disk-------------------------------------------
#You cannot mix the usage of percentage values and byte values within these settings.
#Either all are set to percentage values, or all are set to byte values.
#Elasticsearch will not allocate shards to nodes that have less than 10gb disk space available
cluster.routing.allocation.disk.watermark.low: 10gb
#Elasticsearch will attempt to relocate shards away from a node (to another node if there is any) whose disk space is below 5gb
cluster.routing.allocation.disk.watermark.high: 5gb
#Elasticsearch enforces a read-only index block (index.blocks.read_only_allow_delete) on every index
#that has one or more shards allocated on the node that has at least one disk space below the flood stage
cluster.routing.allocation.disk.watermark.flood_stage: 2gb
Check Elasticsearch
To check that Elasticsearch is running, browse localhost:9200 in a web browser where Elasticsearch is installed. If text like the below displays, then Elasticsearch is running.
{
"name":"SERVER2023",
"cluster_name":"elasticsearch",
"cluster_uuid":"T-J9G630QGiPFWZQUW4e2w",
"version":{
"number":"8.11.1",
"build_flavor":"default",
"build_type":"zip",
"build_hash":"6f9ff581fbcde658e6f69d6ce03050f060d1fd0c",
"build_date":"2023-11-11T10:05:59.421038163Z",
"build_snapshot":false,
"lucene_version":"9.8.0",
"minimum_wire_compatibility_version":"7.17.0",
"minimum_index_compatibility_version":"7.0.0"
},
"tagline":"You Know, for Search"
}