mirror of
https://github.com/prometheus/node_exporter.git
synced 2024-11-23 20:36:21 +01:00
Add logging for ethtool device include/exclude and metrics include flags (#2979)
Signed-off-by: Sam Leiken <sam.k.leiken@gmail.com>
This commit is contained in:
parent
cadb1d1190
commit
9572e7a07b
@ -96,6 +96,16 @@ func makeEthtoolCollector(logger log.Logger) (*ethtoolCollector, error) {
|
|||||||
return nil, fmt.Errorf("failed to initialize ethtool library: %w", err)
|
return nil, fmt.Errorf("failed to initialize ethtool library: %w", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if *ethtoolDeviceInclude != "" {
|
||||||
|
level.Info(logger).Log("msg", "Parsed flag --collector.ethtool.device-include", "flag", *ethtoolDeviceInclude)
|
||||||
|
}
|
||||||
|
if *ethtoolDeviceExclude != "" {
|
||||||
|
level.Info(logger).Log("msg", "Parsed flag --collector.ethtool.device-exclude", "flag", *ethtoolDeviceExclude)
|
||||||
|
}
|
||||||
|
if *ethtoolIncludedMetrics != "" {
|
||||||
|
level.Info(logger).Log("msg", "Parsed flag --collector.ethtool.metrics-include", "flag", *ethtoolIncludedMetrics)
|
||||||
|
}
|
||||||
|
|
||||||
// Pre-populate some common ethtool metrics.
|
// Pre-populate some common ethtool metrics.
|
||||||
return ðtoolCollector{
|
return ðtoolCollector{
|
||||||
fs: fs,
|
fs: fs,
|
||||||
|
Loading…
Reference in New Issue
Block a user