Skip to main content

We've Moved!

Product Documentation has moved to docs.hitachivantara.com
Hitachi Vantara Knowledge

Get file system snapshots

Retrieves all file system snapshots by file system ID filtered by appSearchId.

HTTP request syntax (URI)
GET <base_URI>/v7/storage/filesystem-snapshots/{filesystemId}/{appSearchId}
Parameters
Name Type Required Values Description
filesystemId URI_PARAM Y string Unique identity of the file system.
appSearchId URI_PARAM Y string A filter string to be used to filter out snapshots. When it is null, all available snapshots are retrieved. This is the appSearchId used to create a snapshot. User is recommended to give a specific appSearchId to speed up search. If appSearchId is not known or you do not care, a special wildcard value “null” can be used to retrieve all available snapshots, which includes snapshots not created by application. (see example) Therefore caution should be taken when managing them. Note that when the file system is not in the mounted state, an empty result may be returned without errors. When it is not null, only snapshots created with this appSearchId are retrieved. When the file system is not in the mounted state, an error is returned.

Warning: This API allows you to retrieve all snapshots, which includes system created ones and modifying or deleting automatically created system snapshots may result in unexpected behavior.

Return codes
Code Data Description
200 snapshot File system snapshot successfully retrieved
400 No Data Missing or invalid request contents.
404 Error Message Requested resource not found.
500 Error message Error associated with the storage system.
501 No Data Server has not implemented the request operation on the resource.

Any HTTP status code other than 200 indicates that the API did not complete successfully.

Request example using special wildcard appSearchId “null” to retrieve all snapshots.
curl -vk -H "X-Api-Key: zrxvSDAv9x.RIP4gkmKarG3beF.or.4Tc2im7oeqYN88C9XPGHxbXC"  https://172.17.57.75:8444/v7/storage/filesystem-snapshots/ 75412709E1CB9AAB0000000000000000/null -X GET
Response example
HTTP/1.1 200 OK
{
  "snapshots":
  [
     {
         "creationReason" : "SNAPSHOT_CREATED_BY_HSR",
         "creationTime" : 1469740945,
         "displayName" : "AUTO_SNAPSHOT_22c97d50-e916-11d1-9b15-5ec00375458d_1",
         "filesystemId" : "75412709E1CB9AAB0000000000000000",
         "objectId" : "37353431323730394531434239414142303030303030303030303030303030303a3a3a4155544f5f534e415053484f545f32326339376435302d653931362d313164312d396231352d3565633030333735343538645f31",
         "state" : "SNAPSHOT_MANAGEMENT_STATE_USABLE"
      },
      {
         "creationReason" : "SNAPSHOT_CREATED_BY_HSR",
         "creationTime" : 1469740349,
         "displayName" : "AUTO_SNAPSHOT_bfbac044-e914-11d1-9b13-5ec00375458d_1",
         "filesystemId" : "75412709E1CB9AAB0000000000000000",
         "objectId" : "37353431323730394531434239414142303030303030303030303030303030303a3a3a4155544f5f534e415053484f545f62666261633034342d653931342d313164312d396231332d3565633030333735343538645f31",
         "state" : "SNAPSHOT_MANAGEMENT_STATE_USABLE"
      } 
	]
}
Request example with specific appSearchId “Metro” to retrieve all snapshots with “Metro” prefix
curl -vk -H "X-Api-Key: zrxvSDAv9x.RIP4gkmKarG3beF.or.4Tc2im7oeqYN88C9XPGHxbXC"  https://172.17.57.75:8444/v7/storage/filesystem-snapshots/75412709E1CB9AAB0000000000000000/Metro -X GET
Response example with specific appSearchId “Metro” to retrieve all snapshots with “Metro” prefix
{
   "snapshots" : [
      {
         "creationReason" : "SNAPSHOT_CREATED_BY_APPLICATION",
         "creationTime" : 1585155275,
         "displayName" : "Metro-xyz-fs2-ss-test2",
         "filesystemId" : "AF0BFEDC1CF3BCC70000000000000000",
         "objectId" : "41463042464544433143463342434337303030303030303030303030303030303a3a3a4d6574726f2d6e69636b2d6673322d73732d74657374323a3a3a3a3a3a303a3a3a4f49445f24232140255f56",
         "state" : "SNAPSHOT_MANAGEMENT_STATE_USABLE"
      },
      {
         "creationReason" : "SNAPSHOT_CREATED_BY_APPLICATION",
         "creationTime" : 1585153895,
         "displayName" : "Metro-xyz-fs2-ss-test1",
         "filesystemId" : "AF0BFEDC1CF3BCC70000000000000000",
         "objectId" : "41463042464544433143463342434337303030303030303030303030303030303a3a3a4d6574726f2d6e69636b2d6673322d73732d74657374313a3a3a3a3a3a303a3a3a4f49445f24232140255f56",
         "state" : "SNAPSHOT_MANAGEMENT_STATE_USABLE"
      }
   ]
}

 

  • Was this article helpful?