Posts

Showing posts from July, 2022

Azure SQL Database DTU Calculator

Image
 If we have a plan to migrate our on-premises SQL Server database or   pool of databases  to Azure SQL Databases. We need to check for which we service tier we need to choose first for that particular database(s) in the cloud , to check this we have DTU (Database Transaction Units) calculator 1) Download the below PowerShell script and run it for one hour, chose that particular hour in which you usually see the load DTU Calculator Set-ExecutionPolicy -Scope Process -ExecutionPolicy Unrestricted -Force $ErrorActionPreference = "Stop" $VerbosePreference = "Continue" cls Write-Output "Collecting counters..." Write-Output "Press Ctrl+C to exit." $counters = @ ( "\Processor(_Total)\% Processor Time" , "\LogicalDisk(_Total)\Disk Reads/sec" , "\LogicalDisk(_Total)\Disk Writes/sec" , "\SQLServer:Databases(_Total)\Log Bytes Flushed/sec" ) Get-Counter -Counter $counters -SampleInterval 1 -MaxSampl...