-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathREADME
36 lines (27 loc) · 1.41 KB
/
README
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
collectd-diskstats is a collectd plugin (written in Python) that reads the
Linux 2.6 /proc/diskstats "file" and records detailed device statistics.
It is a superset of the "disk" plugin that ships with collectd. The main
difference is it records additional fields present in /proc/diskstats.
This plugin requires Collectd's Python plugin, which was introduced in
collectd 4.9. To configure, drop the diskstats.py file into a directory
where collectd is configured to find Python modules (ModulePath param).
The plugin must be explicitly told which disks to monitor. This is done
by defining "Disk" parameters inside the <Module> block for diskstats.
One "Disk" parameter per device. To see which devices are available, just
`cat /proc/diskstats`.
Here is an example configuration:
<Plugin python>
ModulePath "/path/to/modules"
Import "diskstats"
<Module diskstats>
Disk sda
Disk sda1
</Module>
</Plugin>
The plugin produces data for the "diskstats" plugin. The plugin instance
will be the device name. The plugin will write gauge data for 10 types. The
type instance corresponds to the fields in /proc/iostats.
The Documentation/iostats.txt file in the Linux kernel source tree
(http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=blob_plain;f=Documentation/iostats.txt;hb=refs/tags/v2.6.36)
describes the fields in /proc/diskstats and can help you make sense of the
data.