Advertisement
Guest User

Untitled

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