Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix global parameter usage in backup script #840

Merged
merged 1 commit into from
Jun 14, 2016
Merged

Fix global parameter usage in backup script #840

merged 1 commit into from
Jun 14, 2016

Conversation

HT43-bqxFqB
Copy link
Contributor

If mysqldump uses --defaults-extra-file mysql should use the same. Otherwise settings like different socket paths etc. will not work. Preferably this should be detected via test cases, as backups are quite important...

If mysqldump uses --defaults-extra-file mysql should use the same. Otherwise settings like different socket paths etc. will not work. Preferably this should be detected via test cases, as backups are quite important...
@DavidS
Copy link
Contributor

DavidS commented May 24, 2016

There are already a few tests exercising the back up script at https://github.com/puppetlabs/puppetlabs-mysql/blob/master/spec/acceptance/mysql_backup_spec.rb#L48-L75 why did they miss this issue?

@HT43-bqxFqB
Copy link
Contributor Author

I think those test don't look for any really unusual cases. In our case the mysql instance was under a different mountpoint. This included the socket file. In https://github.com/puppetlabs/puppetlabs-mysql/blob/master/templates/mysqlbackup.sh.erb#L71 the script fails because it can't connect to the database because it uses the default socket file path.
Anyway, I think if the script uses --defaults-extra-file in the mysqldump part, it should use the same logic when trying to connect to mysql to find out what to dump.

@igalic
Copy link
Contributor

igalic commented Jun 14, 2016

how about we merge this for now?

@bmjen bmjen merged commit 6146d93 into puppetlabs:master Jun 14, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants