{"record":{"id":"49f8e133abf13f5f","repo":"prometheus/node_exporter","slug":"failed-to-parse-mountstats-w","errorCode":null,"errorMessage":"failed to parse mountstats: %w","messagePattern":"failed to parse mountstats: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"collector/mountstats_linux.go","lineNumber":531,"sourceCode":"\t\t\tnil,\n\t\t),\n\n\t\tNFSEventPNFSWriteTotal: prometheus.NewDesc(\n\t\t\tprometheus.BuildFQName(namespace, subsystem, \"event_pnfs_write_total\"),\n\t\t\t\"Number of NFS v4.1+ pNFS writes.\",\n\t\t\tlabels,\n\t\t\tnil,\n\t\t),\n\n\t\tproc:   proc,\n\t\tlogger: logger,\n\t}, nil\n}\n\nfunc (c *mountStatsCollector) Update(ch chan<- prometheus.Metric) error {\n\tmounts, err := c.proc.MountStats()\n\tif err != nil {\n\t\treturn fmt.Errorf(\"failed to parse mountstats: %w\", err)\n\t}\n\n\tmountsInfo, err := c.proc.MountInfo()\n\tif err != nil {\n\t\treturn fmt.Errorf(\"failed to parse mountinfo: %w\", err)\n\t}\n\n\t// store all seen nfsDeviceIdentifiers for deduplication\n\tdeviceList := make(map[nfsDeviceIdentifier]bool)\n\tmountpointList := make(map[nfsMountpointIdentifier]bool)\n\n\tfor idx, m := range mounts {\n\t\t// For the time being, only NFS statistics are available via this mechanism\n\t\tstats, ok := m.Stats.(*procfs.MountStatsNFS)\n\n\t\tif !ok {\n\t\t\tcontinue\n\t\t}","sourceCodeStart":513,"sourceCodeEnd":549,"githubUrl":"https://github.com/prometheus/node_exporter/blob/17ddd77c59ba27e1508e9f7894b1e55b44d6aed3/collector/mountstats_linux.go#L513-L549","documentation":"Update failed while procfs parsed /proc/self/mountstats. This is NFS collector data collection, not a startup problem; a malformed or truncated mountstats file (or a procfs version mismatch) makes the whole mountstats scrape fail for this cycle.","triggerScenarios":"Thrown at collector/mountstats_linux.go:531 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Inspect /proc/self/mountstats on the host for unexpected content or very long lines.","Update node_exporter/vendor procfs if the kernel emits newer mountstats fields the parser rejects.","Re-run the scrape; transient parse errors during mount/unmount churn usually clear on the next scrape."],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"17ddd77c59ba27e1508e9f7894b1e55b44d6aed3","analyzedAt":"2026-09-07T17:54:06.211Z","contentChangedAt":"2026-09-07T17:54:06.211Z","schemaVersion":2},"datasetVersion":"2026-09-16T04:17:20.429Z"}