MySQL_replication module

Hi Guys,

I've finished a module for ansible, it is called as
'mysql_replication' and of course you can manage mysql replication
features with that.
It can operate in different ways, you can check replication master's
status, replication slave's status, you can change replication
parameters, and stop / start slaves. The documentation is speaks for
itself I guess. I hope, it will be merged soon, but before that you
can check/test/use it from here:

https://github.com/banyek/ansible/blob/devel/library/database/mysql_replication

"Some" code was taken from Mark Theunissen's mysqldb module (for
example to connect to db, strip quotes, parse config) thanks for him!

kind regards,
  Balazs Pocze

Pull request is here – https://github.com/ansible/ansible/pull/3195 – were you going to resubmit this or is this one still active?

Would it make sense to have an additional feature that completely removes mysql slave replication from a slave with “reset slave all;” as described here http://www.mysqlperformanceblog.com/2013/04/17/reset-slave-vs-reset-slave-all-disconnecting-a-replication-slave-is-easier-with-mysql-5-5/

Currently it is only possible to stop slave replication with mysql_replication module…

Cheers,

Govinda

I think pull requests would definitely be considered, though I’d be looking for some folks using this module to weigh in.

Internally, we’re more of a Postgres shop, so I’m a bit less the one to comment on applicability.