PMVAL(1) | General Commands Manual | PMVAL(1) |
pmval, pmevent - arbitrary performance metrics value dumper
pmval [-dgLrvz] [-A align] [-a archive] [-f N] [-h host] [-i instances] [-K spec] [-n pmnsfile] [-O offset] [-p port] [-S starttime] [-s samples] [-T endtime] [-t interval] [-U archive] [-w width] [-x pattern] [-Z timezone] metricname
pmval prints current or archived values for the nominated performance metric. The metric of interest is named in the metricname argument, subject to instance qualification with the -i flag as described below.
Unless directed to another host by the -h option, or to a set of archives by the -a or -U options, pmval will contact the Performance Metrics Collector Daemon (PMCD) on the local host to obtain the required information.
The metricname argument may also be given in the metric specification syntax, as described in PCPIntro(1), where the source, metric and instance may all be included in the metricname, e.g. thathost:kernel.all.load["1 minute"]. When this format is used, none of the -h or -a or -U options may be specified.
When using the metric specification syntax, the ``hostname'' @ is treated specially and causes pmval to use a local context to collect metrics from PMDAs on the local host without PMCD. Only some metrics are available in this mode.
When processing a set of archives, pmval may relinquish its own timing control, and operate as a ``slave'' of a pmtime(1) process that uses a GUI dialog to provide timing control. In this case, either the -g option should be used to start pmval as the sole slave of a new pmtime(1) instance, or -p should be used to attach pmval to an existing pmtime(1) instance via the IPC channel identified by the port argument.
The -S, -T, -O and -A options may be used to define a time window to restrict the samples retrieved, set an initial origin within the time window, or specify a ``natural'' alignment of the sample times; refer to PCPIntro(1) for a complete description of these options.
The other options which control the source, timing and layout of the information reported by pmval are as follows:
The instance name may be quoted with single (') or double (") quotes for those cases where the instance name contains white space or commas.
Multiple -i options are allowed as an alternative way of specifying more than one instance of interest.
As an example, the following are all equivalent:
$ pmval -i "'1 minute','5 minute'" kernel.all.load $ pmval -i '"1 minute","5 minute"' kernel.all.load $ pmval -i "'1 minute' '5 minute'" kernel.all.load $ pmval -i "'1 minute'" -i "'5 minute'" kernel.all.load $ pmval 'localhost:kernel.all.load["1 minute","5 minute"]'
At most one of the options -a and -U may be specified.
As pattern may be processed by regcomp(3) it should be a non-empty string. Use . (dot) for a “match all” pattern.
The following symbols may occasionally appear, in place of a metric value, in pmval output: A question mark symbol (?) indicates that a value is no longer available for that metric instance. An exclamation mark (!) indicates that a 64-bit counter wrapped during the sample.
The output from pmval is directed to standard output.
Environment variables with the prefix PCP_ are used to parameterize the file and directory names used by PCP. On each installation, the file /etc/pcp.conf contains the local values for these variables. The $PCP_CONF variable may be used to specify an alternative configuration file, as described in pcp.conf(5).
PCPIntro(1), pmcd(1), pmchart(1), pmdumplog(1), pmdumptext(1), pminfo(1), pmlogger(1), pmrep(1), pmtime(1), PMAPI(3), pmStore(3), pmSpecLocalPMDA(3), pcp.conf(5) and pcp.env(5).
All are generated on standard error and are intended to be self-explanatory.
By default, pmval attempts to display non-integer numeric values in a way that does not distort the inherent precision (rarely more than 4 significant digits), and tries to maintain a tabular format in the output. These goals are sometimes in conflict.
In the absence of the -f option (described above), the following table describes the formats used for different ranges of numeric values for any metric that is of type PM_TYPE_FLOAT or PM_TYPE_DOUBLE, or any metric that has the semantics of a counter (for which pmval reports the rate converted value):
Format | Value Range |
! | No values available |
9.999E-99 | < 0.1 |
0.0 | 0 |
9.9999 | > 0 and <= 0.9999 |
9.999 | > 0.9999 and < 9.999 |
99.99 | > 9.999 and < 99.99 |
999.9 | > 99.99 and < 999.9 |
9999. | > 999.9 and < 9999 |
9.999E+99 | > 9999 |
PCP | Performance Co-Pilot |