Comment 8 for bug 1436093

Revision history for this message
Dmitrii Shcherbakov (dmitriis) wrote :

I validated on a single-unit deployment that currently (18.08) root password changes work but sst password changes do not. If sst-password is set via `juju run --unit mysql/0 'leader-set sst-password=newpasswd'` and a jujud-unit-mysql-0 unit is restarted (to trigger a config-changed event as the leader itself does not receive leader-settings-changed), the code gets to the pxc_installed check which prevents a new sst password from being set.

    133 def install_percona_xtradb_cluster():
    134 '''Attempt PXC install based on seeding of passwords for users'''
    135 if pxc_installed():
    136 log('MySQL already installed, skipping')
--> 137 return

So the change would be to augment this portion of config-changed hook implementation:

    # the password needs to be updated only if the node was already
    # bootstrapped
    if is_bootstrapped():
        update_root_password()
        # update_sst_password() <----
        set_ready_on_peers()