Migrate an On-Premises Database to a Virtual Machine DB System

Simplify your database provisioning, maintenance, and management operations by moving your on-premises deployments of Oracle Database Standard Edition to Oracle Cloud Infrastructure.

Architecture

This architecture shows the resources and topology required to migrate an on-premises deployment of Oracle Database Standard Edition to a single-node, VM DB System in Oracle Cloud Infrastructure.

Description of migrate-vmdb.png follows
Description of the illustration migrate-vmdb.png

The architecture has the following components:

  • On-premises deployment

    The on-premises deployment includes an application server and an instance of Oracle Database Standard Edition on a 4-core Intel server. The database server is connected to a storage device. The on-premises network is connected to an Oracle Cloud region using IPSec VPN or FastConnect. The architecture assumes that the on-premises servers are running Oracle Linux.

  • Region

    An Oracle Cloud Infrastructure region is a localized geographic area that contains one or more data centers, called availability domains. Regions are independent of other regions, and vast distances can separate them (across countries or even continents).

  • Availability domains

    Availability domains are standalone, independent data centers within a region. The physical resources in each availability domain are isolated from the resources in the other availability domains, which provides fault tolerance. Availability domains don’t share infrastructure such as power or cooling, or the internal availability domain network. So, a failure at one availability domain is unlikely to affect the other availability domains in the region.

  • Fault domains

    A fault domain is a grouping of hardware and infrastructure within an availability domain. Each availability domain has three fault domains with independent power and hardware. When you distribute resources across multiple fault domains, your applications can tolerate physical server failure, system maintenance, and power failures inside a fault domain.

  • Virtual cloud network (VCN) and subnets

    A VCN is a customizable, software-defined network that you set up in an Oracle Cloud Infrastructure region. Like traditional data center networks, VCNs give you complete control over your network environment. A VCN can have multiple non-overlapping CIDR blocks that you can change after you create the VCN. You can segment a VCN into subnets, which can be scoped to a region or to an availability domain. Each subnet consists of a contiguous range of addresses that don't overlap with the other subnets in the VCN. You can change the size of a subnet after creation. A subnet can be public or private.

    In this architecture, the database and application tiers use separate subnets.

  • Route tables

    Virtual route tables contain rules to route traffic from subnets to destinations outside a VCN, typically through gateways.

    This architecture uses a route rule to send traffic from the database subnet to Oracle Cloud Infrastructure Object Storage through the service gateway. Another route rule sends traffic from the servers attached to the private subnets to the internet through the NAT gateway.

  • Security lists

    For each subnet, you can create security rules that specify the source, destination, and type of traffic that must be allowed in and out of the subnet.

    This architecture uses ingress and egress rules in the security lists attached to the application server and database subnets. These rules enable connectivity between the application and database. Ingress rules are temporarily added in the security lists attached to the application server and database server subnets during migration, for transferring application files, shell scripts, and configuration data.

  • Dynamic routing gateway (DRG)

    The DRG is a virtual router that provides a path for private network traffic between a VCN and a network outside the region, such as a VCN in another Oracle Cloud Infrastructure region, an on-premises network, or a network in another cloud provider.

  • Service gateway

    The service gateway provides access from a VCN to other services, such as Oracle Cloud Infrastructure Object Storage. The traffic from the VCN to the Oracle service travels over the Oracle network fabric and never traverses the internet.

  • NAT gateway

    The NAT gateway enables private resources in a VCN to access hosts on the internet, without exposing those resources to incoming internet connections.

  • Block volume

    With block storage volumes, you can create, attach, connect, and move storage volumes, and change volume performance to meet your storage, performance, and application requirements. After you attach and connect a volume to an instance, you can use the volume like a regular hard drive. You can also disconnect a volume and attach it to another instance without losing data.

  • Object storage

    Object storage provides quick access to large amounts of structured and unstructured data of any content type, including database backups, analytic data, and rich content such as images and videos. Use standard storage for "hot" storage that you need to access quickly, immediately, and frequently. Use archive storage for "cold" storage that you retain for long periods of time and seldom or rarely access.

  • Database system

    The on-premises database is migrated to a 4-core VM DB system running Oracle Database Standard Edition.

  • Application server

    The on-premises application server is migrated to a 4-core compute instance.

Recommendations

Your requirements might differ from the architecture described here. Use the following recommendations as a starting point.

  • Compute shapes

    This architecture uses an Oracle Linux compute instance with a VM.Standard2.4 shape for the application server. If the application needs more processing power, memory, or network bandwidth, then choose a larger shape.

  • Block volumes

    This architecture uses a 100-GB block volume for the application server. You can use the volume for installing the application, or to store application logs and data.

  • DB system shapes

    This architecture uses the VM.Standard2.4 shape for the DB system. Choose a larger shape if you need more processing power, memory, or network bandwidth.

  • VCN

    When you create a VCN, determine the number of CIDR blocks required and the size of each block based on the number of resources that you plan to attach to subnets in the VCN. Use CIDR blocks that are within the standard private IP address space.

    Select an address range that doesn’t overlap with your on-premises network, so that you can set up a connection between the VCN and your on-premises network using IPSec VPN or FastConnect.

    After you create a VCN, you can change, add, and remove its CIDR blocks.

    When you design the subnets, consider your traffic flow and security requirements. Attach all the resources within a specific tier or role to the same subnet, which can serve as a security boundary.

    Use regional subnets.

  • Database migration method

    In this reference architecture, the Oracle Database Cloud Backup module is used to back up an on-premises Oracle Standard Edition database to Oracle Cloud Infrastructure Object Storage. The backup is then used to create a VM DB system on Oracle Cloud Infrastructure.

    The migration process involves downloading the Oracle Database Cloud Backup module, installing it on the database server, and configuring RMAN to use an Oracle Cloud Infrastructure Object Storage bucket as the database backup target.

    This migration approach requires application downtime while backing up the database to the object storage bucket and restoring the database to a VM DB system on Oracle Cloud Infrastructure. You must also account for the time required to migrate the application server.

    Note:

    You can minimize or eliminate downtime by using Oracle Zero Downtime Migration (ZDM).

    Oracle recommends that you use the Oracle Cloud Infrastructure FastConnect service for migrating large databases to Oracle Cloud Infrastructure.

Considerations

  • Scalability
    • Application tier:

      You can scale the application servers vertically by changing the shape of the compute instances. A shape with a higher core count provides more memory and network bandwidth as well. If more storage is required, increase the size of the block volumes attached to the application server.

    • Database tier

      You can scale the database vertically by changing the shape of the VM DB system. The database is stopped and restarted using the new shape. You can scale the storage attached to a VM DB system up to 40 TB.

  • Availability

    Fault domains provide the best resilience for workloads deployed within a single availability domain. This architecture doesn’t show redundant resources, because the focus is on the migration approach. For high availability in the application tier, deploy the application servers in different fault domains, and use a load balancer to distribute client traffic across the application servers.

    For high availability of the database tier, you can deploy a 2-node RAC DB system. Such a deployment requires a minimum cloud subscription of four cores of Oracle Database Enterprise Edition - Extreme Performance.

  • Cost

    Select the compute and database shapes based on the cores, memory, and network bandwidth that your applications and databases need. You can start with 4-core shape for the application server and a 4-core shape for the database. If you need more performance, memory, or network bandwidth, you can change to a larger shape later.

Deploy

To deploy this reference architecture, create the required resources in Oracle Cloud Infrastructure, and then migrate the on-premises database by using the Oracle Database Cloud Backup module.

  1. Create the required resources in Oracle Cloud Infrastructure.

    The Terraform code to deploy the resources in the cloud is available on GitHub. Use the code to provision the networking resources, a compute instance that you can use as the bastion or for the application server, and a virtual machine DB system.

    You can pull the code into Oracle Cloud Infrastructure Resource Manager with a single click, create the stack, and deploy it. Alternatively, download the code from GitHub to your computer, customize the code, and deploy the architecture by using the Terraform CLI.

    • Deploy the cloud resources by using Oracle Cloud Infrastructure Resource Manager:
      1. Click Deploy to Oracle Cloud

        If you aren't already signed in, enter the tenancy and user credentials.

      2. Review and accept the terms and conditions.
      3. Select the region where you want to deploy the stack.
      4. Follow the on-screen prompts and instructions to create the stack.
      5. After creating the stack, click Terraform Actions, and select Plan.
      6. Wait for the job to be completed, and review the plan.

        To make any changes, return to the Stack Details page, click Edit Stack, and make the required changes. Then, run the Plan action again.

      7. If no further changes are necessary, return to the Stack Details page, click Terraform Actions, and select Apply.
    • Deploy the cloud resources by using the Terraform CLI:
      1. Go to GitHub.
      2. Download the code to your local computer.
      3. Complete the prerequisite steps described in the README.
      4. Apply the configuration using the Terraform CLI.
  2. Migrate the on-premises database by using the Oracle Database Cloud Backup module.

Explore More

Learn more about migrating on-premises databases to the cloud.

Change Log

This log lists only the significant changes: