You can subscribe to notifications for the following block storage events: system events, data disk attaching or detaching, disk retaining, and disk release due to overdue payments.

Event list

You can subscribe to notifications for the following block storage events:

System events

Block storage system events are caused only by exceptions. ECS sends two notifications: one at the start time of the event and one at the end time. For the event notification names of different system events, see Appendix: event notification names.

The following are example notifications for a Stalled event that has severe impact on disk performance.

  • The initial notification that ECS sends you contains the executeStartTime field:
    {
      "ver": "1.0",
      "id": "2256A988-0B26-4E2B-820A-8A********E5",
      "product": "ECS",
      "resourceId": "acs:ecs:cn-hangzhou:169070********30:disk/d-t4ndyqve********n4ds",
      "level": "CRITICAL",
      "name": "Disk:Stalled:Executing",
      "userId": "169070********30",
      "eventTime": "20190410T080101.922+0800",
      "regionId": "cn-hangzhou",
      "content": {
        "eventId": "e-t4navn7********6x5no",
        "diskId": "d-t4ndyqve********n4ds",
        "device": "/dev/xvdb",
        "eventType": "Stalled",
        "executeStartTime": "2019-04-10T01:01:01Z",
        "ecsInstanceId": "i-bp1ecr********5go2go",
        "ecsInstanceName": "ecs-instance-name"
      }
    }
  • The notification that ECS sends you when the event ends contains the executeFinishTime field:
    {
      "ver": "1.0",
      "id": "2256A988-0B26-4E2B-820A-8A********E5",
      "product": "ECS",
      "resourceId": "acs:ecs:cn-hangzhou:169070********30:disk/d-t4ndyqve********n4ds",
      "level": "CRITICAL",
      "name": "Disk:Stalled:Executing",
      "userId": "169070********30",
      "eventTime": "20190410T080301.922+0800",
      "regionId": "cn-hangzhou",
      "content": {
        "eventId": "e-t4navn7********6x5no",   
        "diskId": "d-t4ndyqve********n4ds",    
        "device": "/dev/xvdb",                 
        "eventType": "Stalled",                
        "executeStartTime": "2019-04-10T01:01:01Z",   
        "executeFinishTime": "2019-04-10T01:03:01Z",  
        "ecsInstanceId": "i-bp1ecr********5go2go",    
        "ecsInstanceName": "ecs-instance-name"        
      }
    }
The following table describes sub-fields in the content field.
Field Description Example
eventId The ID of the event. e-t4navn7********6x5no
diskId The ID of the block storage device whose performance is affected. d-t4ndyqve********n4ds
device The mount point of the block storage device. /dev/xvdb
eventType The type of the event. Valid values:
  • Degraded: The disk performance is degraded.
  • SeverelyDegraded: The disk performance is severely degraded.
  • Stalled: The disk performance is severely affected.
Stalled
executeStartTime The time when the event starts (UTC+0). 2019-04-10T01:01:01Z
executeFinishTime The time when the event ends (UTC+0). 2019-04-10T01:03:01Z
ecsInstanceId The ID of the ECS instance to which the block storage device is attached. i-bp1ecr********5go2go
ecsInstanceName The name of the ECS instance to which the block storage device is attached. ecs-instance-name

Data disk attaching or detaching

After a data disk is attached or detached, ECS sends you a notification to indicate whether the operation succeeded. For more information, see Attach a cloud disk and Detach a cloud disk.

The event notification in JSON format is as follows:

{
  "ver": "1.0",
  "id": "2256A988-0B26-4E2B-820A-8A********E5",
  "product": "ECS",
  "resourceId": "acs:ecs:cn-hangzhou:169070********30:disk/d-t4ndyqve********n4ds",
  "level": "INFO",
  "name": "Disk:DiskOperationCompleted",
  "userId": "169070********30",
  "eventTime": "20190409T121826.922+0800",
  "regionId": "cn-hangzhou",
  "content": {
      "diskId" : "d-t4ndyqve********n4ds",
      "operation" : "AttachDisk",
      "result" : "accomplished"
  }
}
The following table describes sub-fields in the content field.
Field Description Example
diskId The ID of the data disk. d-bp1bwa********9ol4mi
operation The operation type. Valid values:
  • AttachDisk: Attaches a disk.
  • DetachDisk: Detaches a disk.
AttachDisk
result The operation result. Valid values:
  • accomplished: The operation succeeded.
  • failed: The operation failed.
Note The event level is INFO if the operation succeeded. The event level is WARN if the operation failed.
accomplished

Disk retaining

When you release an ECS instance, you can retain the data disks by clearing Release with Instance and converting the attached disks (system disks and data disks) to pay-as-you-go disks. For more information, see Release a disk.

The event notification in JSON format is as follows:
{
    "ver": "1.0",
    "id": "2256A988-0B26-4E2B-820A-8A0580D0B8E5",
    "product": "ECS",
    "resourceId": "acs:ecs:cn-hangzhou:169070********30:disk/d-t4ndyqve********n4ds",
    "level": "INFO",
    "instanceName": "disk-event-subscription",
    "name": "Disk:ConvertToPostpaidCompleted",
    "userId": "169070********30",
    "eventTime": "20190409T121826.922+0800",
    "regionId": "cn-hangzhou",
    "content": {
    "diskId" : "d-t4ndyqve********n4ds",
    "result" : "accomplished"
    },
}
The following table describes sub-fields in the content field.
Field Description Example
diskId The ID of the disk. d-bp1bwa********9ol4mi
result The operation result. Valid values:
  • accomplished: The operation succeeded.
  • failed: The operation failed.
accomplished

Disk release due to overdue payments

You may receive a disk release notification in the following scenarios:
  • You purchased a disk in a mainland China region but your account does not pass the real-name verification. As a result, subscription disks cannot be converted to pay-as-you-go disks.
  • Your pay-as-you-go disk is released because there is an overdue payment in your account.
The event notification in JSON format is as follows:
{
    "ver": "1.0",
    "id": "2256A988-0B26-4E2B-820A-8A0580D0B8E5",
    "product": "ECS",
    "resourceId": "acs:ecs:cn-hangzhou:169070********30:disk/d-t4ndyqve********n4ds",
    "level": "CRITICAL",
    "instanceName": "disk-event-subscription",
    "name": "Disk:OverduePaymentRelease",
    "userId": "169070********30",
    "eventTime": "20190409T121826.922+0800",
    "regionId": "cn-hangzhou",
    "content": {
    "instanceId" : "i-bp1792********an2ukf",
    "diskId" : "d-t4ndyqve********n4ds"
    },
}
The following table describes sub-fields in the content field.
Field Description Example
instanceId The ID of the instance to which the disk is attached. i-bp1792********an2ukf
diskId The ID of the disk. d-bp1bwa********9ol4mi

Appendix: event notification names

Event Event type and code Event notification name and code
Performance impact Severe impact on disk performance: Stalled
  • Start of severe impact on disk performance: Disk:Stalled:Executing
  • End of severe impact on disk performance: Disk:Stalled:Executed
Local disk damage Local disks damaged (ErrorDetected)
  • Start of local disk damage alert: Disk:ErrorDetected:Executing
  • End of local disk damage alert: Disk:ErrorDetected:Executed