create_replication_job

SMS.Client.create_replication_job(**kwargs)

Creates a replication job. The replication job schedules periodic replication runs to replicate your server to Amazon Web Services. Each replication run creates an Amazon Machine Image (AMI).

See also: AWS API Documentation

Request Syntax

response = client.create_replication_job(
    serverId='string',
    seedReplicationTime=datetime(2015, 1, 1),
    frequency=123,
    runOnce=True|False,
    licenseType='AWS'|'BYOL',
    roleName='string',
    description='string',
    numberOfRecentAmisToKeep=123,
    encrypted=True|False,
    kmsKeyId='string'
)
Parameters
  • serverId (string) --

    [REQUIRED]

    The ID of the server.

  • seedReplicationTime (datetime) --

    [REQUIRED]

    The seed replication time.

  • frequency (integer) -- The time between consecutive replication runs, in hours.
  • runOnce (boolean) -- Indicates whether to run the replication job one time.
  • licenseType (string) -- The license type to be used for the AMI created by a successful replication run.
  • roleName (string) -- The name of the IAM role to be used by the Server Migration Service.
  • description (string) -- The description of the replication job.
  • numberOfRecentAmisToKeep (integer) -- The maximum number of SMS-created AMIs to retain. The oldest is deleted after the maximum number is reached and a new AMI is created.
  • encrypted (boolean) -- Indicates whether the replication job produces encrypted AMIs.
  • kmsKeyId (string) --

    The ID of the KMS key for replication jobs that produce encrypted AMIs. This value can be any of the following:

    • KMS key ID
    • KMS key alias
    • ARN referring to the KMS key ID
    • ARN referring to the KMS key alias

    If encrypted is true but a KMS key ID is not specified, the customer's default KMS key for Amazon EBS is used.

Return type

dict

Returns

Response Syntax

{
    'replicationJobId': 'string'
}

Response Structure

  • (dict) --

    • replicationJobId (string) --

      The unique identifier of the replication job.

Exceptions

  • SMS.Client.exceptions.InvalidParameterException
  • SMS.Client.exceptions.MissingRequiredParameterException
  • SMS.Client.exceptions.UnauthorizedOperationException
  • SMS.Client.exceptions.OperationNotPermittedException
  • SMS.Client.exceptions.ServerCannotBeReplicatedException
  • SMS.Client.exceptions.ReplicationJobAlreadyExistsException
  • SMS.Client.exceptions.NoConnectorsAvailableException
  • SMS.Client.exceptions.InternalError
  • SMS.Client.exceptions.TemporarilyUnavailableException