prometheus / node_exporter

Exporter for machine metrics
https://prometheus.io/
Apache License 2.0
11.24k stars 2.37k forks source link

panic: runtime error: slice bounds out of range [:-1910825536] #3114

Closed bingws closed 2 months ago

bingws commented 2 months ago

Host operating system: output of uname -a

Linux 210235k0000606000001 5.15.0-aaccb14-dirty-ce722c6 #1 SMP Thu Aug 29 02:56:06 UTC 2024 armv7l GNU/Linux

node_exporter version: output of node_exporter --version

210235k0000606000001:/tmp$ ./node_exporter --version node_exporter, version 1.8.2 (branch: HEAD, revision: f1e0e8360aa60b6cb5e5cc1560bed348fc2c1895) build user: root@c129d06b03dd build date: 20240714-11:53:16 go version: go1.22.5 platform: linux/arm tags: unknown

node_exporter command line flags

node_exporter log output

` 210235k0000606000001:/tmp$ ./node_exporter ts=2024-05-12T18:51:51.417Z caller=node_exporter.go:193 level=info msg="Starting node_exporter" version="(version=1.8.2, branch=HEAD, revision=f1e0e8360aa60b6cb5e5cc1560bed348fc2c1895)" ts=2024-05-12T18:51:51.417Z caller=node_exporter.go:194 level=info msg="Build context" build_context="(go=go1.22.5, platform=linux/arm, user=root@c129d06b03dd, date=20240714-11:53:16, tags=unknown)" ts=2024-05-12T18:51:51.420Z caller=diskstats_common.go:111 level=info collector=diskstats msg="Parsed flag --collector.diskstats.device-exclude" flag=^(z?ram|loop|fd|(h|s|v|xv)d[a-z]|nvme\d+n\d+p)\d+$ ts=2024-05-12T18:51:51.422Z caller=filesystem_common.go:111 level=info collector=filesystem msg="Parsed flag --collector.filesystem.mount-points-exclude" flag=^/(dev|proc|run/credentials/.+|sys|var/lib/docker/.+|var/lib/containers/storage/.+)($|/) ts=2024-05-12T18:51:51.423Z caller=filesystem_common.go:113 level=info collector=filesystem msg="Parsed flag --collector.filesystem.fs-types-exclude" flag=^(autofs|binfmt_misc|bpf|cgroup2?|configfs|debugfs|devpts|devtmpfs|fusectl|hugetlbfs|iso9660|mqueue|nsfs|overlay|proc|procfs|pstore|rpc_pipefs|securityfs|selinuxfs|squashfs|sysfs|tracefs)$ ts=2024-05-12T18:51:51.429Z caller=node_exporter.go:111 level=info msg="Enabled collectors" ts=2024-05-12T18:51:51.429Z caller=node_exporter.go:118 level=info collector=arp ts=2024-05-12T18:51:51.429Z caller=node_exporter.go:118 level=info collector=bcache ts=2024-05-12T18:51:51.430Z caller=node_exporter.go:118 level=info collector=bonding ts=2024-05-12T18:51:51.430Z caller=node_exporter.go:118 level=info collector=btrfs ts=2024-05-12T18:51:51.431Z caller=node_exporter.go:118 level=info collector=conntrack ts=2024-05-12T18:51:51.431Z caller=node_exporter.go:118 level=info collector=cpu ts=2024-05-12T18:51:51.431Z caller=node_exporter.go:118 level=info collector=cpufreq ts=2024-05-12T18:51:51.431Z caller=node_exporter.go:118 level=info collector=diskstats ts=2024-05-12T18:51:51.432Z caller=node_exporter.go:118 level=info collector=dmi ts=2024-05-12T18:51:51.432Z caller=node_exporter.go:118 level=info collector=edac ts=2024-05-12T18:51:51.432Z caller=node_exporter.go:118 level=info collector=entropy ts=2024-05-12T18:51:51.433Z caller=node_exporter.go:118 level=info collector=fibrechannel ts=2024-05-12T18:51:51.433Z caller=node_exporter.go:118 level=info collector=filefd ts=2024-05-12T18:51:51.433Z caller=node_exporter.go:118 level=info collector=filesystem ts=2024-05-12T18:51:51.433Z caller=node_exporter.go:118 level=info collector=hwmon ts=2024-05-12T18:51:51.434Z caller=node_exporter.go:118 level=info collector=infiniband ts=2024-05-12T18:51:51.434Z caller=node_exporter.go:118 level=info collector=ipvs ts=2024-05-12T18:51:51.434Z caller=node_exporter.go:118 level=info collector=loadavg ts=2024-05-12T18:51:51.434Z caller=node_exporter.go:118 level=info collector=mdadm ts=2024-05-12T18:51:51.435Z caller=node_exporter.go:118 level=info collector=meminfo ts=2024-05-12T18:51:51.435Z caller=node_exporter.go:118 level=info collector=netclass ts=2024-05-12T18:51:51.435Z caller=node_exporter.go:118 level=info collector=netdev ts=2024-05-12T18:51:51.435Z caller=node_exporter.go:118 level=info collector=netstat ts=2024-05-12T18:51:51.436Z caller=node_exporter.go:118 level=info collector=nfs ts=2024-05-12T18:51:51.436Z caller=node_exporter.go:118 level=info collector=nfsd ts=2024-05-12T18:51:51.436Z caller=node_exporter.go:118 level=info collector=nvme ts=2024-05-12T18:51:51.437Z caller=node_exporter.go:118 level=info collector=os ts=2024-05-12T18:51:51.437Z caller=node_exporter.go:118 level=info collector=powersupplyclass ts=2024-05-12T18:51:51.437Z caller=node_exporter.go:118 level=info collector=pressure ts=2024-05-12T18:51:51.437Z caller=node_exporter.go:118 level=info collector=rapl ts=2024-05-12T18:51:51.438Z caller=node_exporter.go:118 level=info collector=schedstat ts=2024-05-12T18:51:51.438Z caller=node_exporter.go:118 level=info collector=selinux ts=2024-05-12T18:51:51.438Z caller=node_exporter.go:118 level=info collector=sockstat ts=2024-05-12T18:51:51.439Z caller=node_exporter.go:118 level=info collector=softnet ts=2024-05-12T18:51:51.439Z caller=node_exporter.go:118 level=info collector=stat ts=2024-05-12T18:51:51.439Z caller=node_exporter.go:118 level=info collector=tapestats ts=2024-05-12T18:51:51.439Z caller=node_exporter.go:118 level=info collector=textfile ts=2024-05-12T18:51:51.440Z caller=node_exporter.go:118 level=info collector=thermal_zone ts=2024-05-12T18:51:51.440Z caller=node_exporter.go:118 level=info collector=time ts=2024-05-12T18:51:51.440Z caller=node_exporter.go:118 level=info collector=timex ts=2024-05-12T18:51:51.441Z caller=node_exporter.go:118 level=info collector=udp_queues ts=2024-05-12T18:51:51.441Z caller=node_exporter.go:118 level=info collector=uname ts=2024-05-12T18:51:51.441Z caller=node_exporter.go:118 level=info collector=vmstat ts=2024-05-12T18:51:51.441Z caller=node_exporter.go:118 level=info collector=watchdog ts=2024-05-12T18:51:51.442Z caller=node_exporter.go:118 level=info collector=xfs ts=2024-05-12T18:51:51.442Z caller=node_exporter.go:118 level=info collector=zfs ts=2024-05-12T18:51:51.445Z caller=tls_config.go:313 level=info msg="Listening on" address=[::]:9100 ts=2024-05-12T18:51:51.446Z caller=tls_config.go:316 level=info msg="TLS is disabled." http2=false address=[::]:9100 panic: runtime error: slice bounds out of range [:-1910825536]

goroutine 77 [running]: github.com/prometheus/node_exporter/collector.sysReadFile({0x1474b70, 0x23}) /app/collector/hwmon_linux.go:108 +0x1d0 github.com/prometheus/node_exporter/collector.addValueFile(0x1100d5c, {0x13354f0, 0x5}, {0x13354b6, 0x4}, {0x1474b70, 0x23}) /app/collector/hwmon_linux.go:76 +0x24 github.com/prometheus/node_exporter/collector.collectSensorData({0x125e480, 0x18}, 0x1100d5c) /app/collector/hwmon_linux.go:152 +0x278 github.com/prometheus/node_exporter/collector.(hwMonCollector).updateHwmon(0x1191e50, 0x11c3800, {0x125e480, 0x18}) /app/collector/hwmon_linux.go:172 +0x1e8 github.com/prometheus/node_exporter/collector.(hwMonCollector).Update(0x1191e50, 0x11c3800) /app/collector/hwmon_linux.go:466 +0x394 github.com/prometheus/node_exporter/collector.execute({0x7dd54c, 0x5}, {0x8f3d0c, 0x1191e50}, 0x11c3800, {0x8f37a8, 0x10923a0}) /app/collector/collector.go:161 +0x40 github.com/prometheus/node_exporter/collector.NodeCollector.Collect.func1({0x7dd54c, 0x5}, {0x8f3d0c, 0x1191e50}) /app/collector/collector.go:152 +0x54 created by github.com/prometheus/node_exporter/collector.NodeCollector.Collect in goroutine 44 /app/collector/collector.go:151 +0x98 `

Are you running node_exporter in Docker?

No

chengjoey commented 2 months ago

3108 duplicate issue

SuperQ commented 2 months ago

Duplicate of #3108