1PCP-DSTAT(1)                General Commands Manual               PCP-DSTAT(1)
2
3
4

NAME

6       pcp-dstat - versatile tool for generating system resource statistics
7

SYNOPSIS

9       pcp  [pcp options]  dstat  [-acdfghilmnpqrstvVy?]  [-C cpus] [-D disks]
10       [-I interrupts] [-N  interfaces]  [-o  output-file]  [-S  swap-devices]
11       [--bits]  [--bw] [--color] [--float] [--integer] [--nocolor] [--nohead‐
12       ers] [--noupdate] [--list] [--pidfile pid-file] [--plugin] [--all-plug‐
13       ins] [delay [count]]
14

DESCRIPTION

16       pcp-dstat  is  a general performance analysis tool allowing you to view
17       multiple system resources instantly, for example you can  compare  disk
18       usage in combination with interrupts from a disk controller, or compare
19       the network bandwidth numbers directly with the disk throughput (in the
20       same interval).
21
22       It also cleverly gives you the most detailed information in columns and
23       clearly indicates in what magnitude and unit the output is  being  dis‐
24       played.  Less confusion, fewer mistakes, more efficient.
25
26       The delay is the delay in seconds between each update, and the count is
27       the number of updates to display before exiting.  The default delay  is
28       1  second and count is unspecified (run until interrupted or end of ar‐
29       chive is reached).
30
31       This latest generation of Dstat, pcp-dstat, allows for analysis of his‐
32       torical  performance  data (in the PCP archive format created by pmlog‐
33       ger(1)), as well as distributed systems analysis  of  live  performance
34       data from remote hosts running the pmcd(1) process.
35
36       Additionally,  this  version  introduces configuration files similar to
37       pmrep.conf(5) from the pmrep(1) utility.  The original Dstat notion  of
38       ``plugins'' is replaced by use of named metrics in a Performance Metric
39       Name Space (PMNS(5))  supplied  by  Performance  Metric  Domain  Agents
40       (PMDAs).   Metrics and other formatting information is now specified as
41       plugin configuration files.  This new style of plugin is either  built-
42       in (time-related reporting only), or sourced from the system-wide loca‐
43       tion ($PCP_ETC_DIR/dstat) and/or sourced from an individual  users  set
44       of personal plugins ($HOME/pcp/dstat).
45
46       The  list  of  all available plugins can be seen using the --list dstat
47       command line option.
48

OPTIONS

50       When invoked via  the  pcp(1)  command,  the  -h/--host,  -a/--archive,
51       -O/--origin,  -Z/--timezone  and several other pcp options become indi‐
52       rectly available.
53
54       The available dstat options are:
55
56       --list list all available plugin names
57
58       --plugin-name
59            enable any plugin by name
60
61       -a, --all
62            equals -cdngy (default plugin set)
63
64       -c, --cpu
65            enable CPU stats (system, user, idle, wait), for more CPU  related
66            stats also see --cpu-adv and --cpu-use
67
68       -C 0,3,total
69            include  CPU0,  CPU3  and  total (when using -c/--cpu); use all to
70            show all CPUs
71
72       -d, --disk
73            enable disk stats (read, write), for more disk related stats  look
74            into the other --disk plugins
75
76       -D total,hda
77            include total and hda (when using -d/--disk)
78
79       -g, --page
80            enable page stats (page in, page out)
81
82       -i, --int
83            enable interrupt stats
84
85       -I 5,10
86            include interrupt 5 and 10 (when using -i/--int)
87
88       -l, --load
89            enable load average stats (1 min, 5 mins, 15 mins)
90
91       -m, --mem
92            enable  memory stats (used, buffers, cache, free); for more memory
93            related stats also try --mem-adv and --swap
94
95       -n, --net
96            enable network stats (receive, send)
97
98       -N eth1,total
99            include eth1 and total (when using -n/--net)
100
101       --net-packets
102            show the number of packets received and transmitted
103
104       -p, --proc
105            enable process stats (runnable, uninterruptible, new)
106
107       --proc-count
108            show total number of processes
109
110       -r, --io
111            enable I/O request stats (read, write requests)
112
113       -s, --swap
114            enable swap stats (used, free)
115
116       -S swap1,total
117            include swap1 and total (when using -s/--swap)
118
119       --snooze show time spent between updates in seconds
120
121       -t, --time
122              enable time/date output (try --time-adv for  millisecond  preci‐
123              sion)
124
125       -T, --epoch
126              enable  time counter (seconds since epoch, or millisecond preci‐
127              sion from the --epoch-adv plugin)
128
129       -y, --sys
130              enable system stats (interrupts, context switches)
131
132       --aio  enable aio stats (asynchronous I/O)
133
134       --cpu-adv
135              enable advanced CPU stats
136
137       --cpu-use
138              enable only CPU usage stats
139
140       --disk-avgqu
141              average queue length of the requests that  were  issued  to  the
142              device
143
144       --disk-avgrq
145              average  size  (in  sectors) of the requests that were issued to
146              the device
147
148       --disk-svctm
149              average service time (in milliseconds)  for  I/O  requests  that
150              were issued to the device
151
152       --disk-tps
153              number of transfers per second that were issued to the device
154
155       --disk-util
156              percentage  of CPU time during which I/O requests were issued to
157              the device (bandwidth utilization for the device)
158
159       --disk-wait
160              average time (in milliseconds) for I/O requests  issued  to  the
161              device to be served
162
163       --fs, --filesystem
164              enable filesystem stats (open files, inodes)
165
166       --freespace
167              per filesystem used and available space
168
169       --ipc  enable ipc stats (message queue, semaphores, shared memory)
170
171       --lock enable file lock stats (posix, flock, read, write)
172
173       --mem-adv
174              enable advanced memory stats
175
176       --raw  enable raw stats (raw sockets)
177
178       --socket
179              enable socket stats (total, tcp, udp, raw, ip-fragments)
180
181       --tcp  enable tcp stats (listen, established, syn, time_wait, close)
182
183       --udp  enable udp stats (listen, active)
184
185       --unix enable unix stats (datagram, stream, listen, active)
186
187       --utmp shows login information from utmp(5)
188
189       --vm   enable  virtual  memory stats (hard pagefaults, soft pagefaults,
190              allocated, free)
191
192       --vm-adv
193              enable advance virtual memory stats (steal, scanK, scanD, pgoru,
194              astll)
195
196       --nfs3 show NFS v3 client operations
197
198       --nfs3-ops
199              show extended NFS v3 client operations
200
201       --nfsd3
202              show NFS v3 server operations
203
204       --nfsd3-ops
205              show extended NFS v3 server operations
206
207       --nfsd4-ops
208              show extended NFS v4 server operations
209
210       --nfsstat4
211              show NFS v4 stats
212
213       --rpc  show remote procedure call (RPC) client calls stats
214
215       --rpcd show remote procedure call (RPC) server calls stats
216
217       -f, --full
218              expand -C, -D, -I, -N and -S discovery lists
219
220       -v, --vmstat
221              equals -pmgdsc -D total
222
223       --bits force bits for values expressed in bytes
224
225       --float
226              force float values on screen (mutually exclusive with --integer)
227
228       --integer
229              force integer values on screen (mutually exclusive with --float)
230
231       --bw, --blackonwhite
232              change colors for white background terminal
233
234       --nocolor
235              disable colors
236
237       --noheaders
238              disable repetitive headers
239
240       --noupdate
241              disable intermediate updates when delay greater than 1.
242
243       -o file, --output=file
244              write CSV (Comma-Separated Value) format output to a file.
245
246       -p file, --pidfile=file
247              write the process identifier to a given file.
248

OPTIONAL METRICS PLUGINS

250       Some pcp-dstat configuration files require the installation of optional
251       Performance  Metric  Domain  Agents,  above  and  beyond  the   default
252       installed set.
253
254       --innodb-buffer
255            show innodb buffer stats (needs the MySQL PMDA)
256
257       --innodb-io
258            show innodb I/O stats (needs the MySQL PMDA)
259
260       --innodb-ops
261            show innodb operations counters (needs the MySQL PMDA)
262
263       --lustre
264            show lustre I/O throughput (needs the Lustre PMDA)
265
266       --memcache-hits
267            show the number of hits and misses from memcache
268
269       --mysql5-cmds
270            show the MySQL5 command stats (needs the MySQL PMDA)
271
272       --mysql5-conn
273            show the MySQL5 connection stats (needs the MySQL PMDA)
274
275       --mysql5-innodb
276            show the MySQL5 innodb stats (needs the MySQL PMDA)
277
278       --mysql5-io
279            show the MySQL5 I/O stats (needs the MySQL PMDA)
280
281       --mysql5-keys
282            show the MySQL5 keys stats (needs the MySQL PMDA)
283
284       --mysql-io
285            show the MySQL I/O stats (needs the MySQL PMDA)
286
287       --mysql-keys
288            show the MySQL keys stats (needs the MySQL PMDA)
289
290       --postfix
291            show postfix queue sizes (needs the Postfix PMDA)
292
293       --redis
294            show Redis stats (needs the Redis PMDA)
295
296       --sendmail
297            show sendmail queue size (needs the Sendmail PMDA)
298

HISTORICAL METRICS PLUGINS

300       Anyone  can  create  additional,  custom pcp-dstat plugin configuration
301       files, for any metrics - the list of available metrics can be  produced
302       by either the pminfo(1) or pmprobe(1) command.
303
304       The  following  do  not  yet  have  metrics backing them, but have been
305       included   from   the   original   Dstat   utility.    Please   contact
306       <pcp@groups.io>  if  you need or implement any of these, and we'll work
307       with you to get them included.
308
309       --battery
310            battery in percentage (needs an ACPI PMDA)
311
312       --battery-remain
313            battery remaining in hours, minutes (needs an ACPI PMDA)
314
315       --cpufreq
316            CPU frequency in percentage (needs an ACPI PMDA)
317
318       --dbus
319            number of dbus connections (needs a python-dbus PMDA)
320
321       --fan
322            fan speed (needs an ACPI PMDA)
323
324       --gpfs
325            GPFS read/write I/O (needs mmpmon and a GPFS PMDA)
326
327       --gpfs-ops
328            GPFS filesystem operations (needs mmpmon and a GPFS PMDA)
329
330       --md-status
331            show software raid (MD  driver)  progress  and  speed  (needs  new
332            disk.md metrics)
333
334       --power
335            show power usage (needs an ACPI PMDA)
336
337       --qmail
338            show qmail queue sizes (needs qmail)
339
340       --squid
341            show squid usage statistics (needs a Squid PMDA)
342
343       --thermal
344            system temperature sensors (needs an ACPI PMDA)
345
346       --vm-cpu
347            show VMware CPU stats from hypervisor (needs a VMware PMDA)
348
349       --vm-mem
350            show VMware memory stats from hypervisor (needs a VMware PMDA)
351
352       --vm-mem-adv
353            show  advanced VMware memory stats from hypervisor (needs a VMware
354            PMDA)
355
356       --vmk-hba
357            show VMware ESX kernel vmhba stats (needs a VMware PMDA)
358
359       --vmk-int
360            show VMware ESX kernel interrupt stats (needs a VMware PMDA)
361
362       --vmk-nic
363            show VMware ESX kernel port stats (needs a VMware PMDA)
364
365       --vz-cpu
366            show CPU usage per OpenVZ guest (needs an OpenVZ PMDA)
367
368       --vz-io
369            show I/O usage per OpenVZ guest (needs an OpenVZ PMDA)
370
371       --vz-ubc
372            show OpenVZ user beancounters (needs an OpenVZ PMDA)
373
374       --wifi
375            wireless link quality and signal to noise ratio (needs Linux  PMDA
376            metrics)
377
378       --zfs-arc
379            show ZFS arc stats (needs a Linux ZFS PMDA)
380
381       --zfs-l2arc
382            show ZFS l2arc stats (needs a Linux ZFS PMDA)
383
384       --zfs-zil
385            show ZFS zil stats (needs a Linux ZFS PMDA)
386

INTERMEDIATE UPDATES

388       When  invoking pcp-dstat with a delay greater than 1 second and without
389       the --noupdate option, it will show  intermediate  updates,  i.e.,  the
390       first  time  a  1 second average, the second update a 2 second average,
391       etc. until the delay has been reached.
392
393       So in case you specified a delay of 10, the 9 intermediate updates  are
394       NOT  snapshots,  they  are averages over the time that passed since the
395       last final update.  The end result is that you get a 10 second  average
396       on a new line, just like with vmstat(1).
397

EXAMPLES

399       Using  pcp-dstat  to  relate disk-throughput with network-usage (eth0),
400       total CPU-usage and system counters:
401
402            $ pcp dstat -dnyc -N eth0 -C total -f 5
403
404       Using the time plugin together with cpu, net, disk,  system,  load  and
405       proc plugins:
406
407            $ pcp dstat -tcndylp
408
409       This is identical to:
410
411            $ pcp dstat --time --cpu --net --disk --sys --load --proc
412
413       Using pcp-dstat to report 10 samples from metrics recorded in a PCP ar‐
414       chive 20180729 from 2:30 AM:
415        $ pcp --origin '@02:30' -a 20180729 dstat --time --cpu-adv --sys 1 10
416
417       Examine the same metrics live from a remote host:
418
419            $ pcp --host www.acme.com dstat --time --cpu-adv --sys 1 10
420
421

FILES

423       $HOME/.pcp/dstat/
424              private per-user configuration files
425
426       $PCP_SYSCONF_DIR/pcp/dstat/
427              system-wide configuration files
428

ENVIRONMENT

430       Internal plugins behaviour can be  changed  through  environment  vari‐
431       ables.
432
433       DSTAT_TIMEFMT
434              strftime(3) format string for reporting time (see --time)
435

PCP ENVIRONMENT

437       Environment variables with the prefix PCP_ are used to parameterize the
438       file and directory names used by PCP.  On each installation,  the  file
439       /etc/pcp.conf  contains  the  local  values  for  these variables.  The
440       $PCP_CONF variable may be used to specify an alternative  configuration
441       file, as described in pcp.conf(5).
442
443       For environment variables affecting PCP tools, see pmGetOptions(3).
444

AUTHORS

446       The Dstat utility was initially written by Dag Wieers <dag@wieers.com>.
447
448       The Dstat homepage is at http://dag.wieers.com/home-made/dstat/.
449
450       This   manpage   was   initially   written  by  Andrew  Pollock  <apol‐
451       lock@debian.org> for the Debian GNU/Linux system.
452
453       The pcp-dstat utility is written and maintained by the  PCP  developers
454       <pcp@groups.io>.
455
456       The PCP homepage is at https://pcp.io/.
457

SEE ALSO

459       PCPIntro(1),   pcp(1),  pmcd(1),  pminfo(1),  pmlogger(1),  pmprobe(1),
460       pmrep(1),    vmstat(1),    pmGetOptions(3),    strftime(3),    PMNS(5),
461       pcp.conf(5), pmrep.conf(5) and utmp(5).
462
463
464
465Performance Co-Pilot                  PCP                         PCP-DSTAT(1)
Impressum