SUSE: Apply workaround for mariadb-10.2
The openSUSE repository bumped the mariadb package to 10.2. However, there is an upstream bug that prevents nodes from joining the cluster. The way to workaround it is to export WSREP_SST_OPT_PORT=4444 in the systemd service file. Moreover, we pull the mariadb-galera subpackage which contains some necessary tools for galera clusters. Finally, we drop the default configuration files which are being installed by the packages because they conflict with the ones installed by this role. [hwoarang: This also applies the linter fixes from https://review.openstack.org/#/c/523080/ in order to make the gates happy] Depends-On: Ia4856f36b2d106d987e3c774f31493e25a23d4b5 Link: https://jira.mariadb.org/browse/MDEV-14256 Change-Id: I97cf1585b2fed08f53f62a547547e422bc34fa53
This commit is contained in:
parent
e9d7ab177e
commit
546c402b5c
@ -55,6 +55,15 @@
|
||||
mode: "02755"
|
||||
when: log_dir.rc == 1
|
||||
|
||||
# NOTE: (hwoarang) mariadb packages may drop some default configuration files
|
||||
# in {{ galera_etc_include_dir }} so make sure they are gone if necessary in
|
||||
# case they cause some conflicts with the ones we provide.
|
||||
- name: Remove existing mariadb configuration files
|
||||
file:
|
||||
state: absent
|
||||
path: "{{ galera_etc_include_dir }}/{{ item }}"
|
||||
with_items: "{{ mariadb_delete_etc_conf_files }}"
|
||||
|
||||
- name: Drop mariadb config(s)
|
||||
config_template:
|
||||
src: "{{ item.src }}"
|
||||
@ -127,6 +136,7 @@
|
||||
dest: "/etc/systemd/system/{{ galera_mariadb_service_name }}.service.d/{{ item.dest }}"
|
||||
mode: "0644"
|
||||
with_items:
|
||||
- { src: "systemd.environment.conf.j2", dest: "environment.conf" }
|
||||
- { src: "systemd.limits.conf.j2", dest: "limits.conf" }
|
||||
- { src: "systemd.timeout.conf.j2", dest: "timeout.conf" }
|
||||
- { src: "systemd.restart.conf.j2", dest: "restart.conf" }
|
||||
|
5
templates/systemd.environment.conf.j2
Normal file
5
templates/systemd.environment.conf.j2
Normal file
@ -0,0 +1,5 @@
|
||||
# {{ ansible_managed }}
|
||||
|
||||
[Service]
|
||||
# https://jira.mariadb.org/browse/MDEV-14256
|
||||
Environment="WSREP_SST_OPT_PORT=4444"
|
@ -26,6 +26,7 @@
|
||||
--silent \
|
||||
--skip-column-names
|
||||
register: wsrep_incoming_addresses
|
||||
changed_when: false
|
||||
- name: Check cluster local state
|
||||
command: |
|
||||
mysql -h {{ ansible_host }} \
|
||||
@ -34,6 +35,7 @@
|
||||
--silent \
|
||||
--skip-column-names
|
||||
register: wsrep_local_state_comment
|
||||
changed_when: false
|
||||
- name: Check cluster evs state
|
||||
command: |
|
||||
mysql -h {{ ansible_host }} \
|
||||
@ -42,6 +44,7 @@
|
||||
--silent \
|
||||
--skip-column-names
|
||||
register: wsrep_evs_state
|
||||
changed_when: false
|
||||
- name: Check contents
|
||||
assert:
|
||||
that:
|
||||
|
@ -31,3 +31,5 @@ percona_packages_list:
|
||||
- packages: "{{ [qpress_package_path] }}"
|
||||
enabled: "{{ not use_percona_upstream }}"
|
||||
local_pkg: yes
|
||||
|
||||
mariadb_delete_etc_conf_files: []
|
||||
|
@ -42,8 +42,8 @@ galera_mariadb_service_name: "mysql"
|
||||
galera_server_mariadb_distro_packages:
|
||||
- which
|
||||
- "{{ galera_mariadb_server_package }}"
|
||||
- mariadb-galera
|
||||
- percona-toolkit
|
||||
- xtrabackup
|
||||
- rsync
|
||||
- socat
|
||||
|
||||
@ -55,3 +55,8 @@ _use_percona_upstream: yes
|
||||
# sense for SUSE distributions and as such we provide an empty list here since
|
||||
# we grab everything from the distro repositories.
|
||||
percona_packages_list: []
|
||||
|
||||
mariadb_delete_etc_conf_files:
|
||||
- default_plugins.cnf
|
||||
- galera.cnf
|
||||
- error_log.cnf
|
||||
|
Loading…
x
Reference in New Issue
Block a user