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

server label is not added consistently to metrics #1030

Open
KulykDmytro opened this issue May 8, 2024 · 5 comments
Open

server label is not added consistently to metrics #1030

KulykDmytro opened this issue May 8, 2024 · 5 comments

Comments

@KulykDmytro
Copy link

Hi

At 0.15 running for of RDS instance (in kubernetes) we observing following behaviour. on default settings + queries.yaml
These collectors provides server label, other not:

  • all metrics passed over queries.yaml
  • pg_settings
  • pg_stat_activity
  • pg_stat_archiver
  • pg_stat_database (only for conflicts_confl section)
  • pg_static

expected that labeling will be consistent (all on or all off) or at least configurable per collector

Environment

AWS EKS

  • System information:
Linux 5.10.214-202.855.amzn2.x86_64 x86_64
  • postgres_exporter version:
postgres_exporter, version 0.15.0 (branch: HEAD, revision: 68c176b8833b7580bf847cecf60f8e0ad5923f9a)
  build user:       root@88f74f2c2888
  build date:       20231027-14:38:56
  go version:       go1.21.3
  platform:         linux/amd64
  tags:             unknown
  • postgres_exporter flags/variables:
variables:
  PG_EXPORTER_EXCLUDE_DATABASES: rdsadmin
  PG_EXPORTER_EXTEND_QUERY_PATH: '/var/lib/postgresql/queries.yaml'
  • PostgreSQL version: 14.10.0 (AWS RDS)
@KulykDmytro
Copy link
Author

KulykDmytro commented May 8, 2024

issue is originated from #888
but not relevant to multiserver scrape

@SuperQ
Copy link
Contributor

SuperQ commented May 8, 2024

I think we were working to eliminate the server label now that we have multi-target exporter setup. This is because there's no need for a server label on proxy scrapes.

@SuperQ
Copy link
Contributor

SuperQ commented May 8, 2024

👓 @sysadmind

@sysadmind
Copy link
Contributor

I think there's a decision to be made on whether or not the exporter is going to support multiple DSNs long term. If it does support multiple DSNs, we would need some label to distinguish both. The other option is to deprecate all of those previous collectors in favor of the newer collectors/ package collectors and remove support for multiple DSNs outside of the multi-target support. This should totally eliminate the need for the server label unless I'm missing some other complication.

I think there may be some logic for auto discovering databases that needs to be looked into as well. I think the intent is that some collectors or metrics are database specific.

@SuperQ
Copy link
Contributor

SuperQ commented May 11, 2024

There's a small amount of terminology mixup in some of the flags. There's multiple DSNs to connect to multiple servers. As well as there's the "Discover databases" which is actually used to filter metrics tables about the databases on a single server.

IMO we should eliminate the "multiple DSNs/servers", not the database metrics include/exclude filters for a single server.

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

No branches or pull requests

3 participants