Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New unit value 64kB #740

Merged
merged 1 commit into from Jan 21, 2023
Merged

Conversation

revverse
Copy link

@revverse revverse commented Jan 4, 2023

For Postgres 15 database, exporter panic with error:
`panic: Unknown unit for runtime variable: "64kB"

goroutine 25 [running]:
main.(*pgSetting).metric(0xc0005790e0, 0xc0003b9c50?)
/app/cmd/postgres_exporter/pg_setting.go:87 +0x2fc
main.querySettings(0x0?, 0xc0001b4fd0)
/app/cmd/postgres_exporter/pg_setting.go:56 +0x29e
main.(*Server).Scrape(0xc0001b4fd0, 0xc000026011?, 0xd0?)
/app/cmd/postgres_exporter/server.go:121 +0xd7
main.(*Exporter).scrapeDSN(0xc0001bc0c0, 0xc0000ce764?, {0xc000026011, 0x55})
/app/cmd/postgres_exporter/datasource.go:116 +0x1cd
main.(*Exporter).scrape(0xc0001bc0c0, 0xc0000ce660?)
/app/cmd/postgres_exporter/postgres_exporter.go:711 +0x235
main.(*Exporter).Collect(0xc0001bc0c0, 0xc0000ce760?)
/app/cmd/postgres_exporter/postgres_exporter.go:600 +0x27
github.com/prometheus/client_golang/prometheus.(*Registry).Gather.func1()
/go/pkg/mod/github.com/prometheus/client_golang@v1.12.2/prometheus/registry.go:448 +0x11a
created by github.com/prometheus/client_golang/prometheus.(*Registry).Gather
/go/pkg/mod/github.com/prometheus/client_golang@v1.12.2/prometheus/registry.go:538 +0xb0b
`
So, MR only add a new unit - 64kB

Signed-off-by: Oleksandr Mysyura <olexandr.mysyura@pragmaticplay.com>
Copy link
Contributor

@sysadmind sysadmind left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM thanks.

@sysadmind
Copy link
Contributor

Fixes #372

@sysadmind sysadmind merged commit 8b8466f into prometheus-community:master Jan 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants