[MDEV-5114] seconds_behind_master flips to 0 & spikes back, when running show slaves status Created: 2013-10-09 Updated: 2017-01-04 Resolved: 2015-05-03 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Replication |
| Affects Version/s: | 10.0.4, 5.5, 10.0 |
| Fix Version/s: | 10.0.18 |
| Type: | Bug | Priority: | Major |
| Reporter: | vishnu rao | Assignee: | Sergei Golubchik |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | replication, upstream-fixed, verified | ||
| Environment: |
Linux version 2.6.32-5-amd64 (Debian 2.6.32-48squeeze4) (dannf@debian.org) (gcc version 4.3.5 (Debian 4.3.5-4) ) |
||
| Attachments: |
|
| Description |
|
we setup maria 10.0.4 for multisource replication. it was replicating from a percona 5.5 master. When we started replication, maria was a day behind its master. its working fine but we noticed this phenomenon: when we execute 'show all slaves status' consecutively the 'seconds_behind_master' flips from 0 to XXX and XXX to 0. XXX keeps decreasing though, which is good as its getting closer to the state of its master. But wanted to know why the 'seconds_behind_master' comes down to 0 then again sets to a positive number. Note: XXX is some positive number. Elena Stepanova asked to file a bug for the same. bugs related to this issue these were fixed in 5.6. We need to either merge the bugfixes or fix them on our own |
| Comments |
| Comment by Elena Stepanova [ 2014-11-16 ] | |||||||||||||||||||||||||||||||||||||||||
|
I cannot reproduce Bug#53167 on the current 10.0 tree, but Bug#52166 is definitely there. | |||||||||||||||||||||||||||||||||||||||||
| Comment by Sergei Golubchik [ 2015-02-21 ] | |||||||||||||||||||||||||||||||||||||||||
|
I cannot repeat it using the test case from bug#52166 fix. | |||||||||||||||||||||||||||||||||||||||||
| Comment by Elena Stepanova [ 2015-03-01 ] | |||||||||||||||||||||||||||||||||||||||||
That's because the test tests something different from what the fix fixes.
That is (and the original complaint was really about it), Expected result: when slave has started executing e2, What they test instead:
But of course it is, either with the pre-fix behavior or with the fixed one, it will always be 3600 (or 1-2 seconds more). What they should have done instead is: Then it would have tested what they described. But the actual bug is really fixed in 5.6, while still exists in 10.0. Here is a low-tech dirty test which positively confirms it and is simple enough to read:
With MySQL 5.6, Seconds_Behind_Master printed by multiple show slave status calls, are like this:
While with MariaDB it's this:
|