Skip to content

Commit 7498ade

Browse files
authored
Add new filtering options, continue deprecations (#2483)
* Add new filtering options, continue deprecations * address review
1 parent 591525a commit 7498ade

4 files changed

Lines changed: 582 additions & 167 deletions

File tree

disk/datadog_checks/disk/data/conf.yaml.default

Lines changed: 119 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -5,57 +5,123 @@
55
init_config:
66

77
instances:
8-
# The use_mount parameter will instruct the check to collect disk
9-
# and fs metrics using mount points instead of volumes
8+
## @param use_mount - boolean - required
9+
## Instruct the check to collect using mount points instead of volumes.
10+
#
1011
- use_mount: false
11-
# The (optional) excluded_filesystems parameter will instruct the check to
12-
# ignore disks using these filesystems. Note: On some linux distributions,
13-
# rootfs will be found and tagged as a device, add rootfs here to exclude.
14-
# excluded_filesystems:
15-
# - tmpfs
16-
17-
# The (optional) excluded_disks parameter will instruct the check to
18-
# ignore this list of disks.
19-
# Linux example:
20-
# excluded_disks:
21-
# - /dev/sda1
22-
# - /dev/sda2
23-
#
24-
# Windows example:
25-
# excluded_disks:
26-
# - F:\
27-
#
28-
# The (optional) excluded_disk_re parameter will instruct the check to
29-
# ignore all disks matching this regex.
30-
# excluded_disk_re: /dev/sde.*
31-
#
32-
# The (optional) tag_by_filesystem parameter will instruct the check to
33-
# tag all disks with their filesystem (for ex: filesystem:nfs).
34-
# tag_by_filesystem: false
35-
#
36-
# The (optional) excluded_mountpoint_re parameter will instruct the check to
37-
# ignore all mountpoints matching this regex.
38-
# excluded_mountpoint_re: /mnt/somebody-elses-problem.*
39-
#
40-
# The (optional) all_partitions parameter will instruct the check to
41-
# get metrics for all partitions. use_mount should be set to yes (to avoid
42-
# collecting empty device names) when using this option.
43-
# all_partitions: false
44-
#
45-
# The (optional) device_tag_re parameter will instruct the check to apply additional tags to
46-
# volumes/mountpoints matching these regexes. Multiple comma-separated tags are supported.
47-
# You must properly quote the string if the pattern contains special characters e.g. colons.
48-
# Character casing is ignored on Windows.
49-
# device_tag_re:
50-
# /san/.*: device_type:san
51-
# /dev/sda3: role:db,disk_size:large
52-
# "c:": volume:boot
53-
#
54-
# The (optional) tags parameter allows you to customize tags for the instance
55-
# tags:
56-
# - optional_tag1
57-
# - optional_tag2
58-
#
59-
# The (optional) service_check_rw parameter notifies when one of the partitions is in
60-
# read-only mode
61-
# service_check_rw: false
12+
13+
## @param all_partitions - boolean - optional
14+
## Instruct the check to collect from partitions even without device names.
15+
## Setting `use_mount` to true is strongly recommended in this case.
16+
#
17+
# all_partitions: false
18+
19+
## @param tags - list of key:value string - optional
20+
## List of tags to attach to every metric and service check emitted by this integration.
21+
##
22+
## Learn more about tagging at https://docs.datadoghq.com/tagging
23+
#
24+
# tags:
25+
# - <KEY_1>:<VALUE_1>
26+
# - <KEY_2>:<VALUE_2>
27+
28+
## @param file_system_whitelist - list of regex - optional
29+
## Instruct the check to only collect from matching file systems.
30+
##
31+
## Character casing is ignored. For convenience, the regular expressions
32+
## start matching from the beginning and therefore to match anywhere you
33+
## must prepend `.*`. For exact matches append `$`.
34+
#
35+
# file_system_whitelist:
36+
# - ext[34]$
37+
# - ntfs$
38+
39+
## @param file_system_blacklist - list of regex - optional
40+
## Instruct the check to not collect from matching file systems.
41+
##
42+
## Character casing is ignored. For convenience, the regular expressions
43+
## start matching from the beginning and therefore to match anywhere you
44+
## must prepend `.*`. For exact matches append `$`.
45+
##
46+
## When conflicts arise, this will override `file_system_whitelist`.
47+
#
48+
# file_system_blacklist:
49+
# - tmpfs$
50+
# - rootfs$
51+
# - autofs$
52+
# - .*binfmt_misc
53+
54+
## @param device_whitelist - list of regex - optional
55+
## Instruct the check to only collect from matching devices.
56+
##
57+
## Character casing is ignored on Windows. For convenience, the regular
58+
## expressions start matching from the beginning and therefore to match
59+
## anywhere you must prepend `.*`. For exact matches append `$`.
60+
#
61+
# device_whitelist:
62+
# - /dev/sda[1-3]
63+
# - C:
64+
65+
## @param device_blacklist - list of regex - optional
66+
## Instruct the check to not collect from matching devices.
67+
##
68+
## Character casing is ignored on Windows. For convenience, the regular
69+
## expressions start matching from the beginning and therefore to match
70+
## anywhere you must prepend `.*`. For exact matches append `$`.
71+
##
72+
## When conflicts arise, this will override `device_whitelist`.
73+
#
74+
# device_blacklist:
75+
# - /dev/sde
76+
# - [FJ]:
77+
78+
## @param mount_point_whitelist - list of regex - optional
79+
## Instruct the check to only collect from matching mount points.
80+
##
81+
## Character casing is ignored on Windows. For convenience, the regular
82+
## expressions start matching from the beginning and therefore to match
83+
## anywhere you must prepend `.*`. For exact matches append `$`.
84+
#
85+
# mount_point_whitelist:
86+
# - /dev/sda[1-3]
87+
# - C:
88+
89+
## @param mount_point_blacklist - list of regex - optional
90+
## Instruct the check to not collect from matching mount points.
91+
##
92+
## Character casing is ignored on Windows. For convenience, the regular
93+
## expressions start matching from the beginning and therefore to match
94+
## anywhere you must prepend `.*`. For exact matches append `$`.
95+
##
96+
## When conflicts arise, this will override `mount_point_whitelist`.
97+
#
98+
# mount_point_blacklist:
99+
# - /dev/sde
100+
# - [FJ]:
101+
102+
## @param service_check_rw - boolean - optional
103+
## Instruct the check to notify based on partition state.
104+
##
105+
## read-write -> OK
106+
## read-only -> CRITICAL
107+
## other -> UNKNOWN
108+
#
109+
# service_check_rw: false
110+
111+
## @param tag_by_filesystem - boolean - optional
112+
## Instruct the check to tag all disks with their file system e.g. filesystem:ntfs.
113+
#
114+
# tag_by_filesystem: false
115+
116+
## @param device_tag_re - list of regex:tags string - optional
117+
## Instruct the check to apply additional tags to matching
118+
## devices (or mount points if `use_mount` is true).
119+
##
120+
## Character casing is ignored on Windows. Multiple comma-separated
121+
## tags are supported. You must properly quote the string if the
122+
## pattern contains special characters e.g. colons.
123+
#
124+
# device_tag_re:
125+
# /san/.*: device_type:san
126+
# /dev/sda3: role:db,disk_size:large
127+
# "c:": volume:boot

0 commit comments

Comments
 (0)