Hello community,

here is the log from the commit of package percona-toolkit for openSUSE:Factory 
checked in at 2013-02-17 17:12:19
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/percona-toolkit (Old)
 and      /work/SRC/openSUSE:Factory/.percona-toolkit.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "percona-toolkit", Maintainer is ""

Changes:
--------
--- /work/SRC/openSUSE:Factory/percona-toolkit/percona-toolkit.changes  
2013-01-12 07:55:41.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.percona-toolkit.new/percona-toolkit.changes     
2013-02-17 17:12:21.000000000 +0100
@@ -1,0 +2,16 @@
+Fri Feb 15 21:29:01 UTC 2013 - andreas.stie...@gmx.de
+
+- update to 2.1.9 [bnc#804102], fixing the following bugs:
+  * pt-heartbeat 2.1.8 doesn't use precision/sub-second timestamps
+  * pt-heartbeat 2.1.8 reports big time drift with UTC_TIMESTAMP
+  * pt-online-schema-change fails with "Duplicate entry" on MariaDB
+  * pt-online-schema-change makes bad DELETE trigger if PK is re-created with 
new columns
+  * pt-pmp doesn't list the origin lib for each function
+  * pt-query-digest shouldn't print "Error: none" for tcpdump
+  * pt-query-digest fails to parse non-SQL errors
+  * pt-table-checksum: Confusing error message with binlog_format ROW or MIXED 
on slave
+  * pt-table-sync false-positive error "Cannot nibble table because MySQL 
chose no index
+    instead of the PRIMARY index"
+  * pt-stalk is too verbose, fills up log
+
+-------------------------------------------------------------------

Old:
----
  percona-toolkit-2.1.8.tar.gz

New:
----
  percona-toolkit-2.1.9.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ percona-toolkit.spec ++++++
--- /var/tmp/diff_new_pack.qFV2KI/_old  2013-02-17 17:12:23.000000000 +0100
+++ /var/tmp/diff_new_pack.qFV2KI/_new  2013-02-17 17:12:23.000000000 +0100
@@ -20,7 +20,7 @@
 Summary:        Advanced MySQL and system command-line tools
 License:        GPL-2.0
 Group:          Productivity/Databases/Tools
-Version:        2.1.8
+Version:        2.1.9
 Release:        0
 Url:            https://www.percona.com/software/percona-toolkit/
 Source:         
https://www.percona.com/redir/downloads/%{name}/%{version}/percona-toolkit-%{version}.tar.gz
@@ -53,6 +53,8 @@
 information and other free, open-source software developed by Percona,
 visit http://www.percona.com/software/.
 
+This collection was formerly known as Maatkit.
+
 %prep
 %setup -q
 

++++++ percona-toolkit-2.1.8.tar.gz -> percona-toolkit-2.1.9.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/Changelog 
new/percona-toolkit-2.1.9/Changelog
--- old/percona-toolkit-2.1.8/Changelog 2013-01-08 22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/Changelog 2013-02-14 18:59:10.000000000 +0100
@@ -1,5 +1,18 @@
 Changelog for Percona Toolkit
 
+v2.1.9 released 2013-02-14
+
+  * Fixed bug 1103221: pt-heartbeat 2.1.8 doesn't use precision/sub-second 
timestamps
+  * Fixed bug 1099665: pt-heartbeat 2.1.8 reports big time drift with 
UTC_TIMESTAMP
+  * Fixed bug 1099836: pt-online-schema-change fails with "Duplicate entry" on 
MariaDB
+  * Fixed bug 1103672: pt-online-schema-change makes bad DELETE trigger if PK 
is re-created with new columns
+  * Fixed bug 1115333: pt-pmp doesn't list the origin lib for each function
+  * Fixed bug  823411: pt-query-digest shouldn't print "Error: none" for 
tcpdump
+  * Fixed bug 1103045: pt-query-digest fails to parse non-SQL errors
+  * Fixed bug 1105077: pt-table-checksum: Confusing error message with 
binlog_format ROW or MIXED on slave
+  * Fixed bug  918056: pt-table-sync false-positive error "Cannot nibble table 
because MySQL chose no index instead of the PRIMARY index"
+  * Fixed bug 1099933: pt-stalk is too verbose, fills up log
+
 v2.1.8 released 2012-12-21
 
   * Beta support for MySQL 5.6
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/Makefile.PL 
new/percona-toolkit-2.1.9/Makefile.PL
--- old/percona-toolkit-2.1.8/Makefile.PL       2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/Makefile.PL       2013-02-14 18:59:10.000000000 
+0100
@@ -2,7 +2,7 @@
 
 WriteMakefile(
     NAME      => 'percona-toolkit',
-    VERSION   => '2.1.8',
+    VERSION   => '2.1.9',
     EXE_FILES => [ <bin/*> ],
     MAN1PODS  => {
       'docs/percona-toolkit.pod' => 'blib/man1/percona-toolkit.1p',
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-align 
new/percona-toolkit-2.1.9/bin/pt-align
--- old/percona-toolkit-2.1.8/bin/pt-align      2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-align      2013-02-14 18:59:10.000000000 
+0100
@@ -218,6 +218,6 @@
 
 =head1 VERSION
 
-pt-align 2.1.8
+pt-align 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-archiver 
new/percona-toolkit-2.1.9/bin/pt-archiver
--- old/percona-toolkit-2.1.8/bin/pt-archiver   2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-archiver   2013-02-14 18:59:10.000000000 
+0100
@@ -39,7 +39,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -1744,7 +1744,7 @@
       die "I need a $arg argument" unless $args{$arg};
    }
    my ($dbh, $db, $tbl) = @args{@required_args};
-   my $q      = $self->{Quoter};
+   my $q      = $self->{Quoter} || 'Quoter';
    my $db_tbl = $q->quote($db, $tbl);
    PTDEBUG && _d('Checking', $db_tbl);
 
@@ -7574,6 +7574,6 @@
 
 =head1 VERSION
 
-pt-archiver 2.1.8
+pt-archiver 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-config-diff 
new/percona-toolkit-2.1.9/bin/pt-config-diff
--- old/percona-toolkit-2.1.8/bin/pt-config-diff        2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-config-diff        2013-02-14 
18:59:10.000000000 +0100
@@ -38,7 +38,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -4871,6 +4871,6 @@
 
 =head1 VERSION
 
-pt-config-diff 2.1.8
+pt-config-diff 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-deadlock-logger 
new/percona-toolkit-2.1.9/bin/pt-deadlock-logger
--- old/percona-toolkit-2.1.8/bin/pt-deadlock-logger    2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-deadlock-logger    2013-02-14 
18:59:10.000000000 +0100
@@ -36,7 +36,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -4785,6 +4785,6 @@
 
 =head1 VERSION
 
-pt-deadlock-logger 2.1.8
+pt-deadlock-logger 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-diskstats 
new/percona-toolkit-2.1.9/bin/pt-diskstats
--- old/percona-toolkit-2.1.8/bin/pt-diskstats  2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-diskstats  2013-02-14 18:59:10.000000000 
+0100
@@ -38,7 +38,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -5570,6 +5570,6 @@
 
 =head1 VERSION
 
-pt-diskstats 2.1.8
+pt-diskstats 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-duplicate-key-checker 
new/percona-toolkit-2.1.9/bin/pt-duplicate-key-checker
--- old/percona-toolkit-2.1.8/bin/pt-duplicate-key-checker      2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-duplicate-key-checker      2013-02-14 
18:59:10.000000000 +0100
@@ -39,7 +39,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -394,7 +394,7 @@
       die "I need a $arg argument" unless $args{$arg};
    }
    my ($dbh, $db, $tbl) = @args{@required_args};
-   my $q      = $self->{Quoter};
+   my $q      = $self->{Quoter} || 'Quoter';
    my $db_tbl = $q->quote($db, $tbl);
    PTDEBUG && _d('Checking', $db_tbl);
 
@@ -5435,6 +5435,6 @@
 
 =head1 VERSION
 
-pt-duplicate-key-checker 2.1.8
+pt-duplicate-key-checker 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-fifo-split 
new/percona-toolkit-2.1.9/bin/pt-fifo-split
--- old/percona-toolkit-2.1.8/bin/pt-fifo-split 2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-fifo-split 2013-02-14 18:59:10.000000000 
+0100
@@ -1568,6 +1568,6 @@
 
 =head1 VERSION
 
-pt-fifo-split 2.1.8
+pt-fifo-split 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-find 
new/percona-toolkit-2.1.9/bin/pt-find
--- old/percona-toolkit-2.1.8/bin/pt-find       2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-find       2013-02-14 18:59:10.000000000 
+0100
@@ -35,7 +35,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -1792,7 +1792,7 @@
       die "I need a $arg argument" unless $args{$arg};
    }
    my ($dbh, $db, $tbl) = @args{@required_args};
-   my $q      = $self->{Quoter};
+   my $q      = $self->{Quoter} || 'Quoter';
    my $db_tbl = $q->quote($db, $tbl);
    PTDEBUG && _d('Checking', $db_tbl);
 
@@ -4898,6 +4898,6 @@
 
 =head1 VERSION
 
-pt-find 2.1.8
+pt-find 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-fingerprint 
new/percona-toolkit-2.1.9/bin/pt-fingerprint
--- old/percona-toolkit-2.1.8/bin/pt-fingerprint        2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-fingerprint        2013-02-14 
18:59:10.000000000 +0100
@@ -2129,7 +2129,7 @@
 
 =head1 COPYRIGHT, LICENSE, AND WARRANTY
 
-This program is copyright 2011-2012 Percona Ireland Ltd.
+This program is copyright 2011-2013 Percona Ireland Ltd.
 
 THIS PROGRAM IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED
 WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
@@ -2147,6 +2147,6 @@
 
 =head1 VERSION
 
-pt-fingerprint 2.1.8
+pt-fingerprint 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-fk-error-logger 
new/percona-toolkit-2.1.9/bin/pt-fk-error-logger
--- old/percona-toolkit-2.1.8/bin/pt-fk-error-logger    2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-fk-error-logger    2013-02-14 
18:59:10.000000000 +0100
@@ -35,7 +35,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -4011,7 +4011,7 @@
 
 =head1 COPYRIGHT, LICENSE, AND WARRANTY
 
-This program is copyright 2011-2012 Percona Ireland Ltd.
+This program is copyright 2011-2013 Percona Ireland Ltd.
 
 THIS PROGRAM IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED
 WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
@@ -4029,6 +4029,6 @@
 
 =head1 VERSION
 
-pt-fk-error-logger 2.1.8
+pt-fk-error-logger 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-heartbeat 
new/percona-toolkit-2.1.9/bin/pt-heartbeat
--- old/percona-toolkit-2.1.8/bin/pt-heartbeat  2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-heartbeat  2013-02-14 18:59:10.000000000 
+0100
@@ -38,7 +38,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -2731,7 +2731,7 @@
       die "I need a $arg argument" unless $args{$arg};
    }
    my ($dbh, $db, $tbl) = @args{@required_args};
-   my $q      = $self->{Quoter};
+   my $q      = $self->{Quoter} || 'Quoter';
    my $db_tbl = $q->quote($db, $tbl);
    PTDEBUG && _d('Checking', $db_tbl);
 
@@ -4807,6 +4807,8 @@
    # ########################################################################
    # Create the heartbeat table if --create-table was given.
    # ########################################################################
+   my $utc       = $o->get('utc');
+   my $now_func  = $utc ? 'UTC_TIMESTAMP()' : 'NOW()';
    my $db_tbl    = $q->quote($db, $tbl);
    my $server_id = $dbh->selectrow_array('SELECT @@server_id');
    if ( $o->get('create-table') ) {
@@ -4816,7 +4818,7 @@
       $dbh->do($sql);
 
       $sql = ($o->get('replace') ? "REPLACE" : "INSERT")
-           . qq/ INTO $db_tbl (ts, server_id) VALUES (UTC_TIMESTAMP(), 
$server_id)/;
+           . qq/ INTO $db_tbl (ts, server_id) VALUES ($now_func, $server_id)/;
       PTDEBUG && _d($sql);
       # This may fail if the table already existed and already had this row.
       # We eval to ignore this possibility.
@@ -4913,7 +4915,7 @@
          PTDEBUG && _d('No heartbeat row in table');
          if ( $o->get('insert-heartbeat-row') ) {
             my $sql = "INSERT INTO $db_tbl ($pk_col, ts) "
-                    . "VALUES ('$pk_val', UTC_TIMESTAMP())";
+                    . "VALUES ('$pk_val', $now_func)";
             PTDEBUG && _d($sql);
             $dbh->do($sql);
          }
@@ -5007,8 +5009,7 @@
             tries => 3,
             wait  => sub { sleep 0.25; return; },
             try   => sub {
-               my ($now) = $dbh->selectrow_array(q{SELECT UTC_TIMESTAMP()});
-               $sth->execute($now, @vals);
+               $sth->execute(ts(time, $utc), @vals);
                PTDEBUG && _d($sth->{Statement});
                $sth->finish();
             },
@@ -5039,7 +5040,7 @@
       # UNIX_TIMESTAMP(ts) replaces unix_timestamp($ts) -- MySQL is the
       # authority here, so let it calculate everything.
       $heartbeat_sql
-         = "SELECT UNIX_TIMESTAMP(UTC_TIMESTAMP()), UNIX_TIMESTAMP(ts)"
+         = "SELECT " . ($utc ? 'UNIX_TIMESTAMP(ts)' : 'ts')
          . ($dbi_driver eq 'mysql' ? '/*!50038, @@hostname AS host*/' : '')
          . ($id ? "" : ", server_id")
          . " FROM $db_tbl "
@@ -5053,12 +5054,13 @@
          my ($sth) = @_;
          $sth->execute();
          PTDEBUG && _d($sth->{Statement});
-         my ($now, $ts, $hostname, $server_id) = $sth->fetchrow_array();
+         my ($ts, $hostname, $server_id) = $sth->fetchrow_array();
+         my $now = time;
          PTDEBUG && _d("Heartbeat from server", $server_id, "\n",
-            " now:", $now, "\n",
+            " now:", ts($now, $utc), "\n",
             "  ts:", $ts, "\n",
             "skew:", $skew);
-         my $delay = $now - $ts - $skew;
+         my $delay = $now - unix_timestamp($ts, $utc) - $skew;
          PTDEBUG && _d('Delay', sprintf('%.6f', $delay), 'on', $hostname);
 
          # Because we adjust for skew, if the ts are less than skew seconds
@@ -5863,6 +5865,16 @@
 
 User for login if not current user.
 
+=item --utc
+
+Ignore system time zones and use only UTC.  By default pt-heartbeat does
+not check or adjust for different system or MySQL time zones which can
+cause the tool to compute the lag incorrectly.  Specifying this option is
+a good idea because it ensures that the tool works correctly regardless of
+time zones, but it also makes the tool backwards-incompatible with
+pt-heartbeat 2.1.9 and older (unless the older version of pt-heartbeat
+is running on a system that uses UTC).
+
 =item --version
 
 Show version and exit.
@@ -6047,6 +6059,6 @@
 
 =head1 VERSION
 
-pt-heartbeat 2.1.8
+pt-heartbeat 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-index-usage 
new/percona-toolkit-2.1.9/bin/pt-index-usage
--- old/percona-toolkit-2.1.8/bin/pt-index-usage        2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-index-usage        2013-02-14 
18:59:10.000000000 +0100
@@ -45,7 +45,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -3001,7 +3001,7 @@
       die "I need a $arg argument" unless $args{$arg};
    }
    my ($dbh, $db, $tbl) = @args{@required_args};
-   my $q      = $self->{Quoter};
+   my $q      = $self->{Quoter} || 'Quoter';
    my $db_tbl = $q->quote($db, $tbl);
    PTDEBUG && _d('Checking', $db_tbl);
 
@@ -7483,6 +7483,6 @@
 
 =head1 VERSION
 
-pt-index-usage 2.1.8
+pt-index-usage 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-ioprofile 
new/percona-toolkit-2.1.9/bin/pt-ioprofile
--- old/percona-toolkit-2.1.8/bin/pt-ioprofile  2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-ioprofile  2013-02-14 18:59:10.000000000 
+0100
@@ -20,23 +20,32 @@
 PTDEBUG="${PTDEBUG:-""}"
 EXIT_STATUS=0
 
-log() {
-   TS=$(date +%F-%T | tr ':-' '_');
+ts() {
+   TS=$(date +%F-%T | tr ':-' '_')
    echo "$TS $*"
 }
 
+info() {
+   [ ${OPT_VERBOSE:-3} -ge 3 ] && ts "$*"
+}
+
+log() {
+   [ ${OPT_VERBOSE:-3} -ge 2 ] && ts "$*"
+}
+
 warn() {
-   log "$*" >&2
+   [ ${OPT_VERBOSE:-3} -ge 1 ] && ts "$*" >&2
    EXIT_STATUS=1
 }
 
 die() {
-   warn "$*"
+   ts "$*" >&2
+   EXIT_STATUS=1
    exit 1
 }
 
 _d () {
-   [ "$PTDEBUG" ] && echo "# $PTFUNCNAME: $(log "$*")" >&2
+   [ "$PTDEBUG" ] && echo "# $PTFUNCNAME: $(ts "$*")" >&2
 }
 
 # ###########################################################################
@@ -861,7 +870,7 @@
 # Execute the program if it was not included from another file.
 # This makes it possible to include without executing, and thus test.
 if    [ "${0##*/}" = "$TOOL" ] \
-   || [ "${0##*/}" = "bash" -a "$_" = "$0" ]; then
+   || [ "${0##*/}" = "bash" -a "${_:-""}" = "$0" ]; then
 
    # Parse command line options.  We must do this first so we can
    # see if --daemonize was specified.
@@ -1103,7 +1112,7 @@
 
 =head1 VERSION
 
-pt-ioprofile 2.1.8
+pt-ioprofile 2.1.9
 
 =cut
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-kill 
new/percona-toolkit-2.1.9/bin/pt-kill
--- old/percona-toolkit-2.1.8/bin/pt-kill       2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-kill       2013-02-14 18:59:10.000000000 
+0100
@@ -43,7 +43,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -2678,7 +2678,7 @@
       die "I need a $arg argument" unless $args{$arg};
    }
    my ($dbh, $db, $tbl) = @args{@required_args};
-   my $q      = $self->{Quoter};
+   my $q      = $self->{Quoter} || 'Quoter';
    my $db_tbl = $q->quote($db, $tbl);
    PTDEBUG && _d('Checking', $db_tbl);
 
@@ -7789,6 +7789,6 @@
 
 =head1 VERSION
 
-pt-kill 2.1.8
+pt-kill 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-log-player 
new/percona-toolkit-2.1.9/bin/pt-log-player
--- old/percona-toolkit-2.1.8/bin/pt-log-player 2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-log-player 2013-02-14 18:59:10.000000000 
+0100
@@ -3673,6 +3673,6 @@
 
 =head1 VERSION
 
-pt-log-player 2.1.8
+pt-log-player 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-mext 
new/percona-toolkit-2.1.9/bin/pt-mext
--- old/percona-toolkit-2.1.8/bin/pt-mext       2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-mext       2013-02-14 18:59:10.000000000 
+0100
@@ -282,7 +282,7 @@
 
 =head1 VERSION
 
-pt-mext 2.1.8
+pt-mext 2.1.9
 
 =cut
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-mysql-summary 
new/percona-toolkit-2.1.9/bin/pt-mysql-summary
--- old/percona-toolkit-2.1.8/bin/pt-mysql-summary      2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-mysql-summary      2013-02-14 
18:59:10.000000000 +0100
@@ -22,23 +22,32 @@
 PTDEBUG="${PTDEBUG:-""}"
 EXIT_STATUS=0
 
-log() {
-   TS=$(date +%F-%T | tr ':-' '_');
+ts() {
+   TS=$(date +%F-%T | tr ':-' '_')
    echo "$TS $*"
 }
 
+info() {
+   [ ${OPT_VERBOSE:-3} -ge 3 ] && ts "$*"
+}
+
+log() {
+   [ ${OPT_VERBOSE:-3} -ge 2 ] && ts "$*"
+}
+
 warn() {
-   log "$*" >&2
+   [ ${OPT_VERBOSE:-3} -ge 1 ] && ts "$*" >&2
    EXIT_STATUS=1
 }
 
 die() {
-   warn "$*"
+   ts "$*" >&2
+   EXIT_STATUS=1
    exit 1
 }
 
 _d () {
-   [ "$PTDEBUG" ] && echo "# $PTFUNCNAME: $(log "$*")" >&2
+   [ "$PTDEBUG" ] && echo "# $PTFUNCNAME: $(ts "$*")" >&2
 }
 
 # ###########################################################################
@@ -2412,7 +2421,7 @@
 # Execute the program if it was not included from another file.
 # This makes it possible to include without executing, and thus test.
 if    [ "${0##*/}" = "$TOOL" ] \
-   || [ "${0##*/}" = "bash" -a "$_" = "$0" ]; then
+   || [ "${0##*/}" = "bash" -a "${_:-""}" = "$0" ]; then
 
    # Set up temporary dir.
    mk_tmpdir
@@ -3002,7 +3011,7 @@
 
 =head1 VERSION
 
-pt-mysql-summary 2.1.8
+pt-mysql-summary 2.1.9
 
 =cut
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-online-schema-change 
new/percona-toolkit-2.1.9/bin/pt-online-schema-change
--- old/percona-toolkit-2.1.8/bin/pt-online-schema-change       2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-online-schema-change       2013-02-14 
18:59:10.000000000 +0100
@@ -51,7 +51,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -3270,7 +3270,7 @@
       die "I need a $arg argument" unless $args{$arg};
    }
    my ($dbh, $db, $tbl) = @args{@required_args};
-   my $q      = $self->{Quoter};
+   my $q      = $self->{Quoter} || 'Quoter';
    my $db_tbl = $q->quote($db, $tbl);
    PTDEBUG && _d('Checking', $db_tbl);
 
@@ -8370,19 +8370,74 @@
    # Find a pk or unique index to use for the delete trigger.  can_nibble()
    # above returns an index, but NibbleIterator will use non-unique indexes,
    # so we have to do this again here.
-   my $indexes = $new_tbl->{tbl_struct}->{keys}; # brevity
-   foreach my $index ( $tp->sort_indexes($new_tbl->{tbl_struct}) ) {
-      if ( $index eq 'PRIMARY' || $indexes->{$index}->{is_unique} ) {
-         PTDEBUG && _d('Delete trigger index:', Dumper($index));
-         $new_tbl->{del_index} = $index;
-         last;
+   {
+      my $indexes = $new_tbl->{tbl_struct}->{keys}; # brevity
+      foreach my $index ( $tp->sort_indexes($new_tbl->{tbl_struct}) ) {
+         if ( $index eq 'PRIMARY' || $indexes->{$index}->{is_unique} ) {
+            PTDEBUG && _d('Delete trigger new index:', Dumper($index));
+            $new_tbl->{del_index} = $index;
+            last;
+         }
+      }
+      PTDEBUG && _d('New table delete index:', $new_tbl->{del_index});
+   }
+
+   {
+      my $indexes = $orig_tbl->{tbl_struct}->{keys}; # brevity
+      foreach my $index ( $tp->sort_indexes($orig_tbl->{tbl_struct}) ) {
+         if ( $index eq 'PRIMARY' || $indexes->{$index}->{is_unique} ) {
+            PTDEBUG && _d('Delete trigger orig index:', Dumper($index));
+            $orig_tbl->{del_index} = $index;
+            last;
+         }
       }
+      PTDEBUG && _d('Orig table delete index:', $orig_tbl->{del_index});
    }
+
    if ( !$new_tbl->{del_index} ) {
       die "The new table $new_tbl->{name} does not have a PRIMARY KEY "
         . "or a unique index which is required for the DELETE trigger.\n";
    }
 
+   # Determine whether to use the new or orig table delete index.
+   # The new table del index is preferred due to
+   # https://bugs.launchpad.net/percona-toolkit/+bug/1062324
+   # In short, if the chosen del index is re-created with new columns,
+   # its original columns may be dropped, so just use its new columns.
+   # But, due to https://bugs.launchpad.net/percona-toolkit/+bug/1103672,
+   # the chosen del index on the new table may reference columns which
+   # do not/no longer exist in the orig table, so we check for this
+   # and, if it's the case, we fall back to using the del index from
+   # the orig table.
+   my $del_tbl = $new_tbl; # preferred
+   my $new_del_index_cols  # brevity
+      = $new_tbl->{tbl_struct}->{keys}->{ $new_tbl->{del_index} }->{cols};
+   foreach my $new_del_index_col ( @$new_del_index_cols ) {
+      if ( !exists $orig_cols->{$new_del_index_col} ) {
+         if ( !$orig_tbl->{del_index} ) {
+            die "The new table index $new_tbl->{del_index} would be used "
+               . "for the DELETE trigger, but it uses column "
+               . "$new_del_index_col which does not exist in the original "
+               . "table and the original table does not have a PRIMARY KEY "
+               . "or a unique index to use for the DELETE trigger.\n";
+         }
+         print "Using original table index $orig_tbl->{del_index} for the "
+            . "DELETE trigger instead of new table index $new_tbl->{del_index} 
"
+            . "because the new table index uses column $new_del_index_col "
+            . "which does not exist in the original table.\n";
+         $del_tbl = $orig_tbl;
+         last;
+      }
+   }
+
+   {
+      my $del_cols
+         = $del_tbl->{tbl_struct}->{keys}->{ $del_tbl->{del_index} }->{cols};
+      PTDEBUG && _d('Index for delete trigger: table', $del_tbl->{name},
+         'index', $del_tbl->{del_index},
+         'columns', @$del_cols);
+   }
+
    # ########################################################################
    # Step 3: Create the triggers to capture changes on the original table and
    # apply them to the new table.
@@ -8412,6 +8467,7 @@
       create_triggers(
          orig_tbl     => $orig_tbl,
          new_tbl      => $new_tbl,
+         del_tbl      => $del_tbl,
          columns      => \@common_cols,
          Cxn          => $cxn,
          Quoter       => $q,
@@ -8931,6 +8987,28 @@
    my $ok = 1;
 
    # ########################################################################
+   # Check for DROP PRIMARY KEY.
+   # ########################################################################
+   if ( $alter =~ m/DROP\s+PRIMARY\s+KEY/i ) {
+      my $msg = "--alter contains 'DROP PRIMARY KEY'.  Dropping and "
+              . "altering the primary key can be dangerous, "
+              . "especially if the original table does not have other "
+              . "unique indexes.\n";
+      if ( $dry_run ) {
+         print $msg;
+      }
+      else {
+         $ok = 0;
+         warn $msg
+            . "The tool should handle this correctly, but you should "
+            . "test it first and carefully examine the triggers which "
+            . "rely on the PRIMARY KEY or a unique index.  Specify "
+            . "--no-check-alter to disable this check and perform the "
+            . "--alter.\n";
+      }
+   }
+
+   # ########################################################################
    # Check for renamed columns.
    # https://bugs.launchpad.net/percona-toolkit/+bug/1068562
    # ########################################################################
@@ -8976,6 +9054,7 @@
    }
 
    if ( !$ok ) {
+      # check_alter.t relies on this output.
       die "--check-alter failed.\n";
    }
 
@@ -9536,11 +9615,11 @@
 
 sub create_triggers {
    my ( %args ) = @_;
-   my @required_args = qw(orig_tbl new_tbl columns Cxn Quoter OptionParser);
+   my @required_args = qw(orig_tbl new_tbl del_tbl columns Cxn Quoter 
OptionParser);
    foreach my $arg ( @required_args ) {
       die "I need a $arg argument" unless $args{$arg};
    }
-   my ($orig_tbl, $new_tbl, $cols, $cxn, $q, $o) = @args{@required_args};
+   my ($orig_tbl, $new_tbl, $del_tbl, $cols, $cxn, $q, $o) = 
@args{@required_args};
 
    # This sub works for --dry-run and --execute.  With --dry-run it's
    # only interesting if --print is specified, too; then the user can
@@ -9569,8 +9648,8 @@
    # unique indexes can be nullable.  Cols are from the new table and
    # they may have been renamed
    my %old_col_for    = map { $_->{new} => $_->{old} } @$cols;
-   my $tbl_struct     = $new_tbl->{tbl_struct};
-   my $del_index      = $new_tbl->{del_index};
+   my $tbl_struct     = $del_tbl->{tbl_struct};
+   my $del_index      = $del_tbl->{del_index};
    my $del_index_cols = join(" AND ", map {
       my $new_col  = $_;
       my $old_col  = $old_col_for{$new_col} || $new_col;
@@ -9698,6 +9777,10 @@
       # Ignore this warning because we have purposely set statement-based
       # replication.
       1592 => 1,
+      # Error: 1062 SQLSTATE: 23000 ( ER_DUP_ENTRY )
+      # Message: Duplicate entry '%ld' for key '%s'
+      # MariaDB 5.5.28+ has this as a warning; See 
https://bugs.launchpad.net/percona-toolkit/+bug/1099836
+      1062 => 1,
    );
          
    # Warn once per-table for these error codes if the error message
@@ -9772,6 +9855,7 @@
                            . "Specify --statistics to see a count of all "
                            . "suppressed warnings and errors.\n";
                   }
+                  warn $err;
                }
             }
             else {
@@ -10226,9 +10310,19 @@
 C<CHANGE COLUMN name new_name> would lead to that column's data being lost.
 The tool now parses the alter statement and tries to catch these cases, so
 the renamed columns should have the same data as the originals. However, the
-code that does this is not a full-blown SQL parser, so we recommend that users
-run the tool with L<"--dry-run"> and check if it's detecting the renames
-correctly.
+code that does this is not a full-blown SQL parser, so you should first
+run the tool with L<"--dry-run"> and L<"--print"> and verify that it detects
+the renamed columns correctly.
+
+=item DROP PRIMARY KEY
+
+If L<"--alter"> contain C<DROP PRIMARY KEY> (case- and space-insensitive),
+a warning is printed and the tool exits unless L<"--dry-run"> is specified.
+Altering the primary key can be dangerous, but the tool can handle it.
+The tool's triggers, particularly the DELETE trigger, are most affected by
+altering the primary key because the tool prefers to use the primary key
+for its triggers.  You should first run the tool with L<"--dry-run"> and
+L<"--print"> and verify that the triggers are correct.
 
 =back
 
@@ -10851,6 +10945,6 @@
 
 =head1 VERSION
 
-pt-online-schema-change 2.1.8
+pt-online-schema-change 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-pmp 
new/percona-toolkit-2.1.9/bin/pt-pmp
--- old/percona-toolkit-2.1.8/bin/pt-pmp        2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-pmp        2013-02-14 18:59:10.000000000 
+0100
@@ -82,6 +82,7 @@
             }
             else {
                targ = \$4;
+               tfile= \$NF;
             }
             if ( targ ~ /[<\\(]/ ) {
                targ = substr(\$0, index(\$0, \" in \") + 4);
@@ -126,6 +127,13 @@
          }
          else {
             fname = targ;
+            if ( tfile ~ /^\// ) {
+               last=split(tfile,filen,/\//); 
+               fname = targ \"(\" filen[last] \")\";
+            }
+            else {
+               fname = targ
+            }
          }
          if ( ${maxlen:-0} == 0 || c < ${maxlen:-0} ) {
             if (s != \"\" ) {
@@ -215,7 +223,7 @@
 # Execute the program if it was not included from another file.  This makes it
 # possible to include without executing, and thus test.
 if    [ "${0##*/}" = "$TOOL" ] \
-   || [ "${0##*/}" = "bash" -a "$_" = "$0" ]; then
+   || [ "${0##*/}" = "bash" -a "${_:-""}" = "$0" ]; then
    mk_tmpdir
    main "$@"
    rm_tmpdir
@@ -396,7 +404,7 @@
 
 =head1 VERSION
 
-pt-pmp 2.1.8
+pt-pmp 2.1.9
 
 =cut
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-query-advisor 
new/percona-toolkit-2.1.9/bin/pt-query-advisor
--- old/percona-toolkit-2.1.8/bin/pt-query-advisor      2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-query-advisor      2013-02-14 
18:59:10.000000000 +0100
@@ -46,7 +46,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -5520,7 +5520,7 @@
       die "I need a $arg argument" unless $args{$arg};
    }
    my ($dbh, $db, $tbl) = @args{@required_args};
-   my $q      = $self->{Quoter};
+   my $q      = $self->{Quoter} || 'Quoter';
    my $db_tbl = $q->quote($db, $tbl);
    PTDEBUG && _d('Checking', $db_tbl);
 
@@ -8727,6 +8727,6 @@
 
 =head1 VERSION
 
-pt-query-advisor 2.1.8
+pt-query-advisor 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-query-digest 
new/percona-toolkit-2.1.9/bin/pt-query-digest
--- old/percona-toolkit-2.1.8/bin/pt-query-digest       2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-query-digest       2013-02-14 
18:59:10.000000000 +0100
@@ -64,7 +64,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -3132,6 +3132,19 @@
    if ( $packet->{data_len} == 0 ) {
       PTDEBUG && _d('TCP control:',
          map { uc $_ } grep { $packet->{$_} } qw(syn ack fin rst));
+      if ( $packet->{'fin'}
+           && ($session->{state} || '') eq 'server_handshake' ) {
+         PTDEBUG && _d('Client aborted connection');
+         my $event = {
+            cmd => 'Admin',
+            arg => 'administrator command: Connect',
+            ts  => $packet->{ts},
+         };
+         $session->{attribs}->{Error_msg} = 'Client closed connection during 
handshake';
+         $event = $self->_make_event($event, $packet, $session);
+         delete $self->{sessions}->{$session->{client}};
+         return $event;
+      }
       return;
    }
 
@@ -3348,7 +3361,8 @@
          }
          my $event;
 
-         if ( $session->{state} eq 'client_auth' ) {
+         if (   $session->{state} eq 'client_auth'
+             || $session->{state} eq 'server_handshake' ) {
             PTDEBUG && _d('Connection failed');
             $event = {
                cmd      => 'Admin',
@@ -3375,11 +3389,13 @@
             }
 
             $event = {
-               cmd       => $com,
-               arg       => $arg,
-               ts        => $packet->{ts},
-               Error_no  => $error->{errno} ? "#$error->{errno}" : 'none',
+               cmd => $com,
+               arg => $arg,
+               ts  => $packet->{ts},
             };
+            if ( $error->{errno} ) {
+               $event->{Error_no} = $error->{errno};
+            }
             $session->{attribs}->{Error_msg} = $error->{message};
             return $self->_make_event($event, $packet, $session);
          }
@@ -3590,13 +3606,17 @@
       Thread_id  => $session->{thread_id},
       pos_in_log => $session->{pos_in_log},
       Query_time => timestamp_diff($session->{ts}, $packet->{ts}),
-      Error_no   => $event->{Error_no} || 'none',
       Rows_affected      => ($event->{Rows_affected} || 0),
       Warning_count      => ($event->{Warning_count} || 0),
       No_good_index_used => ($event->{No_good_index_used} ? 'Yes' : 'No'),
       No_index_used      => ($event->{No_index_used}      ? 'Yes' : 'No'),
    };
    @{$new_event}{keys %{$session->{attribs}}} = values %{$session->{attribs}};
+   foreach my $opt_attrib ( qw(Error_no) ) {
+      if ( defined $event->{$opt_attrib} ) {
+         $new_event->{$opt_attrib} = $event->{$opt_attrib};
+      }
+   }
    PTDEBUG && _d('Properties of event:', Dumper($new_event));
 
    delete $session->{cmd};
@@ -3727,9 +3747,17 @@
    }
    my $errno    = to_num(substr($data, 0, 4));
    my $marker   = to_string(substr($data, 4, 2));
-   return unless $marker eq '#';
-   my $sqlstate = to_string(substr($data, 6, 10));
-   my $message  = to_string(substr($data, 16));
+   my $sqlstate = '';
+   my $message  = '';
+   if ( $marker eq '#' ) {
+      $sqlstate = to_string(substr($data, 6, 10));
+      $message  = to_string(substr($data, 16));
+   }
+   else {
+      $marker  = '';
+      $message = to_string(substr($data, 4));
+   }
+   return unless $message;
    my $pkt = {
       errno    => $errno,
       sqlstate => $marker . $sqlstate,
@@ -8323,7 +8351,7 @@
       die "I need a $arg argument" unless $args{$arg};
    }
    my ($dbh, $db, $tbl) = @args{@required_args};
-   my $q      = $self->{Quoter};
+   my $q      = $self->{Quoter} || 'Quoter';
    my $db_tbl = $q->quote($db, $tbl);
    PTDEBUG && _d('Checking', $db_tbl);
 
@@ -17426,6 +17454,6 @@
 
 =head1 VERSION
 
-pt-query-digest 2.1.8
+pt-query-digest 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-show-grants 
new/percona-toolkit-2.1.9/bin/pt-show-grants
--- old/percona-toolkit-2.1.8/bin/pt-show-grants        2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-show-grants        2013-02-14 
18:59:10.000000000 +0100
@@ -2304,6 +2304,6 @@
 
 =head1 VERSION
 
-pt-show-grants 2.1.8
+pt-show-grants 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-sift 
new/percona-toolkit-2.1.9/bin/pt-sift
--- old/percona-toolkit-2.1.8/bin/pt-sift       2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-sift       2013-02-14 18:59:10.000000000 
+0100
@@ -587,7 +587,7 @@
 # Execute the program if it was not included from another file.  This makes it
 # possible to include without executing, and thus test.
 if    [ "${0##*/}" = "$TOOL" ] \
-   || [ "${0##*/}" = "bash" -a "$_" = "$0" ]; then
+   || [ "${0##*/}" = "bash" -a "${_:-""}" = "$0" ]; then
     main "${@:-""}"
 fi
 
@@ -781,7 +781,7 @@
 
 =head1 VERSION
 
-pt-sift 2.1.8
+pt-sift 2.1.9
 
 =cut
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-slave-delay 
new/percona-toolkit-2.1.9/bin/pt-slave-delay
--- old/percona-toolkit-2.1.8/bin/pt-slave-delay        2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-slave-delay        2013-02-14 
18:59:10.000000000 +0100
@@ -36,7 +36,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -4600,6 +4600,6 @@
 
 =head1 VERSION
 
-pt-slave-delay 2.1.8
+pt-slave-delay 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-slave-find 
new/percona-toolkit-2.1.9/bin/pt-slave-find
--- old/percona-toolkit-2.1.8/bin/pt-slave-find 2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-slave-find 2013-02-14 18:59:10.000000000 
+0100
@@ -4025,6 +4025,6 @@
 
 =head1 VERSION
 
-pt-slave-find 2.1.8
+pt-slave-find 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-slave-restart 
new/percona-toolkit-2.1.9/bin/pt-slave-restart
--- old/percona-toolkit-2.1.8/bin/pt-slave-restart      2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-slave-restart      2013-02-14 
18:59:10.000000000 +0100
@@ -37,7 +37,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -5519,6 +5519,6 @@
 
 =head1 VERSION
 
-pt-slave-restart 2.1.8
+pt-slave-restart 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-stalk 
new/percona-toolkit-2.1.9/bin/pt-stalk
--- old/percona-toolkit-2.1.8/bin/pt-stalk      2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-stalk      2013-02-14 18:59:10.000000000 
+0100
@@ -22,23 +22,32 @@
 PTDEBUG="${PTDEBUG:-""}"
 EXIT_STATUS=0
 
-log() {
-   TS=$(date +%F-%T | tr ':-' '_');
+ts() {
+   TS=$(date +%F-%T | tr ':-' '_')
    echo "$TS $*"
 }
 
+info() {
+   [ ${OPT_VERBOSE:-3} -ge 3 ] && ts "$*"
+}
+
+log() {
+   [ ${OPT_VERBOSE:-3} -ge 2 ] && ts "$*"
+}
+
 warn() {
-   log "$*" >&2
+   [ ${OPT_VERBOSE:-3} -ge 1 ] && ts "$*" >&2
    EXIT_STATUS=1
 }
 
 die() {
-   warn "$*"
+   ts "$*" >&2
+   EXIT_STATUS=1
    exit 1
 }
 
 _d () {
-   [ "$PTDEBUG" ] && echo "# $PTFUNCNAME: $(log "$*")" >&2
+   [ "$PTDEBUG" ] && echo "# $PTFUNCNAME: $(ts "$*")" >&2
 }
 
 # ###########################################################################
@@ -962,6 +971,10 @@
    :
 }
 
+after_interval_sleep() {
+   :
+}
+
 after_stalk() {
    :
 }
@@ -1066,9 +1079,7 @@
    local seconds="$1"
    local msg="${2:-""}"
    if oktorun; then
-      if [ -n "$msg" ]; then
-         log "$msg"
-      fi
+      [ "$msg" ] && info "$msg"
       sleep $seconds
    fi
 }
@@ -1126,7 +1137,11 @@
          fi
 
          local msg="Check results: $OPT_VARIABLE=$value, 
matched=${matched:-no}, cycles_true=$cycles_true"
-         log "$msg"
+         if [ "$matched" ]; then
+            log "$msg"
+         else
+            info "$msg"
+         fi
       elif [ "$OPT_COLLECT" ]; then
          # Make the next if condition true.
          matched=1
@@ -1140,7 +1155,7 @@
          # ##################################################################
          # Start collecting, maybe.
          # ##################################################################
-         log "Collect triggered"
+         log "Collect $ITER triggered"
 
          # Send email to whomever that collect has been triggered.
          if [ "$OPT_NOTIFY_BY_EMAIL" ]; then
@@ -1166,8 +1181,8 @@
                "$margin"
             if [ $? -eq 0 ]; then
                # There should be enough disk space, so collect.
-               log "$msg"                        >> "$OPT_DEST/$prefix-trigger"
-               log "pt-stalk ran with $RAN_WITH" >> "$OPT_DEST/$prefix-trigger"
+               ts "$msg"                        >> "$OPT_DEST/$prefix-trigger"
+               ts "pt-stalk ran with $RAN_WITH" >> "$OPT_DEST/$prefix-trigger"
                last_prefix="$prefix"
 
                # Plugin hook:
@@ -1181,7 +1196,7 @@
                   collect "$OPT_DEST" "$prefix"
                ) >> "$OPT_DEST/$prefix-output" 2>&1 &
                local collector_pid=$!
-               log "Collector PID $collector_pid"
+               log "Collect $ITER PID $collector_pid"
 
                # Plugin hook:
                after_collect $collector_pid
@@ -1199,6 +1214,7 @@
          # ##################################################################
          # Done collecting.
          # ##################################################################
+         log "Collect $ITER done"
          ITER=$((ITER + 1))
          cycles_true=0
          sleep_ok "$OPT_SLEEP" "Sleeping $OPT_SLEEP seconds after collect"
@@ -1208,6 +1224,9 @@
       else
          # Trigger/check/value is ok, sleep until next check.
          sleep_ok "$OPT_INTERVAL"
+
+         # Plugin hook:
+         after_interval_sleep
       fi
    done
 
@@ -1291,7 +1310,7 @@
 # Execute the program if it was not included from another file.
 # This makes it possible to include without executing, and thus test.
 if    [ "${0##*/}" = "$TOOL" ] \
-   || [ "${0##*/}" = "bash" -a "$_" = "$0" ]; then
+   || [ "${0##*/}" = "bash" -a "${_:-""}" = "$0" ]; then
 
    # Parse command line options.  We must do this first so we can
    # see if --daemonize was specified.
@@ -1737,6 +1756,10 @@
 Called after sleeping L<"--sleep"> seconds for the collector process to finish.
 This hook is called after C<after_collect>.
 
+=item after_interval_sleep
+
+Called after sleeping L<"--interval"> seconds after each trigger check.
+
 =item after_stalk
 
 Called after stalking.  Since pt-stalk stalks forever by default,
@@ -1840,6 +1863,22 @@
 
 The variable to compare against the threshold. See L<"--function"> for details.
 
+=item --verbose
+
+type: int; default: 2
+
+Print more or less information while running.  Since the tool is designed
+to be a long-running daemon, the default verbosity level only prints the
+most important information.  If you run the tool interactively, you may
+want to use a higher verbosity level.
+
+  LEVEL PRINTS
+  ===== =====================================
+  0     Errors
+  1     Warnings
+  2     Matching triggers and collection info
+  3     Non-matching triggers
+
 =item --version
 
 Print tool's version and exit.
@@ -1984,7 +2023,7 @@
 
 =head1 VERSION
 
-pt-stalk 2.1.8
+pt-stalk 2.1.9
 
 =cut
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-summary 
new/percona-toolkit-2.1.9/bin/pt-summary
--- old/percona-toolkit-2.1.8/bin/pt-summary    2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-summary    2013-02-14 18:59:10.000000000 
+0100
@@ -29,23 +29,32 @@
 PTDEBUG="${PTDEBUG:-""}"
 EXIT_STATUS=0
 
-log() {
-   TS=$(date +%F-%T | tr ':-' '_');
+ts() {
+   TS=$(date +%F-%T | tr ':-' '_')
    echo "$TS $*"
 }
 
+info() {
+   [ ${OPT_VERBOSE:-3} -ge 3 ] && ts "$*"
+}
+
+log() {
+   [ ${OPT_VERBOSE:-3} -ge 2 ] && ts "$*"
+}
+
 warn() {
-   log "$*" >&2
+   [ ${OPT_VERBOSE:-3} -ge 1 ] && ts "$*" >&2
    EXIT_STATUS=1
 }
 
 die() {
-   warn "$*"
+   ts "$*" >&2
+   EXIT_STATUS=1
    exit 1
 }
 
 _d () {
-   [ "$PTDEBUG" ] && echo "# $PTFUNCNAME: $(log "$*")" >&2
+   [ "$PTDEBUG" ] && echo "# $PTFUNCNAME: $(ts "$*")" >&2
 }
 
 # ###########################################################################
@@ -2280,7 +2289,7 @@
 # Execute the program if it was not included from another file.  This makes it
 # possible to include without executing, and thus test.
 if    [ "${0##*/}" = "$TOOL" ] \
-   || [ "${0##*/}" = "bash" -a "$_" = "$0" ]; then
+   || [ "${0##*/}" = "bash" -a "${_:-""}" = "$0" ]; then
 
    # Set up temporary dir.
    mk_tmpdir
@@ -2673,7 +2682,7 @@
 
 =head1 VERSION
 
-pt-summary 2.1.8
+pt-summary 2.1.9
 
 =cut
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-table-checksum 
new/percona-toolkit-2.1.9/bin/pt-table-checksum
--- old/percona-toolkit-2.1.8/bin/pt-table-checksum     2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-table-checksum     2013-02-14 
18:59:10.000000000 +0100
@@ -53,7 +53,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -3984,7 +3984,7 @@
       die "I need a $arg argument" unless $args{$arg};
    }
    my ($dbh, $db, $tbl) = @args{@required_args};
-   my $q      = $self->{Quoter};
+   my $q      = $self->{Quoter} || 'Quoter';
    my $db_tbl = $q->quote($db, $tbl);
    PTDEBUG && _d('Checking', $db_tbl);
 
@@ -8765,12 +8765,13 @@
             }
 
             if ( $master_binlog ne $slave_binlog ) {
-               $err .= $master_cxn->name() . " has binlog_format "
-                  . $master_binlog . " but replica " . $slave_cxn->name()
-                  . " has binlog_format $slave_binlog.  This could cause "
-                  . "pt-table-checksum to break replication.  "
-                  . "If you understand the risks, specify "
-                  .  "--no-check-binlog-format to disable this check.\n";
+               $err .= "Replica " . $slave_cxn->name()
+                  . qq{ has binlog_format $slave_binlog which could cause }
+                  . qq{pt-table-checksum to break replication.  Please read }
+                  . qq{"Replicas using row-based replication" in the }
+                  . qq{LIMITATIONS section of the tool's documentation.  }
+                  . qq{If you understand the risks, specify }
+                  . qq{--no-check-binlog-format to disable this check.\n};
             }
          }
          die $err if $err;
@@ -11957,6 +11958,6 @@
 
 =head1 VERSION
 
-pt-table-checksum 2.1.8
+pt-table-checksum 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-table-sync 
new/percona-toolkit-2.1.9/bin/pt-table-sync
--- old/percona-toolkit-2.1.8/bin/pt-table-sync 2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-table-sync 2013-02-14 18:59:10.000000000 
+0100
@@ -52,7 +52,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -10582,6 +10582,7 @@
          trim              => $o->get('trim'),
          wait              => $o->get('wait'),
          function          => $o->get('function'),
+         trace             => !$ENV{PT_TEST_NO_TRACE},
       );
 
       if ( sum(@status{@ChangeHandler::ACTIONS}) ) {
@@ -11281,19 +11282,30 @@
       PTDEBUG && _d('Ascend params:', Dumper($asc));
    }
 
-   my $lb_sql = $asc->{boundaries}->{'>='};
-   foreach my $val ( $q->deserialize_list($diff->{lower_boundary}) ) {
-      my $quoted_val = $q->quote_val($val);
-      $lb_sql =~ s/\?/$quoted_val/;
+   my ($lb_sql, $ub_sql);
+
+   if ( defined $diff->{lower_boundary} ) {
+      $lb_sql = $asc->{boundaries}->{'>='};
+      foreach my $val ( $q->deserialize_list($diff->{lower_boundary}) ) {
+         my $quoted_val = $q->quote_val($val);
+         $lb_sql =~ s/\?/$quoted_val/;
+      }
    }
 
-   my $ub_sql = $asc->{boundaries}->{'<='};
-   foreach my $val ( $q->deserialize_list($diff->{upper_boundary}) ) {
-      my $quoted_val = $q->quote_val($val);
-      $ub_sql =~ s/\?/$quoted_val/;
+   if ( defined $diff->{upper_boundary} ) {
+      $ub_sql = $asc->{boundaries}->{'<='};
+      foreach my $val ( $q->deserialize_list($diff->{upper_boundary}) ) {
+         my $quoted_val = $q->quote_val($val);
+         $ub_sql =~ s/\?/$quoted_val/;
+      }
    }
 
-   return "$lb_sql AND $ub_sql";
+   die "Invalid checksum diff: " . Dumper($diff)
+      unless $lb_sql || $ub_sql;
+
+   return   $lb_sql && $ub_sql ? "$lb_sql AND $ub_sql"
+          : $lb_sql            ? $lb_sql
+          :                      $ub_sql;
 }
 }
 
@@ -12636,6 +12648,6 @@
 
 =head1 VERSION
 
-pt-table-sync 2.1.8
+pt-table-sync 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-table-usage 
new/percona-toolkit-2.1.9/bin/pt-table-usage
--- old/percona-toolkit-2.1.8/bin/pt-table-usage        2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-table-usage        2013-02-14 
18:59:10.000000000 +0100
@@ -7383,6 +7383,6 @@
 
 =head1 VERSION
 
-pt-table-usage 2.1.8
+pt-table-usage 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-tcp-model 
new/percona-toolkit-2.1.9/bin/pt-tcp-model
--- old/percona-toolkit-2.1.8/bin/pt-tcp-model  2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-tcp-model  2013-02-14 18:59:10.000000000 
+0100
@@ -2532,6 +2532,6 @@
 
 =head1 VERSION
 
-pt-tcp-model 2.1.8
+pt-tcp-model 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-trend 
new/percona-toolkit-2.1.9/bin/pt-trend
--- old/percona-toolkit-2.1.8/bin/pt-trend      2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-trend      2013-02-14 18:59:10.000000000 
+0100
@@ -2233,6 +2233,6 @@
 
 =head1 VERSION
 
-pt-trend 2.1.8
+pt-trend 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-upgrade 
new/percona-toolkit-2.1.9/bin/pt-upgrade
--- old/percona-toolkit-2.1.8/bin/pt-upgrade    2013-01-08 22:49:57.000000000 
+0100
+++ new/percona-toolkit-2.1.9/bin/pt-upgrade    2013-02-14 18:59:10.000000000 
+0100
@@ -58,7 +58,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -664,7 +664,7 @@
       die "I need a $arg argument" unless $args{$arg};
    }
    my ($dbh, $db, $tbl) = @args{@required_args};
-   my $q      = $self->{Quoter};
+   my $q      = $self->{Quoter} || 'Quoter';
    my $db_tbl = $q->quote($db, $tbl);
    PTDEBUG && _d('Checking', $db_tbl);
 
@@ -13171,6 +13171,6 @@
 
 =head1 VERSION
 
-pt-upgrade 2.1.8
+pt-upgrade 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-variable-advisor 
new/percona-toolkit-2.1.9/bin/pt-variable-advisor
--- old/percona-toolkit-2.1.8/bin/pt-variable-advisor   2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-variable-advisor   2013-02-14 
18:59:10.000000000 +0100
@@ -40,7 +40,7 @@
 # ###########################################################################
 {
 package Percona::Toolkit;
-our $VERSION = '2.1.8';
+our $VERSION = '2.1.9';
 
 1;
 }
@@ -5869,6 +5869,6 @@
 
 =head1 VERSION
 
-pt-variable-advisor 2.1.8
+pt-variable-advisor 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/bin/pt-visual-explain 
new/percona-toolkit-2.1.9/bin/pt-visual-explain
--- old/percona-toolkit-2.1.8/bin/pt-visual-explain     2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/bin/pt-visual-explain     2013-02-14 
18:59:10.000000000 +0100
@@ -3143,6 +3143,6 @@
 
 =head1 VERSION
 
-pt-visual-explain 2.1.8
+pt-visual-explain 2.1.9
 
 =cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/percona-toolkit-2.1.8/docs/percona-toolkit.pod 
new/percona-toolkit-2.1.9/docs/percona-toolkit.pod
--- old/percona-toolkit-2.1.8/docs/percona-toolkit.pod  2013-01-08 
22:49:57.000000000 +0100
+++ new/percona-toolkit-2.1.9/docs/percona-toolkit.pod  2013-02-14 
18:59:10.000000000 +0100
@@ -530,6 +530,6 @@
 
 =head1 VERSION
 
-Percona Toolkit v2.1.8 released 2012-12-21
+Percona Toolkit v2.1.9 released 2013-02-14
 
 =cut

-- 
To unsubscribe, e-mail: opensuse-commit+unsubscr...@opensuse.org
For additional commands, e-mail: opensuse-commit+h...@opensuse.org

Reply via email to