Deleting your AWS DataSync task - AWS DataSync

Deleting your AWS DataSync task

If you no longer need an AWS DataSync task, you can delete it and its related AWS resources.

Prerequisites

When you run a task, DataSync automatically creates and manages network interfaces for data transfer traffic (for more information, see Network interface requirements).

To make sure that you delete these network interfaces when you delete your task, you must have the following IAM permissions:

  • ec2:DeleteNetworkInterface

  • ec2:DescribeNetworkInterfaces

  • ec2:ModifyNetworkInterfaceAttribute

These permissions are available in the AWS managed policy AWSDataSyncFullAccess. For more information, see AWS managed policies for AWS DataSync.

Deleting the task

Once you delete a task, you can't restore it.

  1. Open the AWS DataSync console at https://console.aws.amazon.com/datasync/.

  2. In the left navigation pane, choose Tasks.

  3. Select the task that you want to delete.

  4. Choose Actions, then choose Delete.

  5. In the dialog box, choose Delete.

  1. Copy the following delete-task command:

    aws datasync delete-task \ --task-arn "task-to-delete"
  2. For the --task-arn parameter, specify the Amazon Resource Name (ARN) of the task you're deleting (for example, arn:aws:datasync:us-east-2:123456789012:task/task-012345678abcd0123).

  3. Run the delete-task command.