Deploy Database to a Microsoft Azure VM
Create a Azure SQL Virtual Machine by logging on to https://manage.windowsazure.com
Click on [CREATE A VIRTUAL MACHINE]
Select the SQL Image
Select SQL Server from the Image list and choose the right SQL Server version you would like to deploy. I choose SQL Server 2012 Ent.Edition
Configure the VM, choose the correct size in regards to CPU and Memory
Select Location and Storage
Add Endpoints
Configure the Right extension for deployment and Security
Click OK to create the VM
Once the VM is created click on the VM
Click on the DASHBOARD .Select and copy the VM DNS
Download the Connect >< and download the RDP file to connect the Virtual Machine remotely.Once you logged into the server you need to make couple of changes mentioned below.
- Start the SQL Browser Services
- Configure inbound and outbound firewall rules
- Configure the SQL Server Instance to use Windows and SQL Authentication
- Restart SQL Server Services
- Create a SQL Server Account
Connect to Azure Virtual Machine SQL Instance from On-Premises SSMS
Connect to On-Premises SQL Instance andbackup the database to URL on Azure Storage
BACKUP DATABASE [AdventureWorks2014] TO URL = N'https://dbprox.blob.core.windows.net/dbproxstoragecontainer/AdventureWorks2014_backup_2015_11_10_175152.bak' WITH CREDENTIAL = N'AzureCredential' , NOFORMAT, NOINIT, NAME = N'AdventureWorks2014-Full Database Backup', NOSKIP, NOREWIND, NOUNLOAD, STATS = 10 GO
Login to Azure SQL VM
Connect to Azure SQL VM Instance.Right Click the Database folder and select Restore Database
Select option Device and choose Backup media type to URL.Click Add (Configure Storage account)
Click connect.After successful connection , SQL Server will open the Azure Containers
Click OK. SQL Server will read the backup device header from Azure Cloud Storage
Move the files and restore the database
Deploy Database to a Microsoft Azure VM using SSMS
Open SSMS On-Premises and Connect to the On-Premises SQL Instance.Right click the database , click tasks and choose Deploy Database to a Microsoft Azure VM
Connect to the Source SQL Instance and Select the database to move to Azure SQL VM
Choose the local location for backup files
Sign-in to Azure Account