DataSync agent ran into an error connecting to AWS

0

We are trying to move files from EFS to EFS but they are not in the same region. We have connected the 2 VPCs in different regions with PCX and we need to create a EC2 instance hosted in source EFS as DataSync agent.

We have also created VPC Endpoint for AWS DataSync in destination VPC then create agent resource in destination region pointing to agent deployed in source region using the AWS DataSync VPC endpoint just created. However when we run the task to transfer files from source to destination EFS it fails with this error message:

DataSync agent ran into an error connecting to AWS. Please review the DataSync network requirements and ensure required endpoints are accessible from the agent. Please contact AWS support if the error persists.

We tried to allow all traffic in all related SG and the PCX is active, agent status shown in destination region is active. We have no idea on what would be wrong.

I have SSH into the agent and tested the networking with the tool preinstalled in it and shows networking is totally correct, and it confirms I have enough RAM and CPUs to run.

Thanks for helping

Tom Lo
asked 9 months ago583 views
3 Answers
0
Accepted Answer

Hi, DataSync can natively support cross region EFS transfers in the same account for regions that are enabled by default. https://docs.aws.amazon.com/datasync/latest/userguide/working-with-locations.html#working-with-locations-cross-regions

For transfers between EFS with an agent, you can reference this blog to verify configuration. https://aws.amazon.com/blogs/storage/transferring-file-data-across-aws-regions-and-accounts-using-aws-datasync/

AWS
answered 9 months ago
  • Okay so the solution is actually user need to create location in the dedicated region separately or create location directly when you are creating task to replicate cross-region data.

  • When creating a task in the AWS DataSync management console, you can independently select which region the source and destination Amazon EFS locations reside in. You can choose to create a new EFS location in the selected region, or use an existing location that exists in the selected region.

0

Have you considered using EFS Replication?

profile pictureAWS
EXPERT
kentrad
answered 9 months ago
0

Hello! I needed to transfer files from EFS to EFS between different regions in different accounts and I used the following article also mentioned above. https://docs.aws.amazon.com/datasync/latest/userguide/datasync-limits.html In the end I got the same error as the OP. I checked several time the post and my settings, everethyng looked OK. Data sync agent was green and ready to connect, VPC peering connection, endpoint, security groups etc were configured. But I missed only one thing from here https://docs.aws.amazon.com/datasync/latest/userguide/datasync-in-vpc.html

Make sure that you allow outbound traffic from the agent to these interfaces by using port 443.

So the security group in the destination account should allow connections from the VPC endpoint to EFS over TCP 2049 and from the DataSync EC2 instance (or subnet) from the source account over TCP 443. When I added the rules to the group, I was able to transfer data. Hope this helps someone.

Yurii
answered 8 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions