{"record":{"id":"a9450c3f25233ca1","repo":"prometheus/node_exporter","slug":"couldn-t-get-udp6-queued-bytes-w","errorCode":null,"errorMessage":"couldn't get udp6 queued bytes: %w","messagePattern":"couldn't get udp6 queued bytes: %w","errorType":"error_code","errorClass":null,"httpStatus":null,"severity":"error","filePath":"collector/udp_queues_linux.go","lineNumber":79,"sourceCode":"\t\tch <- prometheus.MustNewConstMetric(c.desc, prometheus.GaugeValue, float64(s4.TxQueueLength), \"tx\", \"v4\")\n\t\tch <- prometheus.MustNewConstMetric(c.desc, prometheus.GaugeValue, float64(s4.RxQueueLength), \"rx\", \"v4\")\n\t} else {\n\t\tif errors.Is(errIPv4, os.ErrNotExist) {\n\t\t\tc.logger.Debug(\"not collecting ipv4 based metrics\")\n\t\t} else {\n\t\t\treturn fmt.Errorf(\"couldn't get udp queued bytes: %w\", errIPv4)\n\t\t}\n\t}\n\n\ts6, errIPv6 := c.fs.NetUDP6Summary()\n\tif errIPv6 == nil {\n\t\tch <- prometheus.MustNewConstMetric(c.desc, prometheus.GaugeValue, float64(s6.TxQueueLength), \"tx\", \"v6\")\n\t\tch <- prometheus.MustNewConstMetric(c.desc, prometheus.GaugeValue, float64(s6.RxQueueLength), \"rx\", \"v6\")\n\t} else {\n\t\tif errors.Is(errIPv6, os.ErrNotExist) {\n\t\t\tc.logger.Debug(\"not collecting ipv6 based metrics\")\n\t\t} else {\n\t\t\treturn fmt.Errorf(\"couldn't get udp6 queued bytes: %w\", errIPv6)\n\t\t}\n\t}\n\n\tif errors.Is(errIPv4, os.ErrNotExist) && errors.Is(errIPv6, os.ErrNotExist) {\n\t\treturn ErrNoData\n\t}\n\treturn nil\n}\n","sourceCodeStart":61,"sourceCodeEnd":88,"githubUrl":"https://github.com/prometheus/node_exporter/blob/17ddd77c59ba27e1508e9f7894b1e55b44d6aed3/collector/udp_queues_linux.go#L61-L88","documentation":"The IPv6 counterpart of the udp queues read: fs.NetUDP6Summary() errors that are not os.ErrNotExist become 'couldn't get udp6 queued bytes: %w'. If BOTH v4 and v6 files are missing (ErrNotExist), the collector returns ErrNoData so the scrape is skipped rather than failing — this error only fires for genuine v6 read/parse problems.","triggerScenarios":"udpQueuesCollector.Update when NetUDP6Summary() returns a non-ErrNotExist error while reading /proc/net/udp6 — parse failures or permission errors on hosts with IPv6 enabled.","commonSituations":"Kernels/configs exposing a malformed or partially readable /proc/net/udp6, security modules blocking the read, and parser mismatches after kernel upgrades.","solutions":["Verify /proc/net/udp6 exists and is readable.","Check the wrapped error to see if it is a parse or permission failure.","Disable IPv6 collection (or the udp_queues collector) if the host has no usable udp6 support.","File an upstream procfs issue if the kernel's udp6 format differs from the parser."],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":"if _, err := os.Stat(\"/proc/net/udp6\"); errors.Is(err, os.ErrNotExist) {\n    // no ipv6 udp support; expect ErrNoData skips instead of metrics\n}","typeGuard":null,"tryCatchPattern":"if err := c.Update(ch); err != nil {\n    if errors.Is(err, ErrNoData) { return }\n    if strings.Contains(err.Error(), \"couldn't get udp6 queued bytes\") {\n        logger.Warn(\"udp v6 queue metrics unavailable\", \"err\", err)\n        return\n    }\n    return err\n}","preventionTips":["Verify /proc/net/udp6 exists on IPv6-enabled hosts before relying on v6 metrics.","Handle ErrNoData: missing both v4 and v6 files is intentional no-data behavior.","Keep the procfs dependency current for kernel format changes.","Only enable udp_queues where the kernel exposes both queue summaries you need."],"tags":["linux","procfs","udp","ipv6"],"backgroundTag":"file-read-failed","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"}