mirror of
https://github.com/prometheus-community/windows_exporter
synced 2025-02-16 03:57:37 +00:00
mssql: fix performance counter with additional server instance (#1753)
Signed-off-by: Jan-Otto Kröpke <mail@jkroepke.de>
This commit is contained in:
parent
3b378136f5
commit
4534c2a6ae
@ -360,9 +360,10 @@ func (c *Collector) getMSSQLInstances() mssqlInstancesType {
|
||||
// Counter object for the given SQL instance and Collector.
|
||||
func (c *Collector) mssqlGetPerfObjectName(sqlInstance string, collector string) string {
|
||||
sb := strings.Builder{}
|
||||
sb.WriteString("SQLServer:")
|
||||
|
||||
if sqlInstance != "MSSQLSERVER" {
|
||||
if sqlInstance == "MSSQLSERVER" {
|
||||
sb.WriteString("SQLServer:")
|
||||
} else {
|
||||
sb.WriteString("MSSQL$")
|
||||
sb.WriteString(sqlInstance)
|
||||
sb.WriteString(":")
|
||||
|
Loading…
Reference in New Issue
Block a user