3.3.6 List Clones and Snapshots of Exascale Files
To display information about related Exascale files, clones, and snapshots, use the ESCLI lssnapshots
command. This command has two principal modes of operation:
-
To display information about the snapshots that are based on a specific file, use the
lssnapshots
command and specify the file that is the subject of the command. The specified file can be a snapshot, clone, or regular file. For example:@> lssnapshots @my-vault-name/file1 name @my-vault-name/file1 @my-vault-name/snap2-of-file1 @my-vault-name/snap1-of-file1
As shown in the example, a simple form of the command displays the snapshots that are directly based on the specified file.
Using the command options available with the
lssnapshots
command, you can also:- Filter the output according to your specified conditions.
- Sort the output using specific attributes.
- Choose to display output with different levels of detail.
-
To display information about related files, clones, and snapshots, use the
lssnapshots
command and specify a file name in conjunction with the--all
option or the--tree
option.Both options display information about all files, clones, and snapshots belonging to the snapshot tree that contains the specified file. The specified file can be a snapshot, clone, or regular file at any level in the snapshot tree. No other command options are permitted in conjunction with the
--all
option or the--tree
option.For example, consider a group of related files that is based on the following command sequence:
@my-vault-name/> putfile some-local-file file1 Putting file some-local-file to @my-vault-name/file1 Success. @my-vault-name/> snapshotfile file1 snap1-of-file1 Success. @my-vault-name/> clonefile file1 clone1 Success. @my-vault-name/> snapshotfile file1 snap2-of-file1 Success. @my-vault-name/> snapshotfile clone1 snap1-of-clone1 Success.
The following example shows how to display related files using the
--all
command option. The output is presented in a series of lists. The first list contains the files and clones in the snapshot tree. The remaining output lists snapshots that are grouped by their source file.@> lssnapshots @my-vault-name/clone1 --all ---FILE/CLONES:--- 2022-05-02 06:14:41 UTC @my-vault-name/file1 2022-05-02 06:15:15 UTC @my-vault-name/clone1 ---SNAPSHOTS:--- @my-vault-name/file1 2022-05-02 06:15:06 UTC @my-vault-name/snap1-of-file1 2022-05-02 06:15:15 UTC @my-vault-name/?8000_0000_000a:00000001 2022-05-02 06:15:24 UTC @my-vault-name/snap2-of-file1 @my-vault-name/clone1 2022-05-02 06:15:45 UTC @my-vault-name/snap1-of-clone1
Note that the command output includes an internal snapshot (
@my-vault-name/?8000_0000_000a:00000001
), which was implicitly created as part of the cloning operation to create@my-vault-name/clone1
.The following example shows how to display related files in a snapshot tree using the
--tree
command option.@> lssnapshots @my-vault-name/clone1 --tree +---- [1] @my-vault-name/snap1-of-file1 +---- [2] @my-vault-name/?8000_0000_000a:00000001 | |`---+---- [4] @my-vault-name/snap1-of-clone1 | +---- [6] @my-vault-name/clone1 | +---- [3] @my-vault-name/snap2-of-file1 +---- [5] @my-vault-name/file1
Parent topic: Administer Exascale Files