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

Multiple named instances #56

Open
tp-eallen opened this issue Feb 3, 2023 · 0 comments
Open

Multiple named instances #56

tp-eallen opened this issue Feb 3, 2023 · 0 comments

Comments

@tp-eallen
Copy link

If you have multiple named instances the sql has issues. For example:
https://github.com/awaragi/prometheus-mssql-exporter/blob/master/src/metrics.js#L224

the line:
AND object_name = 'SQLServer:Buffer Manager'

should be similar to:
SELECT * FROM sys.dm_os_performance_counters WHERE object_name LIKE '%Buffer Manager%';

which is how MS recommends to do it:
https://learn.microsoft.com/en-us/sql/relational-databases/performance-monitor/sql-server-buffer-manager-object?view=sql-server-ver16

For example if you have a named instance the string for the object_name could be:
'MSSQL$MYSQLNAME:Buffer Manager'
which won't match currently

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

1 participant