Deleting snapshots

Virtual Storage Platform One SDS Block Storage Administrator Guide

Version
1.17.x
Audience
anonymous
Part Number
MK-24VSP1SDS002-04

When snapshot volumes are no longer necessary, you can delete them as follows.

It is impossible to delete snapshot volumes from the VSP One SDS Block Administrator.

When you perform editing, note the following points:

  • If the path (volume path) between the snapshot volume and the compute node is set, the snapshot volume cannot be deleted. Disconnect the snapshot volume from the compute node before deleting it.

  • You can delete a snapshot only when the snapshot is in Prepared, Normal, or Error state.

  • A snapshot that is the copy source of another existing snapshot cannot be deleted.

  • To delete the S-VOL, run the snapshot deletion command.

  • To delete the P-VOL, run the snapshot deletion command to delete all the snapshot volumes (S-VOL) that were created from the P-VOL to be deleted. Then, run the volume deletion command to delete the P-VOL (which is now a normal volume due to S-VOL deletion).

  • To delete the P/S-VOL, run the snapshot deletion command to delete all the snapshot volumes (S-VOL) that were created from the P/S-VOL to be deleted. Then, run the volume deletion command to delete the P/S-VOL (which is now a S-VOL due to S-VOL deletion).
CAUTION:
  • A snapshot cannot be restored by restoring the storage cluster configuration according to the procedure in Performing the configuration backup operation (Bare metal). A system administrator or users need to delete all the restored snapshot volumes and volume paths.

  • Deleting some snapshots in the snapshot tree will not reduce the storage pool usage because the space allocated for data in snapshot volumes in the storage pool will not be released. The unreleased space will be used again when storing new data in snapshot volumes. If you want to reduce the usage of the storage pool, you need to delete all snapshots created in the corresponding snapshot tree.

  • Required role: Storage

  • When deleting snapshot volumes in a VPS: Scope of the VPS

  1. When you are not using the multi-tenancy function or when you are using the multi-tenancy function and you delete snapshot volumes in a system scope, you can skip this task. Go to the next step.

    When deleting snapshot volumes in a VPS, verify the VPS ID.

    If you want to specify a VPS by its name in the CLI, verify the VPS name.

    REST API: GET /v1/objects/virtual-private-storages

    CLI: vps_list

  2. Verify the ID of the volume (P-VOL or S-VOL).

    If you use the CLI to specify P-VOL and S-VOL by name, check the names of P-VOL and S-VOL.

    REST API: GET /v1/objects/volumes

    CLI: volume_list

  3. Obtain information of the snapshot volumes to be deleted, and verify that snapshotStatus is "Prepared", "Normal" or "Error."

    Run either of the following commands with the volume ID specified.

    If you want to use the CLI, you can specify the name of the volume instead of its ID.

    REST API: GET /v1/objects/volumes/<id>

    CLI: volume_show

    After verification, go to the next step.

  4. Delete the snapshot volumes.

    Run either of the following commands with the S-VOL ID of the volume to be deleted specified.

    If you use the CLI, you can specify the name of the S-VOL instead of its ID.

    REST API: POST /v1/objects/volumes/actions/delete-snapshot/invoke

    CLI: volume_delete_snapshot

    Verify the job ID which is displayed after the command is run.

  5. Verify the state of the job.

    Run either of the following commands with the job ID specified.

    REST API: GET /v1/objects/jobs/<jobId>

    CLI: job_show

    If the job state is "Succeeded", the job is completed.

  6. Obtain a list of information about S-VOLs and verify that S-VOLs are deleted.

    Run either of the following commands with the P-VOL volume ID specified.

    If you use the CLI, you can specify a name instead of the ID of the volume.

    REST API: GET /v1/objects/volumes/<id>/snapshot-volumes

    CLI: snapshot_volume_list

    Note:

    If the snapshotStatus of an S-VOL becomes "Error" and the snapshot deletion command is unsuccessful even if the intended S-VOL is specified, you can delete all S-VOLs created from the P-VOL simultaneously by running the snapshot deletion command with the volume ID of the P-VOL and true specified for masterVolumeId and snapshotTree (for the REST API) and for --master_volume_id and --snapshot_tree (for the CLI), respectively. In performing this operation, if a command that performs an operation on a snapshot volume existing in the tree on the P-VOL is already being run by a prior job, the job might become unsuccessful. The job that runs the snapshot deletion command might also result in failure. If the job results in failure, rerun the command. For detailed operations, see POST/v1/objects/volumes/actions/delete-snapshot/invoke in the VSP One SDS Block REST API Reference and volume_delete_snapshot in the VSP One SDS Block CLI Reference.