prometheus / node_exporter

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

Node Exporter crashes on Oracle Linux 8 KVM hypervisor #2770

Closed ni-kweutzing closed 1 year ago

ni-kweutzing commented 1 year ago

Host operating system: output of uname -a

Linux olkvm03 5.15.0-102.110.5.1.el8uek.x86_64 #2 SMP Sat Jun 10 18:15:29 PDT 2023 x86_64 x86_64 x86_64 GNU/Linux

node_exporter version: output of node_exporter --version

node_exporter, version 1.6.1 (branch: HEAD, revision: 4a1b77600c1873a8233f3ffb55afcedbb63b8d84)
  build user:       root@586879db11e5
  build date:       20230717-12:10:52
  go version:       go1.20.6
  platform:         linux/amd64
  tags:             netgo osusergo static_build

node_exporter command line flags

/usr/local/sbin/node_exporter --log.level=debug --collector.diskstats.device-exclude="^(asm.+|ofsctl|oracleafd/admin|ram\\\\d+|loop\\\\d+|fd\\\\d+|(h|s|v|xv)d[a-z]\\\\d+|nvme\\\\d+n\\\\d+p\\\\d+)$" --collector.filesystem.f s-types-exclude="^(autofs|binfmt_misc|bpf|cgroup2?|configfs|debugfs|devpts|devtmpfs|fusectl|hugetlbfs|iso9660|mqueue|nsfs|overlay|proc|procfs|pstore|rpc_pipefs|securityfs|selinuxfs|squashfs|sysfs|tr acefs|cifs|nfs4|ocfs2|ocfs2_dlmfs|tmpfs)$"

node_exporter log output

node_exporter.log

Aug  9 11:33:26 olkvm03 node_exporter[746794]: panic: runtime error: slice bounds out of range [73:72]
Aug  9 11:33:26 olkvm03 node_exporter[746794]: goroutine 62 [running]:
Aug  9 11:33:26 olkvm03 node_exporter[746794]: github.com/prometheus/procfs/sysfs.filterOfflineCPUs(0xc0004c0200?, 0xc0000f0c08)
Aug  9 11:33:26 olkvm03 node_exporter[746794]: #011/go/pkg/mod/github.com/prometheus/procfs@v0.10.0/sysfs/system_cpu.go:181 +0x23a
Aug  9 11:33:26 olkvm03 node_exporter[746794]: github.com/prometheus/procfs/sysfs.FS.SystemCpufreq({{0xbca465?, 0x4?}})
Aug  9 11:33:26 olkvm03 node_exporter[746794]: #011/go/pkg/mod/github.com/prometheus/procfs@v0.10.0/sysfs/system_cpu.go:209 +0x28b
Aug  9 11:33:26 olkvm03 node_exporter[746794]: github.com/prometheus/node_exporter/collector.(*cpuFreqCollector).Update(0x0?, 0x0?)
Aug  9 11:33:26 olkvm03 node_exporter[746794]: #011/app/collector/cpufreq_linux.go:51 +0x45
Aug  9 11:33:26 olkvm03 node_exporter[746794]: github.com/prometheus/node_exporter/collector.execute({0xbcd883, 0x7}, {0xce39e0, 0xc0000dbca0}, 0x0?, {0xce3500, 0xc0002b3180})
Aug  9 11:33:26 olkvm03 node_exporter[746794]: #011/app/collector/collector.go:161 +0x9c
Aug  9 11:33:26 olkvm03 node_exporter[746794]: github.com/prometheus/node_exporter/collector.NodeCollector.Collect.func1({0xbcd883?, 0x0?}, {0xce39e0?, 0xc0000dbca0?})
Aug  9 11:33:26 olkvm03 node_exporter[746794]: #011/app/collector/collector.go:152 +0x3d
Aug  9 11:33:26 olkvm03 node_exporter[746794]: created by github.com/prometheus/node_exporter/collector.NodeCollector.Collect
Aug  9 11:33:26 olkvm03 node_exporter[746794]: #011/app/collector/collector.go:151 +0xd0

Are you running node_exporter in Docker?

nope

What did you do that produced an error?

Start Node Exporter and call the /metrics URL

What did you expect to see?

The metrics

What did you see instead?

The error message

Old version of Node Exporter is running fine

node_exporter, version 1.3.1 (branch: tarball, revision: 4.el8)
  build user:       
  build date:       20220205
  go version:       go1.16.12
  platform:         linux/amd64
discordianfish commented 1 year ago

Dup of #2746 2746