Skip to content

Unable to get metrics from databases #1130

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

Open
Yeroha opened this issue Feb 23, 2025 · 2 comments
Open

Unable to get metrics from databases #1130

Yeroha opened this issue Feb 23, 2025 · 2 comments

Comments

@Yeroha
Copy link

Yeroha commented Feb 23, 2025

What did you do?
I installed postgres_exporter 0.16.0 linux. I have 2 databases: test_db_1, test_db_2. Trying get metrics from tables pg_stat_user_tables for my databases, but i see metrics from only postgres DB. Inserted --auto-discover-databases to config file, but not working. User postgres_exporter has privileges on these databases
Why i'm not see metrics from DBs?

  • postgres_exporter version:

    0.16.0

  • PostgreSQL version:

    16.7.1

@scottishwidow
Copy link

scottishwidow commented Mar 21, 2025

@Yeroha hey!👋

According to the Flags section of the README, the --auto-discover-databases flag has been deprecated.

You might want to consider using the --extend.query-path option with a custom queries file instead.

@rhclayto
Copy link

rhclayto commented Apr 11, 2025

--extend.query-path is also listed as DEPRECATED.

Adding new metrics via a config file (DEPRECATED)

This feature is deprecated in favor of built-in collector functions. For generic SQL database monitoring see the sql_exporter.

The -extend.query-path command-line argument specifies a YAML file containing additional queries to run. Some examples are provided in queries.yaml.

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