-
-
Save alexandersanchez/3c599c2ec7633756eae79375d7c0f4a9 to your computer and use it in GitHub Desktop.
ElasticSearch config for a write-heavy cluster
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ################################################################## | |
| # /etc/elasticsearch/elasticsearch.yml | |
| # | |
| # Base configuration Cluster of ElasticSearch with 8 processor per node | |
| # | |
| # Cluster / Node Basics | |
| cluster.name: logng | |
| # Node can have abritrary attributes we can use for routing | |
| node.name: logsearch-01 | |
| node.datacenter: amsterdam | |
| # Force all memory to be locked, forcing the JVM to never swap | |
| bootstrap.mlockall: true | |
| ## Threadpool Settings ## | |
| # Index pool | |
| threadpool.index.type: fixed | |
| threadpool.index.size: 8 | |
| threadpool.index.queue_size: 200 | |
| # Search pool | |
| threadpool.search.type: fixed | |
| threadpool.search.size: 12 | |
| threadpool.search.queue_size: 5000 | |
| # Bulk pool | |
| threadpool.bulk.type: fixed | |
| threadpool.bulk.size: 8 | |
| threadpool.bulk.queue_size: 100 | |
| # Get pool | |
| threadpool.get.type : fixed | |
| threadpool.get.size: 8 | |
| threadpool.get.queue_size: 1000 | |
| #Shards Allocation | |
| cluster.routing.allocation.disk.threshold_enabled:true | |
| # Si el 90% del disco está ocupado se detienen la asignacion para ese nodo. | |
| cluster.routing.allocation.disk.watermark.low: 90% | |
| # Si el 95% del disco está lleno ES empezará a sacar fragmentos de ese nodo para reasignarlos. | |
| cluster.routing.allocation.disk.watermark.high: 95% | |
| # Indices settings | |
| indices.memory.index_buffer_size: 30% | |
| #indices.memory.min_shard_index_buffer_size: 12mb | |
| #indices.memory.min_index_buffer_size: 96mb | |
| # Cache Sizes | |
| #indices.fielddata.cache.size: 15% | |
| #indices.fielddata.cache.expire: 6h | |
| #indices.cache.filter.size: 15% | |
| #indices.cache.filter.expire: 6h | |
| # Indexing Settings for Writes | |
| #index.refresh_interval: 30s | |
| #index.translog.flush_threshold_ops: 50000 | |
| # Minimum nodes alive to constitute an operational cluster | |
| discovery.zen.minimum_master_nodes: 1 | |
| # Unicast Discovery (disable multicast) | |
| discovery.zen.ping.multicast.enabled: false | |
| discovery.zen.ping.unicast.hosts: [ "logsearch-01", "logsearch-02", "logsearch-03" ] | |
| discovery.zen.ping.unicast.hosts.resolve_timeout: 10s | |
| # Master Election | |
| #As part of the ping process a master of the cluster is either elected or joined to. This is done automatically. | |
| #The discovery.zen.ping_timeout (which defaults to 3s) determines how long the node will wait before deciding on | |
| #starting an election or joining an existing cluster | |
| discovery.zen.ping_timeout: 15s | |
| #If discovery.zen.master_election.ignore_non_master_pings is true, pings from nodes that are not | |
| #master eligible (nodes where node.master is false) | |
| #are ignored during master election; the default value is false. | |
| discovery.zen.master_election.ignore_non_master_pings : true | |
| # No Master Block | |
| discovery.zen.no_master_block : all | |
| #Master node Configuration | |
| # Configuration only for Master Elegibles, it node does not process data. | |
| #node.master: true | |
| #node.data: false | |
| #node.ingest: false | |
| #search.remote.connect: false | |
| #Data Node Configuration | |
| # Only for Data Node configuration | |
| #node.master: false | |
| #node.data: true | |
| #node.ingest: false | |
| #search.remote.connect: false | |
| # Set the number of shards (splits) of an index (5 by default): | |
| # | |
| index.number_of_shards: 4 | |
| # Set the number of replicas (additional copies) of an index (1 by default): | |
| # | |
| index.number_of_replicas: 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment