0% found this document useful (0 votes)
174 views48 pages

What To Use When: Azure Data and SQL Server

What To Use When

Uploaded by

MarianoKovo
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
174 views48 pages

What To Use When: Azure Data and SQL Server

What To Use When

Uploaded by

MarianoKovo
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 48

What to use When

Azure Data and SQL Server


Anna Hoffman, Data & Applied Scientist, Microsoft
Bob Ward, Principal Architect, Microsoft
You have Questions: We have Answers

Should I migrate to SQL Server 2019?


Is SQL Server the same on Linux?
What does SQL look like in a container or on Kubernetes?
Can anyone explain all the SQL options in the cloud?
Will I lose or gain anything if I move SQL to the cloud?
Do my skills still apply today?
SQL is the best

Edge to Cloud powered by the same Engine


Familiarity T-SQL is the common query language for the world
Performance proof points from ground to cloud

Familiar tools work across all SQL


Tools Languages for every developer
A platform for machine learning and big data

Develop online, offline, on-prem and in cloud


Flexibility Compatible across operating systems, containers and k8s
Get exactly what you need

© Microsoft Corporation
Azure
SQL is everywhere
SQL Server 2019 SQL on Linux SQL in containers SQL on Kubernetes

Best for modernizing your Best for a compatible SQL Best for portable, Best for database
databases in your private running on Linux consistent, and easy to containers at scale with
cloud patch SQL built-in HA

SQL virtual machines SQL managed instances SQL databases SQL Edge

Best for migrations and Best for most lift-and-shift Best for modern cloud Best for data and
applications requiring OS- migrations to the cloud. applications. Elastic pools, machine learning
level access Instance pool options are Hyperscale and Serverless applications on IOT Edge
available options are available
Challenges Solution
• Perf with no app changes


Reduce need for ETL
Integrate with Big Data
SQL Server 2019
• Increase confidential computing Best for modernizing databases in your private cloud
• Increased uptime
• Extend T-SQL • SQL Server Big Data Clusters
• Apps certified on a SQL release • Polybase for Data Virtualization
• Intelligent Query Processing
• Always Encrypted with Secure Enclaves
• Accelerated Database Recovery
• SQL Server Language Extensions

• Certify using latest SQL with Database Compatibility


• Boost performance 90+% with no code changes
• Database recovery in seconds
Customer example • Platform of choice with compatibility
• Integrate Java with security, isolation, governance
SQL Server 2019 solves modern data challenges
Data virtualization and Big Data Clusters Modern platforms with compatibility Built-in Machine Learning and extensibility

PolyBase
R
SQL
ARM64

Microsoft
SQL Server

Intelligent performance Layers of security and compliance Business critical high availability

Query ciphertext

Secure Enclaves
Learn Memory grant
In-memory
Data
plaintext
Run query Classification

Intelligent Query Processing Accelerated Database Recovery


SQL Server 2019 serves as the hub for all your data
Legacy SQL Azure SQL Azure
Server Database Cosmos DB

Legacy suppliers Mobile app


Modern stock items
orders

SQL Server
2019

Customers from
acquisition Accounts
Order reviews receivable

Intelligence over any data


Demo
SQL Server 2019
Challenges Solution
• Part of my company uses Linux


Desire consistent db in my company
I want the best of Linux with SQL
SQL Server on Linux
• I need a better price/perf db on Linux Best for a compatible SQL running on Linux

• Compatibility with SQL Windows using SQLPAL


• SQL Server 2019 has all the features you need
• Deployment and Configuration native to Linux
• Surface area, tools, and T-SQL the same

• Restore a database from Windows with no changes


• Run on Ubuntu, Red Hat Enterprise Linux, or SLES
• Deploy SQL Server fast with Linux package mgmt
Customer example • AD auth, HADR, Security integrated with Linux
• #1 TPC-H 3 and 10TB on Linux
The SQL Server Linux Story

System resource &


All other systems
latency sensitive code paths

RDBMS IS AS RS SQL Platform Abstraction Layer


(SQLPAL)

SQL Platform Abstraction Layer Win32-like APIs


SQL OS API
(SQLPAL)

Linux Host SQL OS v2


Windows Host Ext.
Extension

Windows Linux
Host extension mapping to OS system calls
(IO, Memory, CPU scheduling)

Choice across OS and containers


Linux loves packages
 Major Linux distributions follow the pattern
of using a package manager.
 RHEL: RPM and yum.
 Ubuntu: Debian and apt-get
 SUSE: RPM and zypper.

 Package: binaries + instructions to install.


 Benefits: dependency management, automatic
versioning, one-tool-to-rule-them-all,
architecture control.

mssql-
mssql-server- mssql-server- mssql-server-
mssql-server mssql-tools mssql-server-is extensibility-
fts ha polybase
java
Challenges Solution
• I want to stop using a Dev SQL Server


My devs use all OS platforms
I need superspeed deployment
SQL Server on Containers
• I need a fast way to patch SQL Best for portable, consistent, and easy to patch SQL
• Dedicated VM for SQL is heavy
• I have to keep the same performance • A consistent SQL image for all developers on any
OS
• Containers are isolated but share an OS
• Same surface area, tools, and T-SQL
• Deployment fast and integrated with your CI/CD

• 20M+ container image pulls


• Only way to easily run SQL on
• SQL Server pre-installed. deploy in seconds
Customer example • Patch SQL Server in < 1 min and roll it back
• Containers on Linux are an isolated process
• Multi-instance on Linux with containers
Why SQL Server Containers?
Portable Container configuration
Run anywhere containers are supported
Persisted storage
Lightweight
Reduced disk, CPU, and memory footprint
Database
Switch for
simple
Consistent updates
Consistent image of SQL Server, scripts, and tools

Efficient
Faster deployment, reduced patching, and
less downtime Container Container Container

Container Runtime
sqlservr sqlservr sqlservr
Bins/libs Bins/libs Bins/libs

Host OS

Infrastructure
Challenges Solution
• I need containers at scale


I need HA for database containers
I need containers in any cloud
SQL Server on Kubernetes
• Kubernetes is our preferred platform Best for database containers at scale with built-in HA
• I need to integrate Big Data with SQL
• I need an end-to-end ML platform • SQL Server containers natural for the k8s ecosystem
• k8s comes storage, networking, and resource mgmt
• k8s provides built-in basic HA
• k8s great fit for a complete container solution
• Same surface area, tools, and T-SQL

• Deploy SQL containers with k8s in any cloud


• Built-in HA for SQL no clustering software
• Integrate Big Data with SQL with Big Data Clusters
Customer example • Build end-to-end ML apps with Big Data Clusters
SQL Server - Shared storage HA in Kubernetes
Built-in HA orchestration with no clustering required

Node Node Node


Application

Load Balancer Service

Pod Pod
Kubernetes

SQL Server SQL Server

Pod

SQL Server

ReplicaSet

Persistent Volume Storage


SQL Server 2019 Big Data Clusters
The combination of SQL Server, Polybase, HDFS, Spark, and Machine Learning in one solution
Custom apps BI Analytics

Controller
Kubernetes
SQL Server master instance Availability Group Active Directory
PolyBase

Scale performance with compute pool Languages


App Deploy

SQL Compute Node SQL Compute Node … SQL Compute Node


Any external data source
PolyBase

Data lakes with storage pool

SQL SQL SQL Scale out data mart


Server Server … Server with Data pool

HDFS HDFS HDFS

HDFS HDFS HDFS HDFS tiering

Intelligence over any data


Demo
SQL Server on k8s
On-premises Hybrid
Single-tenant implementation Combination for private &
one or more public clouds
Owned and operated by
IT organization Allows IT organizations to
become brokers of services
Define your own data
management policies Self-service and automation
capabilities provide new agility
Azure SQL

SQL virtual machines Managed instances Databases

Best for migrations and Best for most lift-and-shift Best for modern cloud
applications requiring OS- migrations to the cloud applications. Hyperscale and
level access serverless options are available
Challenges Solution
• The contract on my hardware is


expiring
I have instances of SQL Server
Azure SQL virtual machines
2008 and 2008 R2 Best for migrations and applications requiring OS-level access
• I want to migrate to the cloud as
fast as possible • SQL Server and OS server access
• I use third party software that • Expansive SQL and OS version support
needs OS-level access • Full set of SQL Server features available
• I want to extend our on- • Automated manageability features for SQL Server
premises apps to Azure • Automatic security patching
• I need an unlimited number of • Point in time restore with Azure Backup
DBs

• Free Extended Security Updates for SQL Server


2008/R2*
• 435 percent overall return on an Azure IaaS
Customer example investment over five years (Forrester Consulting)
• GigaOm study shows up to 3.4 times faster and up
to 87 percent less expensive than AWS EC2
SQL Server on Azure VM
What is Resource Provider?
Resource Provider brings the functionality of Azure Marketplace images
to SQL Server instances self-installed on Azure Virtual Machines

Comprehensive Dashboard view for Simple license Straightforward


feature set VM awareness conversions compliance
Self-installed VMs registered Azure VMs are now Self-installed VMs with RP Self-installed VMs with RP
with RP now can access discoverable on the new Azure can be easily converted automatically indicate usage
automation features in SQL blade to PAYG images of Azure Hybrid Benefit
Azure Marketplace images in Azure Marketplace

Leverage auto-backup and Save money by converting Ensure compliance with


auto-patching to avoid Easily manage your SQL VM variable workloads with Software Azure terms and conditions
time-consuming admin and SQL PaaS deployments Assurance to PAYG images without any extra effort
and VM customization from one central location

Learn more aka.ms/sqlvm_rp and aka.ms/sqlvm_rp_documentation


Challenges Solution
• I want to migrate to Azure but


don’t need OS access
I want to reduce overhead and
Azure SQL managed instance
stress of maintain high Best for most lift-and-shift migrations to the cloud
availability.
• I need instance-scoped features • SQL Server surface area compatibility
like SQL Server Agent, • Fully managed Service
Transactional Replication, and • Native virtual network support
Database Mail • Instance pools for consolidation and fast deploy
• Azure Active Directory and AD Connect integration

• Near zero downtime migration using log-shipping


• Built-in replicas and failover groups
• Projected return on investment of 212 percent over
Customer example three years (Forrester Consulting)
• Combine the best of SQL Server with the benefits of
a managed service
Cross database transactions and Linked Servers

Change Data Capture

Database Mail

Azure SQL managed Resource Governor

instance Service Broker


Do you need any of
these? SQL Server Agent

SQL Server Auditing

Transactional Replication

Backup and Restore


Read-only reporting
Primary endpoint Read-only endpoint
(read-write)
 Read Scale-out
Always On AG
 Read-only replica
Super-fast SSD
 Free with SQL MI BC SQL SQL

Primary replica Secondary replica

SQL SQL

Secondary replica Secondary replica

Business Critical service tier: collocated compute and storage


Auto-failover groups with SQL managed instance
Capabilities
 Active / Standby
 <5sec RPO
 All databases in the instance are
automatically replicated
 Automatic or manual failover
 Read-write listener for read-write
database connections
 Read-only listener for read-intended
database connections
 Primary and secondary can be in
different Azure subscriptions

Scenarios
 Transparent recovery from outage
 Load-balancing read-only workloads
 Failback after outage is mitigated
Demo
Azure SQL managed instance
Demo: SQL managed instance
Challenges Solution
• I want to build a modern multi-


tenant SaaS app
I want to use a database with
Azure SQL Database
dedicated resources and Best for modern cloud applications
predictable performance
• I want to independently scale • Single database or elastic pool
compute and storage in my • Hyperscale storage (100TB+)
database • Serverless compute
• I want to have unlimited • Fully managed service
• Private link (preview)
databases storage when I need it
• High availability with AZ isolation
• I want to build a mission critical • Business continuity at scale
application with highest uptime
• I want to integrate Azure
services into my applications

• Industry highest availability SLA of 99.995%


• Industry only business continuity SLA with 5 second
RPO and 30 second RTO
Customer example • Price-performance leader for mission-critical
workloads while costing up to 86 percent less than
AWS RDS (GigaOm)
When is elastic pools the right choice?

Multiple databases with unpredictable


and intermittent usage patterns can be
consolidated into a single server and use
elastic pools for better price
optimization Elastic pools

Customer example
Challenges with sporadic or Azure SQL Database Serverless
unpredictable usage
CPU usage

4
Line of business apps
Expense reporting and employee tracking apps
Procurement systems

Number vCores
E-commerce Inactive Paused

Opening new marketplaces, marketing


campaigns, sales promotions
1

Dev/test workloads
Handling unpredictable workload needs 0

8:00

10:00

14:00
15:00
9:00

11:00

16:00
17:00

1:00

3:00
4:00
5:00

8:00
2:00

6:00
12:00
13:00

18:00
19:00
20:00
21:00
22:00
23:00
0:00

7:00
Min vcores Max vcores Vcores used Vcores billed
Challenges with managing Very Large Databases (VLDB)

Size of data Scaling Compute

Operations take a LONG time (days in some cases) Logistics of moving to larger box
Ongoing operations degrade database performance Economics of sizing for max peaks
Can cause outages and downtime
Provisioning more storage to expand the database
can be painful
Azure SQL DB Hyperscale
• Scalable new tiered storage architecture
• Architected for cloud

Compute • Fully compatible with Azure SQL


Database
• Scale compute and storage separately
• Scale up in constant time.
Page • Support for 100TB+ Infinite Log
Servers
• Supports 4 Read replicas
• Restore in constant time
• No impact of backups on compute
• No impact of checkpoints on compute
Remote
Data • Accelerated database recovery
Storage
Intelligent Database

Intelligent
In-memory Extended
Query Store Query
OLTP Events
Processing

Automatic Performance Azure SQL


Index Advisor
Tuning Dashboards Analytics

Query Advanced
Intelligent Vulnerability
Performance Threat
Insights Assessment
Insights Protection
Advanced Threat Detection
Detect unusual and harmful attempts to breach your database
Detects potential SQL
injection attacks

Detects unusual access &


Attacker
(2) Possible threat to
data exfiltration activities
access / breach data
User

Actionable alerts to
investigate & remediate

Apps Azure SQL Database

View alerts for your entire


Developer Azure tenant using Azure
Audit Log Threat Detection
(1) Turn on Threat Detection
(3) Real-time actionable alerts
Security Center
Demo
Intelligent Database
Azure SQL

SQL virtual machines Managed instances Databases

Best for migrations and Best for most lift-and-shift Best for modern cloud
applications requiring OS- migrations to the cloud applications. Hyperscale and
level access serverless options are available
Challenges Solution
• I need databases on the Edge


I need offline data on the Edge
I need to deploy ML on the Edge
Azure SQL Database Edge
• I use a range of devices Best for data and machine learning applications on IOT Edge
• I need cross-platform support
• I need easy integration with the • The power of SQL on Edge devices
cloud • Support for different processors
• I need the power of SQL • Time-Series and Steaming built-in
• SQL Server database and app compatibility

• < 500Mb footprint for the engine


• Most engine capabilities available
• Deploy with Azure IoT
Customer example • Disconnected, Semi-connected, and Connected
• Train models in the cloud and deploy on Edge
• SQL and Models can run offline and then connect
Azure SQL Database Edge Public Preview

Resource-light, optimized for Edge

Choice of platform Stream Analytics for IoT AI built-in Azure IoT Edge Integration

Streaming

SQL

Light weight SQL Engine Built-In Time-Series


<500 MB which can run Deploy Azure SQL Database Edge
Streaming and Analytics Train in the cloud and score at the Edge module from Azure IoT
on ARM or Intel devices

Local compute, storage, analytics all-in-one Develop Once, Deploy Anywhere for Your Apps

Edge Competitive TCO Data Center/Cloud


Azure Arc: Azure Data Services anywhere

Unified Elastic Always Cloud Unmatched


management scale current billing security

PREVIEW Azure SQL Database PREVIEW Azure Database for PostgreSQL


SQL is everywhere
SQL Server 2019 SQL on Linux SQL in containers SQL on Kubernetes

Best for modernizing your Best for a compatible SQL Best for portable, Best for database
databases in your private running on Linux consistent, and easy to containers at scale with
cloud patch SQL built-in HA

SQL virtual machines SQL managed instances SQL databases SQL Edge

Best for migrations and Best for most lift-and-shift Best for modern cloud Best for data and
applications requiring OS- migrations to the cloud. applications. Elastic pools, machine learning
level access Instance pool options are Hyperscale and Serverless applications on IOT Edge
available options are available
Demo
SQL is everywhere
Next Steps
 Deploy SQL Server 2019: https://aka.ms/ss19
 Get free SQL Server and Azure training at https://aka.ms/sqlworkshops
 Compare SQL and Azure at
https://docs.microsoft.com/en-us/azure/sql-database/sql-database-features
 Learn about SQL and Azure from Channel 9 Data Exposed
 Become an early adopter of Azure SQL Database Edge
Bonus Slides
SQL Database versus Managed Instance Instance

•  In SQL MI you control the instance. In SQL DB you do not.


• As a result a number of features are available in MI that are not in DB:
• E.g. SQL Server Agent, Linked Servers, Cross database transactions, Common Language Runtime, Resource
governor, SQL Server Auditing, Time zone choice, Service Broker, Collation on server / instance level
• Because you control the instance, a number of features are not in MI that are in DB:
• E.g. Auto-scale (serverless), Automatic tuning, Availability Zones, Azure Resource Health, SQL Data Sync, R
Services (in preview)
• For a detailed comparison see
https://docs.microsoft.com/en-us/azure/sql-database/sql-database-features

• Only a detailed analysis of requirements can tell you which is the best fit:

© Microsoft Corporation
Azure
SQL Server 2019 comparison to Azure SQL
Feature SQL Server 2019 Azure SQL

Intelligent Query Processing

Lightweight Query Profiling

In-Memory Database
*
Always Encrypted with Enclaves

Data Classification

Accelerated Database Recovery

UTF-8

Extensibility Framework *

PolyBase Data Virtualization

* In-Memory OLTP exists in both SQL Server and Azure


Hyperscale components

Read & Write Read Only

Compute
Stateless, Local SSD
Cache Log
Landing Zone
Service

Log Service
(Azure Premium Storage)

Log

Page Servers 
Destaging Log Cache
Local SSD Cache
Long Term Storage for PITR

Page Servers
(Azure Standard Storage)
Log

…..
Covering Covering

Local SSD Cache


Covering
RBPEX Data RBPEX Data RBPEX Data
Cache Cache Cache

1 TB data 1 TB data 1 TB data


file file file

Remote Data
…..
Storage
Data Pages Data Pages Data Pages

File Snapshots Azure Storage


File Snapshots File Snapshots

Azure Storage
© Microsoft Corporation
Azure
Hyperscale and Azure SQL DW

HS

SMP Hyperscale Real-time analytics/HTAP


SQL Server, Oracle…

MPP Azure SQL DW Big Data Analysis


APS, Teradata…
SQL Server on Azure VM

How to take advantage of Resource Provider


1. Register the resource provider to your subscription (one-time only) via the Azure Portal or Azure CLI below:  
# Register the new SQL resource provider to your subscription  
az provider register --namespace Microsoft.SqlVirtualMachine  

2. Once subscription registration is complete, register your VM with the SQL VM Resource Provider:
# Register your existing SQL Server VM with the new resource provider 
az sql vm create -n <VMName> -g <ResourceGroupName> -l <VMLocation> 

Ways to get Resource Provider*


Recommended approach

Full version Lightweight version


Get full access to auto-patching, Always On, auto-backup Speed your provision of Resource Provider with a lightweight
and other features. process which does not require restarting your VMs.

Note: Requires full SQL Server restart. Note: Does not enable full functionality.

Learn more aka.ms/sqlvm_rp and aka.ms/sqlvm_rp_documentation

*If you’re unable to select Full or Lightweight RP, choose an Agentless approach. Note this option does not enable verification of Resource Provider.

You might also like