mirror of
https://github.com/prometheus/node_exporter
synced 2025-03-25 12:16:48 +00:00
Skip zfs iostats (#2451)
skip over the zfs IO metrics if their paths are missing Signed-off-by: tnextday <fw2k4@163.com> Signed-off-by: tnextday <fw2k4@163.com>
This commit is contained in:
parent
863f3ac54c
commit
d7e89e769d
@ -74,10 +74,6 @@ func (c *zfsCollector) updatePoolStats(ch chan<- prometheus.Metric) error {
|
|||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
if zpoolPaths == nil {
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
for _, zpoolPath := range zpoolPaths {
|
for _, zpoolPath := range zpoolPaths {
|
||||||
file, err := os.Open(zpoolPath)
|
file, err := os.Open(zpoolPath)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
Loading…
Reference in New Issue
Block a user