snapshot list

Definition

Lists all snapshots of a bucket.

Usage

$ ozone sh snapshot list [-hV] [-p=<prefix>]
                               [-s=<startItem>]
                               [[-l=<limit>] | [-a]]
                               <value>
Arguments
Parameter Description

prefix

A name prefix to filter the items

startItem

The item to start listing from. The chosen item will not appear in the results

limit

Maximum number of the results to list. The default value is 100

-a, --all

If specified, the command will display all the results. By default, it is specified. To counter it, use the -l parameter

value

A bucket URI. It can be a full URI (starts with o3://, e.g. o3://hostname:9862/vol1/bucket1/) or a short URI (starts with a volume name, e.g. vol1/bucket1). Any missing information is obtained from the configuration files

-h, --help

Prints out a help manual for this command

-V, --version

Prints out version information and exits

Examples

List all snapshots of a bucket:

$ ozone sh snapshot list vol1/bucket2

The output depends on the bucket, but should be similar to the following:

 [ {
  "volumeName" : "vol1",
  "bucketName" : "bucket2",
  "name" : "oldsnap",
  "creationTime" : 1740353795458,
  "snapshotStatus" : "SNAPSHOT_ACTIVE",
  "snapshotId" : "e36a629c-b976-4cb1-b8aa-5b4f4beaf5ca",
  "snapshotPath" : "vol1/bucket2",
  "checkpointDir" : "-e36a629c-b976-4cb1-b8aa-5b4f4beaf5ca",
  "referencedSize" : 0,
  "referencedReplicatedSize" : 0,
  "exclusiveSize" : 0,
  "exclusiveReplicatedSize" : 0
}, {
  "volumeName" : "vol1",
  "bucketName" : "bucket2",
  "name" : "s20250223-232331.183",
  "creationTime" : 1740353011183,
  "snapshotStatus" : "SNAPSHOT_ACTIVE",
  "snapshotId" : "c10f2b45-5f40-4b25-ae0c-ce617e5909a0",
  "snapshotPath" : "vol1/bucket2",
  "checkpointDir" : "-c10f2b45-5f40-4b25-ae0c-ce617e5909a0",
  "referencedSize" : 0,
  "referencedReplicatedSize" : 0,
  "exclusiveSize" : 0,
  "exclusiveReplicatedSize" : 0
} ]
Found a mistake? Seleсt text and press Ctrl+Enter to report it