From 20352eeb460574fe7a7d7dc3e08b907c7725b707 Mon Sep 17 00:00:00 2001 From: liubo Date: Tue, 10 Sep 2019 10:47:04 +0800 Subject: [PATCH 1/4] Update disk space check modle (#937) --- roles/check_system_dynamic/tasks/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/roles/check_system_dynamic/tasks/main.yml b/roles/check_system_dynamic/tasks/main.yml index a27253004..d760d4e35 100644 --- a/roles/check_system_dynamic/tasks/main.yml +++ b/roles/check_system_dynamic/tasks/main.yml @@ -1,7 +1,7 @@ --- - name: Disk space check - Fail task when disk is full - raw: df -h . | tail -n1 + shell: df -h . | tail -n1 register: disk_space_st failed_when: " '100%' in disk_space_st.stdout " changed_when: false From ebcd4cb13f45f46c27422c36b8f0a4352444c92c Mon Sep 17 00:00:00 2001 From: Bo Liu Date: Mon, 21 Oct 2019 13:29:23 +0800 Subject: [PATCH 2/4] update release-3.0 config --- roles/tidb/templates/tidb.toml.j2 | 15 +-------------- roles/tikv/vars/default.yml | 3 --- 2 files changed, 1 insertion(+), 17 deletions(-) diff --git a/roles/tidb/templates/tidb.toml.j2 b/roles/tidb/templates/tidb.toml.j2 index f906a1e88..0c726541a 100644 --- a/roles/tidb/templates/tidb.toml.j2 +++ b/roles/tidb/templates/tidb.toml.j2 @@ -5,21 +5,8 @@ {% endfor %} [log] -{% for item, value in tidb_conf.log | dictsort_by_value_type -%} -{% if value is not mapping -%} +{% for item, value in tidb_conf.log | dictsort -%} {{ item }} = {{ value | to_json}} -{% else %} - -[log.{{ item }}] -{% for sub_item, sub_value in value | dictsort -%} -{{ sub_item }} = {{ sub_value | to_json }} -{% endfor %} -{% endif %} -{% endfor %} - -[security] -{% for item, value in tidb_conf.security | dictsort -%} -{{ item }} = {{ value | to_json }} {% endfor %} [status] diff --git a/roles/tikv/vars/default.yml b/roles/tikv/vars/default.yml index e97f6c82e..69e540891 100644 --- a/roles/tikv/vars/default.yml +++ b/roles/tikv/vars/default.yml @@ -279,9 +279,6 @@ rocksdb: ## Allows OS to incrementally sync WAL to disk while it is being written. # wal-bytes-per-sync: "512KB" - ## Options for "Titan" - titan: - ## Options for "Default" Column Family, which stores actual user data. defaultcf: ## Compression method (if any) is used to compress a block. From 772ad129498340fcfaa1157df4d53fbd00c5751d Mon Sep 17 00:00:00 2001 From: Bo Liu Date: Mon, 21 Oct 2019 14:18:56 +0800 Subject: [PATCH 3/4] update release-3.0 config --- roles/tidb/templates/tidb.toml.j2 | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/roles/tidb/templates/tidb.toml.j2 b/roles/tidb/templates/tidb.toml.j2 index 0c726541a..3d64e2f9e 100644 --- a/roles/tidb/templates/tidb.toml.j2 +++ b/roles/tidb/templates/tidb.toml.j2 @@ -9,6 +9,11 @@ {{ item }} = {{ value | to_json}} {% endfor %} +[security] +{% for item, value in tidb_conf.security | dictsort -%} +{{ item }} = {{ value | to_json }} +{% endfor %} + [status] {% for item, value in tidb_conf.status | dictsort -%} {{ item }} = {{ value | to_json }} From 6f07a9919066bb390e04b8a0a1910ed528f0448d Mon Sep 17 00:00:00 2001 From: Bo Liu Date: Mon, 21 Oct 2019 14:34:21 +0800 Subject: [PATCH 4/4] recovery tidb.toml.j2 --- roles/tidb/templates/tidb.toml.j2 | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/roles/tidb/templates/tidb.toml.j2 b/roles/tidb/templates/tidb.toml.j2 index 3d64e2f9e..f906a1e88 100644 --- a/roles/tidb/templates/tidb.toml.j2 +++ b/roles/tidb/templates/tidb.toml.j2 @@ -5,8 +5,16 @@ {% endfor %} [log] -{% for item, value in tidb_conf.log | dictsort -%} +{% for item, value in tidb_conf.log | dictsort_by_value_type -%} +{% if value is not mapping -%} {{ item }} = {{ value | to_json}} +{% else %} + +[log.{{ item }}] +{% for sub_item, sub_value in value | dictsort -%} +{{ sub_item }} = {{ sub_value | to_json }} +{% endfor %} +{% endif %} {% endfor %} [security]