reads one or more Performance Co-Pilot (PCP) archive logs
and creates a temporally merged and/or reduced PCP archive log in
The nature of merging is controlled by the number of input
archive logs, while the nature of data reduction is controlled by
the command line arguments. The input(s) must be PCP archive logs
with performance data collected from the
host, but usually over different time periods and possibly (although
not usually) with different performance metrics being logged.
If only one
is specified, then the default behavior simply copies the input
PCP archive log, into the output PCP archive log. When two or
more PCP archive logs are specified as
the logs are merged (or concatenated) and written to
In the output archive log a ``mark'' record will be inserted at a time
just past the end of each of the input archive logs to indicate
a possible temporal discontinuity between the end of one input
archive log and the start of the next input archive log.
section below for more information.
There is no ``mark''
record after the end of the
(in temporal order) of the input archive logs.
COMMAND LINE OPTIONS
The command line options for
are as follows:
Extract only the metrics specified in
PCP archive log(s). The
syntax accepted by
is explained in more detail in the
Configuration File Syntax
Desperate mode. Normally if a fatal error occurs, all trace of
the partially written PCP archive
is removed. With the
archive log is not removed.
For most common uses, all of the
input archive logs will have been collected in the same timezone.
But if this is not the case, then
must choose one of the timezones from the input archive logs to be
used as the timezone for the output archive log.
The default is to use the timezone from the
input archive log.
option forces the timezone from the
input archive log to be used.
operates on the Performance Metrics Name Space (PMNS) from
however if the
option is specified an alternative
local PMNS is loaded from the file
Define the start of a time window to restrict the samples retrieved
or specify a ``natural'' alignment of the output sample times; refer
See also the
defines the number of samples to be written to
is 0 or
is not specified,
will sample until the end of the PCP archive log,
or the end of the time window as specified by
whichever comes first. The
option will override the
option if it occurs sooner.
Define the termination of a time window to restrict the samples
retrieved or specify a ``natural'' alignment of the output sample
times; refer to
See also the
archive log is potentially a multi-volume data set, and the
to start a new volume after
log records have been written to the archive log.
specify a time window within the same day, the
flag will cause the data within the time window to be extracted,
for every day in the archive log.
For example, the options
-w -S @11:00 -T @15:00
should include archive log records only for the periods from 11am
to 3pm on each day. When
is used, the
archive log will contain ``mark'' records to indicate the temporal
discontinuity between the end of one time window and the start of
when displaying the date and time.
is in the format of the environment variable
as described in
Use the local timezone of the host from the input archive logs.
The default is to initially use the timezone of the local host.
CONFIGURATION FILE SYNTAX
contains metrics of interest, listed one per line. Instances
may also be specified, but they are optional. The format for
each metric name is
may be a leaf or a non-leaf node in the Performance Metrics
Namespace (PMNS, see
If a metric refers to a non-leaf node in the PMNS,
will recursively descend the PMNS and include all metrics
corresponding to descendent leaf nodes. Instances are
optional, and may be specified as a list of one or more
space (or comma) separated names, numbers or strings.
Elements in the list that are numbers are assumed to be external
instance identifiers - see
for more information.
If no instances are given, then the logging specification is applied
to all instances of the associated metric(s).
When more than one input archive log contributes performance data to the
output archive log, then ``mark'' records are inserted to indicate a possible
discontinuity in the performance data.
A ``mark'' record contains a timestamp and no performance data and
is used to indicate that there is a time period
in the PCP archive log where we do not know the values of
performance metrics, because there was no
collecting performance data during this period. Since these periods are
often associated with the restart of a service or
or a system, there may be considerable doubt as to the continuity of
performance data across this time period.
The rationale behind ``mark'' records may be demonstrated with an example.
Consider one input archive log that starts at 00:10 and ends at 09:15 on the
same day, and another input archive log that starts at 09:20 on the
same day and ends at 00:10 the following morning. The would be a very
common case for archives managed and rotated by
The output archive log would contain:
00:10.000first record from first input archive log
09:15.000last record from first input archive log
09:20.000first record from second input archive log
01:10.000last record from second input archive log
The time period where the performance data is missing starts just after
09:15 and ends just before 09:20.
When the output archive log is processed with any of the PCP reporting
tools, the ``mark'' record is used to indicate a period of missing
data. For example in the archive above, if one was reporting the average
I/O rate at 30 minute intervals, aligned on the hour, then there would be
data for the intervals ending at 09:00 and 10:00 but no data reported for
the interval ending at 09:30 as this spans a ``mark'' record.
The presence of ``mark'' records in a PCP archive log can be established
where a timestamp and the annotation
is used to indicate a ``mark'' record.
For each of the
archive logs, several physical files are used.
metadata (metric descriptions, instance domains, etc.) for the archive log
initial volume of metrics values (subsequent volumes have suffixes
temporal index to support rapid random access to the other files in the
Environment variables with the prefix
are used to parameterize the file and directory names
used by PCP.
On each installation, the file
contains the local values for these variables.
variable may be used to specify an alternative
as described in
All error conditions detected by
are reported on
with textual (if sometimes terse) explanation.
Should one of the input archive logs be corrupted (this can happen
instance writing the log suddenly dies), then
will detect and report the position of the corruption in the file,
and any subsequent information from that archive log will not be processed.
If any error is detected,
will exit with a non-zero status.
The preamble metrics (pmcd.pmlogger.archive, pmcd.pmlogger.host,
and pmcd.pmlogger.port), which are automatically recorded by
at the start of the archive, may not be present in the archive output by
These metrics are only relevant while the archive is being created,
and have no significance once recording has finished.