Michael Lando | a544510 | 2018-03-04 14:53:33 +0200 | [diff] [blame] | 1 | |
| 2 | cluster.name: elasticsearch_1_5_2 |
| 3 | |
| 4 | discovery.zen.ping.multicast.enabled: false |
| 5 | discovery.zen.ping.unicast.enabled: true |
| 6 | discovery.zen.ping.unicast.hosts: elasticsearch_host |
| 7 | |
| 8 | |
| 9 | |
| 10 | ##################### Elasticsearch Configuration Example ##################### |
| 11 | |
| 12 | # This file contains an overview of various configuration settings, |
| 13 | # targeted at operations staff. Application developers should |
| 14 | # consult the guide at <http://elasticsearch.org/guide>. |
| 15 | # |
| 16 | # The installation procedure is covered at |
| 17 | # <http://elasticsearch.org/guide/en/elasticsearch/reference/current/setup.html>. |
| 18 | # |
| 19 | # Elasticsearch comes with reasonable defaults for most settings, |
| 20 | # so you can try it out without bothering with configuration. |
| 21 | # |
| 22 | # Most of the time, these defaults are just fine for running a production |
| 23 | # cluster. If you're fine-tuning your cluster, or wondering about the |
| 24 | # effect of certain configuration option, please _do ask_ on the |
| 25 | # mailing list or IRC channel [http://elasticsearch.org/community]. |
| 26 | |
| 27 | # Any element in the configuration can be replaced with environment variables |
| 28 | # by placing them in ${...} notation. For example: |
| 29 | # |
| 30 | # node.rack: ${RACK_ENV_VAR} |
| 31 | |
| 32 | # For information on supported formats and syntax for the config file, see |
| 33 | # <http://elasticsearch.org/guide/en/elasticsearch/reference/current/setup-configuration.html> |
| 34 | |
| 35 | |
| 36 | ################################### Cluster ################################### |
| 37 | |
| 38 | # Cluster name identifies your cluster for auto-discovery. If you're running |
| 39 | # multiple clusters on the same network, make sure you're using unique names. |
| 40 | # |
| 41 | # cluster.name: elasticsearch |
| 42 | |
| 43 | |
| 44 | #################################### Node ##################################### |
| 45 | |
| 46 | # Node names are generated dynamically on startup, so you're relieved |
| 47 | # from configuring them manually. You can tie this node to a specific name: |
| 48 | # |
| 49 | # node.name: "Franz Kafka" |
| 50 | |
| 51 | # Every node can be configured to allow or deny being eligible as the master, |
| 52 | # and to allow or deny to store the data. |
| 53 | # |
| 54 | # Allow this node to be eligible as a master node (enabled by default): |
| 55 | # |
| 56 | # node.master: true |
| 57 | # |
| 58 | # Allow this node to store data (enabled by default): |
| 59 | # |
| 60 | # node.data: true |
| 61 | |
| 62 | # You can exploit these settings to design advanced cluster topologies. |
| 63 | # |
| 64 | # 1. You want this node to never become a master node, only to hold data. |
| 65 | # This will be the "workhorse" of your cluster. |
| 66 | # |
| 67 | # node.master: false |
| 68 | # node.data: true |
| 69 | # |
| 70 | # 2. You want this node to only serve as a master: to not store any data and |
| 71 | # to have free resources. This will be the "coordinator" of your cluster. |
| 72 | # |
| 73 | # node.master: true |
| 74 | # node.data: false |
| 75 | # |
| 76 | # 3. You want this node to be neither master nor data node, but |
| 77 | # to act as a "search load balancer" (fetching data from nodes, |
| 78 | # aggregating results, etc.) |
| 79 | # |
| 80 | # node.master: false |
| 81 | # node.data: false |
| 82 | |
| 83 | # Use the Cluster Health API [http://localhost:9200/_cluster/health], the |
| 84 | # Node Info API [http://localhost:9200/_nodes] or GUI tools |
| 85 | # such as <http://www.elasticsearch.org/overview/marvel/>, |
| 86 | # <http://github.com/karmi/elasticsearch-paramedic>, |
| 87 | # <http://github.com/lukas-vlcek/bigdesk> and |
| 88 | # <http://mobz.github.com/elasticsearch-head> to inspect the cluster state. |
| 89 | |
| 90 | # A node can have generic attributes associated with it, which can later be used |
| 91 | # for customized shard allocation filtering, or allocation awareness. An attribute |
| 92 | # is a simple key value pair, similar to node.key: value, here is an example: |
| 93 | # |
| 94 | # node.rack: rack314 |
| 95 | |
| 96 | # By default, multiple nodes are allowed to start from the same installation location |
| 97 | # to disable it, set the following: |
| 98 | # node.max_local_storage_nodes: 1 |
| 99 | |
| 100 | |
| 101 | #################################### Index #################################### |
| 102 | |
| 103 | # You can set a number of options (such as shard/replica options, mapping |
| 104 | # or analyzer definitions, translog settings, ...) for indices globally, |
| 105 | # in this file. |
| 106 | # |
| 107 | # Note, that it makes more sense to configure index settings specifically for |
| 108 | # a certain index, either when creating it or by using the index templates API. |
| 109 | # |
| 110 | # See <http://elasticsearch.org/guide/en/elasticsearch/reference/current/index-modules.html> and |
| 111 | # <http://elasticsearch.org/guide/en/elasticsearch/reference/current/indices-create-index.html> |
| 112 | # for more information. |
| 113 | |
| 114 | # Set the number of shards (splits) of an index (5 by default): |
| 115 | # |
| 116 | # index.number_of_shards: 5 |
| 117 | |
| 118 | # Set the number of replicas (additional copies) of an index (1 by default): |
| 119 | # |
| 120 | # index.number_of_replicas: 1 |
| 121 | |
| 122 | # Note, that for development on a local machine, with small indices, it usually |
| 123 | # makes sense to "disable" the distributed features: |
| 124 | # |
| 125 | index.number_of_shards: 1 |
| 126 | index.number_of_replicas: 0 |
| 127 | |
| 128 | # These settings directly affect the performance of index and search operations |
| 129 | # in your cluster. Assuming you have enough machines to hold shards and |
| 130 | # replicas, the rule of thumb is: |
| 131 | # |
| 132 | # 1. Having more *shards* enhances the _indexing_ performance and allows to |
| 133 | # _distribute_ a big index across machines. |
| 134 | # 2. Having more *replicas* enhances the _search_ performance and improves the |
| 135 | # cluster _availability_. |
| 136 | # |
| 137 | # The "number_of_shards" is a one-time setting for an index. |
| 138 | # |
| 139 | # The "number_of_replicas" can be increased or decreased anytime, |
| 140 | # by using the Index Update Settings API. |
| 141 | # |
| 142 | # Elasticsearch takes care about load balancing, relocating, gathering the |
| 143 | # results from nodes, etc. Experiment with different settings to fine-tune |
| 144 | # your setup. |
| 145 | |
| 146 | # Use the Index Status API (<http://localhost:9200/A/_status>) to inspect |
| 147 | # the index status. |
| 148 | |
| 149 | |
| 150 | #################################### Paths #################################### |
| 151 | |
| 152 | # Path to directory containing configuration (this file and logging.yml): |
| 153 | # |
| 154 | path.conf: /src/test/resources |
| 155 | |
| 156 | # Path to directory where to store index data allocated for this node. |
| 157 | # |
| 158 | path.data: target/esdata |
| 159 | # |
| 160 | # Can optionally include more than one location, causing data to be striped across |
| 161 | # the locations (a la RAID 0) on a file level, favouring locations with most free |
| 162 | # space on creation. For example: |
| 163 | # |
| 164 | # path.data: /path/to/data1,/path/to/data2 |
| 165 | |
| 166 | # Path to temporary files: |
| 167 | # |
| 168 | path.work: /target/eswork |
| 169 | |
| 170 | # Path to log files: |
| 171 | # |
| 172 | path.logs: /target/eslogs |
| 173 | |
| 174 | # Path to where plugins are installed: |
| 175 | # |
| 176 | # path.plugins: /path/to/plugins |
| 177 | |
| 178 | |
| 179 | #################################### Plugin ################################### |
| 180 | |
| 181 | # If a plugin listed here is not installed for current node, the node will not start. |
| 182 | # |
| 183 | # plugin.mandatory: mapper-attachments,lang-groovy |
| 184 | |
| 185 | |
| 186 | ################################### Memory #################################### |
| 187 | |
| 188 | # Elasticsearch performs poorly when JVM starts swapping: you should ensure that |
| 189 | # it _never_ swaps. |
| 190 | # |
| 191 | # Set this property to true to lock the memory: |
| 192 | # |
| 193 | # bootstrap.mlockall: true |
| 194 | |
| 195 | # Make sure that the ES_MIN_MEM and ES_MAX_MEM environment variables are set |
| 196 | # to the same value, and that the machine has enough memory to allocate |
| 197 | # for Elasticsearch, leaving enough memory for the operating system itself. |
| 198 | # |
| 199 | # You should also make sure that the Elasticsearch process is allowed to lock |
| 200 | # the memory, eg. by using `ulimit -l unlimited`. |
| 201 | |
| 202 | |
| 203 | ############################## Network And HTTP ############################### |
| 204 | |
| 205 | # Elasticsearch, by default, binds itself to the 0.0.0.0 address, and listens |
| 206 | # on port [9200-9300] for HTTP traffic and on port [9300-9400] for node-to-node |
| 207 | # communication. (the range means that if the port is busy, it will automatically |
| 208 | # try the next port). |
| 209 | |
| 210 | # Set the bind address specifically (IPv4 or IPv6): |
| 211 | # |
| 212 | # network.bind_host: 192.168.0.1 |
| 213 | |
| 214 | # Set the address other nodes will use to communicate with this node. If not |
| 215 | # set, it is automatically derived. It must point to an actual IP address. |
| 216 | # |
| 217 | # network.publish_host: 192.168.0.1 |
| 218 | |
| 219 | # Set both 'bind_host' and 'publish_host': |
| 220 | # |
| 221 | # network.host: 192.168.0.1 |
| 222 | |
| 223 | # Set a custom port for the node to node communication (9300 by default): |
| 224 | # |
| 225 | # transport.tcp.port: 9300 |
| 226 | |
| 227 | # Enable compression for all communication between nodes (disabled by default): |
| 228 | # |
| 229 | # transport.tcp.compress: true |
| 230 | |
| 231 | # Set a custom port to listen for HTTP traffic: |
| 232 | # |
| 233 | # http.port: 9200 |
| 234 | |
| 235 | # Set a custom allowed content length: |
| 236 | # |
| 237 | # http.max_content_length: 100mb |
| 238 | |
| 239 | # Disable HTTP completely: |
| 240 | # |
| 241 | # http.enabled: false |
| 242 | |
| 243 | |
| 244 | ################################### Gateway ################################### |
| 245 | |
| 246 | # The gateway allows for persisting the cluster state between full cluster |
| 247 | # restarts. Every change to the state (such as adding an index) will be stored |
| 248 | # in the gateway, and when the cluster starts up for the first time, |
| 249 | # it will read its state from the gateway. |
| 250 | |
| 251 | # There are several types of gateway implementations. For more information, see |
| 252 | # <http://elasticsearch.org/guide/en/elasticsearch/reference/current/modules-gateway.html>. |
| 253 | |
| 254 | # The default gateway type is the "local" gateway (recommended): |
| 255 | # |
| 256 | # gateway.type: local |
| 257 | |
| 258 | # Settings below control how and when to start the initial recovery process on |
| 259 | # a full cluster restart (to reuse as much local data as possible when using shared |
| 260 | # gateway). |
| 261 | |
| 262 | # Allow recovery process after N nodes in a cluster are up: |
| 263 | # |
| 264 | gateway.recover_after_nodes: 1 |
| 265 | |
| 266 | # Set the timeout to initiate the recovery process, once the N nodes |
| 267 | # from previous setting are up (accepts time value): |
| 268 | # |
| 269 | # gateway.recover_after_time: 5m |
| 270 | |
| 271 | # Set how many nodes are expected in this cluster. Once these N nodes |
| 272 | # are up (and recover_after_nodes is met), begin recovery process immediately |
| 273 | # (without waiting for recover_after_time to expire): |
| 274 | # |
| 275 | gateway.expected_nodes: 1 |
| 276 | |
| 277 | |
| 278 | ############################# Recovery Throttling ############################# |
| 279 | |
| 280 | # These settings allow to control the process of shards allocation between |
| 281 | # nodes during initial recovery, replica allocation, rebalancing, |
| 282 | # or when adding and removing nodes. |
| 283 | |
| 284 | # Set the number of concurrent recoveries happening on a node: |
| 285 | # |
| 286 | # 1. During the initial recovery |
| 287 | # |
| 288 | # cluster.routing.allocation.node_initial_primaries_recoveries: 4 |
| 289 | # |
| 290 | # 2. During adding/removing nodes, rebalancing, etc |
| 291 | # |
| 292 | # cluster.routing.allocation.node_concurrent_recoveries: 2 |
| 293 | |
| 294 | # Set to throttle throughput when recovering (eg. 100mb, by default 20mb): |
| 295 | # |
| 296 | # indices.recovery.max_bytes_per_sec: 20mb |
| 297 | |
| 298 | # Set to limit the number of open concurrent streams when |
| 299 | # recovering a shard from a peer: |
| 300 | # |
| 301 | # indices.recovery.concurrent_streams: 5 |
| 302 | |
| 303 | |
| 304 | ################################## Discovery ################################## |
| 305 | |
| 306 | # Discovery infrastructure ensures nodes can be found within a cluster |
| 307 | # and master node is elected. Multicast discovery is the default. |
| 308 | |
| 309 | # Set to ensure a node sees N other master eligible nodes to be considered |
| 310 | # operational within the cluster. Its recommended to set it to a higher value |
| 311 | # than 1 when running more than 2 nodes in the cluster. |
| 312 | # |
| 313 | # discovery.zen.minimum_master_nodes: 1 |
| 314 | |
| 315 | # Set the time to wait for ping responses from other nodes when discovering. |
| 316 | # Set this option to a higher value on a slow or congested network |
| 317 | # to minimize discovery failures: |
| 318 | # |
| 319 | # discovery.zen.ping.timeout: 3s |
| 320 | |
| 321 | # For more information, see |
| 322 | # <http://elasticsearch.org/guide/en/elasticsearch/reference/current/modules-discovery-zen.html> |
| 323 | |
| 324 | # Unicast discovery allows to explicitly control which nodes will be used |
| 325 | # to discover the cluster. It can be used when multicast is not present, |
| 326 | # or to restrict the cluster communication-wise. |
| 327 | # |
| 328 | # 1. Disable multicast discovery (enabled by default): |
| 329 | # |
| 330 | # discovery.zen.ping.multicast.enabled: false |
| 331 | # |
| 332 | # 2. Configure an initial list of master nodes in the cluster |
| 333 | # to perform discovery when new nodes (master or data) are started: |
| 334 | # |
| 335 | # discovery.zen.ping.unicast.hosts: ["host1", "host2:port"] |
| 336 | |
| 337 | # EC2 discovery allows to use AWS EC2 API in order to perform discovery. |
| 338 | # |
| 339 | # You have to install the cloud-aws plugin for enabling the EC2 discovery. |
| 340 | # |
| 341 | # For more information, see |
| 342 | # <http://elasticsearch.org/guide/en/elasticsearch/reference/current/modules-discovery-ec2.html> |
| 343 | # |
| 344 | # See <http://elasticsearch.org/tutorials/elasticsearch-on-ec2/> |
| 345 | # for a step-by-step tutorial. |
| 346 | |
| 347 | # GCE discovery allows to use Google Compute Engine API in order to perform discovery. |
| 348 | # |
| 349 | # You have to install the cloud-gce plugin for enabling the GCE discovery. |
| 350 | # |
| 351 | # For more information, see <https://github.com/elasticsearch/elasticsearch-cloud-gce>. |
| 352 | |
| 353 | # Azure discovery allows to use Azure API in order to perform discovery. |
| 354 | # |
| 355 | # You have to install the cloud-azure plugin for enabling the Azure discovery. |
| 356 | # |
| 357 | # For more information, see <https://github.com/elasticsearch/elasticsearch-cloud-azure>. |
| 358 | |
| 359 | ################################## Slow Log ################################## |
| 360 | |
| 361 | # Shard level query and fetch threshold logging. |
| 362 | |
| 363 | #index.search.slowlog.threshold.query.warn: 10s |
| 364 | #index.search.slowlog.threshold.query.info: 5s |
| 365 | #index.search.slowlog.threshold.query.debug: 2s |
| 366 | #index.search.slowlog.threshold.query.trace: 500ms |
| 367 | |
| 368 | #index.search.slowlog.threshold.fetch.warn: 1s |
| 369 | #index.search.slowlog.threshold.fetch.info: 800ms |
| 370 | #index.search.slowlog.threshold.fetch.debug: 500ms |
| 371 | #index.search.slowlog.threshold.fetch.trace: 200ms |
| 372 | |
| 373 | #index.indexing.slowlog.threshold.index.warn: 10s |
| 374 | #index.indexing.slowlog.threshold.index.info: 5s |
| 375 | #index.indexing.slowlog.threshold.index.debug: 2s |
| 376 | #index.indexing.slowlog.threshold.index.trace: 500ms |
| 377 | |
| 378 | ################################## GC Logging ################################ |
| 379 | |
| 380 | #monitor.jvm.gc.young.warn: 1000ms |
| 381 | #monitor.jvm.gc.young.info: 700ms |
| 382 | #monitor.jvm.gc.young.debug: 400ms |
| 383 | |
| 384 | #monitor.jvm.gc.old.warn: 10s |
| 385 | #monitor.jvm.gc.old.info: 5s |
| 386 | #monitor.jvm.gc.old.debug: 2s |
| 387 | |