:: The problem
In my Azure tests, SQL Server runs much slower, compared to on-premises installation and to other DBMSs.
The same applies to Azure SQL Database.
:: The premises
I develop .NET LOB/BI Applications, most of them using SQL Server as DBMS.
Currently I am testing Azure and one of the most important goals, at least for me, is a good SQL Server Performance.
As I am using Virtual Machines and Virtual HDs I would expect slower performance than I currently find with dedicated servers.
I have created some VMs with SQL server 2008R2, 2012 and 2014, and all of them are much slower than SQL Server running on-premises.
My first hint was IOPS performance, but running SQLIO I found near 500 IOPS.
This is exactly what Azure promisses in an SQL Server Performance White Papers (http://msdn.microsoft.com/en-us/library/dn248436.aspx).
I decided to install 3 other DBMS, all of them free, to compare how much their performance is affected when I migrate them to Azure.
Below you find the SQL Scripts for SQL Server, Firebird, PostgreSQL and MySQL:
http://www.siegmar.com.br/INSERT.zip
The script is a simple INSERT, performed 10.000, 100.000 or 1.000.000 times, inside a programming loop.
All free DBMSs where installed as-is without any optimization.
SQL Server was installed from pre-built Azure Images: 2008R2, 2012 and 2014.
There are almost no differences between the versions, considering performance, so I have choosed SQL Server 2012 SP1 Web:
Microsoft SQL Server 2012 (SP1) - 11.0.3393.0 (X64)
Oct 25 2013 19:04:40
Copyright (c) Microsoft Corporation
Web Edition (64-bit) on Windows NT 6.1 <X64> (Build 7601: Service Pack 1) (Hypervisor)
Databases were created in a 50 GB Data Disk attached to VM as "E:", not in the OS Disk.
The VM OS used in my tests was Windows Server 2008 R2 SP1 Datacenter.
Unfortunately, the SQL Server EULA does not allow publishing any Benchmark result:
"You may not: disclose the results of any benchmark tests of the software to any third party without Microsoft’s prior written approval"
So I will not publish any speed comparison between then DBMSs.
(Microsoft, please do not prosecute me !)
Instead I will just compare a DBMS with itself, in on-premises installation and Azure installation, and will not publish any measured execution time.
Below you find my results, comparing Azure VMs with my i7/8GB DELL Notebook:
- Firebird: Azure execution time = 1,5 X On-Premises execution time
- PostgreSQL: Azure execution time = 1,8 X On-Premises execution time
- SQL Server 2008R2: Azure execution time = 20 X On-Premises execution time !!!
- Azure SQL Database: Azure execution time = 15 X On-Premises execution time !!!
I have repeated the tests many times, with different VMs, as they are almost unbelievable.
You may run the scripts and find your own results.
But, please, do not publish any measured time of comparisons between DBMSs in your answer !
IMPORTANT: All the tests where performed with an Azure TRIAL Account !
:: The Question
Considering the Data Disk is the same, Affinity Groups or IOPS performance would affect all the DBMSs, not just SQL Server.
Why is SQL Server so affected by Azure ?
SQL Server is a Microsoft product, so I believe it would run faster than any other DBMSs in Azure.
What am I doing wrong ?
Is there any kind of optimization missing for SQL Server ?
Thanks
In my Azure tests, SQL Server runs much slower, compared to on-premises installation and to other DBMSs.
The same applies to Azure SQL Database.
:: The premises
I develop .NET LOB/BI Applications, most of them using SQL Server as DBMS.
Currently I am testing Azure and one of the most important goals, at least for me, is a good SQL Server Performance.
As I am using Virtual Machines and Virtual HDs I would expect slower performance than I currently find with dedicated servers.
I have created some VMs with SQL server 2008R2, 2012 and 2014, and all of them are much slower than SQL Server running on-premises.
My first hint was IOPS performance, but running SQLIO I found near 500 IOPS.
This is exactly what Azure promisses in an SQL Server Performance White Papers (http://msdn.microsoft.com/en-us/library/dn248436.aspx).
I decided to install 3 other DBMS, all of them free, to compare how much their performance is affected when I migrate them to Azure.
Below you find the SQL Scripts for SQL Server, Firebird, PostgreSQL and MySQL:
http://www.siegmar.com.br/INSERT.zip
The script is a simple INSERT, performed 10.000, 100.000 or 1.000.000 times, inside a programming loop.
All free DBMSs where installed as-is without any optimization.
SQL Server was installed from pre-built Azure Images: 2008R2, 2012 and 2014.
There are almost no differences between the versions, considering performance, so I have choosed SQL Server 2012 SP1 Web:
Microsoft SQL Server 2012 (SP1) - 11.0.3393.0 (X64)
Oct 25 2013 19:04:40
Copyright (c) Microsoft Corporation
Web Edition (64-bit) on Windows NT 6.1 <X64> (Build 7601: Service Pack 1) (Hypervisor)
Databases were created in a 50 GB Data Disk attached to VM as "E:", not in the OS Disk.
The VM OS used in my tests was Windows Server 2008 R2 SP1 Datacenter.
Unfortunately, the SQL Server EULA does not allow publishing any Benchmark result:
"You may not: disclose the results of any benchmark tests of the software to any third party without Microsoft’s prior written approval"
So I will not publish any speed comparison between then DBMSs.
(Microsoft, please do not prosecute me !)
Instead I will just compare a DBMS with itself, in on-premises installation and Azure installation, and will not publish any measured execution time.
Below you find my results, comparing Azure VMs with my i7/8GB DELL Notebook:
- Firebird: Azure execution time = 1,5 X On-Premises execution time
- PostgreSQL: Azure execution time = 1,8 X On-Premises execution time
- SQL Server 2008R2: Azure execution time = 20 X On-Premises execution time !!!
- Azure SQL Database: Azure execution time = 15 X On-Premises execution time !!!
I have repeated the tests many times, with different VMs, as they are almost unbelievable.
You may run the scripts and find your own results.
But, please, do not publish any measured time of comparisons between DBMSs in your answer !
IMPORTANT: All the tests where performed with an Azure TRIAL Account !
:: The Question
Considering the Data Disk is the same, Affinity Groups or IOPS performance would affect all the DBMSs, not just SQL Server.
Why is SQL Server so affected by Azure ?
SQL Server is a Microsoft product, so I believe it would run faster than any other DBMSs in Azure.
What am I doing wrong ?
Is there any kind of optimization missing for SQL Server ?
Thanks