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

EXAMPLES

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

EXIT STATUS

78       pmloglabel exits with status 0 if the archive  labels  are  clean.   If
79       invoked  incorrectly,  the  exit  status  will  be 1.  If corruption is
80       detected and still exists at the end, the exit status will  be  2.   If
81       requested  to  write  out  the  archive labels, and some aspect of that
82       write out fails, then the exit status will be 3.
83

FILES

85       $PCP_LOG_DIR/pmlogger/hostname
86                 Default directory for  PCP  archives  containing  performance
87                 metric values collected from the host hostname.
88

PCP ENVIRONMENT

90       Environment variables with the prefix PCP_ are used to parameterize the
91       file and directory names used by PCP.  On each installation,  the  file
92       /etc/pcp.conf  contains  the  local  values  for  these variables.  The
93       $PCP_CONF variable may be used to specify an alternative  configuration
94       file, as described in pcp.conf(5).
95

SEE ALSO

97       PCPIntro(1),   pmlogcheck(1),   pmlogextract(1),   pmlogger(1),  pmlog‐
98       ger_check(1),  pmlogger_daily(1),  pmlogrewrite(1),  pcp.conf(5),   and
99       pcp.env(5).
100
101
102
103Performance Co-Pilot                  PCP                        PMLOGLABEL(1)
Impressum