{"id":167,"date":"2018-11-04T13:28:36","date_gmt":"2018-11-04T10:28:36","guid":{"rendered":"https:\/\/artem.services\/?p=167"},"modified":"2018-11-04T21:30:05","modified_gmt":"2018-11-04T18:30:05","slug":"elk-cluster","status":"publish","type":"post","link":"https:\/\/artem.services\/?p=167","title":{"rendered":"Elasticsearch &#8212; \u041a\u043b\u0430\u0441\u0442\u0435\u0440"},"content":{"rendered":"<p><img loading=\"lazy\" class=\"size-full wp-image-223 aligncenter\" src=\"https:\/\/artem.services\/wp-content\/uploads\/2018\/11\/Elasticsearch-Logo.png\" alt=\"\" width=\"4796\" height=\"1277\" srcset=\"https:\/\/artem.services\/wp-content\/uploads\/2018\/11\/Elasticsearch-Logo.png 4796w, https:\/\/artem.services\/wp-content\/uploads\/2018\/11\/Elasticsearch-Logo-300x80.png 300w, https:\/\/artem.services\/wp-content\/uploads\/2018\/11\/Elasticsearch-Logo-768x204.png 768w, https:\/\/artem.services\/wp-content\/uploads\/2018\/11\/Elasticsearch-Logo-1024x273.png 1024w, https:\/\/artem.services\/wp-content\/uploads\/2018\/11\/Elasticsearch-Logo-954x254.png 954w, https:\/\/artem.services\/wp-content\/uploads\/2018\/11\/Elasticsearch-Logo-1354x361.png 1354w\" sizes=\"(max-width: 4796px) 100vw, 4796px\" \/><\/p>\n<p><a href=\"https:\/\/artem.services\/?p=163\" target=\"_blank\" rel=\"noopener\">\u0412 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0435\u0439 \u0441\u0442\u0430\u0442\u044c\u0435<\/a> \u0431\u044b\u043b \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d <strong>Elasticsearch<\/strong> \u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0435<strong> CentOS 7<\/strong>. \u0414\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043a\u043b\u0430\u0441\u0442\u0435\u0440 \u043d\u0430\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043c\u0438\u043d\u0438\u043c\u0443\u043c 2 \u0438\u043d\u0441\u0442\u0430\u043d\u0441\u0430 \u0441 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u044b\u043c <strong>Elasticsearch<\/strong>.<br \/>\n\u0422\u0430\u043a \u043a\u0430\u043a \u044d\u0442\u043e \u0442\u0435\u0441\u0442\u043e\u0432\u0430\u044f \u0441\u0440\u0435\u0434\u0430, \u0442\u043e \u0432 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0435 \u0431\u0443\u0434\u0435\u0442 2 \u0432\u043e\u0440\u043a\u0435\u0440\u0430 <strong>Elasticsearch<\/strong>, \u0430 \u0442\u0430\u043a \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u043d\u0435\u0447\u0435\u0442\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e, \u0438 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e &#8212; 3.<\/p>\n<p>\u041e\u0442\u043a\u0440\u043e\u0435\u043c \u0444\u0430\u0439\u043b \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 <strong>Elasticsearch<\/strong>:<\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\nvim \/etc\/elasticsearch\/elasticsearch.yml\r\n<\/pre>\n<p>\u0422\u0443\u0442 \u043d\u0430\u043c \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u044b \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b:<\/p>\n<ul>\n<li>cluster.name \u2014 \u0438\u043c\u044f \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0430;<\/li>\n<li>node.name: \u0438\u043c\u044f \u043d\u043e\u0434\u044b;<\/li>\n<li>network.host: IP \u0430\u0434\u0440\u0435\u0441, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0441\u0435\u0440\u0432\u0435\u0440 \u0431\u0443\u0434\u0435\u0442 &quot;\u0441\u043b\u0443\u0448\u0430\u0442\u044c&quot;.<\/li>\n<\/ul>\n<p><!--more--><\/p>\n<p>\u041c\u043d\u0435 \u043d\u0430 <strong>AWS<\/strong> \u0442\u0430\u043a\u043e\u0433\u043e &quot;\u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u043d\u0430\u0431\u043e\u0440\u0430&quot; \u043d\u0435 \u0445\u0432\u0430\u0442\u0438\u043b\u043e, <strong>Elasticsearch<\/strong> \u043f\u0430\u0434\u0430\u043b \u0441 \u0442\u0430\u043a\u0438\u043c \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435\u043c \u0432 \u043b\u043e\u0433:<\/p>\n<pre>bound or publishing to a non-loopback address, enforcing bootstrap checks<\/pre>\n<p>\u0412\u0438\u043d\u043e\u0439 \u0442\u043e\u043c\u0443 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 &quot;<strong>network.bind_host<\/strong>&quot; \u0438 &quot;<strong>network.publish_host<\/strong>&quot;. \u041f\u0440\u0438\u0432\u0435\u043b \u043a\u043e\u043d\u0444\u0438\u0433 \u043a \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u043c\u0443 \u0432\u0438\u0434\u0443:<\/p>\n<pre>cluster.name: artem-es\r\nnode.name: node-US\r\nnode.master: true\r\nnode.data: true\r\nnetwork.host: 0.0.0.0\r\nnetwork.bind_host: 0.0.0.0\r\nnetwork.publish_host: 1.1.1.1<\/pre>\n<p><strong>Elasticsearch<\/strong> \u043f\u0435\u0440\u0435\u0441\u0442\u0430\u043b \u043f\u0430\u0434\u0430\u0442\u044c \u043f\u0440\u0438 \u0437\u0430\u043f\u0443\u0441\u043a\u0435.<\/p>\n<p>\u0418\u043c\u044f \u043d\u043e\u0434\u044b: <strong>node-US<\/strong>, \u0442\u0430\u043a \u043a\u0430\u043a \u0442\u0435\u0441\u0442\u0438\u043b \u0437\u0430\u043f\u0443\u0441\u043a \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0430 <strong>Elasticsearch<\/strong> \u0432 \u0440\u0430\u0437\u043d\u044b\u0445 \u0437\u043e\u043d\u0430\u0445.<\/p>\n<p>\u0412\u0442\u043e\u0440\u043e\u0439 \u0438\u043d\u0441\u0442\u0430\u043d\u0441 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u043c \u043f\u043e \u0442\u043e\u043c\u0443 \u0436\u0435 \u043f\u043e\u0434\u043e\u0431\u0438\u044e. \u0418 \u0442\u0430\u043a \u0435\u0441\u0442\u044c 2 \u0438\u043d\u0441\u0442\u0430\u043d\u0441\u0430, \u044d\u0442\u043e <strong>node-US<\/strong> \u0438 <strong>node-EU<\/strong>.<\/p>\n<p>\u041d\u0435\u043e\u0445\u043e\u0434\u0438\u043c\u043e \u0440\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044c \u0438\u043c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0434\u0440\u0443\u0433 \u0434\u0440\u0443\u0433\u0443 \u043f\u043e <strong>TCP<\/strong> \u043f\u043e\u0440\u0442\u0443 <strong>9300<\/strong>. \u041d\u0430 <strong>AWS<\/strong> \u044d\u0442\u043e \u0434\u0435\u043b\u0430\u0435\u0442\u0441\u044f \u0432 <strong>SecureGroup<\/strong>, \u0435\u0441\u043b\u0438 \u0432\u044b \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u043b\u0438 \u043d\u0435 \u043d\u0430 <strong>AWS<\/strong>, \u0442\u043e \u0434\u043e\u0431\u0430\u0432\u044c\u0442\u0435 \u0440\u0430\u0437\u0440\u0435\u0448\u0430\u044e\u0449\u0438\u0435 \u043f\u0440\u0430\u0432\u0438\u043b\u043e \u0432 \u0444\u0430\u0435\u0440\u0432\u043e\u043b\u0435.<\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u0432\u0441\u0435 \u0433\u043e\u0442\u043e\u0432\u043e, \u0447\u0442\u043e\u0431\u044b \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0438\u0442\u044c \u043d\u0430\u0448\u0438 \u043d\u043e\u0434\u044b \u0432 \u043a\u043b\u0430\u0441\u0442\u0435\u0440.<\/p>\n<p>\u0412\u0435\u0440\u043d\u0435\u043c\u0441\u044f \u043e\u043f\u044f\u0442\u044c \u043a \u0444\u0430\u0439\u043b\u0443 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438:<\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\nvim \/etc\/elasticsearch\/elasticsearch.yml\r\n<\/pre>\n<p>\u0418 \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435:<\/p>\n<pre>discovery.zen.ping.unicast.hosts: [\"1.1.1.1\", \"2.2.2.2\"]\r\ndiscovery.zen.minimum_master_nodes: 1<\/pre>\n<p>\u041f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435.<\/p>\n<p><strong>\u0425\u043e\u0441\u0442 node-US<\/strong>:<\/p>\n<pre>cluster.name: artem-es\r\nnode.name: node-US\r\nnode.master: true\r\nnode.data: true\r\nnetwork.host: 0.0.0.0\r\nnetwork.bind_host: 0.0.0.0\r\nnetwork.publish_host: 1.1.1.1\r\ndiscovery.zen.ping.unicast.hosts: [\"1.1.1.1\", \"2.2.2.2\"]\r\ndiscovery.zen.minimum_master_nodes: 1<\/pre>\n<p><strong>\u0425\u043e\u0441\u0442 node-EU<\/strong>:<\/p>\n<pre>cluster.name: artem-es\r\nnode.name: node-EU\r\nnode.master: true\r\nnode.data: true\r\nnetwork.host: 0.0.0.0\r\nnetwork.bind_host: 0.0.0.0\r\nnetwork.publish_host: 2.2.2.2\r\ndiscovery.zen.ping.unicast.hosts: [\"1.1.1.1\", \"2.2.2.2\"]\r\ndiscovery.zen.minimum_master_nodes: 1<\/pre>\n<p>\u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0441\u043f\u0438\u0441\u043e\u043a \u0445\u043e\u0441\u0442\u043e\u0432 \u0432 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0435 \u043c\u043e\u0436\u043d\u043e \u0442\u0430\u043a:<\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\ncurl -X GET localhost:9200\/_cat\/nodes?v\r\n<\/pre>\n<p>\u0421\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0430:<\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\ncurl -X GET localhost:9200\/_cluster\/health?pretty\r\n<\/pre>\n<p>\u041d\u0430 \u044d\u0442\u043e\u043c \u0441\u0442\u0430\u0442\u044c\u044f \u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0435 <strong>Elasticsearch<\/strong> \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0430, \u0432 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u043c\u044b \u043a \u0443\u0436\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u043c\u0443 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0443 \u043f\u0440\u0438\u043a\u0440\u0443\u0442\u0438\u043c Kibana.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u0412 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0435\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0431\u044b\u043b \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d Elasticsearch \u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 CentOS 7. \u0414\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043a\u043b\u0430\u0441\u0442\u0435\u0440 \u043d\u0430\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043c\u0438\u043d\u0438\u043c\u0443\u043c 2 \u0438\u043d\u0441\u0442\u0430\u043d\u0441\u0430 \u0441 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u044b\u043c Elasticsearch. \u0422\u0430\u043a \u043a\u0430\u043a \u044d\u0442\u043e \u0442\u0435\u0441\u0442\u043e\u0432\u0430\u044f \u0441\u0440\u0435\u0434\u0430, \u0442\u043e \u0432 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0435 \u0431\u0443\u0434\u0435\u0442 2 \u0432\u043e\u0440\u043a\u0435\u0440\u0430 Elasticsearch, \u0430 \u0442\u0430\u043a \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u043d\u0435\u0447\u0435\u0442\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e, \u0438 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e &#8212; 3. \u041e\u0442\u043a\u0440\u043e\u0435\u043c \u0444\u0430\u0439\u043b \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 Elasticsearch: \u0422\u0443\u0442 \u043d\u0430\u043c \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u044b \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b: cluster.name &hellip; <a href=\"https:\/\/artem.services\/?p=167\" class=\"more-link\">\u041f\u0440\u043e\u0434\u043e\u043b\u0436\u0438\u0442\u044c \u0447\u0438\u0442\u0430\u0442\u044c<span class=\"screen-reader-text\"> &quot;Elasticsearch &#8212; \u041a\u043b\u0430\u0441\u0442\u0435\u0440&quot;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[2],"tags":[28],"_links":{"self":[{"href":"https:\/\/artem.services\/index.php?rest_route=\/wp\/v2\/posts\/167"}],"collection":[{"href":"https:\/\/artem.services\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/artem.services\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/artem.services\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/artem.services\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=167"}],"version-history":[{"count":10,"href":"https:\/\/artem.services\/index.php?rest_route=\/wp\/v2\/posts\/167\/revisions"}],"predecessor-version":[{"id":225,"href":"https:\/\/artem.services\/index.php?rest_route=\/wp\/v2\/posts\/167\/revisions\/225"}],"wp:attachment":[{"href":"https:\/\/artem.services\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=167"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/artem.services\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=167"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/artem.services\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=167"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}