diff options
author | shuai chen <chenshuai@huawei.com> | 2016-09-08 02:22:34 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@172.30.200.206> | 2016-09-08 02:22:34 +0000 |
commit | 6911e5491ec95eb7878595e186e6f2ff0bd4d237 (patch) | |
tree | 1c539fde98258660c443b496a5f6b71d556920d4 /deploy | |
parent | 5fbd0c26cbc7496dcb7a368f208f520494d280ed (diff) | |
parent | 11f6bd1154b5ad29aab7382feb28868dfbf9a88f (diff) |
Merge "Restart mysql in centos-no-ha scenario" into stable/colorado
Diffstat (limited to 'deploy')
-rw-r--r-- | deploy/adapters/ansible/roles/database/tasks/mariadb_config.yml | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/deploy/adapters/ansible/roles/database/tasks/mariadb_config.yml b/deploy/adapters/ansible/roles/database/tasks/mariadb_config.yml index b18ae8f7..780fc322 100644 --- a/deploy/adapters/ansible/roles/database/tasks/mariadb_config.yml +++ b/deploy/adapters/ansible/roles/database/tasks/mariadb_config.yml @@ -41,6 +41,24 @@ script: remove_user.sh when: ansible_os_family == "RedHat" +- name: restart mysql for centos noha + service: + name: mysql + state: restarted + when: > + inventory_hostname == haproxy_hosts.keys()[0] + and haproxy_hosts|length == 1 + and ansible_os_family == "RedHat" + +- name: restart mysql second time for centos noha + service: + name: mysql + state: restarted + when: > + inventory_hostname == haproxy_hosts.keys()[0] + and haproxy_hosts|length == 1 + and ansible_os_family == "RedHat" + - name: restart first nodes service: name: mysql |