diff --git a/collector/wifi_linux.go b/collector/wifi_linux.go index 117e4ae5..0e3ef9b9 100644 --- a/collector/wifi_linux.go +++ b/collector/wifi_linux.go @@ -144,11 +144,15 @@ func NewWifiCollector() (Collector, error) { func (c *wifiCollector) Update(ch chan<- prometheus.Metric) error { stat, err := newWifiStater(*collectorWifi) if err != nil { - // Cannot access wifi metrics, report no error + // Cannot access wifi metrics, report no error. if os.IsNotExist(err) { log.Debug("wifi collector metrics are not available for this system") return nil } + if os.IsPermission(err) { + log.Debug("wifi collector got permission denied when accessing metrics") + return nil + } return fmt.Errorf("failed to access wifi data: %v", err) }