aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'README.md')
-rw-r--r--README.md33
1 files changed, 33 insertions, 0 deletions
diff --git a/README.md b/README.md
index 04053a1..d4ef98a 100644
--- a/README.md
+++ b/README.md
@@ -107,6 +107,39 @@ echo 'role{role="application_server"} 1' > /path/to/directory/role.prom.$$
107mv /path/to/directory/role.prom.$$ /path/to/directory/role.prom 107mv /path/to/directory/role.prom.$$ /path/to/directory/role.prom
108``` 108```
109 109
110### Filtering enabled collectors
111
112The node_exporter will expose all metrics from enabled collectors by default, but it can be passed an optional list of collectors to filter metrics. The `collect[]` parameter accepts values matching enabled collector names.
113
114This can be useful for specifying different scrape intervals for different collectors in Prometheus:
115
116```yaml
117scrape_configs:
118 - job_name: 'node resources'
119 scrape_interval: 15s
120 static_configs:
121 - targets:
122 - '192.168.1.2:9100'
123 params:
124 collect[]:
125 - cpu
126 - meminfo
127 - diskstats
128 - netdev
129 - netstat
130
131 - job_name: 'node storage'
132 scrape_interval: 1m
133 static_configs:
134 - targets:
135 - '192.168.1.2:9100'
136 params:
137 collect[]:
138 - filefd
139 - filesystem
140 - xfs
141```
142
110## Building and running 143## Building and running
111 144
112Prerequisites: 145Prerequisites: