Only attempt to start previous MariaDB if the image is available
On upgrade of undercloud from Rocky to Stein, we can't run this task always. The old MariaDB image was in Docker, but after the upgrade only Podman might be available, and it wouldn't have the previous MariaDB image available. Our best option here is likely skipping the redo log cleanup and hope that the redo log is clean. If this happens to cause problems in the wild, we might need a completely different solution (a parameter pointing to old MariaDB image url so that we can re-download it etc.). Change-Id: I51a338d840190c8931ab40692f727e5e0638ba40 Closes-Bug: #1821013
This commit is contained in:
parent
0a841e3433
commit
39930ed2fd
@ -305,7 +305,7 @@ outputs:
|
||||
shell: |
|
||||
{{ mysql_json.cli }} update --restart=unless-stopped mysql
|
||||
{{ mysql_json.cli }} stop mysql
|
||||
when: mysql_json.image != post_upgrade_mysql_image
|
||||
when: mysql_json.image is defined and mysql_json.image != post_upgrade_mysql_image
|
||||
- name: Clean up redo log by running a transient mysql server
|
||||
shell:
|
||||
str_replace:
|
||||
@ -316,7 +316,7 @@ outputs:
|
||||
IMAGE: "{{ mysql_json.image }}"
|
||||
VOLUMES: "-v {{ mysql_clean_up_volumes | join(' -v ') }}"
|
||||
SCRIPT: "{{ mysql_clean_up_script }}"
|
||||
when: mysql_json.image != post_upgrade_mysql_image
|
||||
when: mysql_json.image is defined and mysql_json.image != post_upgrade_mysql_image
|
||||
post_upgrade_tasks:
|
||||
- when: step|int == 1
|
||||
import_role:
|
||||
|
Loading…
Reference in New Issue
Block a user