carloscastilla - Fotolia

Manage Learn to apply best practices and optimize your operations.

How to provision a SQL Server virtual machine on Azure

Basit Farooq provides two different methods for provisioning a SQL Server virtual machine on Windows Azure. He also explains the benefits of the Windows Azure virtual machine and how to migrate from on-premises to Windows Azure.

Windows Azure virtual machines are hosted on the Microsoft public cloud environment and offer all the benefits of infrastructure as a service (IaaS). You can use Windows Azure Virtual Machines to run key server applications and workloads, such as Active Directory, SharePoint, SQL Server and most applications that can run on an on-premises virtual machine (VM) today.

To create a SQL Server virtual machine in Windows Azure, first get the Windows Azure Platform subscription. You can purchase a Windows Azure subscription the Microsoft Azure website.

Once you have the subscription, you can provision the SQL Server virtual machine in Windows Azure in one of the following three ways:

Using Windows Azure Management Portal integrated image gallery

The easiest way to provision a SQL Server virtual machine in Window Azure is to use the Windows Azure Management Portal integrated image gallery. The Windows Azure Management Portal image gallery comes with several pre-populated virtual machine templates, including Windows Server images, such as Windows Server 2012, Windows Server 2008 R2, SQL Server, BizTalk Server and SharePoint Server, and Linux images, such as Ubuntu, CentO and SUSE Linux distributions. Windows Azure Management Portal integrated image gallery includes the pre-populated virtual machine templates found in Figure 1.

Operating system SQL Server version SQL Server edition
Windows Server 2008 R2 SQL Server 2008 R2 Service Pack 2 Enterprise, Standard and Web
Windows Server 2012 SQL Server 2012 Service Pack 1 Enterprise, Standard, Web and Data Warehouse (Enterprise)
Windows Server 2012 R2 SQL Server 2014 and SQL Server 2014 for Data Warehousing Enterprise, Standard, Web and Data Warehouse (Enterprise)

Fig. 1: Pre-populated virtual machine templates available in the Windows Azure Management Portal integrated image gallery

For an up-to-date list of all the supported SQL Server versions and editions, log in to the Windows Azure Management Portal. Microsoft refreshes these pre-populated virtual machine templates every month. So every Service Pack or critical update is already included at the point of provisioning.  The end-to-end process of provisioning a SQL Server virtual machine on a Windows Azure platform using this method is approximately ten minutes.

Using your own custom-built VHD image

Another way to provision a SQL Server virtual machine in Window Azure is to use a custom-built VHD image to create the SQL Server virtual machine in Windows Azure. To do this, you can either create a new custom-built VHD image on-premises or take a copy of an existing on-premises VHD image and upload it to Windows Azure. You can provision multiple SQL Server virtual machines with that VHD image after it's been uploaded.

Migrating databases from an on-premises SQL Server to one running in a Windows Azure VM

You can use the Deploy a SQL Server Database to a Windows Azure VM wizard (Figure 2) in SQL Server 2014 Management Studio to migrate databases from an on-premises SQL Server instance to SQL Server running in a Windows Azure virtual machine. The wizard utilizes the full backup operation.  When you run this wizard, it takes the full backup of your user database to a network share and then copies it to Windows Azure blob storage. Then, it uses this backup to restore your user database to the SQL Server running in a Windows Azure virtual machine. The wizard does the entire Window Azure virtual machine configuration for you, so no pre-configuration is required. You can also use this wizard to migrate databases hosted in earlier versions of SQL Server. The wizard is compatible with SQL Server 2008, SQL Server 2008 R2, SQL Server 2012 and SQL Server 2014.

Fig. 2: The Deploy a SQL Server Database to a Windows Azure VM wizard in SQL Server 2014 Management Studio

For more information about this wizard, refer to "Deploy a SQL Server Database to a Windows Azure Virtual Machine."

Advantages of running SQL Server in a Windows Azure VM

Running your SQL Server virtual machines on a Windows Azure platform helps reduce infrastructure operating costs. This is because you are only responsible for managing the SQL Server and the cloud-based VM, while the Microsoft Azure team manages the underlying physical hardware, storage, virtualization and networking of the Windows Azure virtual machine.

Everyone wants to build and test applications using the latest version of SQL Server. With Windows Azure virtual machines, you can accelerate the development and testing phases of new database applications, since you can easily and quickly provision your SQL Server virtual machine on Windows Azure.

With SQL Server virtual machines on the Windows Azure platform, you can easily move on-premises SQL Server database applications to Windows Azure. The on-premises SQL Server database applications do not require major code changes when migrating to a SQL Server instance running on a Windows Azure VM.

You can add the SQL Server running on a Windows Azure VM as an AlwaysOn availability group replica node for your on-premises SQL Server. This improves on-premises SQL Server availability and can be used in disaster recovery situations when the on-premises SQL Server instance is down. You can also use the AlwaysOn secondary replicas to offload on-premises SQL Server reporting workloads and backups.

For further articles, tutorials,and videos to help you get started with SQL Server in Azure virtual machines, see SQL Server in Azure Virtual Machines.

Next Steps

Learn more about the tools at your disposal when you use Windows Azure

The Azure File Service may mean the end of setting up Windows Server virtual machines on the cloud

Take a look at some of the challenges of migrating your applications to the Azure cloud

This was last published in October 2014

Dig Deeper on Microsoft SQL Server Consolidation and Virtualization

Start the conversation

Send me notifications when other members comment.

By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Please create a username to comment.

-ADS BY GOOGLE

SearchBusinessAnalytics

SearchDataCenter

SearchDataManagement

SearchAWS

SearchOracle

SearchContentManagement

SearchWindowsServer

Close