Amazon FSx
API Reference

CreateFileSystemFromBackup

Creates a new Amazon FSx file system from an existing Amazon FSx for Windows File Server backup.

If a file system with the specified client request token exists and the parameters match, this operation returns the description of the file system. If a client request token specified by the file system exists and the parameters don't match, this call returns IncompatibleParameterError. If a file system with the specified client request token doesn't exist, this operation does the following:

  • Creates a new Amazon FSx file system from backup with an assigned ID, and an initial lifecycle state of CREATING.

  • Returns the description of the file system.

Parameters like Active Directory, default share name, automatic backup, and backup settings default to the parameters of the file system that was backed up, unless overridden. You can explicitly supply other settings.

By using the idempotent operation, you can retry a CreateFileSystemFromBackup call without the risk of creating an extra file system. This approach can be useful when an initial call fails in a way that makes it unclear whether a file system was created. Examples are if a transport level timeout occurred, or your connection was reset. If you use the same client request token and the initial call created a file system, the client receives success as long as the parameters are the same.

Note

The CreateFileSystemFromBackup call returns while the file system's lifecycle state is still CREATING. You can check the file-system creation status by calling the DescribeFileSystems operation, which returns the file system state along with other information.

Request Syntax

{ "BackupId": "string", "ClientRequestToken": "string", "SecurityGroupIds": [ "string" ], "SubnetIds": [ "string" ], "Tags": [ { "Key": "string", "Value": "string" } ], "WindowsConfiguration": { "ActiveDirectoryId": "string", "AutomaticBackupRetentionDays": number, "CopyTagsToBackups": boolean, "DailyAutomaticBackupStartTime": "string", "SelfManagedActiveDirectoryConfiguration": { "DnsIps": [ "string" ], "DomainName": "string", "FileSystemAdministratorsGroup": "string", "OrganizationalUnitDistinguishedName": "string", "Password": "string", "UserName": "string" }, "ThroughputCapacity": number, "WeeklyMaintenanceStartTime": "string" } }

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

The request accepts the following data in JSON format.

BackupId

The ID of the backup. Specifies the backup to use if you're creating a file system from an existing backup.

Type: String

Length Constraints: Minimum length of 12. Maximum length of 128.

Pattern: ^(backup-[0-9a-f]{8,})$

Required: Yes

ClientRequestToken

(Optional) A string of up to 64 ASCII characters that Amazon FSx uses to ensure idempotent creation. This string is automatically filled on your behalf when you use the AWS Command Line Interface (AWS CLI) or an AWS SDK.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 255.

Pattern: [A-za-z0-9_.-]{0,255}$

Required: No

SecurityGroupIds

A list of IDs for the security groups that apply to the specified network interfaces created for file system access. These security groups apply to all network interfaces. This value isn't returned in later describe requests.

Type: Array of strings

Array Members: Maximum number of 50 items.

Length Constraints: Minimum length of 11. Maximum length of 20.

Pattern: ^(sg-[0-9a-f]{8,})$

Required: No

SubnetIds

A list of IDs for the subnets that the file system will be accessible from. Currently, you can specify only one subnet. The file server is also launched in that subnet's Availability Zone.

Type: Array of strings

Array Members: Maximum number of 50 items.

Length Constraints: Minimum length of 15. Maximum length of 24.

Pattern: ^(subnet-[0-9a-f]{8,})$

Required: Yes

Tags

The tags to be applied to the file system at file system creation. The key value of the Name tag appears in the console as the file system name.

Type: Array of Tag objects

Array Members: Minimum number of 1 item. Maximum number of 50 items.

Required: No

WindowsConfiguration

The configuration for this Microsoft Windows file system.

Type: CreateFileSystemWindowsConfiguration object

Required: No

Response Syntax

{ "FileSystem": { "CreationTime": number, "DNSName": "string", "FailureDetails": { "Message": "string" }, "FileSystemId": "string", "FileSystemType": "string", "KmsKeyId": "string", "Lifecycle": "string", "LustreConfiguration": { "DataRepositoryConfiguration": { "ExportPath": "string", "ImportedFileChunkSize": number, "ImportPath": "string" }, "WeeklyMaintenanceStartTime": "string" }, "NetworkInterfaceIds": [ "string" ], "OwnerId": "string", "ResourceARN": "string", "StorageCapacity": number, "SubnetIds": [ "string" ], "Tags": [ { "Key": "string", "Value": "string" } ], "VpcId": "string", "WindowsConfiguration": { "ActiveDirectoryId": "string", "AutomaticBackupRetentionDays": number, "CopyTagsToBackups": boolean, "DailyAutomaticBackupStartTime": "string", "MaintenanceOperationsInProgress": [ "string" ], "SelfManagedActiveDirectoryConfiguration": { "DnsIps": [ "string" ], "DomainName": "string", "FileSystemAdministratorsGroup": "string", "OrganizationalUnitDistinguishedName": "string", "UserName": "string" }, "ThroughputCapacity": number, "WeeklyMaintenanceStartTime": "string" } } }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

FileSystem

A description of the file system.

Type: FileSystem object

Errors

For information about the errors that are common to all actions, see Common Errors.

ActiveDirectoryError

An Active Directory error.

HTTP Status Code: 400

BackupNotFound

No Amazon FSx backups were found based upon the supplied parameters.

HTTP Status Code: 400

BadRequest

A generic error indicating a failure with a client request.

HTTP Status Code: 400

IncompatibleParameterError

The error returned when a second request is received with the same client request token but different parameters settings. A client request token should always uniquely identify a single request.

HTTP Status Code: 400

InternalServerError

A generic error indicating a server-side failure.

HTTP Status Code: 500

InvalidNetworkSettings

One or more network settings specified in the request are invalid. InvalidVpcId means that the ID passed for the virtual private cloud (VPC) is invalid. InvalidSubnetIds returns the list of IDs for subnets that are either invalid or not part of the VPC specified. InvalidSecurityGroupIds returns the list of IDs for security groups that are either invalid or not part of the VPC specified.

HTTP Status Code: 400

MissingFileSystemConfiguration

File system configuration is required for this operation.

HTTP Status Code: 400

ServiceLimitExceeded

An error indicating that a particular service limit was exceeded. You can increase some service limits by contacting AWS Support.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: