08. Using Elastic File System (EFS) with N2WS

Now you can backup and recover Amazon Elastic File System (EFS) with N2WS. In this guide, we walk you through how to set it up.

Configuring EFS on N2WS allows you to determine backup:

  • Schedule and frequency
  • Retention
  • Lifecycle policy, including moving backups to cold storage, defining expiration options, and deleting them at end of life.

With AWS Backup, you pay only for the amount of backup storage you use and the amount of backup data you restore in the month. There is no minimum fee and there are no set-up charges.

Important: EFS Backup and Restore is performed by AWS Backup Service. When adding an EFS target for the first time in a region, you must create the default backup vault in AWS. Go to the AWS Backup console and choose Backup vaults.

For more information regarding the AWS Backup Service, refer to: https://docs.aws.amazon.com/efs/latest/ug/awsbackup.html

Before continuing, consider the following:

  • Currently, AWS Backup service doesn’t support DR for EFS resources.
  • Not all regions are available for EFS backup on the AWS Backup service. Currently, the available regions are: US East (N. Virginia), US East (Ohio), US West (Oregon), EU (Ireland), EU (Frankfort), and Asia Pacific (Sydney).
  • For regions not enabled by default, such as Asia Pacific (Hong Kong) and Middle East (Bahrain), see section 9.7.
  • Backup transitions and expirations are performed automatically according to the configured lifecycle.
  • A default or custom IAM role must exist in AWS to create and manage backups on behalf of N2WS. The IAM identity contains the backup and restore policies allowing operations on EFS. If a default was not automatically created, or you prefer to use a custom IAM role, see section 2.

Configuring EFS

  1. In the AWS Console, create the EFS in one of the available regions listed in section 8.

In N2WS, in the Backup Targets of a Policy, Add Elastic File Systems.

Configure the backup and restore options:

Complete the EFS Configuration:

Backup Vault – A logical backup container for your recovery points (your EFS snapshots) that allows you to organize your backups.

Note: Default Backup vaults are created in AWS: AWS Backup > Backup vaults.

IAM Role – An IAM identity that has specific permissions for EFS. The following AWS backup permissions should be attached to your IAM role:

  • AWSBackupServiceRolePolicyForBackup – Create backups on your behalf across AWS services.
  • AWSBackupServiceRolePolicyForRestores – Perform restores on your behalf across AWS services.
  • If a default IAM role was not automatically created by AWS, or you require a custom IAM role, see section 8.2. Selecting the preferred IAM role is only required during the EFS policy configuration.

Transition to cold – Select the transition lifecycle of a recovery point (your EFS snapshots). The default is Policy Generations.

Expire – When does a protected resource expire. The default is Never.

Note: Moving a backup to the Freezer will set Expiration Date to Never.

Creating IAM Roles in AWS

A default or custom IAM role is necessary for AWS to perform EFS operations on behalf of N2WS.

To create a default IAM Role:

  1. Go to the AWS Backup Service: https://us-east-1.console.aws.amazon.com/backup/
  2. Click the Create an on-demand backup button.
  3. For Resource type, select EBS.
  4. For Volume ID, select any EBS volume to backup.
  5. Select Default IAM Role.
  6. Click the Create on-demand backup button. Ignore the error provided by AWS.
  7. Verify that the following role was created on AWS IAM Service:


To create a custom IAM Role:

  1. Go to AWS IAM Service: https://console.aws.amazon.com/iam/home#/roles
  2. Click the Create role button.
  3. Select AWS Backup and click Next: Permissions.
  4. Search for BackupService.
  5. Select the following AWS managed policies:
    1. AWSBackupServiceRolePolicyForBackup
    2. AWSBackupServiceRolePolicyForRestores
  6. Click Next: Tags and then click Next: Review.
  7. Enter a Role name and click Create role.


Backup Options for EFS Instances

EFS can be configured by creating the cpm backup tag with the following values. In this case, N2WS will override the EFS configuration with the tag values:

Key Value
vault Vault. Example: Default
role_arn Arn of role. Example: arn:aws:iam::040885004714:role/service-role/AWSBackupDefaultServiceRole
cold_opt Lifecycle transition:

N – Never

D – Days

W – Weeks

M – Months

Y – Years

cold_opt_val Integer for D, W, M, Y only
exp_opt When does resource expire:

P – Policy Generations

N – Never

D – Days

W- Weeks

M – Months

Y – Years

exp_opt_val Integer for D, W, M, Y only


cpm backup my_policy+vault=Default+exp_opt=D+exp_opt_val=1

CPM will backup EFS to the default vault, and set its expiration date to 1 day.

Note: The max length for the cpm backup value is limited to 256 characters.

Share this post →

Share on twitter
Share on linkedin
Share on facebook
Share on email

Limited Time Offer:

Activate a free trial of N2WS —and get $250

Try N2WS Backup & Recovery today —and we'll give you $250 in AWS credits.

*All new active trials will receive $250 in AWS credits for a limited time!