5.2.5 Creating a snapshot
Function
This plug-in creates a snapshot as a backup for the volume managed in the Amazon EBS environment.
The prerequisite server for this plug-in is as follows:
- AWS operating server (execution target server)
AWS Tools for Windows PowerShell (AWS Tools below) is installed on this server. This product transfers plug-ins to this server for execution.
Scripts in this plug-in execute the following AWS Tools commandlet.
- New-EC2Snapshot -VolumeId "value-of-volume-ID(AWS.volumeId-property)"
[-Description "value-of-snapshot-explanation(AWS.snapshotDescription-property)"]
After executing the above commandlet, check that the status of the created snapshot changes to "completed".
For details of the AWS Tools commandlets, see the AWS document AWS Tools for Windows PowerShell Cmdlet Reference.
Use situation
This plug-in can be used to create a snapshot as a backup for volumes managed in the Amazon EBS environment.
Prerequisites
For the latest support status of the following items, see the Release notes: Prerequisite products within the system, prerequisite products on the execution target server, and running OS for prerequisite products on the execution target server.
Prerequisite product within the system:
- JP1/Automatic Operation 11-00 or later
Prerequisite products on the execution target server:
- AWS Tools for Windows PowerShell
- Microsoft .Net Framework 3.5 or later
Running OS for prerequisite products on the execution target server:
- Windows Server 2008 R2 Standard/Enterprise/Datacenter
- Windows Server 2012 Standard/Datacenter or Windows Server 2012 R2 Standard/Datacenter
However, a Server Core installation environment is excluded.
Cautions
(1) Do not use a character string containing a double quotation mark (") or single quotation mark (') in a plug-in property.
(2) For other cautions, see the descriptions about cautions in the AWS document AWS Tools for Windows PowerShell Cmdlet Reference.
Execution privilege
(1) A policy setting is required so that an IAM user who logs in to AWS can perform the following action:
- Creating a snapshot
Version
02.00.01
Plug-in tags
Snapshot VM,AWS
Plug-in name displayed in the task log
awsCreateSnapshot
Return code
0: Normal
12: Error (Mistake by user) Invalid property
23: Error (Invalid environment) The environment requirements are not met.
27: Error (Check with the task log about the error details.) Unidentified error
41: Error (An error was detected in the component.) Property not entered (An error was detected in the component script.)
Property list
The following table lists the properties:
Property key |
Property name |
Description |
Default value |
I/O type |
Required |
---|---|---|---|---|---|
plugin.destinationHost |
Host name of the execution target server |
Specify the host name or IP address of the server on which this plugin will be executed. IPv6 addresses are not supported. |
-- |
Input |
R |
AWS.accessKeyId |
Access key ID |
Specify the access key ID for connecting to AWS. |
-- |
Input |
R |
AWS.secretAccessKey |
Secret access key |
Specify the secret access key for connecting to AWS. |
-- |
Input |
R |
AWS.region |
Region |
Specify an AWS region that is a connection destination. |
-- |
Input |
R |
AWS.volumeId |
Volume ID |
Specify the volume ID. |
-- |
Input |
R |
AWS.snapshotDescription |
Explanation of the snapshot |
Specify an explanation to be set for the snapshot you want to create. |
-- |
Input |
O |
AWS.checkSnapshotCreationCount |
Number of times to check whether snapshot creation is completed |
Specify the number of times to check whether snapshot creation is completed. The maximum wait time is comprised of this value and the interval to check whether snapshot creation is completed. |
-- |
Input |
R |
AWS.checkSnapshotCreationInterval |
Interval to check whether snapshot creation is completed |
Specify the interval (units: seconds) to check whether snapshot creation is completed. |
-- |
Input |
R |
AWS.outSnapshotId |
Snapshot ID |
The ID of the created snapshot is stored here. |
-- |
Output |
O |
common.returnValue |
Return value for the plugin |
The return value of this plugin stored. |
-- |
Output |
O |