From 85e48763385517b61e75f1c7b1f6fe003d365ddd Mon Sep 17 00:00:00 2001 From: pengln Date: Tue, 15 Feb 2022 14:39:54 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E5=B0=86=E5=8F=82=E6=95=B0=E9=BB=98?= =?UTF-8?q?=E8=AE=A4=E5=80=BC=E4=BB=8EFalse=E6=94=B9=E4=B8=BAno?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- playbooks/roles/filebeat/defaults/main.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/playbooks/roles/filebeat/defaults/main.yml b/playbooks/roles/filebeat/defaults/main.yml index 17ef4d8..4a0d9d3 100644 --- a/playbooks/roles/filebeat/defaults/main.yml +++ b/playbooks/roles/filebeat/defaults/main.yml @@ -30,7 +30,7 @@ filebeat_logs: filebeat_older_dir: "/data/opt/filebeat/{{ instance_name }}" filebeat_older_data_dir: data #[1002041] 只给quick日志和gw日志开启elastic_delays检查 - elastic_delays_metric_enabled: True + elastic_delays_metric_enabled: yes manager: paths: - "/data/game/htdocs/center/manager/storage/cp/logs/*.log" @@ -58,4 +58,4 @@ filebeat_logs: filebeat_older_dir: "/data/opt/filebeat/quick" filebeat_older_data_dir: data #[1002041] 只给quick日志和gw日志开启elastic_delays检查 - elastic_delays_metric_enabled: True \ No newline at end of file + elastic_delays_metric_enabled: yes \ No newline at end of file From 0455b1d144e8a9a1d7141b91d7350800a3bf316d Mon Sep 17 00:00:00 2001 From: pengln Date: Tue, 15 Feb 2022 15:51:29 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E5=A6=82=E6=9E=9Cfilebaet=5Film=5Fenabled?= =?UTF-8?q?=E8=A2=AB=E8=AE=BE=E7=BD=AE=E4=B8=BAfalse=E5=88=99=E7=A6=81?= =?UTF-8?q?=E6=AD=A2ilm=EF=BC=8C=E8=BF=99=E6=98=AF=E4=B8=BA=E4=BA=86?= =?UTF-8?q?=E5=85=BC=E5=AE=B9=E5=8D=8E=E4=B8=BA=E4=BA=91=E7=9A=84ES?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- playbooks/roles/filebeat/templates/filebeat.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/playbooks/roles/filebeat/templates/filebeat.yml b/playbooks/roles/filebeat/templates/filebeat.yml index ff1b972..17c703a 100644 --- a/playbooks/roles/filebeat/templates/filebeat.yml +++ b/playbooks/roles/filebeat/templates/filebeat.yml @@ -41,7 +41,7 @@ filebeat.config.modules: # ======================= Elasticsearch template setting ======================= #[#1002043] 通过强制filebeat注册ilm策略方式,修订意外丢失的ilm策略 -setup.ilm.enabled: true +setup.ilm.enabled: {{ logs[log_type]['filebaet_ilm_enabled'] | default true }} setup.ilm.policy_name: "{{ logs[log_type]['setup_ilm_policy_name'] | default('gw-nginx-ug10') }}" setup.ilm.check_exists: true From f6c876d0647419aaef3f87c30508d6b665ae6ab9 Mon Sep 17 00:00:00 2001 From: pengln Date: Tue, 15 Feb 2022 15:51:43 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E5=A6=82=E6=9E=9Cfilebaet=5Film=5Fenabled?= =?UTF-8?q?=E8=A2=AB=E8=AE=BE=E7=BD=AE=E4=B8=BAfalse=E5=88=99=E7=A6=81?= =?UTF-8?q?=E6=AD=A2ilm=EF=BC=8C=E8=BF=99=E6=98=AF=E4=B8=BA=E4=BA=86?= =?UTF-8?q?=E5=85=BC=E5=AE=B9=E5=8D=8E=E4=B8=BA=E4=BA=91=E7=9A=84ES?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- playbooks/roles/filebeat/templates/filebeat.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/playbooks/roles/filebeat/templates/filebeat.yml b/playbooks/roles/filebeat/templates/filebeat.yml index 17c703a..2aaf273 100644 --- a/playbooks/roles/filebeat/templates/filebeat.yml +++ b/playbooks/roles/filebeat/templates/filebeat.yml @@ -40,7 +40,8 @@ filebeat.config.modules: reload.enabled: false # ======================= Elasticsearch template setting ======================= -#[#1002043] 通过强制filebeat注册ilm策略方式,修订意外丢失的ilm策略 +#[#1002043] 通过强制filebeat注册ilm策略方式,修订意外丢失的ilm策略。 +#如果filebaet_ilm_enabled被设置为false则禁止ilm,这是为了兼容华为云的ES setup.ilm.enabled: {{ logs[log_type]['filebaet_ilm_enabled'] | default true }} setup.ilm.policy_name: "{{ logs[log_type]['setup_ilm_policy_name'] | default('gw-nginx-ug10') }}" setup.ilm.check_exists: true