Skip to main content

Migration Of MS SQL From Azure VM To Amazon RDS

who is using Azure Cloud for their application and Microsoft SQL server is hosted on a virtual machine. Soon, they found the need to migrate the application from Azure to AWS due to some amazing features and services of it which would be very helpful to enhance the app & it’s functionalities.

So, in order to do that, my client decided to migrate the Database from VM to Amazon RDS to release the burden of its management along with all the related tasks too. It’s quite difficult to manage a database on a VM. Also, Amazon RDS is a fully managed service & a better platform for running relational databases on Amazon Web Services (AWS).

Migration Of MS SQL From Azure VM To Amazon RDS

In this blog, we will do hands on of migrating Microsoft SQL server from Azure VM to Amazon RDS by using AWS Database Migration Service with minimal downtime.

To know more about AWS DMS you may follow the link below : Database Migration Service in AWS

Prerequisites

1. Azure VM With MS SQL Installed , follow the below link for the same.

https://discourse.ubuntu.com/t/microsoft-sql-server-2019-on-ubuntu-20-04/21943 )

https://learn.microsoft.com/en-us/azure/virtual-machines/linux/quick-create-portal?tabs=ubuntu )

This Azure VM With Microsoft SQL Server Installed & In Running State

Install the command line tools to interact with it

2. Site To Site VPN Established Connection Among Both Clouds

https://www.netreo.com/blog/connect-azure-using-vpn-gateway-to-aws-vpc/

3. MS SQL Database ( Target ) within Amazon RDS. Create by following this link https://aws.amazon.com/getting-started/hands-on/create-mysql-db/

Let’s get Our hands dirty here

Create a Replication Instance

Open the AWS Console, search for Database Migration Service and choose Replication Instances from the navigation pane. Then choose to “Create a replication instance”, provide the required details as shown below.

Here provide all the required values in the respective fields as shown below

Select the same VPC in which you have RDS instance for the replication instance as well , in order to keep seamless connectivity throughout the process.

Select the same Availability Zone for Replication Instance as in RDS Instance, Security Group

After you click on the “Create replication instance” button, AWS provisions your replication instance. When your replication instance is ready to run, its status is “Available”, as shown.

Note: Go to the Security Groups section in the Amazon EC2 console & Azure VM. You need to check whether your security group allows your replication instance to access your RDS target database and Source database. Set the rule accordingly.

[Good Read: AWS Direct Connect – A Dedicated Gateway for Migration Solution]

Creating Target and Source Endpoints

Target endpoint

First, create the endpoint for your target database. Navigate to the Endpoints section of the AWS DMS console. Choose “Create endpoint” to create a new endpoint, as shown here.

Select the Target Database created in Amazon RDS.

Enter the following values for the target endpoint, as shown , in the “Username and password” boxes; enter “Username and password” of the target database that you will connect to.

Click on the “Run test” button to test the target endpoint. After a few seconds, you should see a Status of successful. After seeing the status value is “successful”, click on the “Create endpoint” button .

We have successfully created target endpoint now

Source endpoint

Follow these same steps again to create an endpoint for your source database, as shown . 

Note : In Server Name We Have To Mention Private IP Of The Azure VM i.e Source Database

Connection Has Been Established Successfully Between Source Database & Replication Instance

Now we have both target and source database endpoints to move further in the process as shown above

Creating a Migration Task

A migration task is responsible for migrating data from a source database to a target database. In order to start, navigate to the Database migration tasks section of the AWS DMS console. Choose “Create task” to create a new Database migration task, as shown below.

Choose the source endpoint for your database in Azure VM ( for me, source azure) and your target endpoint that we have just created in Amazon RDS ( for me, “database-target”).

In the “Migration type” section; select the “Migrate existing data” to perform a one-time process to copy data from your source database to your target database. Use migration type one-time migrations. 

You can check more info:


Comments

Popular posts from this blog

Containerization vs Virtualization: Explore the Difference!

  In today’s world, technology has become an integral part of our daily lives, and the way we work has been greatly revolutionized by the rise of cloud computing. One of the critical aspects of cloud computing is the ability to run applications and services in a virtualized environment. However, with the emergence of new technologies and trends, there are two popular approaches that have emerged, containerization and virtualization, and it can be confusing to understand the difference between the two. In this blog on Containerization vs Virtualization, we’ll explore what virtualization and containerization are, the key difference between virtualization and containerization, and the use cases they are best suited for. By the end of this article, you should have a better understanding of the two technologies and be able to make an informed decision on which one is right for your business needs. Here, we’ll discuss, –  What is Containerization? –  What is Virtualization? – Benefits of Con

Step-by-Step Guide to Cloud Migration With DevOps

This successful adoption of cloud technologies is attributed to scalability, security, faster time to market, and team collaboration benefits it offers. With this number increasing rapidly among companies at all levels, organizations are  looking forward to the methods that help them: Eliminate platform complexities Reduce information leakage Minimize cloud operation costs To materialize these elements, organizations are actively turning to DevOps culture that helps them integrate development and operations processes to automate and optimize the complete software development lifecycle. In this blog post, we will discuss the step-by-step approach to cloud migration with DevOps. Steps to Perform Cloud Migration With DevOps Approach Automation, teamwork, and ongoing feedback are all facilitated by the DevOps culture in the cloud migration process. This translates into cloud environments that are continuously optimized to support your business goals and enable faster, more seamless migrat

Migration Of MS SQL From Azure VM To Amazon RDS

The MongoDB operator is a custom CRD-based operator inside Kubernetes to create, manage, and auto-heal MongoDB setup. It helps in providing different types of MongoDB setup on Kubernetes like-  standalone, replicated, and sharded.  There are quite amazing features we have introduced inside the operator and some are in-pipeline on which deployment is going on. Some of the MongoDB operator features are:- Standalone and replicated cluster setup Failover and recovery of MongoDB nodes Inbuilt monitoring support for Prometheus using MongoDB Exporter. Different Kubernetes-related best practices like:- Affinity, Pod Disruption Budget, Resource management, etc, are also part of it. Insightful and detailed monitoring dashboards for Grafana. Custom MongoDB configuration support. [Good Read:  Migration Of MS SQL From Azure VM To Amazon RDS  ] Other than this, there are a lot of features are in the backlog on which active development is happening. For example:- Backup and Restore support TLS encryp