Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions collector/filesystem_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,11 @@ func (c *filesystemCollector) processStat(labels filesystemLabels) filesystemSta
}
stuckMountsMtx.Unlock()

// Remove options from labels because options will not be used from this point forward
// and keeping them can lead to errors when the same device is mounted to the same mountpoint
// twice, with different options (metrics would be recorded multiple times).
labels.options = ""

if err != nil {
labels.deviceError = err.Error()
c.logger.Debug("Error on statfs() system call", "rootfs", rootfsFilePath(labels.mountPoint), "err", err)
Expand Down