Menu
AWS Database Migration Service
API Reference (API Version 2016-01-01)

CreateReplicationInstance

Creates the replication instance using the specified parameters.

Request Syntax

{ "AllocatedStorage": number, "AutoMinorVersionUpgrade": boolean, "AvailabilityZone": "string", "EngineVersion": "string", "KmsKeyId": "string", "MultiAZ": boolean, "PreferredMaintenanceWindow": "string", "PubliclyAccessible": boolean, "ReplicationInstanceClass": "string", "ReplicationInstanceIdentifier": "string", "ReplicationSubnetGroupIdentifier": "string", "Tags": [ { "Key": "string", "Value": "string" } ], "VpcSecurityGroupIds": [ "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.

AllocatedStorage

The amount of storage (in gigabytes) to be initially allocated for the replication instance.

Type: Integer

Required: No

AutoMinorVersionUpgrade

Indicates that minor engine upgrades will be applied automatically to the replication instance during the maintenance window.

Default: true

Type: Boolean

Required: No

AvailabilityZone

The EC2 Availability Zone that the replication instance will be created in.

Default: A random, system-chosen Availability Zone in the endpoint's region.

Example: us-east-1d

Type: String

Required: No

EngineVersion

The engine version number of the replication instance.

Type: String

Required: No

KmsKeyId

The KMS key identifier that will be used to encrypt the content on the replication instance. If you do not specify a value for the KmsKeyId parameter, then AWS DMS will use your default encryption key. AWS KMS creates the default encryption key for your AWS account. Your AWS account has a different default encryption key for each AWS region.

Type: String

Required: No

MultiAZ

Specifies if the replication instance is a Multi-AZ deployment. You cannot set the AvailabilityZone parameter if the Multi-AZ parameter is set to true.

Type: Boolean

Required: No

PreferredMaintenanceWindow

The weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC).

Format: ddd:hh24:mi-ddd:hh24:mi

Default: A 30-minute window selected at random from an 8-hour block of time per region, occurring on a random day of the week.

Valid Days: Mon, Tue, Wed, Thu, Fri, Sat, Sun

Constraints: Minimum 30-minute window.

Type: String

Required: No

PubliclyAccessible

Specifies the accessibility options for the replication instance. A value of true represents an instance with a public IP address. A value of false represents an instance with a private IP address. The default value is true.

Type: Boolean

Required: No

ReplicationInstanceClass

The compute and memory capacity of the replication instance as specified by the replication instance class.

Valid Values: dms.t2.micro | dms.t2.small | dms.t2.medium | dms.t2.large | dms.c4.large | dms.c4.xlarge | dms.c4.2xlarge | dms.c4.4xlarge

Type: String

Required: Yes

ReplicationInstanceIdentifier

The replication instance identifier. This parameter is stored as a lowercase string.

Constraints:

  • Must contain from 1 to 63 alphanumeric characters or hyphens.

  • First character must be a letter.

  • Cannot end with a hyphen or contain two consecutive hyphens.

Example: myrepinstance

Type: String

Required: Yes

ReplicationSubnetGroupIdentifier

A subnet group to associate with the replication instance.

Type: String

Required: No

Tags

Tags to be associated with the replication instance.

Type: Array of Tag objects

Required: No

VpcSecurityGroupIds

Specifies the VPC security group to be used with the replication instance. The VPC security group must work with the VPC containing the replication instance.

Type: Array of strings

Required: No

Response Syntax

{ "ReplicationInstance": { "AllocatedStorage": number, "AutoMinorVersionUpgrade": boolean, "AvailabilityZone": "string", "EngineVersion": "string", "InstanceCreateTime": number, "KmsKeyId": "string", "MultiAZ": boolean, "PendingModifiedValues": { "AllocatedStorage": number, "EngineVersion": "string", "MultiAZ": boolean, "ReplicationInstanceClass": "string" }, "PreferredMaintenanceWindow": "string", "PubliclyAccessible": boolean, "ReplicationInstanceArn": "string", "ReplicationInstanceClass": "string", "ReplicationInstanceIdentifier": "string", "ReplicationInstancePrivateIpAddress": "string", "ReplicationInstancePrivateIpAddresses": [ "string" ], "ReplicationInstancePublicIpAddress": "string", "ReplicationInstancePublicIpAddresses": [ "string" ], "ReplicationInstanceStatus": "string", "ReplicationSubnetGroup": { "ReplicationSubnetGroupDescription": "string", "ReplicationSubnetGroupIdentifier": "string", "SubnetGroupStatus": "string", "Subnets": [ { "SubnetAvailabilityZone": { "Name": "string" }, "SubnetIdentifier": "string", "SubnetStatus": "string" } ], "VpcId": "string" }, "SecondaryAvailabilityZone": "string", "VpcSecurityGroups": [ { "Status": "string", "VpcSecurityGroupId": "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.

ReplicationInstance

The replication instance that was created.

Type: ReplicationInstance object

Errors

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

AccessDeniedFault

AWS DMS was denied access to the endpoint.

HTTP Status Code: 400

InsufficientResourceCapacityFault

There are not enough resources allocated to the database migration.

HTTP Status Code: 400

InvalidResourceStateFault

The resource is in a state that prevents it from being used for database migration.

HTTP Status Code: 400

InvalidSubnet

The subnet provided is invalid.

HTTP Status Code: 400

KMSKeyNotAccessibleFault

AWS DMS cannot access the KMS key.

HTTP Status Code: 400

ReplicationSubnetGroupDoesNotCoverEnoughAZs

The replication subnet group does not cover enough Availability Zones (AZs). Edit the replication subnet group and add more AZs.

HTTP Status Code: 400

ResourceAlreadyExistsFault

The resource you are attempting to create already exists.

HTTP Status Code: 400

ResourceNotFoundFault

The resource could not be found.

HTTP Status Code: 400

ResourceQuotaExceededFault

The quota for this resource quota has been exceeded.

HTTP Status Code: 400

StorageQuotaExceededFault

The storage quota has been exceeded.

HTTP Status Code: 400

Example

Sample Request

POST / HTTP/1.1 Host: dms.<region>.<domain> x-amz-Date: <Date> Authorization: AWS4-HMAC-SHA256 Credential=<Credential>, SignedHeaders=contenttype;date;host;user-agent;x-amz-date;x-amz-target;x-amzn-requestid,Signature=<Signature> User-Agent: <UserAgentString> Content-Type: application/x-amz-json-1.1 Content-Length: <PayloadSizeBytes> Connection: Keep-Alive X-Amz-Target: AmazonDMSv20160101.CreateReplicationInstance { "ReplicationInstanceIdentifier":"test-rep-1", "AllocatedStorage":5, "ReplicationInstanceClass":"dms.t2.micro", "AvailabilityZone":"", "ReplicationSubnetGroupIdentifier":"default", "PreferredMaintenanceWindow":"", "EngineVersion":"1.5.0", "AutoMinorVersionUpgrade":true, "Tags":[ { "Key":"", "Value":"" } ], "KmsKeyId":"", "PubliclyAccessible":true }

Sample Response

HTTP/1.1 200 OK x-amzn-RequestId: <RequestId> Content-Type: application/x-amz-json-1.1 Content-Length: <PayloadSizeBytes> Date: <Date> { "ReplicationInstance":{ "PubliclyAccessible":true, "ReplicationInstanceArn":"arn:aws:dms:us-east- 1:152683116123:rep:PWEBBEUNOLU7VEB2OHTEH4I4GQ", "ReplicationInstanceClass":"dms.t2.micro", "ReplicationSubnetGroup":{ "ReplicationSubnetGroupDescription":"default", "Subnets":[ { "SubnetStatus":"Active", "SubnetIdentifier":"subnet-f6dd91af", "SubnetAvailabilityZone":{ "Name":"us-east-1d" } }, { "SubnetStatus":"Active", "SubnetIdentifier":"subnet-3605751d", "SubnetAvailabilityZone":{ "Name":"us-east-1b" } }, { "SubnetStatus":"Active", "SubnetIdentifier":"subnet-c2daefb5", "SubnetAvailabilityZone":{ "Name":"us-east-1c" } }, { "SubnetStatus":"Active", "SubnetIdentifier":"subnet-85e90cb8", "SubnetAvailabilityZone":{ "Name":"us-east-1e" } } ], "VpcId":"vpc-6741a603", "SubnetGroupStatus":"Complete", "ReplicationSubnetGroupIdentifier":"default" }, "AutoMinorVersionUpgrade":true, "ReplicationInstanceStatus":"creating", "KmsKeyId":"arn:aws:kms:us-east-1:152683116123:key/4dc17316-5543- 4ded-b1e3-d53a7cfb411d", "AllocatedStorage":5, "EngineVersion":"1.5.0", "ReplicationInstanceIdentifier":"test-rep-1", "PreferredMaintenanceWindow":"sun:06:00-sun:14:00", "PendingModifiedValues":{ } } }

See Also

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