pt-table-checksum doesn't warn if no slaves are found

Bug #1087804 reported by Daniel Nichter
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Percona Toolkit moved to https://jira.percona.com/projects/PT
Fix Released
Medium
Daniel Nichter

Bug Description

pt-table-checksum doesn't warn if no slaves are found. For PXC clusters it does, but not for regular replication. This can lead to misleading results because a master is always consistent with itself. The tool should really at least warn if no slaves are found so the user knows that --recursion-method (i.e. auto-slave finding) failed and the results aren't really useful.

Related branches

Changed in percona-toolkit:
assignee: nobody → Daniel Nichter (daniel-nichter)
status: Triaged → Fix Committed
Revision history for this message
Daniel Nichter (daniel-nichter) wrote :

If no slaves are found, and recursion-method is not "none", and --quiet < 2, then this warning is printed and exit status is non-zero:

"Diffs cannot be detected because no slaves were found. Please read the --recursion-method documentation for information."

I thought about making the tool die at this point so it doesn't do a bunch of useless work, but it could happen that slaves do exist but aren't found, so checksums do replicate, then the user can --replicate-check-only later to see if there are diffs.

I think non-zero exit status is correct because some users may be checking it rather than the output, in which case this will indicate that despite zero diffs, there was a problem that explains why there are zero diffs.

Changed in percona-toolkit:
status: Fix Committed → Fix Released
Revision history for this message
Shahriyar Rzayev (rzayev-sehriyar) wrote :

Percona now uses JIRA for bug reports so this bug report is migrated to: https://jira.percona.com/browse/PT-600

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.