pt-deadlock-logger 2.2 requires DSN on command line

Bug #1206728 reported by Mike Siekkinen
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Percona Toolkit moved to https://jira.percona.com/projects/PT
Fix Released
Medium
Daniel Nichter

Bug Description

My percona toolkit installation was upgraded from 2.1.9 to 2.2.4 today and pt-deadlock-logger began failing.

It's failing with the error:

-----------------------------------------------------------------------------------------------------------------------------------------------
pt-deadlock-logger logs information about MySQL deadlocks on the given DSN.
Information is printed to C<STDOUT>, and it can also be saved to a table by
specifying L<"--dest">. The tool runs for forever unless L<"--run-time"> or
L<"--iterations"> is specified. For more details, please use the --help option,
or try 'perldoc /usr/bin/pt-deadlock-logger' for complete documentation.
Usage: pt-deadlock-logger [OPTIONS] DSN

Errors in command-line arguments:
  * No DSN was specified.
-----------------------------------------------------------------------------------------------------------------------------------------------

Nothing was changed with my configuration or db permissions. The command line call looks like

/usr/bin/pt-deadlock-logger --config /home/mon/pt-deadlock-logger/pt-deadlock.conf

-----------------------------------------------------------------------------------------------------------------------------------------------

# Start DSN options for connection to server you want to monitor
h=localhost
S=/var/lib/mysql/mysql.sock
u=user
p=pass
# End DSN

interval=1s # Time interval to poll samples. Since I didn't specify a run-time param this should run forever

# This is destination DSN information. I didn't specify a username or
# password so it inherits those credentials from the DSN definition at the top
dest=D=deadlocksdb,t=deadlock,h=dbserver,P=3320
-----------------------------------------------------------------------------------------------------------------------------------------------

I reviewed the latest docs and didn't see anyting about a change in the dest param or DSN format.

tags: added: pt-deadlock-logger regression
Changed in percona-toolkit:
status: New → Confirmed
milestone: none → 2.2.5
importance: Undecided → Medium
Changed in percona-toolkit:
milestone: 2.2.5 → none
summary: - pt-deadlock-logger claims "* No DSN was specified." After upgrading
- from 2.1.9 to 2.2.4
+ pt-deadlock-logger 2.2 requires a DSN
Revision history for this message
Daniel Nichter (daniel-nichter) wrote : Re: pt-deadlock-logger 2.2 requires a DSN

This was a regression, now tested and fixed. Generally, for tools that take DSN on command line, that DSN is optional because no DSN defaults to h=localhost. In this case, however, the code was preventing that from happening. Now the DSN can be left out, the default h=localhost is used, and then the --config settings are applied to/override that default.

Changed in percona-toolkit:
status: Confirmed → Fix Committed
assignee: nobody → Daniel Nichter (daniel-nichter)
milestone: none → 2.2.5
Revision history for this message
Daniel Nichter (daniel-nichter) wrote :
summary: - pt-deadlock-logger 2.2 requires a DSN
+ pt-deadlock-logger 2.2 requires DSN on command line
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-620

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.