summaryrefslogtreecommitdiffstats
path: root/pcp-htop.5.in
blob: ebb47487e16ec3905a5cb9d53d762ee080198347 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
.TH "PCP-HTOP" "5" "2024" "@PACKAGE_STRING@" "File Formats"
.SH "NAME"
\f3pcp-htop\f1 \- pcp-htop configuration file
.SH "DESCRIPTION"
.B pcp-htop
is a customizable performance metrics reporting tool.
It has a dynamic architecture, where a set of configuration files
provide additional, optional meters and columns to extend the fixed
set of display options provided by regular
.BR htop .
.LP
These configuration files can be provided from both system-wide
locations (first
.I @sysconfdir@/pcp/htop
then
.IR @datarootdir@/pcp/htop )
and below the user's home directory (usually
.IR ~/.config/htop ).
Within these locations the
.I meters
and
.I columns
are scanned for dynamic Meter and Column specifications.
.LP
Meters are displayed in the top part of the
.B pcp-htop
window, and columns are displayed in the lower part.
Meters tend to display system-wide metrics, and Columns
display metrics about individual processes.
.LP
The formats are similar but have slightly different requirements.
Both formats follow the common ini-style. Blank lines are ignored.
Lines starting with the "#" character are treated as comments.
.SH "METERS"
The following is an example configuration for a new Redis meter:
.LP
.ft CW
.nf
.in +0.5i
[redisclient]
caption = Redis clients
type = bar
blocked.metric = redis.blocked_clients
blocked.color = blue
blocked.label = blk
clients.metric = redis.connected_clients
clients.color = green
clients.label = conn
.in
.fi
.ft 1
.LP
A configuration file can contain multiple meter definitions.
Each definition begins with a identifying name enclosed by
square brackets \-
.I redisclient
in this example.
The name is used internally within
.B pcp-htop
and must be unique, must begin with an alphabetic character,
and may subsequently only contain alphanumeric characters or
the underscore character.
No whitespace or other characters are allowed.
.LP
There are several parameters that define the way the meter
will be displayed to the user.
.TP 5
.B caption
This value is displayed on the Setup screen once the meter
has been selected.
A truncated version of the
.I caption
will also be displayed (followed by a colon) on the primary
display while the meter is updating.
.TP
.B description
This can be used to provide more detail during the meter
selection process on the Setup screen, and if present it is
displayed in the "Available Meters" column.
If not present, the
.B caption
will be used for this.
If neither is present, the internal (mandatory)
.B name
will be used.
.TP
.B type
This setting allows a preferred default meter type to be specified.
The associated value must be one of
.IR bar ,
.IR text ,
.IR graph ,
or
.IR led .
If no value is provided for a dynamic meter, the default value of
.IR text
will be used.
.TP
.B maximum
A numeric value can also be set to size the meter, such that
values (e.g. for a
.I bar
type meter display) will be scaled within range zero to
.IR maximum .
.LP
The remaining definition syntax describes the individual
metric(s) which will be used to animate the meter.
One or more metrics must be specified for each meter and
there are several properties associated with each.
Once again, these metrics must be named (the same rules
described above for meters apply here) and the following
properties can be configured:
.TP 5
.B name.metric
This is the only mandatory field and associates a PCP metric
with the meter.
Values sampled for each metric at runtime provide the
animation visible in the
.B pcp-htop
display.
The metric specification can be either a PCP metric name as
listed by
.BR pminfo (1)
or a "derived" metric expression.
The format for derived metric expressions is described on the
.BR pmRegisterDerived (3)
manual page.
.TP
.B name.color
Setting color to be used when rendering metric values.
Possible values are
.IR red ,
.IR green ,
.IR blue ,
.IR cyan ,
.IR magenta ,
.IR yellow ,
.IR gray ,
.I darkgray
or
.IR white .
.TP
.B name.label
An optional, short label to display before the metric value.
The ":" character will be appended to the
.I label
before the metric value part of the display.
.TP
.B name.suffix
An optional, short suffix to display after the metric value.
Commonly used to indicate values as a percentage using a "%"
.I suffix
value and to provide the base unit of measurement.
Note that since PCP maintains units for metrics, for those
metrics that have dimension in "space" (bytes, kilobytes,
megabytes, etc), a suffix will be automatically appended.
.SH "COLUMNS"
The following is an example configuration for a new column
showing open file descriptors for each process:
.LP
.ft CW
.nf
.in +0.5i
[openfds]
heading = FDS
caption = FDCOUNT
description = Open file descriptors
metric = proc.fd.count
width = 3
.in
.fi
.ft 1
.LP
A configuration file can contain multiple column definitions.
Each definition begins with a identifying name enclosed
by square brackets \-
.I openfds
in this example, and the same rules apply as described above
for meter names.
.LP
Each column must specify a metric.
Optional parameters can also be set.
.TP 5
.B metric
As with meters, the metric value must be either a PCP metric
name as listed by
.BR pminfo (1)
or a derived metric.
The metric must have an instance domain (set of values) and
that instance domain must map to the set of processes with
the instance identifier being PIDs (process identifiers).
Typically this will be metrics from the
.I proc
or
.I hotproc
namespace (\c
.BR pmdaproc (1)),
but metrics from other domains (\c
.BR pmdabcc (1),
.BR pmdabpf (1),
etc) that have per-process values are equally applicable.
.TP
.B width
Column width to use when displaying values for the metric.
A negative value can be used to specify left alignment.
An upper column limit of 28 characters is enforced.
The default column width is 5 characters.
.TP
.B heading
The short title that will be displayed at the head of the
column \- usually a short, cryptic, all uppercase string.
.TP
.B caption
A short identifying word presented to users on the Setup
screen under both the Available and Active Columns lists.
.TP
.B description
Text that assists users to understand the meaning of this
column when it is being presented via the Setup screen in
the Available Columns list.
.SH "SEE ALSO"
.BR pcp-htop (1),
.BR pminfo (1),
.BR pmcd (1),
.BR pmdaproc (1),
.BR pmdabcc (1),
.BR pmdabpf (1)
and
.BR pmRegisterDerived (3).
.SH "AUTHORS"
.B htop
was originally developed by Hisham Muhammad.
Nowadays it is maintained by the community at <htop@groups.io>.
.LP
.B pcp-htop
is maintained as a collaboration between the <htop@groups.io> and <pcp@groups.io>
communities, and forms part of the Performance Co-Pilot suite of tools.