Hi, On Tue, Jun 29, 2010 at 12:45:47AM +0200, Marek Marczykowski wrote: > Hello, > > I'm implementing some HA solution using pacemaker and I've made some > changes to mysql RA. Maybe you get interested in some of them. Patch > attached. List of changes: > * [bugfix] monitor return $OCF_RUNNING_MASTER on master > * [bugfix] slave info collected with replication user > * [bugfix] cut ending space from OCF_* host lists > * [doc] suggest --skip-slave-start option > * [feature] detailed logging on errors > * [feature] setup replication on late slave start > * [feature] another concept of M/S replication - try to keep state
Could we please have this split into as many patches as there are unrelated changes (looks like there should be 7). Otherwise it's going to be difficult to see what's affected by which part of the patch. > Some explanation about the last one: in dual-node mysql setup there is > no need to reset master after any topology change. You need to store > last log_file and log_pos and when master demotes (or started as slave) > it can continue from the last position (as slave - new master - was in > read-only mode). This also helps to not lose some data, ex. in scenario: > - slave maintenance shutdown > - some time later master reboot (yes - no mysql left for a moment) > -> this resets master > - slave startup > -> replication starts from point at master reboot, loosing data from > time after slave shutdown and before master reboot > > The main concept is to NOT use of "RESET MASTER". When some positions > desynchronises - it will need manual intervention. In original version > you can not even notice that you miss some inserts in replicas! That sounds quite bad. > This concept works only in dual-node mysql setup (namely: when a slave > have only one choose for master). In more-node setup it will need manual > synchronization (or original version with RESET MASTER - with warning > above). OK. Anybody out there running mysql wants to comment? Many thanks for sharing your work! Cheers, Dejan _______________________________________________________ Linux-HA-Dev: [email protected] http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev Home Page: http://linux-ha.org/
