Browse files

- Fix top-plugins on python 2.2 and older

- Documentation improvements
  • Loading branch information...
1 parent 05609f5 commit 7b634179e677632698740730f550fc32c2584061 @dagwieers committed Nov 26, 2009
Showing with 966 additions and 317 deletions.
  1. +4 −0 ChangeLog
  2. +70 −40 docs/dstat-paper.html
  3. +44 −38 docs/dstat-paper.txt
  4. +45 −47 docs/dstat.1
  5. +47 −48 docs/dstat.1.html
  6. +50 −51 docs/dstat.1.txt
  7. +607 −0 docs/performance.html
  8. +4 −3 dstat
  9. +5 −2 dstat.spec
  10. +0 −1 plugins/dstat_battery.py
  11. +2 −2 plugins/dstat_dbus.py
  12. +1 −1 plugins/dstat_disk_util.py
  13. +1 −1 plugins/dstat_freespace.py
  14. +1 −1 plugins/dstat_gpfs.py
  15. +2 −2 plugins/dstat_gpfs_ops.py
  16. +3 −3 plugins/dstat_helloworld.py
  17. +2 −2 plugins/dstat_innodb_buffer.py
  18. +2 −2 plugins/dstat_innodb_io.py
  19. +2 −2 plugins/dstat_innodb_ops.py
  20. +2 −2 plugins/dstat_memcache_hits.py
  21. +4 −3 plugins/dstat_mysql5_cmds.py
  22. +2 −2 plugins/dstat_mysql5_conn.py
  23. +2 −2 plugins/dstat_mysql5_keys.py
  24. +2 −2 plugins/dstat_mysql_keys.py
  25. +2 −2 plugins/dstat_net_packets.py
  26. +2 −2 plugins/dstat_nfs3.py
  27. +2 −2 plugins/dstat_nfs3_ops.py
  28. +2 −2 plugins/dstat_nfsd3.py
  29. +2 −2 plugins/dstat_nfsd3_ops.py
  30. +2 −2 plugins/dstat_ntp.py
  31. +2 −2 plugins/dstat_postfix.py
  32. +2 −2 plugins/dstat_power.py
  33. +2 −2 plugins/dstat_proc_count.py
  34. +2 −2 plugins/dstat_rpc.py
  35. +2 −2 plugins/dstat_rpcd.py
  36. +1 −2 plugins/dstat_sendmail.py
  37. +1 −1 plugins/dstat_snooze.py
  38. +1 −1 plugins/dstat_top_bio.py
  39. +1 −1 plugins/dstat_top_cpu.py
  40. +1 −1 plugins/dstat_top_cputime.py
  41. +1 −1 plugins/dstat_top_cputime_avg.py
  42. +1 −1 plugins/dstat_top_io.py
  43. +1 −1 plugins/dstat_top_latency.py
  44. +1 −1 plugins/dstat_top_latency_avg.py
  45. +1 −1 plugins/dstat_top_mem.py
  46. +3 −3 plugins/dstat_top_oom.py
  47. +4 −2 plugins/dstat_utmp.py
  48. +5 −5 plugins/dstat_vm_memctl.py
  49. +2 −3 plugins/dstat_vmk_hba.py
  50. +3 −4 plugins/dstat_vmk_int.py
  51. +3 −3 plugins/dstat_vmk_nic.py
  52. +2 −1 plugins/dstat_vz_cpu.py
  53. +2 −0 plugins/dstat_vz_io.py
  54. +3 −1 plugins/dstat_vz_ubc.py
  55. +3 −5 plugins/dstat_wifi.py
View
4 ChangeLog
@@ -1,3 +1,7 @@
+* 0.7.0svn - ... - release 26/11/2009
+- Fix top-plugins on python 2.2 and older
+- Documentation improvements
+
* 0.7.0 - Tokyo - release 25/11/2009
- Fixed dstat_disk plugin for total calculation on 2.6.25+ kernels (Noel J. Bergman)
- Precompile regular expressions used as a disk filter (self.diskfilter)
View
110 docs/dstat-paper.html
@@ -855,6 +855,11 @@ <h3 id="_external_plugins">External plugins</h3><div style="clear:left"></div>
</li>
<li>
<p>
+battery-remain: remaining battery time
+</p>
+</li>
+<li>
+<p>
cpufreq: CPU frequency
</p>
</li>
@@ -865,6 +870,11 @@ <h3 id="_external_plugins">External plugins</h3><div style="clear:left"></div>
</li>
<li>
<p>
+disk-util: disk utilization percentage
+</p>
+</li>
+<li>
+<p>
fan: Fan speed
</p>
</li>
@@ -875,12 +885,12 @@ <h3 id="_external_plugins">External plugins</h3><div style="clear:left"></div>
</li>
<li>
<p>
-gpfsop: GPFS operations counters
+gpfs: GPFS IO counters
</p>
</li>
<li>
<p>
-gpfs: GPFS IO counters
+gpfs-ops: GPFS operations counters
</p>
</li>
<li>
@@ -890,22 +900,22 @@ <h3 id="_external_plugins">External plugins</h3><div style="clear:left"></div>
</li>
<li>
<p>
-innodb_buffer: innodb buffer counters
+innodb-buffer: innodb buffer counters
</p>
</li>
<li>
<p>
-innodb_io: innodb I/O counters
+innodb-io: innodb I/O counters
</p>
</li>
<li>
<p>
-innodb_keys: innodb key operation counters
+innodb-keys: innodb key operation counters
</p>
</li>
<li>
<p>
-innodb_ops: innodb operations counters
+innodb-ops: innodb operations counters
</p>
</li>
<li>
@@ -915,42 +925,42 @@ <h3 id="_external_plugins">External plugins</h3><div style="clear:left"></div>
</li>
<li>
<p>
-memcache_hits: Memcache hit counters
+memcache-hits: Memcache hit counters
</p>
</li>
<li>
<p>
-mysql5_com: MySQL communication counters
+mysql5-cmds: MySQL communication counters
</p>
</li>
<li>
<p>
-mysql5_conn: MySQL connection counters
+mysql5-conn: MySQL connection counters
</p>
</li>
<li>
<p>
-mysql5_io: MySQL I/O counters
+mysql5-io: MySQL I/O counters
</p>
</li>
<li>
<p>
-mysql5_keys: MySQL keys counters
+mysql5-keys: MySQL keys counters
</p>
</li>
<li>
<p>
-mysql_io: MySQL I/O counters
+mysql-io: MySQL I/O counters
</p>
</li>
<li>
<p>
-mysql_ops: MySQL operations counters
+mysql-ops: MySQL operations counters
</p>
</li>
<li>
<p>
-nfs3op: NFS3 client operations counters
+nfs3-ops: NFS3 client operations counters
</p>
</li>
<li>
@@ -960,7 +970,7 @@ <h3 id="_external_plugins">External plugins</h3><div style="clear:left"></div>
</li>
<li>
<p>
-nfsd3op: NFS3 server operations counters
+nfsd3-ops: NFS3 server operations counters
</p>
</li>
<li>
@@ -1010,27 +1020,47 @@ <h3 id="_external_plugins">External plugins</h3><div style="clear:left"></div>
</li>
<li>
<p>
-topbio: most expensive block I/O process
+top-bio: most expensive block I/O process
+</p>
+</li>
+<li>
+<p>
+top-cpu: most expensive cpu process
+</p>
+</li>
+<li>
+<p>
+top-cputime: process using the most CPU time
+</p>
+</li>
+<li>
+<p>
+top-cputime-avg: process having the highest average CPU time
+</p>
+</li>
+<li>
+<p>
+top-io: most expensive I/O process
</p>
</li>
<li>
<p>
-topcpu: most expensive cpu process
+top-latency: process with the highest total latency
</p>
</li>
<li>
<p>
-topio: most expensive I/O process
+top-latency-avg: process with the highest average latency
</p>
</li>
<li>
<p>
-topmem: most expensive memory process
+top-mem: most expensive memory process
</p>
</li>
<li>
<p>
-topoom: process first shot by OOM killer
+top-oom: process first shot by OOM killer
</p>
</li>
<li>
@@ -1040,32 +1070,32 @@ <h3 id="_external_plugins">External plugins</h3><div style="clear:left"></div>
</li>
<li>
<p>
-vmkhba: VMware kernel HBA counters
+vmk-hba: VMware kernel HBA counters
</p>
</li>
<li>
<p>
-vmkint: VMware kernel interrupt counters
+vmk-int: VMware kernel interrupt counters
</p>
</li>
<li>
<p>
-vmknic: VMware kernel NIC counters
+vmk-nic: VMware kernel NIC counters
</p>
</li>
<li>
<p>
-vmmemctl: VMware guest memory counters
+vm-memctl: VMware guest memory counters
</p>
</li>
<li>
<p>
-vzcpu: OpenVZ CPU counters
+vz-cpu: OpenVZ CPU counters
</p>
</li>
<li>
<p>
-vzubc: OpenVZ user beancounters
+vz-ubc: OpenVZ user beancounters
</p>
</li>
<li>
@@ -1122,7 +1152,7 @@ <h3 id="_enabling_plugins">Enabling plugins</h3><div style="clear:left"></div>
<div class="paragraph"><p>The internal plugins have short and/or long options within Dstat, eg. <tt>-c</tt> or
<tt>--cpu</tt> will enable the cpu counters.</p></div>
<div class="paragraph"><p>The external plugins are enable by a long option including their name,
-eg. --topcpu</p></div>
+eg. <tt>--top-cpu</tt></p></div>
<div class="paragraph"><p>The following examples will enable the time, cpu and disk plugins, and are
equal.</p></div>
<div class="listingblock">
@@ -1236,14 +1266,14 @@ <h3 id="_simple_system_check">Simple system check</h3><div style="clear:left"></
</tr></table>
</div>
<h3 id="_what_is_this_system_doing_now">What is this system doing now ?</h3><div style="clear:left"></div>
-<div class="paragraph"><p>I often run both the <tt>dstat_topcpu</tt> and <tt>dstat_topmem</tt> programs on a system,
+<div class="paragraph"><p>I often run both the <tt>dstat_top_cpu</tt> and <tt>dstat_top_mem</tt> programs on a system,
just to see what a system is doing. Having a quick look at what application
is using the most CPU over a few minutes and to see what the general usage
of memory is of the top application gives away a lot about a system.</p></div>
<div class="listingblock">
<div class="title">Sample output</div>
<div class="content">
-<pre><tt>[dag@horsea dag]$ dstat -c --topcpu -dng --topmem
+<pre><tt>[dag@horsea dag]$ dstat -c --top-cpu -dng --top-mem
----total-cpu-usage---- -most-expensive- -dsk/total- -net/total- ---paging-- -most-expensive-
usr sys idl wai hiq siq| cpu process | read writ| recv send| in out | memory process
9 2 80 9 0 0|kswapd 0| 123k 164k| 0 0 |9196B 18k|rsync 74M
@@ -1261,17 +1291,17 @@ <h3 id="_what_process_is_using_all_my_cpu_memory_or_i_o_at_4_20_am">What process
causing it and why ? As of now you can do:</p></div>
<div class="listingblock">
<div class="content">
-<pre><tt>screen dstat -tcy --topcpu 120
-screen dstat -tmgs --topmem 120
-screen dstat -tdi --topio 120</tt></pre>
+<pre><tt>screen dstat -tcy --top-cpu 120
+screen dstat -tmgs --top-mem 120
+screen dstat -tdi --top-io 120</tt></pre>
</div></div>
<div class="paragraph"><p>to see what process is using the most CPU, the most memory and the most I/O
resources.</p></div>
<div class="paragraph"><p>And hopefully one day we can do:</p></div>
<div class="listingblock">
<div class="content">
-<pre><tt>dstat -tn --topnet 120
-dstat -tn --topx 120</tt></pre>
+<pre><tt>dstat -tn --top-net 120
+dstat -tn --top-x 120</tt></pre>
</div></div>
<div class="paragraph"><p>Leave it running during the night and in the morning you can see the light.</p></div>
<h3 id="_what_device_is_slowing_down_my_system">What device is slowing down my system ?</h3><div style="clear:left"></div>
@@ -1591,20 +1621,20 @@ <h4 id="_debugging_dstat">Debugging Dstat</h4>
</div></div>
<div class="paragraph"><p>As you can see, getting the CPU counters and calculating the CPU usage takes
up 0.5 milliseconds on this particular system. But if we look at the usage of
-the <tt>dstat_topcpu</tt> plugin:</p></div>
+the <tt>dstat_top_cpu</tt> plugin:</p></div>
<div class="listingblock">
-<div class="title">The cost of running the <tt>dstat_topcpu</tt> plugin</div>
+<div class="title">The cost of running the <tt>dstat_top_cpu</tt> plugin</div>
<div class="content">
-<pre><tt>[dag@rhun dstat]$ dstat --topcpu --debug
-Module dstat_topcpu
+<pre><tt>[dag@rhun dstat]$ dstat --top-cpu --debug
+Module dstat_top_cpu
-most-expensive-
cpu process
Xorg 2 43.82ms
Xorg 1 33.23ms
firefox-bin 2 33.54ms
Xorg 1 33.24ms</tt></pre>
</div></div>
-<div class="paragraph"><p>we see that processing the <em>/proc/pid</em> files causes the topcpu plugin to use
+<div class="paragraph"><p>we see that processing the <em>/proc/pid</em> files causes the top-cpu plugin to use
an additional 33ms.</p></div>
<div class="admonitionblock">
<table><tr>
@@ -1740,7 +1770,7 @@ <h2 id="_links">Links</h2>
<div id="footnotes"><hr /></div>
<div id="footer">
<div id="footer-text">
-Last updated 2009-11-23 01:38:45 CEST
+Last updated 2009-11-25 13:04:13 CEST
</div>
</div>
</body>
View
82 docs/dstat-paper.txt
@@ -214,28 +214,30 @@ This basic functionality is easily extended by writing your own plugins
into Dstat. A set of 'external' modules exist for:
- battery: battery usage
+ - battery-remain: remaining battery time
- cpufreq: CPU frequency
- dbus: DBUS connections
+ - disk-util: disk utilization percentage
- fan: Fan speed
- freespace: free space on filesystems
- - gpfsop: GPFS operations counters
- gpfs: GPFS IO counters
+ - gpfs-ops: GPFS operations counters
- helloworld: Hello world dispenser
- - innodb_buffer: innodb buffer counters
- - innodb_io: innodb I/O counters
- - innodb_keys: innodb key operation counters
- - innodb_ops: innodb operations counters
+ - innodb-buffer: innodb buffer counters
+ - innodb-io: innodb I/O counters
+ - innodb-keys: innodb key operation counters
+ - innodb-ops: innodb operations counters
- lustre: lustre throughput counters
- - memcache_hits: Memcache hit counters
- - mysql5_com: MySQL communication counters
- - mysql5_conn: MySQL connection counters
- - mysql5_io: MySQL I/O counters
- - mysql5_keys: MySQL keys counters
- - mysql_io: MySQL I/O counters
- - mysql_ops: MySQL operations counters
- - nfs3op: NFS3 client operations counters
+ - memcache-hits: Memcache hit counters
+ - mysql5-cmds: MySQL communication counters
+ - mysql5-conn: MySQL connection counters
+ - mysql5-io: MySQL I/O counters
+ - mysql5-keys: MySQL keys counters
+ - mysql-io: MySQL I/O counters
+ - mysql-ops: MySQL operations counters
+ - nfs3-ops: NFS3 client operations counters
- nfs3: NFS3 client counters
- - nfsd3op: NFS3 server operations counters
+ - nfsd3-ops: NFS3 server operations counters
- nfsd3: NFS3 server counters
- ntp: NTP time counters
- postfix: postfix queue counters
@@ -245,18 +247,22 @@ into Dstat. A set of 'external' modules exist for:
- sendmail: sendmail queue counters
- snooze: Dstat time delay counters
- thermal: Thermal counters
- - topbio: most expensive block I/O process
- - topcpu: most expensive cpu process
- - topio: most expensive I/O process
- - topmem: most expensive memory process
- - topoom: process first shot by OOM killer
+ - top-bio: most expensive block I/O process
+ - top-cpu: most expensive cpu process
+ - top-cputime: process using the most CPU time
+ - top-cputime-avg: process having the highest average CPU time
+ - top-io: most expensive I/O process
+ - top-latency: process with the highest total latency
+ - top-latency-avg: process with the highest average latency
+ - top-mem: most expensive memory process
+ - top-oom: process first shot by OOM killer
- utmp: utmp counters
- - vmkhba: VMware kernel HBA counters
- - vmkint: VMware kernel interrupt counters
- - vmknic: VMware kernel NIC counters
- - vmmemctl: VMware guest memory counters
- - vzcpu: OpenVZ CPU counters
- - vzubc: OpenVZ user beancounters
+ - vmk-hba: VMware kernel HBA counters
+ - vmk-int: VMware kernel interrupt counters
+ - vmk-nic: VMware kernel NIC counters
+ - vm-memctl: VMware guest memory counters
+ - vz-cpu: OpenVZ CPU counters
+ - vz-ubc: OpenVZ user beancounters
- wifi: WIFI quality information
@@ -287,7 +293,7 @@ The internal plugins have short and/or long options within Dstat, eg. +-c+ or
+--cpu+ will enable the cpu counters.
The external plugins are enable by a long option including their name,
-eg. --topcpu
+eg. +--top-cpu+
The following examples will enable the time, cpu and disk plugins, and are
equal.
@@ -379,14 +385,14 @@ nevertheless interesting.
=== What is this system doing now ?
-I often run both the +dstat_topcpu+ and +dstat_topmem+ programs on a system,
+I often run both the +dstat_top_cpu+ and +dstat_top_mem+ programs on a system,
just to see what a system is doing. Having a quick look at what application
is using the most CPU over a few minutes and to see what the general usage
of memory is of the top application gives away a lot about a system.
.Sample output
----
-[dag@horsea dag]$ dstat -c --topcpu -dng --topmem
+[dag@horsea dag]$ dstat -c --top-cpu -dng --top-mem
----total-cpu-usage---- -most-expensive- -dsk/total- -net/total- ---paging-- -most-expensive-
usr sys idl wai hiq siq| cpu process | read writ| recv send| in out | memory process
9 2 80 9 0 0|kswapd 0| 123k 164k| 0 0 |9196B 18k|rsync 74M
@@ -406,9 +412,9 @@ Something indicates the system is doing something unexpected but what is
causing it and why ? As of now you can do:
----
-screen dstat -tcy --topcpu 120
-screen dstat -tmgs --topmem 120
-screen dstat -tdi --topio 120
+screen dstat -tcy --top-cpu 120
+screen dstat -tmgs --top-mem 120
+screen dstat -tdi --top-io 120
----
to see what process is using the most CPU, the most memory and the most I/O
@@ -417,8 +423,8 @@ resources.
And hopefully one day we can do:
----
-dstat -tn --topnet 120
-dstat -tn --topx 120
+dstat -tn --top-net 120
+dstat -tn --top-x 120
----
Leave it running during the night and in the morning you can see the light.
@@ -731,12 +737,12 @@ usr sys idl wai hiq siq
As you can see, getting the CPU counters and calculating the CPU usage takes
up 0.5 milliseconds on this particular system. But if we look at the usage of
-the +dstat_topcpu+ plugin:
+the +dstat_top_cpu+ plugin:
-.The cost of running the +dstat_topcpu+ plugin
+.The cost of running the +dstat_top_cpu+ plugin
----
-[dag@rhun dstat]$ dstat --topcpu --debug
-Module dstat_topcpu
+[dag@rhun dstat]$ dstat --top-cpu --debug
+Module dstat_top_cpu
-most-expensive-
cpu process
Xorg 2 43.82ms
@@ -745,7 +751,7 @@ firefox-bin 2 33.54ms
Xorg 1 33.24ms
----
-we see that processing the _/proc/pid_ files causes the topcpu plugin to use
+we see that processing the _/proc/pid_ files causes the top-cpu plugin to use
an additional 33ms.
WARNING: These values show the time it takes to process the plugins and does
View
92 docs/dstat.1
@@ -195,130 +195,130 @@ GPFS filesystem operations (needs mmpmon)
Hello world example dstat plugin
.TP
\-\-innodb\-buffer
-TBD
+show innodb buffer stats
.TP
\-\-innodb\-io
-TBD
+show innodb I/O stats
.TP
\-\-innodb\-ops
-TBD
+show innodb operations counters
.TP
\-\-lustre
-TBD
+show lustre I/O throughput
.TP
\-\-memcache\-hits
-TBD
+show the number of hits and misses from memcache
.TP
-\-\-mysql5\-com
-TBD
+\-\-mysql5\-cmds
+show the MySQL5 command stats
.TP
\-\-mysql5\-conn
-TBD
+show the MySQL5 connection stats
.TP
\-\-mysql5\-io
-TBD
+show the MySQL5 I/O stats
.TP
\-\-mysql5\-keys
-TBD
+show the MySQL5 keys stats
.TP
\-\-mysql\-io
-TBD
+show the MySQL I/O stats
.TP
\-\-mysql\-keys
-TBD
+show the MySQL keys stats
.TP
\-\-net\-packets
-TBD
+show the number of packets received and transmitted
.TP
\-\-nfs3
-NFS v3 client operations
+show NFS v3 client operations
.TP
\-\-nfs3\-ops
-Extended NFS v3 client operations
+show extended NFS v3 client operations
.TP
\-\-nfsd3
-NFS v3 server operations
+show NFS v3 server operations
.TP
\-\-nfsd3\-ops
-Extended NFS v3 server operations
+show extended NFS v3 server operations
.TP
\-\-ntp
-TBD
+show NTP time from an NTP server
.TP
\-\-postfix
-postfix queue size (needs postfix)
+show postfix queue sizes (needs postfix)
.TP
\-\-power
-TBD
+show power usage
.TP
\-\-proc\-count
-TBD
+show total number of processes
.TP
\-\-rpc
-RPC client calls
+show RPC client calls stats
.TP
\-\-rpcd
-RPC server calls
+show RPC server calls stats
.TP
\-\-sendmail
-sendmail queue size (needs sendmail)
+show sendmail queue size (needs sendmail)
.TP
\-\-snooze
-number of ticks per second
+show number of ticks per second
.TP
\-\-test
-TBD
+show test plugin output
.TP
\-\-thermal
system temperature sensors
.TP
\-\-top\-bio
-TBD
+show most expensive block I/O process
.TP
\-\-top\-cpu
-TBD
+show most expensive CPU process
.TP
\-\-top\-cputime
-TBD
+show process using the most CPU time (in ms)
.TP
\-\-top\-cputime\-avg
-TBD
+show process with the highest average timeslice (in ms)
.TP
\-\-top\-io
-TBD
+show most expensive I/O process
.TP
\-\-top\-latency
-TBD
+show process with highest total latency (in ms)
.TP
\-\-top\-latency\-avg
-TBD
+show process with the highest average latency (in ms)
.TP
\-\-top\-mem
-TBD
+show process using the most memory
.TP
\-\-top\-oom
-TBD
+show process that will be killed by OOM the first
.TP
\-\-utmp
-Number of utmp connections (needs python\-utmp)
+show number of utmp connections (needs python\-utmp)
.TP
\-\-vmk\-hba
-TBD
+show VMware ESX kernel vmhba stats
.TP
\-\-vmk\-int
-TBD
+show VMware ESX kernel interrupt stats
.TP
\-\-vmk\-nic
-TBD
+show VMware ESX kernel port stats
.TP
\-\-vm\-memctl
-TBD
+show ballooning status inside VMware guests
.TP
\-\-vz\-io
-TBD
+show CPU usage per OpenVZ guest
.TP
\-\-vz\-ubc
-TBD
+show OpenVZ user beancounters
.TP
\-\-wifi
wireless link quality and signal to noise ratio
@@ -347,17 +347,17 @@ Checking dstat\(cqs behaviour and the system impact of dstat:
.nf
dstat \-taf \-\-debug
.fi
-Using the time plugin together with cpu, net, disk, system, load, proc and topcpu plugins:
+Using the time plugin together with cpu, net, disk, system, load, proc and top_cpu plugins:
.sp
.sp
.nf
-dstat \-tcndylp \-\-topcpu
+dstat \-tcndylp \-\-top\-cpu
.fi
this is identical to
.sp
.sp
.nf
-dstat \-\-time \-\-cpu \-\-net \-\-disk \-\-sys \-\-load \-\-proc \-\-topcpu
+dstat \-\-time \-\-cpu \-\-net \-\-disk \-\-sys \-\-load \-\-proc \-\-top\-cpu
.fi
Using dstat to relate cpu stats with interrupts per device:
.sp
@@ -382,8 +382,6 @@ Paths that may contain external dstat_*.py plugins:
.sp
.nf
~/.dstat/
-./
-./plugins/
(path of binary)/plugins/
/usr/share/dstat/
/usr/local/share/dstat/
View
95 docs/dstat.1.html
@@ -1032,199 +1032,199 @@ <h2 id="_plugins">PLUGINS</h2>
</dt>
<dd>
<p>
- TBD
+ show innodb buffer stats
</p>
</dd>
<dt class="hdlist1">
--innodb-io
</dt>
<dd>
<p>
- TBD
+ show innodb I/O stats
</p>
</dd>
<dt class="hdlist1">
--innodb-ops
</dt>
<dd>
<p>
- TBD
+ show innodb operations counters
</p>
</dd>
<dt class="hdlist1">
--lustre
</dt>
<dd>
<p>
- TBD
+ show lustre I/O throughput
</p>
</dd>
<dt class="hdlist1">
--memcache-hits
</dt>
<dd>
<p>
- TBD
+ show the number of hits and misses from memcache
</p>
</dd>
<dt class="hdlist1">
---mysql5-com
+--mysql5-cmds
</dt>
<dd>
<p>
- TBD
+ show the MySQL5 command stats
</p>
</dd>
<dt class="hdlist1">
--mysql5-conn
</dt>
<dd>
<p>
- TBD
+ show the MySQL5 connection stats
</p>
</dd>
<dt class="hdlist1">
--mysql5-io
</dt>
<dd>
<p>
- TBD
+ show the MySQL5 I/O stats
</p>
</dd>
<dt class="hdlist1">
--mysql5-keys
</dt>
<dd>
<p>
- TBD
+ show the MySQL5 keys stats
</p>
</dd>
<dt class="hdlist1">
--mysql-io
</dt>
<dd>
<p>
- TBD
+ show the MySQL I/O stats
</p>
</dd>
<dt class="hdlist1">
--mysql-keys
</dt>
<dd>
<p>
- TBD
+ show the MySQL keys stats
</p>
</dd>
<dt class="hdlist1">
--net-packets
</dt>
<dd>
<p>
- TBD
+ show the number of packets received and transmitted
</p>
</dd>
<dt class="hdlist1">
--nfs3
</dt>
<dd>
<p>
- NFS v3 client operations
+ show NFS v3 client operations
</p>
</dd>
<dt class="hdlist1">
--nfs3-ops
</dt>
<dd>
<p>
- Extended NFS v3 client operations
+ show extended NFS v3 client operations
</p>
</dd>
<dt class="hdlist1">
--nfsd3
</dt>
<dd>
<p>
- NFS v3 server operations
+ show NFS v3 server operations
</p>
</dd>
<dt class="hdlist1">
--nfsd3-ops
</dt>
<dd>
<p>
- Extended NFS v3 server operations
+ show extended NFS v3 server operations
</p>
</dd>
<dt class="hdlist1">
--ntp
</dt>
<dd>
<p>
- TBD
+ show NTP time from an NTP server
</p>
</dd>
<dt class="hdlist1">
--postfix
</dt>
<dd>
<p>
- postfix queue size (needs postfix)
+ show postfix queue sizes (needs postfix)
</p>
</dd>
<dt class="hdlist1">
--power
</dt>
<dd>
<p>
- TBD
+ show power usage
</p>
</dd>
<dt class="hdlist1">
--proc-count
</dt>
<dd>
<p>
- TBD
+ show total number of processes
</p>
</dd>
<dt class="hdlist1">
--rpc
</dt>
<dd>
<p>
- RPC client calls
+ show RPC client calls stats
</p>
</dd>
<dt class="hdlist1">
--rpcd
</dt>
<dd>
<p>
- RPC server calls
+ show RPC server calls stats
</p>
</dd>
<dt class="hdlist1">
--sendmail
</dt>
<dd>
<p>
- sendmail queue size (needs sendmail)
+ show sendmail queue size (needs sendmail)
</p>
</dd>
<dt class="hdlist1">
--snooze
</dt>
<dd>
<p>
- number of ticks per second
+ show number of ticks per second
</p>
</dd>
<dt class="hdlist1">
--test
</dt>
<dd>
<p>
- TBD
+ show test plugin output
</p>
</dd>
<dt class="hdlist1">
@@ -1240,127 +1240,127 @@ <h2 id="_plugins">PLUGINS</h2>
</dt>
<dd>
<p>
- TBD
+ show most expensive block I/O process
</p>
</dd>
<dt class="hdlist1">
--top-cpu
</dt>
<dd>
<p>
- TBD
+ show most expensive CPU process
</p>
</dd>
<dt class="hdlist1">
--top-cputime
</dt>
<dd>
<p>
- TBD
+ show process using the most CPU time (in ms)
</p>
</dd>
<dt class="hdlist1">
--top-cputime-avg
</dt>
<dd>
<p>
- TBD
+ show process with the highest average timeslice (in ms)
</p>
</dd>
<dt class="hdlist1">
--top-io
</dt>
<dd>
<p>
- TBD
+ show most expensive I/O process
</p>
</dd>
<dt class="hdlist1">
--top-latency
</dt>
<dd>
<p>
- TBD
+ show process with highest total latency (in ms)
</p>
</dd>
<dt class="hdlist1">
--top-latency-avg
</dt>
<dd>
<p>
- TBD
+ show process with the highest average latency (in ms)
</p>
</dd>
<dt class="hdlist1">
--top-mem
</dt>
<dd>
<p>
- TBD
+ show process using the most memory
</p>
</dd>
<dt class="hdlist1">
--top-oom
</dt>
<dd>
<p>
- TBD
+ show process that will be killed by OOM the first
</p>
</dd>
<dt class="hdlist1">
--utmp
</dt>
<dd>
<p>
- Number of utmp connections (needs python-utmp)
+ show number of utmp connections (needs python-utmp)
</p>
</dd>
<dt class="hdlist1">
--vmk-hba
</dt>
<dd>
<p>
- TBD
+ show VMware ESX kernel vmhba stats
</p>
</dd>
<dt class="hdlist1">
--vmk-int
</dt>
<dd>
<p>
- TBD
+ show VMware ESX kernel interrupt stats
</p>
</dd>
<dt class="hdlist1">
--vmk-nic
</dt>
<dd>
<p>
- TBD
+ show VMware ESX kernel port stats
</p>
</dd>
<dt class="hdlist1">
--vm-memctl
</dt>
<dd>
<p>
- TBD
+ show ballooning status inside VMware guests
</p>
</dd>
<dt class="hdlist1">
--vz-io
</dt>
<dd>
<p>
- TBD
+ show CPU usage per OpenVZ guest
</p>
</dd>
<dt class="hdlist1">
--vz-ubc
</dt>
<dd>
<p>
- TBD
+ show OpenVZ user beancounters
</p>
</dd>
<dt class="hdlist1">
@@ -1402,15 +1402,16 @@ <h2 id="_examples">EXAMPLES</h2>
<div class="content">
<pre><tt>dstat -taf --debug</tt></pre>
</div></div>
-<div class="paragraph"><p>Using the time plugin together with cpu, net, disk, system, load, proc and topcpu plugins:</p></div>
+<div class="paragraph"><p>Using the time plugin together with cpu, net, disk, system, load, proc and
+top_cpu plugins:</p></div>
<div class="listingblock">
<div class="content">
-<pre><tt>dstat -tcndylp --topcpu</tt></pre>
+<pre><tt>dstat -tcndylp --top-cpu</tt></pre>
</div></div>
<div class="paragraph"><p>this is identical to</p></div>
<div class="listingblock">
<div class="content">
-<pre><tt>dstat --time --cpu --net --disk --sys --load --proc --topcpu</tt></pre>
+<pre><tt>dstat --time --cpu --net --disk --sys --load --proc --top-cpu</tt></pre>
</div></div>
<div class="paragraph"><p>Using dstat to relate cpu stats with interrupts per device:</p></div>
<div class="listingblock">
@@ -1440,8 +1441,6 @@ <h2 id="_files">FILES</h2>
<div class="literalblock">
<div class="content">
<pre><tt>~/.dstat/
-./
-./plugins/
(path of binary)/plugins/
/usr/share/dstat/
/usr/local/share/dstat/</tt></pre>
@@ -1512,7 +1511,7 @@ <h2 id="_author">AUTHOR</h2>
<div id="footer">
<div id="footer-text">
Version 0.7.0<br />
-Last updated 2009-11-24 02:39:47 CEST
+Last updated 2009-11-25 12:59:57 CEST
</div>
</div>
</body>
View
101 docs/dstat.1.txt
@@ -124,7 +124,7 @@ information.
--vm::
enable vm stats (hard pagefaults, soft pagefaults, allocated, free)
---stat1 --stat2::
+--plugin-name::
enable (external) plugins by plugin name, see *PLUGINS* for options
Possible internal stats are::
@@ -144,15 +144,15 @@ Possible internal stats are::
-v, --vmstat::
equals -pmgdsc -D total
---bw, --blackonwhite::
- change colors for white background terminal
-
--float::
force float values on screen (mutual exclusive with *--integer*)
--integer::
force integer values on screen (mutual exclusive with *--float*)
+--bw, --blackonwhite::
+ change colors for white background terminal
+
--nocolor::
disable colors (implies *--noupdate*)
@@ -202,130 +202,130 @@ Here is an overview of the plugins dstat ships with:
Hello world example dstat plugin
--innodb-buffer::
- TBD
+ show innodb buffer stats
--innodb-io::
- TBD
+ show innodb I/O stats
--innodb-ops::
- TBD
+ show innodb operations counters
--lustre::
- TBD
+ show lustre I/O throughput
--memcache-hits::
- TBD
+ show the number of hits and misses from memcache
---mysql5-com::
- TBD
+--mysql5-cmds::
+ show the MySQL5 command stats
--mysql5-conn::
- TBD
+ show the MySQL5 connection stats
--mysql5-io::
- TBD
+ show the MySQL5 I/O stats
--mysql5-keys::
- TBD
+ show the MySQL5 keys stats
--mysql-io::
- TBD
+ show the MySQL I/O stats
--mysql-keys::
- TBD
+ show the MySQL keys stats
--net-packets::
- TBD
+ show the number of packets received and transmitted
--nfs3::
- NFS v3 client operations
+ show NFS v3 client operations
--nfs3-ops::
- Extended NFS v3 client operations
+ show extended NFS v3 client operations
--nfsd3::
- NFS v3 server operations
+ show NFS v3 server operations
--nfsd3-ops::
- Extended NFS v3 server operations
+ show extended NFS v3 server operations
--ntp::
- TBD
+ show NTP time from an NTP server
--postfix::
- postfix queue size (needs postfix)
+ show postfix queue sizes (needs postfix)
--power::
- TBD
+ show power usage
--proc-count::
- TBD
+ show total number of processes
--rpc::
- RPC client calls
+ show RPC client calls stats
--rpcd::
- RPC server calls
+ show RPC server calls stats
--sendmail::
- sendmail queue size (needs sendmail)
+ show sendmail queue size (needs sendmail)
--snooze::
- number of ticks per second
+ show number of ticks per second
--test::
- TBD
+ show test plugin output
--thermal::
system temperature sensors
--top-bio::
- TBD
+ show most expensive block I/O process
--top-cpu::
- TBD
+ show most expensive CPU process
--top-cputime::
- TBD
+ show process using the most CPU time (in ms)
--top-cputime-avg::
- TBD
+ show process with the highest average timeslice (in ms)
--top-io::
- TBD
+ show most expensive I/O process
--top-latency::
- TBD
+ show process with highest total latency (in ms)
--top-latency-avg::
- TBD
+ show process with the highest average latency (in ms)
--top-mem::
- TBD
+ show process using the most memory
--top-oom::
- TBD
+ show process that will be killed by OOM the first
--utmp::
- Number of utmp connections (needs python-utmp)
+ show number of utmp connections (needs python-utmp)
--vmk-hba::
- TBD
+ show VMware ESX kernel vmhba stats
--vmk-int::
- TBD
+ show VMware ESX kernel interrupt stats
--vmk-nic::
- TBD
+ show VMware ESX kernel port stats
--vm-memctl::
- TBD
+ show ballooning status inside VMware guests
--vz-io::
- TBD
+ show CPU usage per OpenVZ guest
--vz-ubc::
- TBD
+ show OpenVZ user beancounters
--wifi::
wireless link quality and signal to noise ratio
@@ -362,13 +362,14 @@ Checking dstat's behaviour and the system impact of dstat:
dstat -taf --debug
----
-Using the time plugin together with cpu, net, disk, system, load, proc and topcpu plugins:
+Using the time plugin together with cpu, net, disk, system, load, proc and
+top_cpu plugins:
----
-dstat -tcndylp --topcpu
+dstat -tcndylp --top-cpu
----
this is identical to
----
-dstat --time --cpu --net --disk --sys --load --proc --topcpu
+dstat --time --cpu --net --disk --sys --load --proc --top-cpu
----
Using dstat to relate cpu stats with interrupts per device:
@@ -392,8 +393,6 @@ Please see the TODO file for known bugs and future plans.
Paths that may contain external dstat_*.py plugins:
~/.dstat/
- ./
- ./plugins/
(path of binary)/plugins/
/usr/share/dstat/
/usr/local/share/dstat/
View
607 docs/performance.html
@@ -0,0 +1,607 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
+ "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
+<meta name="generator" content="AsciiDoc 8.5.1" />
+<title>Dstat performance</title>
+<style type="text/css">
+/* Debug borders */
+p, li, dt, dd, div, pre, h1, h2, h3, h4, h5, h6 {
+/*
+ border: 1px solid red;
+*/
+}
+
+body {
+ margin: 1em 5% 1em 5%;
+}
+
+a {
+ color: blue;
+ text-decoration: underline;
+}
+a:visited {
+ color: fuchsia;
+}
+
+em {
+ font-style: italic;
+ color: navy;
+}
+
+strong {
+ font-weight: bold;
+ color: #083194;
+}
+
+tt {
+ color: navy;
+}
+
+h1, h2, h3, h4, h5, h6 {
+ color: #527bbd;
+ font-family: sans-serif;
+ margin-top: 1.2em;
+ margin-bottom: 0.5em;
+ line-height: 1.3;
+}
+
+h1, h2, h3 {
+ border-bottom: 2px solid silver;
+}
+h2 {
+ padding-top: 0.5em;
+}
+h3 {
+ float: left;
+}
+h3 + * {
+ clear: left;
+}
+
+div.sectionbody {
+ font-family: serif;
+ margin-left: 0;
+}
+
+hr {
+ border: 1px solid silver;
+}
+
+p {
+ margin-top: 0.5em;
+ margin-bottom: 0.5em;
+}
+
+ul, ol, li > p {
+ margin-top: 0;
+}
+
+pre {
+ padding: 0;
+ margin: 0;
+}
+
+span#author {
+ color: #527bbd;
+ font-family: sans-serif;
+ font-weight: bold;
+ font-size: 1.1em;
+}
+span#email {
+}
+span#revnumber, span#revdate, span#revremark {
+ font-family: sans-serif;
+}
+
+div#footer {
+ font-family: sans-serif;
+ font-size: small;
+ border-top: 2px solid silver;
+ padding-top: 0.5em;
+ margin-top: 4.0em;
+}
+div#footer-text {
+ float: left;
+ padding-bottom: 0.5em;
+}
+div#footer-badges {
+ float: right;
+ padding-bottom: 0.5em;
+}
+
+div#preamble {
+ margin-top: 1.5em;
+ margin-bottom: 1.5em;
+}
+div.tableblock, div.imageblock, div.exampleblock, div.verseblock,
+div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock,
+div.admonitionblock {
+ margin-top: 0.25em;
+ margin-bottom: 1.5em;
+}
+div.admonitionblock {
+ margin-top: 2.5em;
+ margin-bottom: 2.5em;
+}
+
+div.content { /* Block element content. */
+ padding: 0;
+}
+
+/* Block element titles. */
+div.title, caption.title {
+ color: #527bbd;
+ font-family: sans-serif;
+ font-weight: bold;
+ text-align: left;
+ margin-top: 1.0em;
+ margin-bottom: 0.5em;
+}
+div.title + * {
+ margin-top: 0;
+}
+
+td div.title:first-child {
+ margin-top: 0.0em;
+}
+div.content div.title:first-child {
+ margin-top: 0.0em;
+}
+div.content + div.title {
+ margin-top: 0.0em;
+}
+
+div.sidebarblock > div.content {
+ background: #ffffee;
+ border: 1px solid silver;
+ padding: 0.5em;
+}
+
+div.listingblock > div.content {
+ border: 1px solid silver;
+ background: #f4f4f4;
+ padding: 0.5em;
+}
+
+div.quoteblock {
+ padding-left: 2.0em;
+ margin-right: 10%;
+}
+div.quoteblock > div.attribution {
+ padding-top: 0.5em;
+ text-align: right;
+}
+
+div.verseblock {
+ padding-left: 2.0em;
+ margin-right: 10%;
+}
+div.verseblock > div.content {
+ white-space: pre;
+}
+div.verseblock > div.attribution {
+ padding-top: 0.75em;
+ text-align: left;
+}
+/* DEPRECATED: Pre version 8.2.7 verse style literal block. */
+div.verseblock + div.attribution {
+ text-align: left;
+}
+
+div.admonitionblock .icon {
+ vertical-align: top;
+ font-size: 1.1em;
+ font-weight: bold;
+ text-decoration: underline;
+ color: #527bbd;
+ padding-right: 0.5em;
+}
+div.admonitionblock td.content {
+ padding-left: 0.5em;
+ border-left: 2px solid silver;
+}
+
+div.exampleblock > div.content {
+ border-left: 2px solid silver;
+ padding: 0.5em;
+}
+
+div.imageblock div.content { padding-left: 0; }
+span.image img { border-style: none; }
+a.image:visited { color: white; }
+
+dl {
+ margin-top: 0.8em;
+ margin-bottom: 0.8em;
+}
+dt {
+ margin-top: 0.5em;
+ margin-bottom: 0;
+ font-style: normal;
+ color: navy;
+}
+dd > *:first-child {
+ margin-top: 0.1em;
+}
+
+ul, ol {
+ list-style-position: outside;
+}
+ol.arabic {
+ list-style-type: decimal;
+}
+ol.loweralpha {
+ list-style-type: lower-alpha;
+}
+ol.upperalpha {
+ list-style-type: upper-alpha;
+}
+ol.lowerroman {
+ list-style-type: lower-roman;
+}
+ol.upperroman {
+ list-style-type: upper-roman;
+}
+
+div.compact ul, div.compact ol,
+div.compact p, div.compact p,
+div.compact div, div.compact div {
+ margin-top: 0.1em;
+ margin-bottom: 0.1em;
+}
+
+div.tableblock > table {
+ border: 3px solid #527bbd;
+}
+thead {
+ font-family: sans-serif;
+ font-weight: bold;
+}
+tfoot {
+ font-weight: bold;
+}
+td > div.verse {
+ white-space: pre;
+}
+p.table {
+ margin-top: 0;
+}
+/* Because the table frame attribute is overriden by CSS in most browsers. */
+div.tableblock > table[frame="void"] {
+ border-style: none;
+}
+div.tableblock > table[frame="hsides"] {
+ border-left-style: none;
+ border-right-style: none;
+}
+div.tableblock > table[frame="vsides"] {
+ border-top-style: none;
+ border-bottom-style: none;
+}
+
+
+div.hdlist {
+ margin-top: 0.8em;
+ margin-bottom: 0.8em;
+}
+div.hdlist tr {
+ padding-bottom: 15px;
+}
+dt.hdlist1.strong, td.hdlist1.strong {
+ font-weight: bold;
+}
+td.hdlist1 {
+ vertical-align: top;
+ font-style: normal;
+ padding-right: 0.8em;
+ color: navy;
+}
+td.hdlist2 {
+ vertical-align: top;
+}
+div.hdlist.compact tr {
+ margin: 0;
+ padding-bottom: 0;
+}
+
+.comment {
+ background: yellow;
+}
+
+.footnote, .footnoteref {
+ font-size: 0.8em;
+}
+
+span.footnote, span.footnoteref {
+ vertical-align: super;
+}
+
+#footnotes {
+ margin: 20px 0 20px 0;
+ padding: 7px 0 0 0;
+}
+
+#footnotes div.footnote {
+ margin: 0 0 5px 0;
+}
+
+#footnotes hr {
+ border: none;
+ border-top: 1px solid silver;
+ height: 1px;
+ text-align: left;
+ margin-left: 0;
+ width: 20%;
+ min-width: 100px;
+}
+
+
+@media print {
+ div#footer-badges { display: none; }
+}
+
+div#toctitle {
+ color: #527bbd;
+ font-family: sans-serif;
+ font-size: 1.1em;
+ font-weight: bold;
+ margin-top: 1.0em;
+ margin-bottom: 0.1em;
+}
+
+div.toclevel1, div.toclevel2, div.toclevel3, div.toclevel4 {
+ margin-top: 0;
+ margin-bottom: 0;
+}
+div.toclevel2 {
+ margin-left: 2em;
+ font-size: 0.9em;
+}
+div.toclevel3 {
+ margin-left: 4em;
+ font-size: 0.9em;
+}
+div.toclevel4 {
+ margin-left: 6em;
+ font-size: 0.9em;
+}
+/* Workarounds for IE6's broken and incomplete CSS2. */
+
+div.sidebar-content {
+ background: #ffffee;
+ border: 1px solid silver;
+ padding: 0.5em;
+}
+div.sidebar-title, div.image-title {
+ color: #527bbd;
+ font-family: sans-serif;
+ font-weight: bold;
+ margin-top: 0.0em;
+ margin-bottom: 0.5em;
+}
+
+div.listingblock div.content {
+ border: 1px solid silver;
+ background: #f4f4f4;
+ padding: 0.5em;
+}
+
+div.quoteblock-attribution {
+ padding-top: 0.5em;
+ text-align: right;
+}
+
+div.verseblock-content {
+ white-space: pre;
+}
+div.verseblock-attribution {
+ padding-top: 0.75em;
+ text-align: left;
+}
+
+div.exampleblock-content {
+ border-left: 2px solid silver;
+ padding-left: 0.5em;
+}
+
+/* IE6 sets dynamically generated links as visited. */
+div#toc a:visited { color: blue; }
+</style>
+<script type="text/javascript">
+/*<![CDATA[*/
+window.onload = function(){asciidoc.footnotes();}
+var asciidoc = { // Namespace.
+
+/////////////////////////////////////////////////////////////////////
+// Table Of Contents generator
+/////////////////////////////////////////////////////////////////////
+
+/* Author: Mihai Bazon, September 2002
+ * http://students.infoiasi.ro/~mishoo
+ *
+ * Table Of Content generator
+ * Version: 0.4
+ *
+ * Feel free to use this script under the terms of the GNU General Public
+ * License, as long as you do not remove or alter this notice.
+ */
+
+ /* modified by Troy D. Hanson, September 2006. License: GPL */
+ /* modified by Stuart Rackham, 2006, 2009. License: GPL */
+
+// toclevels = 1..4.
+toc: function (toclevels) {
+
+ function getText(el) {
+ var text = "";
+ for (var i = el.firstChild; i != null; i = i.nextSibling) {
+ if (i.nodeType == 3 /* Node.TEXT_NODE */) // IE doesn't speak constants.
+ text += i.data;
+ else if (i.firstChild != null)
+ text += getText(i);
+ }
+ return text;
+ }
+
+ function TocEntry(el, text, toclevel) {
+ this.element = el;
+ this.text = text;
+ this.toclevel = toclevel;
+ }
+
+ function tocEntries(el, toclevels) {
+ var result = new Array;
+ var re = new RegExp('[hH]([2-'+(toclevels+1)+'])');
+ // Function that scans the DOM tree for header elements (the DOM2
+ // nodeIterator API would be a better technique but not supported by all
+ // browsers).
+ var iterate = function (el) {
+ for (var i = el.firstChild; i != null; i = i.nextSibling) {
+ if (i.nodeType == 1 /* Node.ELEMENT_NODE */) {
+ var mo = re.exec(i.tagName);
+ if (mo)
+ result[result.length] = new TocEntry(i, getText(i), mo[1]-1);
+ iterate(i);
+ }
+ }
+ }
+ iterate(el);
+ return result;
+ }
+
+ var toc = document.getElementById("toc");
+ var entries = tocEntries(document.getElementById("content"), toclevels);
+ for (var i = 0; i < entries.length; ++i) {
+ var entry = entries[i];
+ if (entry.element.id == "")
+ entry.element.id = "_toc_" + i;
+ var a = document.createElement("a");
+ a.href = "#" + entry.element.id;
+ a.appendChild(document.createTextNode(entry.text));
+ var div = document.createElement("div");
+ div.appendChild(a);
+ div.className = "toclevel" + entry.toclevel;
+ toc.appendChild(div);
+ }
+ if (entries.length == 0)
+ toc.parentNode.removeChild(toc);
+},
+
+
+/////////////////////////////////////////////////////////////////////
+// Footnotes generator
+/////////////////////////////////////////////////////////////////////
+
+/* Based on footnote generation code from:
+ * http://www.brandspankingnew.net/archive/2005/07/format_footnote.html
+ */
+
+footnotes: function () {
+ var cont = document.getElementById("content");
+ var noteholder = document.getElementById("footnotes");
+ var spans = cont.getElementsByTagName("span");
+ var refs = {};
+ var n = 0;
+ for (i=0; i<spans.length; i++) {
+ if (spans[i].className == "footnote") {
+ n++;
+ // Use [\s\S] in place of . so multi-line matches work.
+ // Because JavaScript has no s (dotall) regex flag.
+ note = spans[i].innerHTML.match(/\s*\[([\s\S]*)]\s*/)[1];
+ noteholder.innerHTML +=
+ "<div class='footnote' id='_footnote_" + n + "'>" +
+ "<a href='#_footnoteref_" + n + "' title='Return to text'>" +
+ n + "</a>. " + note + "</div>";
+ spans[i].innerHTML =
+ "[<a id='_footnoteref_" + n + "' href='#_footnote_" + n +
+ "' title='View footnote' class='footnote'>" + n + "</a>]";
+ var id =spans[i].getAttribute("id");
+ if (id != null) refs["#"+id] = n;
+ }
+ }
+ if (n == 0)
+ noteholder.parentNode.removeChild(noteholder);
+ else {
+ // Process footnoterefs.
+ for (i=0; i<spans.length; i++) {
+ if (spans[i].className == "footnoteref") {
+ var href = spans[i].getElementsByTagName("a")[0].getAttribute("href");
+ href = href.match(/#.*/)[0]; // Because IE return full URL.
+ n = refs[href];
+ spans[i].innerHTML =
+ "[<a href='#_footnote_" + n +
+ "' title='View footnote' class='footnote'>" + n + "</a>]";
+ }
+ }
+ }
+}
+
+}
+/*]]>*/
+</script>
+</head>
+<body>
+<div id="header">
+<h1>Dstat performance</h1>
+</div>
+<div id="content">
+<h2 id="_introduction">Introduction</h2>
+<div class="sectionbody">
+<div class="paragraph"><p>Since dstat is written in python, it is not optimized for performance.</p></div>
+<div class="paragraph"><p>When doing performance analysis, it is always important to verify that
+the monitoring tool is not messing with the performance numbers.
+(eg. writing to disk, using cpu/memory/network, increasing load)</p></div>
+<div class="paragraph"><p>Depending on the stats being used and the load on the server itself
+the impact Dstat has on the system you are monitoring might be
+considerable. A lot of plugins are pretty fast (less than 0.1ms on
+an modest 1.2Ghz laptop, but some plugins may use up to 3ms using
+up to 2% of your CPU).</p></div>
+<div class="paragraph"><p>Before performing any tests please verify for yourself what impact
+Dstat has on your test results and keep that in mind when analysing
+the results afterwards.</p></div>
+<div class="paragraph"><p>In case the impact is higher than expected, reduce the number of stats
+and remove expensive stats or even look at the plugin you&#8217;re using and
+send me optimisations.</p></div>
+<div class="paragraph"><p>Newer python versions are also faster than older ones, and hardware is
+only becoming faster at a pace that these considerations may not hold
+anylonger.</p></div>
+<div class="paragraph"><p>If you need feedback about plugin performance, use the --debug option
+to profile different plugins. If you use -t together with --debug, you
+can see the time deviation on your system in relation to load/plugins.</p></div>
+<div class="paragraph"><p>Remember that invisible plugins (that run out of your terminal window)
+do take up cycles because the information is still being collected and
+possibly written to CSV output.</p></div>
+<div class="paragraph"><p>It should be possible to write plugins in C to improve the impact on
+the system, but I have no experience with writing python modules in C.
+Any feedback on this is welcomed.</p></div>
+</div>
+<h2 id="_performance_tuning">Performance tuning</h2>
+<div class="sectionbody">
+<div class="paragraph"><p>The following documents may be useful to tune a system for performance</p></div>
+<div class="ulist"><ul>
+<li>
+<p>
+<a href="http://people.redhat.com/alikins/system_tuning.html">http://people.redhat.com/alikins/system_tuning.html</a>
+</p>
+</li>
+</ul></div>
+<div class="admonitionblock">
+<table><tr>
+<td class="icon">
+<div class="title">Note</div>
+</td>
+<td class="content">Please send me improvements to this document.</td>
+</tr></table>
+</div>
+</div>
+</div>
+<div id="footnotes"><hr /></div>
+<div id="footer">
+<div id="footer-text">
+Last updated 2009-11-24 02:49:07 CEST
+</div>
+</div>
+</body>
+</html>
View
7 dstat
@@ -16,7 +16,7 @@
from __future__ import generators
-VERSION = '0.7.0'
+VERSION = '0.7.0svn'
theme = { 'default': '' }
@@ -299,9 +299,10 @@ Dstat options:
-f, --full automatically expand -C, -D, -I, -N and -S lists
-v, --vmstat equals -pmgdsc -D total
- --bw, --blackonwhite change colors for white background terminal
--float force float values on screen
--integer force integer values on screen
+
+ --bw, --blackonwhite change colors for white background terminal
--nocolor disable colors (implies --noupdate)
--noheaders disable repetitive headers
--noupdate disable intermediate updates
@@ -2211,7 +2212,7 @@ def main():
### TODO: Would using .pyc help with anything ?
### Try loading python plugin
- if description[0] in ('.py'):
+ if description[0] in ('.py', ):
execfile(pathname)
exec 'o = dstat_plugin(); o.filename = "%s"; o.check(); o.prepare(); del(dstat_plugin);' % pluginfile
View
7 dstat.spec
@@ -4,7 +4,7 @@
Summary: Versatile resource statistics tool
Name: dstat
-Version: 0.7.0
+Version: 0.7.0svn
Release: 1
License: GPL
Group: System Environment/Base
@@ -52,9 +52,12 @@ confusion, less mistakes.
%{_datadir}/dstat/
%changelog
+* Thu Nov 26 2009 Dag Wieers <dag@wieers.com> - 0.7.0svn-1
+- Updated to release 0.7.0svn.
+
* Wed Nov 25 2009 Dag Wieers <dag@wieers.com> - 0.7.0-1
- Updated to release 0.7.0.
-- Reduce the number of paths used for importing modules (CVE-2009-3894)
+- Reduce the number of paths used for importing modules. {CVE-2009-3894}
* Tue Dec 02 2008 Dag Wieers <dag@wieers.com> - 0.6.9-1
- Updated to release 0.6.9.
View
1 plugins/dstat_battery.py
@@ -6,7 +6,6 @@ class dstat_plugin(dstat):
"""
def __init__(self):
- self.file = file
self.name = 'battery'
self.type = 'p'
self.width = 4
View
4 plugins/dstat_dbus.py
@@ -7,11 +7,11 @@ class dstat_plugin(dstat):
def __init__(self):
self.name = 'dbus'
+ self.nick = ('sys', 'ses')
+ self.vars = ('system', 'session')
self.type = 'd'
self.width = 3
self.scale = 100
- self.nick = ('sys', 'ses')
- self.vars = ('system', 'session')
def check(self):
# dstat.info(1, 'The dbus module is an EXPERIMENTAL module.')
View
2 plugins/dstat_disk_util.py
@@ -10,12 +10,12 @@ class dstat_plugin(dstat):
"""
def __init__(self):
+ self.nick = ('util', )
self.type = 'f'
self.width = 4
self.scale = 34
self.diskfilter = re.compile('^(dm-[0-9]+|md[0-9]+|[hs]d[a-z]+[0-9]+)$')
self.open('/proc/diskstats')
- self.nick = ('util', )
self.cols = 1
def discover(self, *objlist):
View
2 plugins/dstat_freespace.py
@@ -9,8 +9,8 @@ class dstat_plugin(dstat):
"""
def __init__(self):
- self.open('/etc/mtab')
self.nick = ('used', 'free')
+ self.open('/etc/mtab')
self.cols = 2
def vars(self):
View
2 plugins/dstat_gpfs.py
@@ -7,8 +7,8 @@ class dstat_plugin(dstat):
def __init__(self):
self.name = 'gpfs i/o'
- self.vars = ('_br_', '_bw_')
self.nick = ('read', 'write')
+ self.vars = ('_br_', '_bw_')
def check(self):
if os.access('/usr/lpp/mmfs/bin/mmpmon', os.X_OK):
View
4 plugins/dstat_gpfs_ops.py
@@ -7,11 +7,11 @@ class dstat_plugin(dstat):
def __init__(self):
self.name = 'gpfs file operations'
+ self.nick = ('open', 'clos', 'read', 'writ', 'rdir', 'inod')
+ self.vars = ('_oc_', '_cc_', '_rdc_', '_wc_', '_dir_', '_iu_')
self.type = 'd'
self.width = 5
self.scale = 1000
- self.vars = ('_oc_', '_cc_', '_rdc_', '_wc_', '_dir_', '_iu_')