14
pt-trend - Compute statistics over a set of time-series data points.
22
Usage: pt-trend [OPTION...] [FILE ...]
24
pt-trend reads a slow query log and outputs statistics on it.
32
The following section is included to inform users about the potential risks,
33
whether known or unknown, of using this tool. The two main categories of risks
34
are those created by the nature of the tool (e.g. read-only tools vs. read-write
35
tools) and those created by bugs.
37
pt-trend simply reads files give on the command-line. It should be very low-risk.
39
At the time of this release, we know of no bugs that could cause serious harm to
42
The authoritative source for updated information is always the online issue
43
tracking system. Issues that affect this tool will be marked as such. You can
44
see a list of such issues at the following URL:
45
`http://www.percona.com/bugs/pt-trend <http://www.percona.com/bugs/pt-trend>`_.
47
See also "BUGS" for more information on filing bugs and getting help.
55
You can specify multiple files on the command line. If you don't specify any,
56
or if you use the special filename \ ``-``\ , lines are read from standard input.
64
This tool accepts additional command-line arguments. Refer to the
65
"SYNOPSIS" and usage information for details.
72
Read this comma-separated list of config files; if specified, this must be the
73
first option on the command line.
87
Create the given PID file. The file contains the process ID of the script.
88
The PID file is removed when the script exits. Before starting, the script
89
checks if the PID file already exists. If it does not, then the script creates
90
and writes its own PID to it. If it does, then the script checks the following:
91
if the file contains a PID and a process is running with that PID, then
92
the script dies; or, if there is no process running with that PID, then the
93
script overwrites the file with its own PID and starts; else, if the file
94
contains no PID, then the script dies.
100
type: array; default: time,15
102
Print progress reports to STDERR. The value is a comma-separated list with two
103
parts. The first part can be percentage, time, or iterations; the second part
104
specifies how often an update should be printed, in percentage, seconds, or
105
number of iterations.
111
Show version and exit.
121
The environment variable \ ``PTDEBUG``\ enables verbose debugging output to STDERR.
122
To enable debugging and capture all output to a file, run the tool like:
127
PTDEBUG=1 pt-trend ... > FILE 2>&1
130
Be careful: debugging output is voluminous and can generate several megabytes
139
You need Perl, DBI, DBD::mysql, and some core packages that ought to be
140
installed in any reasonably new version of Perl.
148
For a list of known bugs, see `http://www.percona.com/bugs/pt-trend <http://www.percona.com/bugs/pt-trend>`_.
150
Please report bugs at `https://bugs.launchpad.net/percona-toolkit <https://bugs.launchpad.net/percona-toolkit>`_.
151
Include the following information in your bug report:
154
\* Complete command-line used to run the tool
162
\* MySQL version of all servers involved
166
\* Output from the tool including STDERR
170
\* Input files (log/dump/config files, etc.)
174
If possible, include debugging output by running the tool with \ ``PTDEBUG``\ ;
183
Visit `http://www.percona.com/software/percona-toolkit/ <http://www.percona.com/software/percona-toolkit/>`_ to download the
184
latest release of Percona Toolkit. Or, get the latest release from the
190
wget percona.com/get/percona-toolkit.tar.gz
192
wget percona.com/get/percona-toolkit.rpm
194
wget percona.com/get/percona-toolkit.deb
197
You can also get individual tools from the latest release:
202
wget percona.com/get/TOOL
205
Replace \ ``TOOL``\ with the name of any tool.
216
*********************
217
ABOUT PERCONA TOOLKIT
218
*********************
221
This tool is part of Percona Toolkit, a collection of advanced command-line
222
tools developed by Percona for MySQL support and consulting. Percona Toolkit
223
was forked from two projects in June, 2011: Maatkit and Aspersa. Those
224
projects were created by Baron Schwartz and developed primarily by him and
225
Daniel Nichter, both of whom are employed by Percona. Visit
226
`http://www.percona.com/software/ <http://www.percona.com/software/>`_ for more software developed by Percona.
229
********************************
230
COPYRIGHT, LICENSE, AND WARRANTY
231
********************************
234
This program is copyright 2010-2011 Baron Schwartz, 2011 Percona Inc.
235
Feedback and improvements are welcome.
237
THIS PROGRAM IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED
238
WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
239
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
241
This program is free software; you can redistribute it and/or modify it under
242
the terms of the GNU General Public License as published by the Free Software
243
Foundation, version 2; OR the Perl Artistic License. On UNIX and similar
244
systems, you can issue \`man perlgpl' or \`man perlartistic' to read these
247
You should have received a copy of the GNU General Public License along with
248
this program; if not, write to the Free Software Foundation, Inc., 59 Temple
249
Place, Suite 330, Boston, MA 02111-1307 USA.
257
Percona Toolkit v0.9.5 released 2011-08-04