Elasticsearch requires configuration and settings file changes to be made consistently across your the Elasticsearch cluster.
Table of Contents | ||
---|---|---|
|
...
Upgrading Elasticsearch in place (using the same index) if it detects that a supported version (6.8.6) is already installed and configured
Editing
/etc/elasticsearch/elasticsearch.yml
(except for changing the path.data variable to use a different data directory)Editing
/etc/elasticsearch/log4j2.properties
Editing
/usr/lib/systemd/system/elasticsearch.service
Editing
/etc/sysconfig/elasticsearch
Creating the override file for Systemd:
/etc/systemd/system/elasticsearch.service.d/override.conf
Bulk | This method is most efficient if you have a large number of nodes and/or have manual configurations to apply to the
| |||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Non-Bulk |
|
...
The paths given are relative to the Elasticsearch installation directory, which is assumed to be your the working directory.
Info |
---|
Caution
|
Elasticsearch Config File
Info |
---|
Version differencesThe Elasticsearch configuration settings have changed with each major release. To track how they changed since Elasticsearch 2.3.3, see Elasticsearch Configuration Differences. |
Edit the Elasticsearch config file: /etc/elasticsearch/elasticsearch.yml
action.auto_create_index: "+csmeter*,+*_nfsconnector,.watches, | Needed to disable automatic index creation, csmeter indices, and Swarm NFS connectors. (v10.1) | |||||
cluster.name: <ES_cluster_name> | Provide your the Elasticsearch cluster a unique name, which is unrelated to your the Swarm cluster name. Do not use periods in the name.
| |||||
node.name: <ES_node_name> | Optional. Elasticsearch supplies a node name if you do one is not set one. Do not use periods in the name. | |||||
network.host: _site_ | Assign a specific hostname or IP address, which requires clients to access the ES server using that address. If you use using a hostname, update | |||||
cluster.initial_master_nodes | (ES 7+) For first-time bootstrapping of a production ES cluster. Set to an array or comma-delimited list of the hostnames of the master-eligible ES nodes whose votes should be counted in the very first election. | |||||
discovery.zen. | (ES 6 only) Set to (number of master-eligible nodes / 2, rounded down) + 1. Prevents split-brain scenarios by setting the minimum number of ES nodes online before deciding on electing a new master. | |||||
discovery.seed_hosts | (ES 7+) Enables auto-clustering of ES nodes across hosts. Set to an array or comma-delimited list of the addresses of all the master-eligible nodes in the cluster. | |||||
discovery.zen.ping.unicast.hosts: ["es0", "es1"] | (ES 6 only) Set to the list of node names/IPs in the cluster, verifying all ES servers are included. Multicast is disabled by default. | |||||
gateway.expected_nodes: 4 | Add and set to the number of nodes in your the ES cluster. Recovery of local shards starts as soon as this number of nodes have joined the cluster. It falls back to the | |||||
gateway.recover_after_nodes: 2 | Set to the minimum number of ES nodes started before going into operation status, computed as such:
| |||||
bootstrap.memory_lock: true | Set to lock the memory on startup to verify Elasticsearch never swaps (swapping makes it perform poorly). Verify enough system memory resources are available for all processes running on the server. To allow the
| |||||
path.data: <path_to_data_directory> | By default, path.data goes to
| |||||
thread_pool.write.queue_size | The size of the queue used for bulk indexing. This variable was called |
...
In its default location, logging has the needed ownership. However, if If you want to move the log directory, choose a separate, dedicated partition of ample size, and make the elasticsearch
user the owner of that directory:
...
This is the log of deprecated actions, to inform you for future migrations. Adjust the log size and log file count for the deprecation log:
...