Monitor the status of Amazon EBS volume initialization
When you create a volume from a snapshot, you can monitor the status of the volume initialization to determine whether the initialization process is complete. You can monitor volume initialization using the following options:
Amazon CLI and Amazon EC2 console
You can use the Amazon CLI and Amazon EC2 console to check the status of the volume initialization at any time after the volume has been created. The following information is provided:
-
Initialization type (Amazon CLI only) — Indicates the type of volume initialization used.
default
for fast snapshot restore and default volume initialization, andprovisioned-rate
for Amazon EBS Provisioned Rate for Volume Initialization. -
Estimated time to completion (Amazon CLI only) — Only for volumes created using a Amazon EBS Provisioned Rate for Volume Initialization. The estimated remaining time, in seconds, for the volume initialization to complete.
-
Progress — The progress, as a percentage (0-100), for the volume initialization process. For volumes initialized with fast snapshot restore, the progress moves to 100 percent immediately after creation.
-
Initialization state — The overall state of the volume initialization (
initializing
orcompleted
). For volumes initialized with fast snapshot restore, the state moves to completed immediately after creation.
Note
It can take up to 5 minutes for the volume initialization information to be updated.
Amazon EventBridge
An Amazon EventBridge event is sent to your account within five minutes after the volume initialization has completed. You can create rules that trigger programmatic actions in response to these events.
Note
-
Events are emitted on a best effort basis.
-
If you delete the volume before initialization completes, or within 5 minutes after initialization completes, you might not receive the event.
For more information about the event, see EBS volume initialization event.
To monitor status of volume initialization using EventBridge
Open the Amazon EventBridge console at https://console.amazonaws.cn/events/
. -
Choose Rules, Create rule.
-
For Step 1, do the following:
-
Specify a name and description for the rule.
-
For Event bus, choose the bus to receive the events. If you haven't created a custom event bus, keep default, or see Creating an event bus.
-
For Rule type, keep Rule with an event pattern.
-
Choose Next.
-
-
For Step 2, do the following:
-
For Event source, keep Amazon events or EventBridge partner events.
-
For Creation method, choose Custom pattern (JSON editor).
-
For Event pattern, add the following:
{ "detail-type": ["EBS Volume Notification"], "source": ["aws.ec2"], "detail": { "event": ["initializeVolume"], "result": ["succeeded"] } }
For an example event, see EBS volume initialization event.
-
Choose Next.
-
-
For Step 3, do the following:
-
For Target types, choose Amazon service.
-
For Select target, choose SNS topic, and for Topic select the required topic. If you haven't created any topics, see Creating a topic.
-
For Permissions, keep Use execution role (recommended) selected.
-
For Execution role, keep Create a new role for this specific resource selected and the defauly role name.
-
Choose Next.
-
-
For Step 4, specify tags for the rule if needed, and then choose Next.
-
For Step 5, review the rule and then choose Create rule.