1PMLOGLABEL(1)               General Commands Manual              PMLOGLABEL(1)
2
3
4

NAME

6       pmloglabel - check and repair a performance metrics archive label
7

SYNOPSIS

9       pmloglabel  [-lLsv]  [-h  hostname] [-p pid] [-V version] [-Z timezone]
10       archive
11

DESCRIPTION

13       pmloglabel verifies, reports on, and can  modify  all  details  of  the
14       labels  in  each  of  the files of a Performance Co-Pilot (PCP) archive
15       log.  The archive log has the base name archive and must have been pre‐
16       viously created using pmlogger(1).
17
18       Each  of  the files in a PCP archive (metadata, temporal index, and one
19       or more data volumes) must contain a valid label at the start, else the
20       PCP tools will refuse to open the archive at all.
21
22       Thus,  the  primary  function of pmloglabel is to be able to repair any
23       inconsistent or corrupt label fields, such that the entire  archive  is
24       not  lost.  It will not check the remainder of the archive, but it will
25       give you a fighting chance to recover otherwise lost  data.   Together,
26       pmloglabel  and  pmlogextract  are  able to produce a valid PCP archive
27       from many forms of corruption.
28
29       Note that if the temporal index is found to be corrupt,  the  "*.index"
30       file  can  be safely moved aside and the archive will still be accessi‐
31       ble, however retrievals may take longer without the index.
32

OPTIONS

34       The available command line options are:
35
36       -h hostname, --host=hostname
37            Modify the logged hostname in the archive label, for all files  in
38            the archive.
39
40       -l, --label
41            Dump  out  the  archive label, showing the log format version, the
42            time and date for the start and (current) end of the archive,  and
43            the host from which the performance metrics values were collected.
44
45       -L   Like -l, just a little more verbose, showing also the timezone and
46            creator process identifier from the archive label.
47
48       -p pid, --pid=pid
49            Set the process identifier stored in the archive label to pid, for
50            all files in the archive.
51
52       -s   Rewrite  the  sentinel values which precede and follow the archive
53            label, for all files in the archive.
54
55       -v, --verbose
56            Verbose mode.  Additional progress information is produced at each
57            step.
58
59       -V version, --version=version
60            Stamp  the version number into the magic number field at the start
61            of the archive label, for all files in the archive.
62
63       -Z timezone, --timezone=timezone
64            Changes the timezone in the archive labels to timezone in the for‐
65            mat of the environment variable TZ as described in environ(7).
66

EXAMPLES

68       The  following  demonstrates  the use of pmloglabel in finding and then
69       correcting a corrupt field (PID) in the label of the temporal index  of
70       an archive named "20080125".
71
72                 $ pmdumplog -l 20080125
73                 pmdumplog: Cannot open archive "20080125": Illegal label record at start of a PCP archive log file
74                 $ pmloglabel 20080125
75                 Mismatched PID (5264/5011) between temporal index and data volume 0
76                 $ pmloglabel -p 5264 20080125
77                 $ pmdumplog -l 20080125
78                 Log Label (Log Format Version 2)
79                 Performance metrics from host fw1
80                   commencing Fri Jan 25 00:10:09.341 2008
81                   ending     Sat Jan 26 00:09:54.344 2008
82

EXIT STATUS

84       pmloglabel  exits  with  status  0 if the archive labels are clean.  If
85       invoked incorrectly, the exit status  will  be  1.   If  corruption  is
86       detected  and  still  exists at the end, the exit status will be 2.  If
87       requested to write out the archive labels,  and  some  aspect  of  that
88       write out fails, then the exit status will be 3.
89

FILES

91       $PCP_LOG_DIR/pmlogger/<hostname>
92            Default  directory  for PCP archives containing performance metric
93            values collected from the host <hostname>.
94

PCP ENVIRONMENT

96       Environment variables with the prefix PCP_ are used to parameterize the
97       file  and  directory names used by PCP.  On each installation, the file
98       /etc/pcp.conf contains the  local  values  for  these  variables.   The
99       $PCP_CONF  variable may be used to specify an alternative configuration
100       file, as described in pcp.conf(5).
101

SEE ALSO

103       PCPIntro(1),  pmlogcheck(1),   pmlogextract(1),   pmlogger(1),   pmlog‐
104       ger_check(1),   pmlogger_daily(1),   pmlogrewrite(1),  pcp.conf(5)  and
105       pcp.env(5).
106
107
108
109Performance Co-Pilot                  PCP                        PMLOGLABEL(1)
Impressum