vpenso / prometheus-slurm-exporter

Prometheus exporter for performance metrics from Slurm.
GNU General Public License v3.0
219 stars 138 forks source link

panic: runtime error: index out of range [4] with length 4 #87

Open gbeyer3 opened 2 years ago

gbeyer3 commented 2 years ago

Hello, I'm getting the same error as issue #56:

panic: runtime error: index out of range [4] with length 4

goroutine 26 [running]: main.ParseNodeMetrics(0xc000140000, 0x25e, 0x600, 0x87080d) /storage/home/hhiveman1/gbeyer3/prometheus-slurm-exporter/node.go:56 +0x6d6 main.NodeGetMetrics(0x1) /storage/home/hhiveman1/gbeyer3/prometheus-slurm-exporter/node.go:40 +0x2a main.(NodeCollector).Collect(0xc000020030, 0xc000072660) /storage/home/hhiveman1/gbeyer3/prometheus-slurm-exporter/node.go:128 +0x37 github.com/prometheus/client_golang/prometheus.(Registry).Gather.func1() /storage/home/hhiveman1/gbeyer3/go/pkg/mod/github.com/prometheus/client_golang@v1.2.1/prometheus/registry.go:443 +0x12b created by github.com/prometheus/client_golang/prometheus.(*Registry).Gather /storage/home/hhiveman1/gbeyer3/go/pkg/mod/github.com/prometheus/client_golang@v1.2.1/prometheus/registry.go:535 +0xe4d

Answering the questions you asked that poster:

I am using the latest version of the slurm-exporter which I cloned directly from your repo and built using instructions in DEVELOPMENT.md ver 0.20

slurm version 22.05.0

sinfo -h -N -O "NodeList,AllocMem,Memory,CPUsState,StateLong" atl1-1-02-018-35 0 515741 0/64/0/64 idle atl1-1-03-002-35 0 191856 0/24/0/24 idle compile-coda 0 191881 0/24/0/24 idle compute-dev-slurm-1-0 3770 0/4/0/4 idle compute-dev-slurm-1-0 3770 0/4/0/4 idle compute-dev-slurm-2-0 3770 0/4/0/4 idle

gbeyer3 commented 2 years ago

@mtds @vpenso, please see issue posted. Thx