Browse Source

Remove shutdown of MariaDB

Since we are now in the Train cycle, we can be sure that any running
MariaDB containers can be safely stopped, and we do not need to perform
an explicit shutdown prior to restarting them.

Change-Id: I5450690f1cbe0c995e8e4b01a76e90dac2574d61
Related-Bug: #1820325
changes/55/650855/1
Mark Goddard 2 months ago
parent
commit
d93c604d7a
1 changed files with 0 additions and 65 deletions
  1. 0
    65
      ansible/roles/mariadb/handlers/main.yml

+ 0
- 65
ansible/roles/mariadb/handlers/main.yml View File

@@ -42,39 +42,6 @@
42 42
     - bootstrap_host == inventory_hostname
43 43
   listen: Bootstrap MariaDB cluster
44 44
 
45
-# NOTE(mgoddard): In Rocky the MariaDB image had an issue where it would not
46
-# stop on demand, and would result in Docker forcibly killing the container.
47
-# This could lead to a failed upgrade if the new image is unable to recover
48
-# from the crash. See https://bugs.launchpad.net/kolla-ansible/+bug/1820325.
49
-# TODO(mgoddard): Remove this task in Train.
50
-- name: shutdown slave mariadb
51
-  vars:
52
-    service_name: "mariadb"
53
-    service: "{{ mariadb_services[service_name] }}"
54
-  become: true
55
-  kolla_docker:
56
-    action: "start_container"
57
-    command: >-
58
-      bash -c '
59
-      sudo -E kolla_set_configs &&
60
-      mysqladmin shutdown --host={{ api_interface_address }} --user=root --password={{ database_password }}
61
-      '
62
-    common_options: "{{ docker_common_options }}"
63
-    detach: False
64
-    name: "mariadb_shutdown"
65
-    image: "{{ service.image }}"
66
-    volumes: "{{ service.volumes }}"
67
-    dimensions: "{{ service.dimensions }}"
68
-    labels:
69
-      UPGRADE:
70
-    restart_policy: "never"
71
-  no_log: true
72
-  when:
73
-    - kolla_action != "config"
74
-    - has_cluster | bool
75
-    - inventory_hostname != master_host
76
-  listen: restart mariadb
77
-
78 45
 - name: restart slave mariadb
79 46
   vars:
80 47
     service_name: "mariadb"
@@ -138,38 +105,6 @@
138 105
     - inventory_hostname != master_host
139 106
   listen: restart mariadb
140 107
 
141
-# NOTE(mgoddard): In Rocky the MariaDB image had an issue where it would not
142
-# stop on demand, and would result in Docker forcibly killing the container.
143
-# This could lead to a failed upgrade if the new image is unable to recover
144
-# from the crash. See https://bugs.launchpad.net/kolla-ansible/+bug/1820325.
145
-# TODO(mgoddard): Remove this task in Train.
146
-- name: shutdown master mariadb
147
-  vars:
148
-    service_name: "mariadb"
149
-    service: "{{ mariadb_services[service_name] }}"
150
-  become: true
151
-  kolla_docker:
152
-    action: "start_container"
153
-    command: >-
154
-      bash -c '
155
-      sudo -E kolla_set_configs &&
156
-      mysqladmin shutdown --host={{ api_interface_address }} --user=root --password={{ database_password }}
157
-      '
158
-    common_options: "{{ docker_common_options }}"
159
-    detach: False
160
-    name: "mariadb_shutdown"
161
-    image: "{{ service.image }}"
162
-    volumes: "{{ service.volumes }}"
163
-    dimensions: "{{ service.dimensions }}"
164
-    labels:
165
-      UPGRADE:
166
-    restart_policy: "never"
167
-  no_log: true
168
-  when:
169
-    - kolla_action != "config"
170
-    - inventory_hostname == master_host
171
-  listen: restart mariadb
172
-
173 108
 - name: restart master mariadb
174 109
   vars:
175 110
     service_name: "mariadb"

Loading…
Cancel
Save