SlideShare a Scribd company logo
SQL SERVER IN MICROSOFT AZURE
VIRTUAL MACHINES – THE IMPORTANT
DETAILS
SCOTT KLEIN
SENIOR TECHNICAL EVANGELIST
MICROSOFT
THOMAS LAROCK
HEAD GEEK
SOLARWINDS
WHY ARE YOU HERE?
» You want to know more about Azure
» You have, or will have, SQL Server running on an Azure VM
» You want to know the important details regarding SQL Server in an Azure VM
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 2
A LITTLE ABOUT SCOTT…
Scott is a Senior Technical Evangelist for Microsoft
with over 20 years experience as a developer and
architect.
He is a frequent speaker at events around the world.
You can either find him on a plane in the clouds or
on the ground speaking about the Cloud.
scottkl@microsoft.com
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 3
A LITTLE ABOUT ME…
Thomas has over 15 years experience in roles
including programmer, developer, analyst, and DBA.
He is a frequent speaker, published author, and avid
blogger on data related technologies.
He enjoys working with data, probably too much to
be healthy, really.
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 4
A LITTLE ABOUT SOLARWINDS…
» Network Management
» System Management
» IT Security
» Database Management
» solarwinds.com/products
#Datachat
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 5
AGENDA
» Azure Blob Storage
» VM instance size and limits
» Types of Disks
» Disk Performance
» Virtual machine disk cache
» Best Practices
» Troubleshooting
» Disaster Recovery and High Availability
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 6
MICROSOFT AZURE BLOB STORAGE
» Two types of durable storage:
 Premium – SSDs -> high-performance, low-latency
 Standard – HDDs
» Run on the new flat network topology
» Disable geo-replication
http://tinyurl.com/azure-storage-scalability
Total Capacity Total Request Rate Total Bandwidth
(Geo-redundant)
Total Bandwidth
(Locally
Redundant)
500 TB 20,000 / sec 10 gb/sec Ingress
20 gb/sec Egress
20 gb/sec Ingress
30 gb/sec Egress
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 7
VIRTUAL MACHINE SIZE
» Basic Tier – Up to 8 cores, 14 GB, 240 GB Disk
 Economical option for dev workloads, test servers, apps that
don’t require load balancing or auto-scaling
» Standard Tier – Up to 16 Cores, 112 GB, 382 GB Disk
 Offer the most flexibility
» D Series - Up to 16 Cores, 112 GB, 800 GB Disk
 60% faster CPUs, more memory, and local SSD
» G Series – Up to 32 Cores, 448 GB, 6,500 GB Disk
 Extraordinary performance for demanding applications
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 8
DISKS
» OS Disk
 Size: (Gallery image: 127GB)
 Default caching is Read/Write
» Scratch Disk
 Used to store temporary data – data is NOT persisted on Microsoft
Azure Storage (may be wiped clean on VM reboot)
 Can store tempdb and/or BFE on D when using D-series or higher
» Data Disk(s)
 Data disk stored as VHD files inside a single page
 Persistent
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 9
DATA DISKS
» Number of disks: Add max number allowed by VM size.
» Caching Policy: None (default). Enable read with Premium storage.
» NTFS allocation: 64KB
» Disk Striping:
 Win8/Server2012, use Storage Spaces. Set stripe size to 64KB for OLTP and
256 KB for DW to avoid performance impact.
 Windows 2008R2 or earlier: use OS striped volumes.
» Data and Log Placement:
 If not an intensive workload, configure one storage pool
 Otherwise, place data and log files on separate disks or storage pools
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 10
DISK I/O PERFORMANCE PREDICTABILITY
» Azure Infrastructure Services is a shared, multi-tenant
service
» Where and when you provision your virtual machines
matters
» Maintenance operations have an affect
» Cost vs. Control
» Azure disks vs. local attached disks
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 11
VIRTUAL MACHINE DISK CACHE
 Two tier cache
 Most recently accessed data stored in RAM of the physical host
 This cache space is shared by virtual machines on the host.
 Less recently accessed data stored on the local hard disks of the
physical host
 There is a cache space reserved to each virtual machine OS
Disk and Data Disk based on the virtual machine size
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 12
VIRTUAL MACHINE DISK CACHE
» Purpose of Microsoft Azure VM disk cache
 Reduce transactions (hence costs) against Azure Storage
 Reduce disk IO latency when IO rate is low
 Improve boot time
» Support Cache Modes
Disk type Read Only Read Write None
OS Disk Supported Default Not Supported
Data Disks Supported Supported Default
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 13
SQL Best Practices
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 14
PLACEMENT OPTIONS FOR DATA FILES
Place database files across multiple data disks
Create a single volume on top of multiple data disks
Create multiple striped volumes, each with one or more data
disks based on specific I/O performance requirements
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 15
SYSTEM DATABASES
» Place on Data Disk
 Adjust the XEvent & Trace file paths, SQL Error log path, default
backup path, default database location.
» Three Reasons Why:
 Performance Variance – More IOPS from the OS disk or a data
disk. Performance of D drive is not predictable due to varying size.
 Configuration upon VM downtime – SQL Server service and file
placement
 Performance Bottleneck – Heavy use of D can introduce IOPS
constraints.
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 16
MICROSOFT AZURE VM SQL BEST PRACTICES
» Place user database files (data & log) on data disks; do
not change the default cache setting for data disk
» If the OS disk has to be used:
 Disable write cache (ReadOnly)
 Limit the DB size to 20 GB
» Avoid OS disk striping
 Use SQL striping instead – distribute data files evenly across all
the data disks
» Add more data disks when I/O bound
 Stop adding more disks if no longer gaining IOPs© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 17
TRADITIONAL SQL BEST PRACTICES
» Data page compression recommended for I/O bound
workloads
 Reduce IO
 CPU usage can increase through
» Enable instant file initialization
 Grant (Perform volume maintenance tasks) to SQL Server
 This helps restore and autogrow performance
» Don’t use autogrow, pre-allocate instead
» Disable autoshrink
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 18
DISK WARM-UP
» Warm up = “Priming the pump”
» Warm-up affect can result in reduced rate of throughput and
bandwidth
» Warm up will increase costs
» Warm up your disks before measuring performance
 After initializing the file by writing some bit pattern sequentially using
SQLIO for example, run any random IO workload with a high
outstanding I/O (to drive High IOPs) to warm-up the drive. (1 hour
should be sufficient)
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 19
APP DESIGN/DEPLOYMENT CONSIDERATIONS
» Moving to the cloud doesn’t solve app design issues
 Poor designs can (and will) get magnified!
» Performance baselining
 Bare metal, Hyper-V, third party hosting
 Hardware (CPU, memory, SSD?)
Understand the constraints of your workload!
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 20
PERFORMANCE MONITORING
» Define and monitor key SQL Server performance KPIs
 Maximum value for Process(SQLServ)% Processor Time
 Average value for Process(SQLServ)% Processor Time
 Maximum value for Processor(_Total)% Processor Time
 Average value for Processor(_Total)% Processor Time
 Maximum value for SQLServer:SQL StatisticsBatch Requests/sec
 Average value for SQLServer:SQL StatisticsBatch Requests/sec
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 21
KEY PERFORMANCE COUNTERS
Logical disk counter Typical storage term
Suggested actions in
Microsoft Azure virtual machine environment
Disk reads / second
Disk writes / second
IOPS Measure the number of I/O’s per second.
Consider adding more data disks in line with your IOPS
requirements.
Average disk sec / read
Average disk sec / write
Latency Measure disk latency.
Note: Numbers might vary; look at averages over time.
Average disk bytes / read
Average disk bytes / write
Block size Measure the size of I/O’s being issued.
Note: Larger I/O’s tend to have higher latency, such as those
associated with BACKUP/RESTORE.
Average / current disk
queue length
Outstanding or waiting
IOPS
Provides insight into the applications I/O pattern.
Disk read bytes/sec
Disk write bytes/sec
Throughput or aggregate
throughput
Measure of total disk throughput.
Note: Ideally, larger block scans should be able to heavily utilize
connection bandwidth (for example, your throughput can be higher
with a smaller number of larger IOPS).
Monitor along with information from sys.dm_io_virtual_file_stats© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 22
VM DASHBOARD
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 23
• Monitor tab for
storage account
• Enabled under the
configure tab
• VM read and write
to their VHDs using
GetBlob and
PutPage
commands
respectively
VM DASHBOARD
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 24
TROUBLESHOOTING - STORAGE ANALYTICS
LOGGING
» Enable monitoring of the blob service
 Minimal: only the aggregate value is available for each metric.
Recommended for ongoing monitoring
 Verbose: each metric can be filtered by the specific API of interest.
Recommended for troubleshooting and detailed analysis
» Aggregated data is placed inside the storage account
inside a hidden container called $logs
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 25
Disaster Recovery and
High Availability
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 26
THE NEED FOR DISASTER-RECOVERY
 An event can cause on-prem SQL Server to become
unavailable
• Temporarily (e.g. gateway failure)
• Permanently (e.g. flooding)
 A disaster recovery site is expensive
• Site rent + maintenance
• Hardware
• Operations
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 27
USING AZURE FOR DISASTER RECOVERY
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 28
redmond.corp.microsoft.com
uswest.internal.cloudapp.net
Windows Cluster
Availability Group
Virtual
Network
EXAMPLE OF AVAILABILITY GROUP SPANNING
ON-PREMISE AND AZURE
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 29
WHAT IS SUPPORTED
Technology SQL Server
Version
Zero Data Loss Scop
e
#
Secondaries
Automatic
Failover
Readable
Secondarie
s
Availability
Groups
SQL Server 2012 Yes*
(Sync Mode)
DB(s) 4 Yes
(w/ additional
cluster
member)**
Yes
Database
Mirroring
SQL Server 2008
R2
SQL Server 2012
Yes*
(High Safety
Mode)
DB 1 Yes
(w/
Witness)**
Limited
(database
snapshots)
Log
Shipping
SQL Server 2008
R2
SQL Server 2012
No DB N No Limited
(standby
state)
* Most customers use Async Mode (High Performance) to avoid impacting primary performance
**Async Mode only supports Force Failover to make DR (and potential data loss) a conscious decision
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 30
WHY?
AVAILABILITY GROUPS
 Provide additional benefits:
• Integrated HA/DR
• Offload Read workloads to Azure
• Connect reporting/BI apps
• Migrate apps and run against local secondaries
• Offload Backups to Azure
• A solution for policy compliance
 Remember it requires:
• Same Windows Domain
• Needs an Active Directory Domain Controller
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 31
AGENDA
» Azure Blob Storage
» VM instance size and limits
» Types of Disks
» Disk Performance
» Virtual machine disk cache
» Best Practices
» Troubleshooting
» Disaster Recovery and High Availability
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 32
FREE TRIAL
• Try Database Performance Analyzer FREE for 14 days
• Quickly identify root cause of issues that impact end-user response time
• See historical trends over days, months, and years
• Monitor on-premise, on VMware®, in the Cloud, including Amazon® AWS and Azure™
virtual machines
• Agentless architecture, safe to use in production
33
RESOLVE PERFORMANCE ISSUES QUICKLY
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED.
www.solarwinds.com/dpa-download/
Questions?
(NOW IS THE TIME TO ASK THEM)
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 34
Thank You!
The SOLARWINDS and SOLARWINDS & Design marks are the exclusive property of SolarWinds Worldwide, LLC, are registered with the U.S. Patent and Trademark Office, and
may be registered or pending registration in other countries. All other SolarWinds trademarks, service marks, and logos may be common law marks, registered or pending
registration in the United States or in other countries. All other trademarks mentioned herein are used for identification purposes only and may be or are trademarks or registered
trademarks of their respective companies.
© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 35

More Related Content

PDF
How to configure SQL Server like a pro
PDF
How to configure SQL Server for SSDs and VMs
PDF
Why new hardware may not make Oracle databases faster
PDF
The have no fear guide to virtualizing databases
PDF
How to fix IO problems for faster SQL Server performance
PDF
Why new hardware may not make SQL Server faster
PDF
Find and fix SQL Server performance problems faster
PPTX
SOUG_Deployment__Automation_DB
How to configure SQL Server like a pro
How to configure SQL Server for SSDs and VMs
Why new hardware may not make Oracle databases faster
The have no fear guide to virtualizing databases
How to fix IO problems for faster SQL Server performance
Why new hardware may not make SQL Server faster
Find and fix SQL Server performance problems faster
SOUG_Deployment__Automation_DB

What's hot (19)

PDF
VMworld 2014: Virtualizing Databases
PDF
SQL Server Best Practices - Install SQL Server like a boss (RELOADED)
PDF
Database as a Service on the Oracle Database Appliance Platform
PDF
VMworld 2013: How SRP Delivers More Than Power to Their Customers
PPTX
NGENSTOR_ODA_P2V_V5
PDF
High availability disaster recovery 101
PDF
OOW13: It's a solid state-world
PPTX
Hardware planning & sizing for sql server
PDF
VMworld 2014: Advanced SQL Server on vSphere Techniques and Best Practices
PDF
Best Practices of HA and Replication of PostgreSQL in Virtualized Environments
PDF
VMworld 2013: Just Because You Could, Doesn't Mean You Should: Lessons Learne...
PDF
Hadoop Operations for Production Systems (Strata NYC)
PDF
Hadoop Operations: Starting Out Small / So Your Cluster Isn't Yahoo-sized (yet)
PDF
Hadoop Operations at LinkedIn
PPTX
SQL Server Wait Types Everyone Should Know
PDF
Postgres Plus Cloud Database on OpenStack
PPTX
Storage and performance- Batch processing, Whiptail
PDF
PostgreSQL and Benchmarks
PDF
Distributed Caching Essential Lessons (Ts 1402)
VMworld 2014: Virtualizing Databases
SQL Server Best Practices - Install SQL Server like a boss (RELOADED)
Database as a Service on the Oracle Database Appliance Platform
VMworld 2013: How SRP Delivers More Than Power to Their Customers
NGENSTOR_ODA_P2V_V5
High availability disaster recovery 101
OOW13: It's a solid state-world
Hardware planning & sizing for sql server
VMworld 2014: Advanced SQL Server on vSphere Techniques and Best Practices
Best Practices of HA and Replication of PostgreSQL in Virtualized Environments
VMworld 2013: Just Because You Could, Doesn't Mean You Should: Lessons Learne...
Hadoop Operations for Production Systems (Strata NYC)
Hadoop Operations: Starting Out Small / So Your Cluster Isn't Yahoo-sized (yet)
Hadoop Operations at LinkedIn
SQL Server Wait Types Everyone Should Know
Postgres Plus Cloud Database on OpenStack
Storage and performance- Batch processing, Whiptail
PostgreSQL and Benchmarks
Distributed Caching Essential Lessons (Ts 1402)
Ad

Viewers also liked (20)

PPTX
Power BI: From the Basics
PPTX
Enterprise Cloud Data Platforms - with Microsoft Azure
PPTX
The Power of BI: A guided tour of Microsoft's Business Intelligence tooling
PPTX
20060416 Azure Boot Camp 2016- Azure Data Lake Storage and Analytics
PPTX
Microsoft Azure Batch
PDF
[JSS2015] Azure SQL Data Warehouse - Azure Data Lake
PPTX
Azure SQL DWH
PPTX
SQL Saturday #313 Rheinland - MapReduce in der Praxis
PDF
AnalyticsConf : Azure SQL Data Warehouse
PDF
Datawarehouse como servicio en azure (sqldw)
PPTX
Microsoft Azure Data Warehouse Overview
PDF
SQL Azure Data Warehouse - Silviu Niculita
PPTX
What are the Business Benefits of Microsoft Azure
PPTX
Machine learning with Spark
PPTX
Introducing Azure SQL Data Warehouse
PDF
Microsoft Azure Security Infographic
PPTX
Introducing Azure SQL Database
PPTX
Intorducing Big Data and Microsoft Azure
PDF
Cortana Analytics Workshop: Azure Data Lake
PPTX
Implement SQL Server on an Azure VM
Power BI: From the Basics
Enterprise Cloud Data Platforms - with Microsoft Azure
The Power of BI: A guided tour of Microsoft's Business Intelligence tooling
20060416 Azure Boot Camp 2016- Azure Data Lake Storage and Analytics
Microsoft Azure Batch
[JSS2015] Azure SQL Data Warehouse - Azure Data Lake
Azure SQL DWH
SQL Saturday #313 Rheinland - MapReduce in der Praxis
AnalyticsConf : Azure SQL Data Warehouse
Datawarehouse como servicio en azure (sqldw)
Microsoft Azure Data Warehouse Overview
SQL Azure Data Warehouse - Silviu Niculita
What are the Business Benefits of Microsoft Azure
Machine learning with Spark
Introducing Azure SQL Data Warehouse
Microsoft Azure Security Infographic
Introducing Azure SQL Database
Intorducing Big Data and Microsoft Azure
Cortana Analytics Workshop: Azure Data Lake
Implement SQL Server on an Azure VM
Ad

Similar to How to deploy SQL Server on an Microsoft Azure virtual machines (20)

PPTX
IaaS for DBAs in Azure
PDF
VMworld 2013: Enterprise Architecture Design for VMware Horizon View 5.2
PPTX
Silk_SQLSaturdayBatonRouge_kgorman_2024.pptx
PPTX
Azure Databases with IaaS
PPTX
How Do I Know My SQL & Virtual Environments Are Ready for SSD?
PPTX
Achieving maximum performance in microsoft vdi environments - Jeff Stokes
PDF
Preventing Possible PVS Performance Pain Points
PPTX
Evaluating Storage for VDI Projects
PPTX
Boston_sql_kegorman_highIO.pptx
PPTX
Biwug2402 SharePoint on Azure
PDF
Presentation architecting a cloud infrastructure
PDF
Presentation architecting a cloud infrastructure
PDF
HPC DAY 2017 | HPE Storage and Data Management for Big Data
PPTX
All about Azure workshop deck
PPTX
Architectural designs driving sql server performance and high availability
PPTX
Azure DBA with IaaS
PPTX
IMC Summit 2016 Breakout - Brian Bulkowski - NVMe, Storage Class Memory and O...
PDF
Application acceleration from the data storage perspective
PDF
cloudera Apache Kudu Updatable Analytical Storage for Modern Data Platform
PDF
VMworld 2013: Virtualizing Databases: Doing IT Right
IaaS for DBAs in Azure
VMworld 2013: Enterprise Architecture Design for VMware Horizon View 5.2
Silk_SQLSaturdayBatonRouge_kgorman_2024.pptx
Azure Databases with IaaS
How Do I Know My SQL & Virtual Environments Are Ready for SSD?
Achieving maximum performance in microsoft vdi environments - Jeff Stokes
Preventing Possible PVS Performance Pain Points
Evaluating Storage for VDI Projects
Boston_sql_kegorman_highIO.pptx
Biwug2402 SharePoint on Azure
Presentation architecting a cloud infrastructure
Presentation architecting a cloud infrastructure
HPC DAY 2017 | HPE Storage and Data Management for Big Data
All about Azure workshop deck
Architectural designs driving sql server performance and high availability
Azure DBA with IaaS
IMC Summit 2016 Breakout - Brian Bulkowski - NVMe, Storage Class Memory and O...
Application acceleration from the data storage perspective
cloudera Apache Kudu Updatable Analytical Storage for Modern Data Platform
VMworld 2013: Virtualizing Databases: Doing IT Right

More from SolarWinds (20)

PPTX
SolarWinds Government and Education Webinar: Greatest SolarWinds Features I N...
PPTX
SolarWinds Government and Education Webinar: Gaps Exist in Your Monitoring In...
PPTX
Government Webinar: Alerting and Reporting in the Age of Observability
PPTX
Government and Education Webinar: Full Stack Observability
PPTX
Government and Education Webinar: Public Sector Cybersecurity Survey - What I...
PPTX
Becoming Secure By Design: Questions You Should Ask Your Software Vendors
PPTX
Government and Education Webinar: Real-Time Mission, CIO, and Command Dashboards
PPTX
Government and Education Webinar: Simplify Your Database Performance Manageme...
PPTX
Government and Education Webinar: SolarWinds Orion Platform: Audit and Stream...
PPTX
Government and Education Webinar: Leverage Automation to Improve IT Operations
PPTX
Government and Education Webinar: Improving Application Performance
PPTX
Government and Education: IT Tools to Support Your Hybrid Workforce
PPTX
Government and Education Webinar: There's More Than One Way to Monitor SQL Da...
PPTX
SolarWinds Government and Education Webinar: Virtual Technology Briefing 08.0...
PPTX
Government and Education Webinar: Zero-Trust Panel Discussion
PPTX
Government and Education: Leveraging The SolarWinds Orion Assistance Program ...
PPTX
Government and Education Webinar: SQL Server—Advanced Performance Tuning
PPTX
Government and Education Webinar: Recovering IP Addresses on Your Network
PPTX
Government and Education Webinar: Optimize Performance With Advanced Host Mon...
PPTX
Government and Education Webinar: Conquering Remote Work IT Challenges
SolarWinds Government and Education Webinar: Greatest SolarWinds Features I N...
SolarWinds Government and Education Webinar: Gaps Exist in Your Monitoring In...
Government Webinar: Alerting and Reporting in the Age of Observability
Government and Education Webinar: Full Stack Observability
Government and Education Webinar: Public Sector Cybersecurity Survey - What I...
Becoming Secure By Design: Questions You Should Ask Your Software Vendors
Government and Education Webinar: Real-Time Mission, CIO, and Command Dashboards
Government and Education Webinar: Simplify Your Database Performance Manageme...
Government and Education Webinar: SolarWinds Orion Platform: Audit and Stream...
Government and Education Webinar: Leverage Automation to Improve IT Operations
Government and Education Webinar: Improving Application Performance
Government and Education: IT Tools to Support Your Hybrid Workforce
Government and Education Webinar: There's More Than One Way to Monitor SQL Da...
SolarWinds Government and Education Webinar: Virtual Technology Briefing 08.0...
Government and Education Webinar: Zero-Trust Panel Discussion
Government and Education: Leveraging The SolarWinds Orion Assistance Program ...
Government and Education Webinar: SQL Server—Advanced Performance Tuning
Government and Education Webinar: Recovering IP Addresses on Your Network
Government and Education Webinar: Optimize Performance With Advanced Host Mon...
Government and Education Webinar: Conquering Remote Work IT Challenges

Recently uploaded (20)

PDF
Modernizing your data center with Dell and AMD
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
Electronic commerce courselecture one. Pdf
PDF
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
PDF
Network Security Unit 5.pdf for BCA BBA.
PPT
Teaching material agriculture food technology
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
Review of recent advances in non-invasive hemoglobin estimation
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
DOCX
The AUB Centre for AI in Media Proposal.docx
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
cuic standard and advanced reporting.pdf
Modernizing your data center with Dell and AMD
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
Electronic commerce courselecture one. Pdf
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
Network Security Unit 5.pdf for BCA BBA.
Teaching material agriculture food technology
Diabetes mellitus diagnosis method based random forest with bat algorithm
Review of recent advances in non-invasive hemoglobin estimation
Unlocking AI with Model Context Protocol (MCP)
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Per capita expenditure prediction using model stacking based on satellite ima...
Dropbox Q2 2025 Financial Results & Investor Presentation
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
Advanced methodologies resolving dimensionality complications for autism neur...
The AUB Centre for AI in Media Proposal.docx
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Building Integrated photovoltaic BIPV_UPV.pdf
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
cuic standard and advanced reporting.pdf

How to deploy SQL Server on an Microsoft Azure virtual machines

  • 1. SQL SERVER IN MICROSOFT AZURE VIRTUAL MACHINES – THE IMPORTANT DETAILS SCOTT KLEIN SENIOR TECHNICAL EVANGELIST MICROSOFT THOMAS LAROCK HEAD GEEK SOLARWINDS
  • 2. WHY ARE YOU HERE? » You want to know more about Azure » You have, or will have, SQL Server running on an Azure VM » You want to know the important details regarding SQL Server in an Azure VM © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 2
  • 3. A LITTLE ABOUT SCOTT… Scott is a Senior Technical Evangelist for Microsoft with over 20 years experience as a developer and architect. He is a frequent speaker at events around the world. You can either find him on a plane in the clouds or on the ground speaking about the Cloud. scottkl@microsoft.com © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 3
  • 4. A LITTLE ABOUT ME… Thomas has over 15 years experience in roles including programmer, developer, analyst, and DBA. He is a frequent speaker, published author, and avid blogger on data related technologies. He enjoys working with data, probably too much to be healthy, really. © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 4
  • 5. A LITTLE ABOUT SOLARWINDS… » Network Management » System Management » IT Security » Database Management » solarwinds.com/products #Datachat © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 5
  • 6. AGENDA » Azure Blob Storage » VM instance size and limits » Types of Disks » Disk Performance » Virtual machine disk cache » Best Practices » Troubleshooting » Disaster Recovery and High Availability © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 6
  • 7. MICROSOFT AZURE BLOB STORAGE » Two types of durable storage:  Premium – SSDs -> high-performance, low-latency  Standard – HDDs » Run on the new flat network topology » Disable geo-replication http://tinyurl.com/azure-storage-scalability Total Capacity Total Request Rate Total Bandwidth (Geo-redundant) Total Bandwidth (Locally Redundant) 500 TB 20,000 / sec 10 gb/sec Ingress 20 gb/sec Egress 20 gb/sec Ingress 30 gb/sec Egress © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 7
  • 8. VIRTUAL MACHINE SIZE » Basic Tier – Up to 8 cores, 14 GB, 240 GB Disk  Economical option for dev workloads, test servers, apps that don’t require load balancing or auto-scaling » Standard Tier – Up to 16 Cores, 112 GB, 382 GB Disk  Offer the most flexibility » D Series - Up to 16 Cores, 112 GB, 800 GB Disk  60% faster CPUs, more memory, and local SSD » G Series – Up to 32 Cores, 448 GB, 6,500 GB Disk  Extraordinary performance for demanding applications © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 8
  • 9. DISKS » OS Disk  Size: (Gallery image: 127GB)  Default caching is Read/Write » Scratch Disk  Used to store temporary data – data is NOT persisted on Microsoft Azure Storage (may be wiped clean on VM reboot)  Can store tempdb and/or BFE on D when using D-series or higher » Data Disk(s)  Data disk stored as VHD files inside a single page  Persistent © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 9
  • 10. DATA DISKS » Number of disks: Add max number allowed by VM size. » Caching Policy: None (default). Enable read with Premium storage. » NTFS allocation: 64KB » Disk Striping:  Win8/Server2012, use Storage Spaces. Set stripe size to 64KB for OLTP and 256 KB for DW to avoid performance impact.  Windows 2008R2 or earlier: use OS striped volumes. » Data and Log Placement:  If not an intensive workload, configure one storage pool  Otherwise, place data and log files on separate disks or storage pools © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 10
  • 11. DISK I/O PERFORMANCE PREDICTABILITY » Azure Infrastructure Services is a shared, multi-tenant service » Where and when you provision your virtual machines matters » Maintenance operations have an affect » Cost vs. Control » Azure disks vs. local attached disks © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 11
  • 12. VIRTUAL MACHINE DISK CACHE  Two tier cache  Most recently accessed data stored in RAM of the physical host  This cache space is shared by virtual machines on the host.  Less recently accessed data stored on the local hard disks of the physical host  There is a cache space reserved to each virtual machine OS Disk and Data Disk based on the virtual machine size © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 12
  • 13. VIRTUAL MACHINE DISK CACHE » Purpose of Microsoft Azure VM disk cache  Reduce transactions (hence costs) against Azure Storage  Reduce disk IO latency when IO rate is low  Improve boot time » Support Cache Modes Disk type Read Only Read Write None OS Disk Supported Default Not Supported Data Disks Supported Supported Default © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 13
  • 14. SQL Best Practices © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 14
  • 15. PLACEMENT OPTIONS FOR DATA FILES Place database files across multiple data disks Create a single volume on top of multiple data disks Create multiple striped volumes, each with one or more data disks based on specific I/O performance requirements © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 15
  • 16. SYSTEM DATABASES » Place on Data Disk  Adjust the XEvent & Trace file paths, SQL Error log path, default backup path, default database location. » Three Reasons Why:  Performance Variance – More IOPS from the OS disk or a data disk. Performance of D drive is not predictable due to varying size.  Configuration upon VM downtime – SQL Server service and file placement  Performance Bottleneck – Heavy use of D can introduce IOPS constraints. © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 16
  • 17. MICROSOFT AZURE VM SQL BEST PRACTICES » Place user database files (data & log) on data disks; do not change the default cache setting for data disk » If the OS disk has to be used:  Disable write cache (ReadOnly)  Limit the DB size to 20 GB » Avoid OS disk striping  Use SQL striping instead – distribute data files evenly across all the data disks » Add more data disks when I/O bound  Stop adding more disks if no longer gaining IOPs© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 17
  • 18. TRADITIONAL SQL BEST PRACTICES » Data page compression recommended for I/O bound workloads  Reduce IO  CPU usage can increase through » Enable instant file initialization  Grant (Perform volume maintenance tasks) to SQL Server  This helps restore and autogrow performance » Don’t use autogrow, pre-allocate instead » Disable autoshrink © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 18
  • 19. DISK WARM-UP » Warm up = “Priming the pump” » Warm-up affect can result in reduced rate of throughput and bandwidth » Warm up will increase costs » Warm up your disks before measuring performance  After initializing the file by writing some bit pattern sequentially using SQLIO for example, run any random IO workload with a high outstanding I/O (to drive High IOPs) to warm-up the drive. (1 hour should be sufficient) © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 19
  • 20. APP DESIGN/DEPLOYMENT CONSIDERATIONS » Moving to the cloud doesn’t solve app design issues  Poor designs can (and will) get magnified! » Performance baselining  Bare metal, Hyper-V, third party hosting  Hardware (CPU, memory, SSD?) Understand the constraints of your workload! © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 20
  • 21. PERFORMANCE MONITORING » Define and monitor key SQL Server performance KPIs  Maximum value for Process(SQLServ)% Processor Time  Average value for Process(SQLServ)% Processor Time  Maximum value for Processor(_Total)% Processor Time  Average value for Processor(_Total)% Processor Time  Maximum value for SQLServer:SQL StatisticsBatch Requests/sec  Average value for SQLServer:SQL StatisticsBatch Requests/sec © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 21
  • 22. KEY PERFORMANCE COUNTERS Logical disk counter Typical storage term Suggested actions in Microsoft Azure virtual machine environment Disk reads / second Disk writes / second IOPS Measure the number of I/O’s per second. Consider adding more data disks in line with your IOPS requirements. Average disk sec / read Average disk sec / write Latency Measure disk latency. Note: Numbers might vary; look at averages over time. Average disk bytes / read Average disk bytes / write Block size Measure the size of I/O’s being issued. Note: Larger I/O’s tend to have higher latency, such as those associated with BACKUP/RESTORE. Average / current disk queue length Outstanding or waiting IOPS Provides insight into the applications I/O pattern. Disk read bytes/sec Disk write bytes/sec Throughput or aggregate throughput Measure of total disk throughput. Note: Ideally, larger block scans should be able to heavily utilize connection bandwidth (for example, your throughput can be higher with a smaller number of larger IOPS). Monitor along with information from sys.dm_io_virtual_file_stats© 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 22
  • 23. VM DASHBOARD © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 23
  • 24. • Monitor tab for storage account • Enabled under the configure tab • VM read and write to their VHDs using GetBlob and PutPage commands respectively VM DASHBOARD © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 24
  • 25. TROUBLESHOOTING - STORAGE ANALYTICS LOGGING » Enable monitoring of the blob service  Minimal: only the aggregate value is available for each metric. Recommended for ongoing monitoring  Verbose: each metric can be filtered by the specific API of interest. Recommended for troubleshooting and detailed analysis » Aggregated data is placed inside the storage account inside a hidden container called $logs © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 25
  • 26. Disaster Recovery and High Availability © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 26
  • 27. THE NEED FOR DISASTER-RECOVERY  An event can cause on-prem SQL Server to become unavailable • Temporarily (e.g. gateway failure) • Permanently (e.g. flooding)  A disaster recovery site is expensive • Site rent + maintenance • Hardware • Operations © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 27
  • 28. USING AZURE FOR DISASTER RECOVERY © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 28
  • 29. redmond.corp.microsoft.com uswest.internal.cloudapp.net Windows Cluster Availability Group Virtual Network EXAMPLE OF AVAILABILITY GROUP SPANNING ON-PREMISE AND AZURE © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 29
  • 30. WHAT IS SUPPORTED Technology SQL Server Version Zero Data Loss Scop e # Secondaries Automatic Failover Readable Secondarie s Availability Groups SQL Server 2012 Yes* (Sync Mode) DB(s) 4 Yes (w/ additional cluster member)** Yes Database Mirroring SQL Server 2008 R2 SQL Server 2012 Yes* (High Safety Mode) DB 1 Yes (w/ Witness)** Limited (database snapshots) Log Shipping SQL Server 2008 R2 SQL Server 2012 No DB N No Limited (standby state) * Most customers use Async Mode (High Performance) to avoid impacting primary performance **Async Mode only supports Force Failover to make DR (and potential data loss) a conscious decision © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 30
  • 31. WHY? AVAILABILITY GROUPS  Provide additional benefits: • Integrated HA/DR • Offload Read workloads to Azure • Connect reporting/BI apps • Migrate apps and run against local secondaries • Offload Backups to Azure • A solution for policy compliance  Remember it requires: • Same Windows Domain • Needs an Active Directory Domain Controller © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 31
  • 32. AGENDA » Azure Blob Storage » VM instance size and limits » Types of Disks » Disk Performance » Virtual machine disk cache » Best Practices » Troubleshooting » Disaster Recovery and High Availability © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 32
  • 33. FREE TRIAL • Try Database Performance Analyzer FREE for 14 days • Quickly identify root cause of issues that impact end-user response time • See historical trends over days, months, and years • Monitor on-premise, on VMware®, in the Cloud, including Amazon® AWS and Azure™ virtual machines • Agentless architecture, safe to use in production 33 RESOLVE PERFORMANCE ISSUES QUICKLY © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. www.solarwinds.com/dpa-download/
  • 34. Questions? (NOW IS THE TIME TO ASK THEM) © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 34
  • 35. Thank You! The SOLARWINDS and SOLARWINDS & Design marks are the exclusive property of SolarWinds Worldwide, LLC, are registered with the U.S. Patent and Trademark Office, and may be registered or pending registration in other countries. All other SolarWinds trademarks, service marks, and logos may be common law marks, registered or pending registration in the United States or in other countries. All other trademarks mentioned herein are used for identification purposes only and may be or are trademarks or registered trademarks of their respective companies. © 2015 SOLARWINDS WORLDWIDE, LLC. ALL RIGHTS RESERVED. 35