Open topic with navigation

# Creating the Elastic File System

Amazon Elastic File System (Amazon EFS) provides a simple, scalable, fully managed elastic NFS file system. You can create an EFS through the web UI or the CLI.

To create an EFS using the web UI:

1. Using the Find Services search tool, locate and browse to the EFS dashboard.

1. Click Create file system.

1. On the Create file system dialog:
   1. In Name, specify a name for the EFS.
   2. Under Virtual Private Cloud (VPC), select the VPC you recorded in your AWS worksheet.
   3. Click Customize to start the custom EFS wizard.
2. On the File system settings page:
   1. In General, deselect Enable encryption of data at rest.
   2. In Tags, add one or more identification tags as desired.
   3. Click Next.

3. On the Network Access page:
   1. Under Mount Targets, for each target:
   2. Under Subnet ID, select the subnet ID of the private subnet.
   3. Change the Security groups by adding the Intra VPC security group to the dropdown, and remove any other security groups from the list.
   4. Click Next.

4. On the File system policy - optional page, leave all settings as is and click Next.

5. On the Review and create page, review all settings for accuracy, then click Create. You are redirected to the EFS dashboard.
The creation process may take a few moments; please give the process time to complete.
6. Record the File system ID in the AWS worksheet.

To create the EFS using the CLI:

1. Run the following command to create an encrypted EFS file system:

    aws efs create-file-system \
    --encrypted \
    --tags Key=Name,Value=<EFS name chosen for easy identification>

Example input and output:

    aws efs create-file-system \
    --encrypted \
    --tags Key=Name,Value=srgdemo-efs

    {
       "OwnerId":"115370811111",
       "CreationToken":"a53deaf5-ecd6-4dfa-9206-0e1a3db3e1d9",
       "FileSystemId":"fs-ebe456b3",
       "CreationTime":1589557528.0,
       "LifeCycleState":"creating",
       "Name":"srgdemo-efs",
       "NumberOfMountTargets":0,
       "SizeInBytes":{
          "Value":0,
          "ValueInIA":0,
          "ValueInStandard":0
       },
       "PerformanceMode":"generalPurpose",
       "Encrypted":true,
       "ThroughputMode":"bursting",
       "Tags":[
          {
             "Key":"Name",
             "Value":"srgdemo-efs"
          }
       ]

2. From the description, record the `FileSystemId` in the AWS worksheet.
3. Examine the value of `LifeCycleState`. Provisioning is complete when the value changes to `available`. (In the example, it has the value `creating`.)

4. To check the provisioning status while the process is running, run the following command:

       aws efs describe-file-systems \
       --file-system-id <FileSystemId>

   Provisioning usually takes approximately 5 minutes.

   Example input and output:

       aws efs describe-file-systems --file-system-id fs-ebe456b3

       {
          "FileSystems":[
             {
                "OwnerId":"115370811111",
                "CreationToken":"a53deaf5-ecd6-4dfa-9206-0e1a3db3e1d9",
                "FileSystemId":"fs-ebe456b3",
                "CreationTime":1589557528.0,
                "LifeCycleState":"available",
                "Name":"srgdemo-efs",
                "NumberOfMountTargets":0,
                "SizeInBytes":{
                   "Value":6144,
                   "ValueInIA":0,
                   "ValueInStandard":6144
                },
                "PerformanceMode":"generalPurpose",
                "Encrypted":true,
                "ThroughputMode":"bursting",
                "Tags":[
                   {
                      "Key":"Name",
                      "Value":"srgdemo-efs"
                   }
                ]
             }
          ]
       }

Next Step: Create Mount Targets