Your source server shows Stalled in the AWS Elastic Disaster Recovery console, and under Replication initiation steps one step has a red x. In my rollout it happened twice, at two different steps: first AUTHENTICATE_WITH_SERVICE, then, once that was fixed, CONNECT_AGENT_TO_REPLICATION_SERVER. Those are the step names the DRS API and aws drs describe-source-servers report, and the matching errors are FAILED_TO_AUTHENTICATE_WITH_SERVICE and FAILED_TO_CONNECT_AGENT_TO_REPLICATION_SERVER. The first stall was a security group: my VPC interface endpoints had the VPC’s default security group, which only accepts traffic from its own members, so the replication servers could not reach the DRS API. The second was routing: the staging subnet’s route table had no route back to the on-premises network, so the replication server’s replies to the agent went nowhere.

This article is for anyone replicating on-premises Linux servers into DRS over a site-to-site VPN into a private subnet. It covers both stalls, a complete port checklist, a table that maps every initiation step to its usual cause, commands to verify each hop from both ends, and one quieter failure I found later: the agent’s systemd unit was not enabled at boot on any server in the fleet.

Last verified: December 2026. AWS CLI v2, IAM Roles Anywhere credential helper (aws_signing_helper) 1.8.6. DRS currently supports Linux kernels up to 7.3 (7.2 and 7.3 need agent 6.42.29 or later). Example addresses use documentation ranges (192.0.2.0/24, 198.51.100.0/24); use your own private ranges in practice.

What DRS is, and what it is not

Elastic Disaster Recovery (DRS) runs an agent, the AWS Replication Agent, on each source server. The agent watches every block written to the server’s disks and copies those blocks continuously to a replication server, a small EC2 instance that DRS launches in a staging subnet you choose. The replication server writes them to EBS volumes, and DRS takes point-in-time snapshots of those volumes. When you run a drill or a real recovery, DRS builds full EC2 instances from a chosen point in time and launches them into your recovery subnet.

AWS describes the result as a crash-consistent recovery point measured in seconds, with recovery time typically 5 to 20 minutes depending on how long the operating system takes to boot.

DRS is not a backup. It replicates every write, including a mistaken rm -rf, a dropped table and ransomware encrypting your files, within seconds. Point-in-time snapshots let you step back: DRS keeps 10-minute snapshots for an hour and hourly snapshots for 24 hours (both fixed), plus daily snapshots for a retention you set between 1 and 365 days. It is built to survive losing the building, not to give you versioned, offline, independent copies. Keep real backups alongside it, and treat DRS as a fast way to stand the business back up somewhere else. For the difference between snapshots, backups and DR replication, see Snapshot Before You Touch Production.

The design

Topology: on-prem Linux servers and firewall connect over two IPsec tunnels with BGP to a virtual private gateway; the staging subnet holds replication servers, interface endpoints for drs and ec2, and a route table with an S3 gateway endpoint route and a propagated on-prem route; a separate recovery subnet holds recovery instances The two amber paths are where replication stalled.

  • On-premises: Linux source servers behind a firewall that terminates a site-to-site IPsec VPN to an AWS virtual private gateway (VGW). The firewall and the VGW exchange routes with BGP, so AWS learns the on-premises prefix dynamically.
  • Staging subnet: fully private. No internet gateway, no NAT gateway, no default route. The replication servers reach AWS only through VPC endpoints:
    • interface endpoints for drs and ec2, with private DNS enabled, so the normal names drs.<REGION>.amazonaws.com and ec2.<REGION>.amazonaws.com resolve to private addresses inside the subnet;
    • an S3 gateway endpoint associated with the staging route table, which adds a route to S3’s prefix list.
  • Replication settings: data routed over private IP (the console calls it Use private IP for data replication, the API calls it dataPlaneRouting=PRIVATE_IP) and public IP creation off (createPublicIP=false). The agent sends data to the replication server’s private address across the VPN.
  • Recovery subnet: where drill and recovery instances launch. Nothing runs there day to day.
  • Credentials for the installer: IAM Roles Anywhere, trusting my own internal CA (a root and an intermediate), so no long-lived access keys sit on any server.

DRS’s secured-network guide lists these endpoints (plus an S3 interface endpoint for the installer, covered next) and notes that replication traffic never uses them. It goes straight over the VPN to the replication server’s private IP.

One thing the diagram leaves open is how the agent on each source server reaches the DRS API and S3 on TCP 443. You have two choices. The simple one is the on-premises network’s normal outbound internet access to drs.<REGION>.amazonaws.com and the regional DRS S3 buckets. The private one is to reach interface endpoints over the VPN and install with --endpoint and --s3-endpoint, passing the endpoint-specific DNS names (vpce-<ID>.drs.<REGION>.vpce.amazonaws.com). Two gotchas with the private route: an S3 gateway endpoint cannot be used from the far side of a VPN at all, so on-premises agents need an S3 interface endpoint; and private DNS names only resolve inside the VPC unless you forward queries to Route 53 Resolver endpoints.

The initiation sequence and where it breaks

When you install the agent, DRS walks through a fixed list of initiation steps. The console shows the list under Replication initiation steps and marks the failed one. The API reports the same steps by name.

Sequence diagram of the DRS replication initiation steps between the agent, the DRS service, the replication server, the interface endpoints and the S3 gateway endpoint, with stall 1 at AUTHENTICATE_WITH_SERVICE and stall 2 at the SYN-ACK of CONNECT_AGENT_TO_REPLICATION_SERVER Stall 1 is a staging-subnet problem. Stall 2 is a VPN routing problem. The agent is fine in both.

To read the steps from the CLI:

Copied!
aws drs describe-source-servers \
  --filters sourceServerIDs=<SOURCE_SERVER_ID> \
  --query 'items[0].dataReplicationInfo.{state:dataReplicationState,error:dataReplicationError,steps:dataReplicationInitiation.steps[].[name,status]}'

The table maps each step to the cause that usually breaks it and the check that confirms it. Where AWS documents no common cause, the table says so.

Step Usual cause when it fails Check that confirms it
WAIT Nothing; DRS is queuing the next attempt dataReplicationInitiation.nextAttemptDateTime (add it to the query above)
CREATE_SECURITY_GROUP IAM permissions for the security group calls, or the staging subnet in the replication settings no longer exists CloudTrail for the security group API calls; aws drs get-replication-configuration for stagingAreaSubnetId
LAUNCH_REPLICATION_SERVER IAM or SCP denial, or the staging subnet in the replication settings is wrong or gone CloudTrail for RunInstances errors; aws drs get-replication-configuration for stagingAreaSubnetId
BOOT_REPLICATION_SERVER No common cause documented The replication server’s EC2 status checks and system log in the EC2 console
AUTHENTICATE_WITH_SERVICE Replication server cannot reach the DRS endpoint on TCP 443: endpoint security group, endpoint policy, NACL, route table or DNS Endpoint security group inbound rules; dig and curl from a test instance in the staging subnet (below)
DOWNLOAD_REPLICATION_SOFTWARE No path to S3, or the S3 gateway endpoint policy does not allow the DRS buckets (including the Amazon Linux 2023 repository bucket) Route table has the S3 prefix-list route; endpoint policy lists every bucket on DRS’s network requirements page
CREATE_STAGING_DISKS No permission on a customer managed KMS key, or an EBS quota reached CloudTrail for CreateVolume errors; KMS key policy
ATTACH_STAGING_DISKS No permission on the selected KMS key, or a policy that restricts the attach call CloudTrail for AttachVolume errors; KMS key policy
PAIR_REPLICATION_SERVER_WITH_AGENT No cause documented; the re:Post checklist in the sources points at the TCP 1500 path between source and replication server (security groups, NACLs, route tables) Same checks as the next row; the agent log on the source
CONNECT_AGENT_TO_REPLICATION_SERVER TCP 1500 from the source to the replication server is blocked or has no return path: on-prem firewall, replication server security group, staging NACL, or no route back to on-prem nc -zv <REPLICATION_SERVER_IP> 1500 from the source; staging route table for the on-prem prefix
START_DATA_TRANSFER No common cause documented /var/lib/aws-replication-agent/agent.log.0 on the source

Stall 1: AUTHENTICATE_WITH_SERVICE

What I saw. The first server got as far as launching and booting a replication server, then stopped at AUTHENTICATE_WITH_SERVICE. The agent on the source server was registered and talking to DRS. The failure was inside AWS.

What it was. DRS’s own troubleshooting page puts it plainly: this error means the replication server cannot reach the DRS endpoint on TCP 443, and it calls it a staging-area network issue. In a subnet with no internet path, “the DRS endpoint” means the interface endpoint’s network interfaces. Those network interfaces have a security group, and I had never chosen one. When you create an interface endpoint without specifying a security group, AWS attaches the VPC’s default security group. The default group’s only inbound rule allows traffic from members of that same group.

The replication servers are not members of it. DRS puts them in its own security group, which it creates and monitors. So every HTTPS connection from a replication server to the endpoint was dropped at the endpoint’s security group. DNS can resolve exactly as designed and still hand back addresses that drop your traffic. An AWS knowledge center article on this exact error says the endpoint’s security group must allow inbound TCP 443 from the staging subnet.

The fix. Allow TCP 443 into the endpoint security group from the staging subnet’s CIDR. Find the group on each endpoint first:

Copied!
aws ec2 describe-vpc-endpoints \
  --filters Name=vpc-id,Values=<VPC_ID> \
  --query 'VpcEndpoints[].{id:VpcEndpointId,service:ServiceName,type:VpcEndpointType,privateDns:PrivateDnsEnabled,groups:Groups[].GroupId}' \
  --output table

The drs and ec2 rows (type Interface) show the security group. The S3 row (type Gateway) has none, because gateway endpoints are route table entries, not network interfaces. Add the rule:

Copied!
aws ec2 authorize-security-group-ingress \
  --group-id <ENDPOINT_SG_ID> \
  --protocol tcp --port 443 \
  --cidr 198.51.100.0/25

The output includes "Return": true and the new rule. Better still, give the endpoints a dedicated security group with this one inbound rule instead of editing the VPC default group, which other resources may share. DRS retries initiation on its own; the step should move past AUTHENTICATE_WITH_SERVICE on the next attempt.

Stall 2: CONNECT_AGENT_TO_REPLICATION_SERVER

What I saw. With authentication fixed, initiation went further: the replication software downloaded, staging disks were created and attached, the agent paired with the replication server. Then it stopped at CONNECT_AGENT_TO_REPLICATION_SERVER.

What it was. This step is the agent opening a TCP connection to the replication server on port 1500, the data channel. The VPN was up and the on-premises firewall had a route to the staging subnet, so the agent’s SYN could go into the tunnel and reach the replication server. The replication server answered with a SYN-ACK addressed to the source server’s on-premises IP, and the staging subnet’s route table had no route for that prefix. No default route either, by design. The reply was dropped and the agent’s connection timed out.

A VPN connection does not add anything to your route tables by itself. AWS’s VPN documentation says you must either add a route for your remote network with the VGW as its target, or enable route propagation so the VGW installs the routes it has learned. Because my firewall advertises the on-premises prefix over BGP, propagation was the right fix: the route follows whatever BGP advertises.

The fix. Enable VGW route propagation on the staging route table:

Copied!
aws ec2 enable-vgw-route-propagation \
  --route-table-id <STAGING_ROUTE_TABLE_ID> \
  --gateway-id <VGW_ID>

That command prints nothing on success. Confirm the propagated route appeared:

Copied!
aws ec2 describe-route-tables \
  --route-table-ids <STAGING_ROUTE_TABLE_ID> \
  --query 'RouteTables[0].{propagating:PropagatingVgws[].GatewayId,routes:Routes[].[DestinationCidrBlock||DestinationPrefixListId,GatewayId,Origin,State]}' \
  --output json

Expected, in shape:

Copied!
{
    "propagating": ["<VGW_ID>"],
    "routes": [
        ["198.51.100.0/24", "local", "CreateRouteTable", "active"],
        ["pl-<ID>", "vpce-<ID>", "CreateRoute", "active"],
        ["192.0.2.0/24", "<VGW_ID>", "EnableVgwRoutePropagation", "active"]
    ]
}

If propagating lists the VGW but no EnableVgwRoutePropagation route appears, AWS is not receiving the prefix over BGP. Check that the tunnels are up and accepting routes:

Copied!
aws ec2 describe-vpn-connections \
  --vpn-connection-ids <VPN_CONNECTION_ID> \
  --query 'VpnConnections[0].VgwTelemetry[].{status:Status,routes:AcceptedRouteCount,msg:StatusMessage}'

Each tunnel should be UP with AcceptedRouteCount of at least 1. If you use static routing instead of BGP, propagation installs the static routes you configured on the VPN connection, or you can add the route to the table directly. Also make sure the recovery subnet’s route table gets the same treatment before you need it: recovered servers will have to talk to whatever is still on-premises.

The complete network checklist

Every flow in this design, with direction. “Outbound” means the side that opens the connection; replies on established connections are handled by stateful firewalls and security groups, but they still need a route back.

# From To Port Purpose Where to allow it
1 Source servers (agent) drs.<REGION>.amazonaws.com, or the DRS interface endpoint over the VPN TCP 443 out Registration, agent upgrades, status, events, drill and recovery prep On-prem firewall; endpoint security group if using endpoints
2 Source servers (installer) Regional DRS S3 buckets, or an S3 interface endpoint over the VPN TCP 443 out Download the agent and its components On-prem firewall; S3 interface endpoint security group
3 Source servers (agent) Replication servers’ private IPs in the staging subnet TCP 1500 out Replicated data, TLS 1.2 end to end On-prem firewall (outbound into the tunnel, no source NAT); DRS security group (inbound 1500, managed by DRS); staging NACL
4 Replication servers DRS interface endpoint TCP 443 out Download software, authenticate, report status Endpoint security group: inbound 443 from the staging CIDR
5 Replication servers EC2 interface endpoint TCP 443 out EC2 API access from the staging subnet Same endpoint security group rule
6 Replication servers S3 via gateway endpoint TCP 443 out Replication software and Amazon Linux 2023 packages Staging route table association; gateway endpoint policy
7 Staging subnet On-prem prefix Return traffic for #3 Replies to the agent Staging route table: on-prem prefix via the VGW (propagated or static)
8 VPC n/a n/a Private DNS for interface endpoints VPC attributes: DNS resolution and DNS hostnames both enabled

The S3 buckets for rows 2 and 6 are listed on DRS’s network requirements page: aws-drs-clients-<REGION>, aws-drs-clients-hashes-<REGION>, aws-drs-internal-<REGION>, aws-drs-internal-hashes-<REGION>, aws-elastic-disaster-recovery-<REGION>, aws-elastic-disaster-recovery-hashes-<REGION> and al2023-repos-<REGION>-de612dc2. If your S3 gateway endpoint has a restrictive policy, it must allow s3:GetObject on all of them; the page gives an example policy. The bucket list can change, so copy it from the page, not from here.

The default NACL allows everything. NACLs are stateless, so if you use a custom one, the staging subnet also needs outbound ephemeral ports (1024 to 65535) back to the on-prem prefix.

Verifying from both sides

From the on-premises source server

Check the agent can reach the DRS API. AWS’s troubleshooting pages use curl -v, telnet or openssl s_client for this; the form below prints only curl’s exit code, where 0 means a TLS connection and an HTTP response, 28 means a timeout, 6 means DNS failed:

Copied!
curl https://drs.<REGION>.amazonaws.com -s --connect-timeout 5 --head > /dev/null; echo $?
Copied!
0

If you install through interface endpoints instead, resolve and test the endpoint-specific name. It should return addresses inside your staging subnet:

Copied!
dig +short vpce-<ID>.drs.<REGION>.vpce.amazonaws.com
curl https://vpce-<ID>.drs.<REGION>.vpce.amazonaws.com -s --connect-timeout 5 --head > /dev/null; echo $?

Find the replication server’s private IP (DRS launches it into the staging subnet, so list what is running there):

Copied!
aws ec2 describe-instances \
  --filters Name=subnet-id,Values=<STAGING_SUBNET_ID> Name=instance-state-name,Values=running \
  --query 'Reservations[].Instances[].[InstanceId,PrivateIpAddress]' \
  --output text

Then test TCP 1500 from the source server:

Copied!
nc -zv -w 5 198.51.100.20 1500

Working (OpenBSD netcat):

Copied!
Connection to 198.51.100.20 1500 port [tcp/*] succeeded!

What stall 2 looks like from the source side:

Copied!
nc: connect to 198.51.100.20 port 1500 (tcp) timed out: Operation now in progress

A timeout says packets vanished, not where. A security group and a missing route look identical from here.

Read the agent’s log. DRS’s diagnostics page gives the location:

Copied!
sudo tail -100 /var/lib/aws-replication-agent/agent.log.0
sudo grep -i "ERROR\|FATAL" /var/lib/aws-replication-agent/agent.log.0
cat /var/lib/aws-replication-agent/agent.version

The installer also writes aws_replication_agent_installer.log; AWS’s support runbook for agent installation reads that file. I find it with sudo find / -name aws_replication_agent_installer.log 2>/dev/null rather than trusting a path.

Finally, check the service is running now and will start at boot (more on why below):

Copied!
systemctl is-enabled aws-replication-agent; systemctl is-active aws-replication-agent
Copied!
enabled
active

From the AWS side

Confirm the VPC can do private DNS at all. Both must be true:

Copied!
aws ec2 describe-vpc-attribute --vpc-id <VPC_ID> --attribute enableDnsSupport --query 'EnableDnsSupport.Value'
aws ec2 describe-vpc-attribute --vpc-id <VPC_ID> --attribute enableDnsHostnames --query 'EnableDnsHostnames.Value'

Read the endpoint security group’s inbound rules and confirm 443 from the staging CIDR is there:

Copied!
aws ec2 describe-security-groups \
  --group-ids <ENDPOINT_SG_ID> \
  --query 'SecurityGroups[0].IpPermissions[].{proto:IpProtocol,from:FromPort,to:ToPort,cidrs:IpRanges[].CidrIp,groups:UserIdGroupPairs[].GroupId}'

A VPC default group that nobody has touched shows a single rule with protocol -1, no CIDRs and its own group ID under groups. That is stall 1.

Read the replication server security group and confirm inbound 1500:

Copied!
aws drs get-replication-configuration \
  --source-server-id <SOURCE_SERVER_ID> \
  --query '{routing:dataPlaneRouting,publicIp:createPublicIP,subnet:stagingAreaSubnetId,defaultSg:associateDefaultSecurityGroup,extraSgs:replicationServersSecurityGroupsIDs}'

With the recommended Always use AWS Elastic Disaster Recovery security group setting, DRS manages the inbound 1500 rule and repairs it if someone edits it.

For the route table, use the describe-route-tables command from the stall 2 section.

To test from inside the staging subnet itself, launch a small test instance there with a security group other than the endpoints’ group, so it sees what a replication server sees. With no internet access, the practical way in is SSH over the VPN, which needs the stall 2 return route in place and a rule allowing TCP 22 from the on-prem prefix. Remove the instance and the rule when you are done. From the test instance (dig is in the bind-utils package on Amazon Linux):

Copied!
dig +short drs.<REGION>.amazonaws.com
curl https://drs.<REGION>.amazonaws.com -s --connect-timeout 5 --head > /dev/null; echo $?
curl https://ec2.<REGION>.amazonaws.com -s --connect-timeout 5 --head > /dev/null; echo $?

dig should return addresses in the staging subnet. If it returns public addresses, private DNS is not in effect. If it returns staging addresses and curl exits 28, look at the endpoint security group.

If you would rather not launch anything, VPC Reachability Analyzer can test the path from a running replication server to the endpoint without sending traffic. It costs $0.10 per analysis at the time of writing:

Copied!
aws ec2 create-network-insights-path \
  --source <REPLICATION_SERVER_INSTANCE_ID> \
  --destination <DRS_ENDPOINT_ID> \
  --protocol tcp --destination-port 443 \
  --query 'NetworkInsightsPath.NetworkInsightsPathId' --output text

aws ec2 start-network-insights-analysis \
  --network-insights-path-id <PATH_ID> \
  --query 'NetworkInsightsAnalysis.NetworkInsightsAnalysisId' --output text

aws ec2 describe-network-insights-analyses \
  --network-insights-analysis-ids <ANALYSIS_ID> \
  --query 'NetworkInsightsAnalyses[0].{status:Status,found:NetworkPathFound,why:Explanations[].ExplanationCode}'

Wait for status to read succeeded. found: false with an explanation code such as ENI_SG_RULES_MISMATCH points straight at a security group.

The quiet one: the agent was not enabled at boot

After both stalls were fixed, while chasing replication lag on one server, I found its aws-replication-agent unit disabled. The agent was running, but nothing would start it again after a reboot. I enabled it on that server and checked the rest of the fleet with the same two commands:

Copied!
systemctl is-enabled aws-replication-agent; systemctl is-active aws-replication-agent

Every one of the other ten came back disabled and active. A uniform result across the whole fleet points at the installation, not at someone disabling it by hand. I don’t know why the installer left it disabled, and AWS’s Linux installation page doesn’t say whether it enables the unit. Don’t assume. Check.

The fix on each host:

Copied!
sudo systemctl enable aws-replication-agent
Copied!
Created symlink /etc/systemd/system/multi-user.target.wants/aws-replication-agent.service → /etc/systemd/system/aws-replication-agent.service.

That symlink into multi-user.target.wants is what makes systemd start the agent at boot. Without it, the next reboot (a kernel update, a power event) stops replication on that server. DRS documents an AGENT_NOT_SEEN error and a Disconnected status for that case, so the console would eventually show it, but nothing pages you unless you are watching for it. In a real disaster you would find out that the recovery point is days old.

I now run systemctl enable aws-replication-agent and the two checks above as part of every agent install. A graceful reboot during a maintenance window is a reasonable end-to-end test: on Ubuntu 16 and later, Debian 9 and later, and RHEL-family 6 and later, DRS says a graceful reboot does not trigger a rescan.

Installer credentials without static keys: IAM Roles Anywhere

The agent installer needs AWS credentials to register the server. DRS’s documentation recommends temporary credentials from STS over access keys, and the installer accepts a session token (--aws-session-token, or the AWS_SESSION_TOKEN environment variable). The installation policy includes drs:IssueAgentCertificateForDrs, and DRS’s credentials page says the agent’s own temporary credentials use a mechanism similar to Roles Anywhere. So your installer credentials only need to live as long as the install.

IAM Roles Anywhere lets a server outside AWS trade an X.509 certificate from your own CA for temporary credentials. Four pieces:

  • Trust anchor: a reference to the CA you trust, either AWS Private CA or your own CA certificate in PEM format. Root and intermediate CAs both work as anchors. Certificates from public CAs cannot be used.
  • Role: an IAM role whose trust policy trusts the service principal rolesanywhere.amazonaws.com for sts:AssumeRole, sts:TagSession and sts:SetSourceIdentity.
  • Profile: lists the roles Roles Anywhere may assume, and can cap permissions and session length (900 to 43,200 seconds, default 3,600).
  • Credential helper: aws_signing_helper, which signs the request with the server’s private key and returns credentials in the format the AWS CLI’s credential_process expects.

My internal CA has a root and an intermediate. In the commands below the trust anchor is the root, and each source server’s client certificate is issued by the intermediate. The client certificate must be X.509v3 with Digital Signature key usage, CA:false if basic constraints are present, and a SHA-256 or stronger signature. The CA certificate needs CA:true and Certificate Sign.

Create the anchor from the root’s PEM file. jq builds the JSON so the newlines survive (sudo apt install jq if you don’t have it):

Copied!
jq -n --rawfile pem root-ca.pem \
  '{sourceType:"CERTIFICATE_BUNDLE",sourceData:{x509CertificateData:$pem}}' > anchor-source.json

aws rolesanywhere create-trust-anchor \
  --name drs-agent-install \
  --source file://anchor-source.json \
  --enabled

The output includes trustAnchorArn; you need it below. Next, the role. Save its trust policy as trust.json with vim trust.json (press i to insert, Esc then :wq to save and quit). It is scoped to the anchor because AWS warns that without a condition, any certificate your CA or its subordinates issued could assume the role:

Copied!
{
  "Version": "2012-10-17",
  "Statement": [
    {
      "Effect": "Allow",
      "Principal": { "Service": "rolesanywhere.amazonaws.com" },
      "Action": ["sts:AssumeRole", "sts:TagSession", "sts:SetSourceIdentity"],
      "Condition": {
        "ArnEquals": {
          "aws:SourceArn": "arn:aws:rolesanywhere:<REGION>:<ACCOUNT_ID>:trust-anchor/<TRUST_ANCHOR_ID>"
        }
      }
    }
  ]
}

You can tighten it further with aws:PrincipalTag/x509Subject/CN or aws:PrincipalTag/x509Issuer/CN conditions, which Roles Anywhere maps from the certificate. Use the trust anchor’s ID-based ARN in aws:SourceArn; AWS notes a condition on an alias ARN never matches. Create the role, attach the installation policy, and create the profile:

Copied!
aws iam create-role \
  --role-name <ROLE_NAME> \
  --assume-role-policy-document file://trust.json

aws iam attach-role-policy \
  --role-name <ROLE_NAME> \
  --policy-arn arn:aws:iam::aws:policy/AWSElasticDisasterRecoveryAgentInstallationPolicy

aws rolesanywhere create-profile \
  --name drs-agent-install \
  --role-arns arn:aws:iam::<ACCOUNT_ID>:role/<ROLE_NAME> \
  --duration-seconds 3600 \
  --enabled

On the source server, download the credential helper and the installer, and verify both. The helper’s download links and SHA-256 checksums are on the credential helper page; this is the Linux x86-64 build of 1.8.6, the current release as I write this:

Copied!
curl -fsSLo aws_signing_helper https://rolesanywhere.amazonaws.com/releases/1.8.6/X86_64/Linux/Amzn2023/aws_signing_helper
sha256sum aws_signing_helper
chmod +x aws_signing_helper

curl -fsSLo aws-replication-installer-init https://aws-elastic-disaster-recovery-<REGION>.s3.<REGION>.amazonaws.com/latest/linux/aws-replication-installer-init
curl -fsSLo aws-replication-installer-init.sha512 https://aws-elastic-disaster-recovery-hashes-<REGION>.s3.<REGION>.amazonaws.com/latest/linux/aws-replication-installer-init.sha512
sha512sum aws-replication-installer-init; cat aws-replication-installer-init.sha512
chmod +x aws-replication-installer-init

Compare each printed hash with the published one before going further. Then get credentials and run the installer (this step needs jq on the source server as well). The client certificate is signed by the intermediate, so pass the intermediate with --intermediates:

Copied!
creds=$(sudo ./aws_signing_helper credential-process \
  --certificate /etc/pki/drs/agent.crt \
  --private-key /etc/pki/drs/agent.key \
  --intermediates /etc/pki/drs/intermediate.crt \
  --trust-anchor-arn <TRUST_ANCHOR_ARN> \
  --profile-arn <PROFILE_ARN> \
  --role-arn <ROLE_ARN>)

export AWS_ACCESS_KEY_ID=$(echo "$creds" | jq -r .AccessKeyId)
export AWS_SECRET_ACCESS_KEY=$(echo "$creds" | jq -r .SecretAccessKey)
export AWS_SESSION_TOKEN=$(echo "$creds" | jq -r .SessionToken)

sudo -E ./aws-replication-installer-init --region <REGION> --no-prompt
sudo systemctl enable aws-replication-agent
unset AWS_ACCESS_KEY_ID AWS_SECRET_ACCESS_KEY AWS_SESSION_TOKEN

The certificate paths are examples; use wherever you keep the server’s certificate and key, readable only by root. sudo -E keeps the environment variables, which is how DRS’s own documentation passes temporary credentials. If you install through interface endpoints, add --endpoint and --s3-endpoint with the endpoint-specific DNS names.

Why this beats access keys: nothing long-lived is written to disk on the source server. The private key never leaves the server, the credentials expire in an hour, and revoking a server means revoking its certificate (Roles Anywhere can check imported CRLs) rather than hunting down which keys were copied where.

On policies. AWS documents AWSElasticDisasterRecoveryAgentInstallationPolicy as the policy for the credentials you give the installer. In my setup the role needed AWSElasticDisasterRecoveryAgentPolicy attached as well. Be aware that AWS’s page for that second policy says it is designed for the agent itself and recommends against attaching it to users or roles. Try the installation policy alone first. If you do end up needing both, keep the trust policy scoped as above so that only certificates from your CA, through your trust anchor, can use the role.

Kernel support

When I installed, the agent supported kernels up to 6.14. That limit has moved. DRS’s supported Linux page now lists kernels up to 7.3, with 7.2 and 7.3 requiring agent version 6.42.29 or later, Ubuntu 12.04 through 26.04 (26.04 needs agent 6.42.26 or later) and Debian 10 through 13. Check the page before you install, and check uname -r on each source server against it.

While you are there, read the installation requirements page too. Kernel headers that exactly match the running kernel and a /tmp mounted without noexec are both on it.

The console’s numbers are not the whole story

Once initiation succeeds, the stalls stop being about networking and start being about reading the dashboard.

The initial sync ETA can be wildly wrong. For a large database server, the console showed 1% done and “5 months left.” The same page showed 13.13 of 931.51 GiB replicated, a start time and a last-seen time 2.75 hours apart. That is 4.78 GiB per hour, so the remaining 918 GiB would take about 8 days. Later readings came in lower, around 2.45 GiB per hour, which still meant roughly two weeks, not five months. Compute the rate yourself from two readings a known time apart:

Copied!
aws drs describe-source-servers \
  --filters sourceServerIDs=<SOURCE_SERVER_ID> \
  --query 'items[0].dataReplicationInfo.replicatedDisks[].{disk:deviceName,done:replicatedStorageBytes,total:totalStorageBytes}'

Lag and backlog measure different things. DRS defines backlog as data written at the source that has not been copied to AWS yet, and lag as how far behind a recovery instance launched right now would be. After a drill, one server’s agent restarted, it went into a partial resync, and the console showed it Stalled with NOT_CONVERGING while lag climbed to about three hours. It looked like the link couldn’t keep up with that server’s write rate. It wasn’t. Backlog drained from about 13 GiB to zero while lag kept rising, and then the server went back to CONTINUOUS on its own. My reading is that DRS couldn’t record a new consistent recovery point until the resync finished, so lag kept counting even though the data had arrived; AWS’s documentation doesn’t spell that out. Check backlog before you act on lag:

Copied!
aws drs describe-source-servers \
  --filters sourceServerIDs=<SOURCE_SERVER_ID> \
  --query 'items[0].dataReplicationInfo.{state:dataReplicationState,lag:lagDuration,backlog:replicatedDisks[].backloggedStorageBytes}'

Backlog falling means it is working through it. Backlog flat or growing for hours means the source writes faster than the link carries, which is a real NOT_CONVERGING problem.

Cost

At the time of writing, AWS’s pricing page lists DRS at $0.028 per source server per hour, about $20.44 per server for a 730-hour month. That covers replication, drills, recovery launches and point-in-time recovery. Billed separately: the replication servers (t3.small by default), EBS staging volumes (one per source disk), EBS snapshots, recovery and drill instances while they run, and data transfer. Interface endpoints are billed per endpoint per Availability Zone per hour plus per GB processed; the S3 gateway endpoint is free. For my fleet of about a dozen servers, my account’s monthly AWS spend went from roughly $650 to roughly $1,000 after rollout. Prices change; check the DRS pricing page and the AWS Pricing Calculator for your Region.

What I would do differently

  • Create a dedicated endpoint security group up front. Inbound TCP 443 from the staging and recovery subnet CIDRs, attached when you create each interface endpoint. Never let an endpoint fall back to the VPC default group.
  • Turn on route propagation when you attach the VGW, on every route table that needs to reach on-premises, not after the first stall.
  • Test before installing the agent. A test instance in the staging subnet with dig and curl against the DRS and EC2 names, plus a look at the staging route table for the on-prem prefix, would have caught both stalls before the first install.
  • Make systemctl enable part of the install and check is-enabled across the fleet after every batch.
  • Watch the tunnels. In my setup, traffic from on-premises left on one tunnel and AWS sent the return traffic on the other. I haven’t confirmed that it costs throughput, but it matters for failback, and some firewalls drop return traffic that arrives on a different interface than it left on. Check how your firewall treats asymmetric routes before you depend on it.
  • Drill early, and check the server afterwards. A drill is when you find out whether the recovery subnet’s routes, security groups and launch settings work. Run one soon after the first server reaches CONTINUOUS, then check that server’s backlog and lag over the next few hours, as above.

Sources and further reading