AWS DRS Now Supports EBS Multi-AZ Volumes, So I Tried It Out

AWS DRS Now Supports EBS Multi-AZ Volumes, So I Tried It Out

AWS Elastic Disaster Recovery can now replicate EBS Multi-AZ volumes. After a planned failover and failback, replication returned to CONTINUOUS on the same source server, and data written in each AZ was readable in the Osaka drill.
2026.12.03

This page has been translated by machine translation. View original

Introduction

On November 30, 2026, it was announced that AWS Elastic Disaster Recovery (AWS DRS) now supports Amazon EBS Multi-AZ volumes.

https://aws.amazon.com/about-aws/whats-new/2026/11/aws-drs-supports-ebs-multi-az/

An EBS Multi-AZ volume is a volume that synchronously replicates all writes to two AZs in the same Region.

In this article, using an EC2 instance with an EBS Multi-AZ volume, I performed a planned failover and failback by stopping the instance normally, and confirmed that AWS DRS replication continues.

Test Environment

Hereafter, the instance in ap-northeast-1a is called the "source" and the instance in ap-northeast-1d is called the "standby".

  • Replication source: Tokyo (ap-northeast-1)
    • Active AZ of the volume: ap-northeast-1a (apne1-az4)
    • Standby AZ of the volume: ap-northeast-1d (apne1-az2)
  • Replication destination: Osaka (ap-northeast-3)
  • Instances: t3.small (Nitro), 2 instances
    • Source (1a)
    • Standby (1d)
  • AMI: Amazon Linux 2023 kernel 6.12 (SSM parameter /aws/service/ami-amazon-linux-latest/al2023-ami-kernel-6.12-x86_64)
  • Kernel: 6.12.115
  • Volume: root volume only (gp3 8 GiB EBS Multi-AZ volume)
  • AWS Replication Agent: 6.47.24.2026.324.0109
  • Recovery points: 3 rules, every 10 minutes, every hour, and every day

Preparation

The requirements and installation steps are summarized in the AWS DRS User Guide.

https://docs.aws.amazon.com/drs/latest/userguide/ebs-multi-az.html

I created an instance profile and prepared two instances in Tokyo, the source and the standby.

Instance Profile

Attach an instance profile with AWSElasticDisasterRecoveryEc2InstancePolicy attached to both the source and the standby. The instance profile does not move with the volume failover, so attach it to the standby before the failover as well.

In addition to the policy for AWS DRS, I also attached AmazonSSMManagedInstanceCore so that I could operate the instances with SSM.

aws iam create-role --role-name devio-drs-ec2-role --assume-role-policy-document file://ec2-trust.json
aws iam attach-role-policy --role-name devio-drs-ec2-role --policy-arn arn:aws:iam::aws:policy/service-role/AWSElasticDisasterRecoveryEc2InstancePolicy
aws iam attach-role-policy --role-name devio-drs-ec2-role --policy-arn arn:aws:iam::aws:policy/AmazonSSMManagedInstanceCore
aws iam create-instance-profile --instance-profile-name devio-drs-ec2-profile
aws iam add-role-to-instance-profile --instance-profile-name devio-drs-ec2-profile --role-name devio-drs-ec2-role
ec2-trust.json
{"Version":"2012-10-17","Statement":[{"Effect":"Allow","Principal":{"Service":"ec2.amazonaws.com"},"Action":"sts:AssumeRole"}]}

Source Instance

When specifying the standby AZ in the block device mapping and when running failover-volumes, you specify the AZ ID. You can check the mapping between AZ names and AZ IDs with the following command.

aws ec2 describe-availability-zones --region ap-northeast-1 --query 'AvailabilityZones[].[ZoneName,ZoneId]' --output text

To make the root volume an EBS Multi-AZ volume, I saved the following block device mapping as bdm-multi-az-root.json.

[
  {
    "DeviceName": "/dev/xvda",
    "Ebs": {
      "VolumeSize": 8,
      "VolumeType": "gp3",
      "DeleteOnTermination": false,
      "MultiAvailabilityZoneConfiguration": {
        "ConfigurationType": "multi-az-1",
        "StandbyAvailabilityZones": [
          { "AvailabilityZoneId": "apne1-az2" }
        ]
      }
    }
  }
]

I passed this file and launched the source in a subnet in ap-northeast-1a. <ami-id> is the AMI pointed to by the SSM parameter listed in the test environment.

aws ec2 run-instances --region ap-northeast-1 --image-id <ami-id> --instance-type t3.small --subnet-id <subnet-1a> --iam-instance-profile Name=devio-drs-ec2-profile --block-device-mappings file://bdm-multi-az-root.json --metadata-options HttpTokens=required

Installing the agent

Install the agent with --multi-az-enabled-volumes. With this option, the installation succeeds only if registration as Multi-AZ-enabled succeeds. The credentials of the instance profile are used instead of access keys.

sudo ./aws-replication-installer-init --region ap-northeast-3 --no-prompt --multi-az-enabled-volumes

After installation, I checked with multiAzEnabledType whether the source server had been registered as Multi-AZ-enabled.

aws drs describe-source-servers --region ap-northeast-3 --filters '{"sourceServerIDs": ["<source-server-id>"]}' --query 'items[0].multiAzEnabledType' --output json
"MULTI_AZ_ENABLED_VOLUME"
Script used for installation on Amazon Linux 2023 t3.small (install-agent.sh)

In this AMI, the kernel header package name is kernel6.12-devel-$(uname -r). /tmp is a tmpfs of about 955 MB, which does not have enough capacity to extract the installer. Therefore, before installation, I bind-mounted a directory on the disk onto /tmp.

#!/bin/bash
set -ex
uname -r
dnf install -y kernel6.12-devel-$(uname -r) gcc make elfutils-libelf-devel
mkdir -p /var/tmp/drs-install-tmp && chmod 1777 /var/tmp/drs-install-tmp
mount --bind /var/tmp/drs-install-tmp /tmp
cd /root
curl -fsSo aws-replication-installer-init https://aws-elastic-disaster-recovery-ap-northeast-3.s3.ap-northeast-3.amazonaws.com/latest/linux/aws-replication-installer-init
chmod +x aws-replication-installer-init
./aws-replication-installer-init --region ap-northeast-3 --no-prompt --multi-az-enabled-volumes

Standby Instance

For the standby, I first launched an instance in ap-northeast-1d with a temporary root volume, stopped it, and then detached the temporary root volume. After that, I attached the EBS Multi-AZ volume, which is the source's root volume, as /dev/xvda.

aws ec2 run-instances --region ap-northeast-1 --image-id <ami-id> --instance-type t3.small --subnet-id <subnet-1d> --iam-instance-profile Name=devio-drs-ec2-profile --metadata-options HttpTokens=required
aws ec2 stop-instances --region ap-northeast-1 --instance-ids <standby-instance-id>
aws ec2 detach-volume --region ap-northeast-1 --volume-id <temp-root-volume-id>
aws ec2 attach-volume --region ap-northeast-1 --volume-id <volume-id> --instance-id <standby-instance-id> --device /dev/xvda

After attaching, I ran describe-volumes.

aws ec2 describe-volumes --region ap-northeast-1 --volume-ids <volume-id> --query 'Volumes[0].[AvailabilityZone,MultiAvailabilityZoneConfiguration.StandbyAvailabilityZones[0].AvailabilityZone,Attachments[].[InstanceId,AvailabilityZone,State]]' --output json
[
    "ap-northeast-1a",
    "ap-northeast-1d",
    [
        [
            "<standby-instance-id>",
            "ap-northeast-1d",
            "attached"
        ],
        [
            "<source-instance-id>",
            "ap-northeast-1a",
            "attached"
        ]
    ]
]

Verification

Verification Method

At each stage, I ran the following describe-source-servers. The values obtained were awsInstanceID, originAvailabilityZone, and dataReplicationState. awsInstanceID and originAvailabilityZone indicate the instance and AZ that are sending the replication.

aws drs describe-source-servers --region ap-northeast-3 --filters '{"sourceServerIDs": ["<source-server-id>"]}' --query 'items[0].[sourceProperties.identificationHints.awsInstanceID, sourceCloudProperties.originAvailabilityZone, dataReplicationInfo.dataReplicationState]'

To confirm whether the data reached Osaka, I wrote markers to the root file system and finally read them in a drill in Osaka. There are three markers, from /var/devio-marker-M1.txt to /var/devio-marker-M3.txt.

Initial Sync

After dataReplicationState became CONTINUOUS, I wrote marker M1 on the source. In the Tokyo Region, I used AWS-RunShellScript in SSM and ran the following. Because both tee and the final cat produce output, the same line is displayed twice.

echo "M1 tokyo-1a $(date -u +%FT%TZ) $(hostname)" | tee /var/devio-marker-M1.txt
sync
cat /var/devio-marker-M1.txt
M1 tokyo-1a 2026-12-02T15:14:25Z ip-172-31-xx-xx.ap-northeast-1.compute.internal
M1 tokyo-1a 2026-12-02T15:14:25Z ip-172-31-xx-xx.ap-northeast-1.compute.internal

Failover

I stopped the source normally, moved the active AZ to ap-northeast-1d with failover-volumes, and then started the standby. For --source-active-availability-zone-id, pass the AZ ID of the AZ that was active before the move.

aws ec2 stop-instances --region ap-northeast-1 --instance-ids <source-instance-id>
aws ec2 failover-volumes --region ap-northeast-1 --instance-id <source-instance-id> --source-active-availability-zone-id apne1-az4
aws ec2 start-instances --region ap-northeast-1 --instance-ids <standby-instance-id>
{
    "VolumeFailovers": [
        {
            "VolumeId": "<volume-id>",
            "SourceActiveAvailabilityZone": "ap-northeast-1a",
            "SourceActiveAvailabilityZoneId": "apne1-az4",
            "SourceStandbyAvailabilityZones": [
                {
                    "AvailabilityZone": "ap-northeast-1d",
                    "AvailabilityZoneId": "apne1-az2"
                }
            ],
            "TargetActiveAvailabilityZone": "ap-northeast-1d",
            "TargetActiveAvailabilityZoneId": "apne1-az2",
            "TargetStandbyAvailabilityZones": [
                {
                    "AvailabilityZone": "ap-northeast-1a",
                    "AvailabilityZoneId": "apne1-az4"
                }
            ]
        }
    ]
}

The agent on the standby connected to the same source server. After awsInstanceID switched to the standby's instance ID, dataReplicationState went through RESCAN and BACKLOG and returned to CONTINUOUS. The root volume is 8 GiB, and it took about 2 minutes from RESCAN to return to CONTINUOUS.

After it returned to CONTINUOUS, I read M1 and wrote M2 on the standby.

cat /var/devio-marker-M1.txt
echo "M2 tokyo-1d $(date -u +%FT%TZ) $(hostname) $(curl -s -H "X-aws-ec2-metadata-token: $(curl -s -X PUT http://169.254.169.254/latest/api/token -H X-aws-ec2-metadata-token-ttl-seconds:60)" http://169.254.169.254/latest/meta-data/placement/availability-zone)" | tee /var/devio-marker-M2.txt
sync
cat /var/devio-marker-M2.txt
M1 tokyo-1a 2026-12-02T15:14:25Z ip-172-31-xx-xx.ap-northeast-1.compute.internal
M2 tokyo-1d 2026-12-02T15:23:57Z ip-172-31-xx-xx.ap-northeast-1.compute.internal ap-northeast-1d
M2 tokyo-1d 2026-12-02T15:23:57Z ip-172-31-xx-xx.ap-northeast-1.compute.internal ap-northeast-1d

Failback

I stopped the standby normally, returned the active AZ to ap-northeast-1a with failover-volumes, and then started the source.

aws ec2 stop-instances --region ap-northeast-1 --instance-ids <standby-instance-id>
aws ec2 failover-volumes --region ap-northeast-1 --instance-id <standby-instance-id> --source-active-availability-zone-id apne1-az2
aws ec2 start-instances --region ap-northeast-1 --instance-ids <source-instance-id>

As with the failover, dataReplicationState went through RESCAN and BACKLOG and returned to CONTINUOUS. It took about 2 minutes from RESCAN to CONTINUOUS.

On the source after the failback, I read M1 and M2 and wrote M3.

cat /var/devio-marker-M1.txt /var/devio-marker-M2.txt
echo "M3 tokyo-1a $(date -u +%FT%TZ) $(hostname) $(curl -s -H "X-aws-ec2-metadata-token: $(curl -s -X PUT http://169.254.169.254/latest/api/token -H X-aws-ec2-metadata-token-ttl-seconds:60)" http://169.254.169.254/latest/meta-data/placement/availability-zone)" | tee /var/devio-marker-M3.txt
sync
cat /var/devio-marker-M3.txt
M1 tokyo-1a 2026-12-02T15:14:25Z ip-172-31-xx-xx.ap-northeast-1.compute.internal
M2 tokyo-1d 2026-12-02T15:23:57Z ip-172-31-xx-xx.ap-northeast-1.compute.internal ap-northeast-1d
M3 tokyo-1a 2026-12-02T15:28:35Z ip-172-31-xx-xx.ap-northeast-1.compute.internal ap-northeast-1a
M3 tokyo-1a 2026-12-02T15:28:35Z ip-172-31-xx-xx.ap-northeast-1.compute.internal ap-northeast-1a

Replication State at Each Stage

The following table shows the values obtained for the same source server at three stages.

Stage awsInstanceID originAvailabilityZone dataReplicationState
After initial sync (before M1) <source-instance-id> ap-northeast-1a CONTINUOUS
After failover <standby-instance-id> ap-northeast-1d CONTINUOUS
After failback <source-instance-id> ap-northeast-1a CONTINUOUS

Drill in Osaka

I specified the recovery point obtained after writing M3 (2026-12-02T15:47:39Z) and launched a drill in Osaka.

aws drs start-recovery --region ap-northeast-3 --is-drill --source-servers sourceServerID=<source-server-id>,recoverySnapshotID=<recovery-snapshot-id>

The job became COMPLETED, and launchStatus was LAUNCHED. On the drill instance, I ran the following.

hostname
ls -l /var/devio-marker-M*.txt
for f in /var/devio-marker-M1.txt /var/devio-marker-M2.txt /var/devio-marker-M3.txt; do echo "== $f"; cat $f; done
ip-172-31-xx-xx.ap-northeast-3.compute.internal
-rw-r--r--. 1 root root 81 Dec  2 15:14 /var/devio-marker-M1.txt
-rw-r--r--. 1 root root 98 Dec  2 15:23 /var/devio-marker-M2.txt
-rw-r--r--. 1 root root 97 Dec  2 15:28 /var/devio-marker-M3.txt
== /var/devio-marker-M1.txt
M1 tokyo-1a 2026-12-02T15:14:25Z ip-172-31-xx-xx.ap-northeast-1.compute.internal
== /var/devio-marker-M2.txt
M2 tokyo-1d 2026-12-02T15:23:57Z ip-172-31-xx-xx.ap-northeast-1.compute.internal ap-northeast-1d
== /var/devio-marker-M3.txt
M3 tokyo-1a 2026-12-02T15:28:35Z ip-172-31-xx-xx.ap-northeast-1.compute.internal ap-northeast-1a

M1 through M3 could be read exactly as they were written.

Carry-over of the Source Server

The agent installed on the source before the initial sync could continue to be used as is. The following were carried over.

  • Source server ID and Name tag: the same values from right after installation to the end
  • Launch settings: both after the failback and at the final check, the values specified in the launch template
    • launchDisposition: STARTED
    • targetInstanceTypeRightSizingMethod: BASIC
    • copyPrivateIp: false
    • copyTags: true
    • postLaunchEnabled: false
  • Recovery points: the first point remained in the list even after the failover and failback, and the three points obtained after that were added
aws drs describe-recovery-snapshots --region ap-northeast-3 --source-server-id <source-server-id> --order DESC --query 'items[?timestamp!=`null`].[snapshotID,timestamp]' --output text
pit-EXAMPLE1	2026-12-02T15:57:42.264232+00:00
pit-EXAMPLE2	2026-12-02T15:47:39.493756+00:00
pit-EXAMPLE3	2026-12-02T15:27:34.161901+00:00
pit-EXAMPLE4	2026-12-02T15:19:28.919575+00:00

Summary

I confirmed that the data of an EBS Multi-AZ volume replicated with AWS DRS continues to be carried over to Osaka even after a planned failover in Tokyo.

If you want to combine cross-Region DR with the AZ failure resilience provided by EBS Multi-AZ volumes, give this update a try.

Share this article

AWSのお困り事はクラスメソッドへ