I am trying to calculate the type of AZURE SQL I need using this: http://dtucalculator.azurewebsites.net/ => http://dtucalculator.azurewebsites.net/Downloads/sql-perfmon.zip
This is a PowerShell script that gets data from some counters from SQL but it errors out when accessing the "Log Bytes Flushed/sec" counter that it is pressent in SQL when I run
select * FROM sys.dm_os_performance_counters where counter_name like 'Log Bytes Flushed/sec%'
the error I get from PowerShell is:
Get-Counter : The specified object was not found on the computer. At C:\users\ringhel\desktop\sql-perfmon.ps1:47 char:1 + Get-Counter -Counter $counters -SampleInterval 1 -MaxSamples 3600 | + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : InvalidResult: (:) [Get-Counter], Exception + FullyQualifiedErrorId : CounterApiError,Microsoft.PowerShell.Commands.GetCounterCommand
The error comes from this variable:
$counters = @("\Processor(_Total)\% Processor Time", "\LogicalDisk(C:)\Disk Reads/sec", "\LogicalDisk(C:)\Disk Writes/sec",
"\LogicalDisk(C:)\Disk Read Bytes/sec", "\LogicalDisk(C:)\Disk Write Bytes/sec", "\SQLSERVER:Databases($DatabaseName)\Log Bytes Flushed/sec")
After searching the web, instead of SQLSERVER I tried MSSQLSERVER (this is the instance name of the SQL server), MSSQL'$MSSQLSERVER and MSSQL$MSSQLSERVER but the same error.
Please help.