This page describes filtering of possible monitored sensors (to save disk space, disk writes, CPU cycles, space for graphs on server page, …).
There are two basic types of plugins depending on how they handle multiple instances of same resource (something we want to measure).
/proc/diskstats, usage of mount points when parsing output of
If you don't want to monitor certain MySQL instance you can just comment the relevant configuration. However if you don't want to monitor disks
sd[a-z] you must use filters (though you can filter sensors of MySQL plugin too).
Sensor is an abstraction of part of some resource and associated data (currently stored in RRD). Sensor name consists of base name (everything from start until first '-') and instance name (everything after first '-'). However sensor doesn't need to have associated instance. Examples:
Sensors aren't currently tied to plugins (on bijk-node). List of valid sensors is in
Filters are configured under plugin node in
/etc/bijk/plugins.yml. In order to add filter, add
sensors node under plugin node (
filesystem, …) with
exclude child nodes.
exclude nodes must contain array of Perl regular expressions which are matched with actual sensor. Example:
filesystem: sensors: include: - '^[^-]*-/lib/my_mount' exclude: - '^[^-]*-/lib' - '^[^-]*-/dev'
It's better to put regular expression in quotes to avoid YAML parser from interpreting some special characters. The
^[^-]* matches sensor base name. Here we filter just instances.
update_sensor( sensor_base, timestamp, value, sensor_instance )
sensor_instance) was already checked against filters, sensor is discarded/allowed instantly
includearray matches with sensor name, sensor is allowed
excludearray matches with sensor name, sensor is discarded
Suppose you have Ethernet interfaces
eth0:2 where only the first one is real you want to monitor. The configuration for this plugin will look like this:
traffic: sensors: exclude: - 'eth0:'
If you decided you want to monitor also
eth0:2, the configuration will look like this:
traffic: sensors: include: - 'eth0:2' exclude: - 'eth0:'