获取一个或者多个符合条件的历史备份快照。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
调试
授权信息
|
操作 |
访问级别 |
资源类型 |
条件关键字 |
关联操作 |
|
hbr:SearchHistoricalSnapshots |
get |
*全部资源
|
无 | 无 |
请求参数
|
名称 |
类型 |
必填 |
描述 |
示例值 |
| SourceType |
string |
否 |
数据源类型。取值范围:
|
ECS_FILE |
| Query |
array |
是 |
查询条件。Query 示例如下:
|
[ { "field": "VaultId", "value": "v-0003rf9m17pap3ltpqx5", "operation": "MATCH_TERM" }, { "field": "InstanceId", "value": "i-bp1i20zq2wuzdie9368m", "operation": "MATCH_TERM" }, { "field": "PlanId", "value": "plan-0005vkqhpesqgkd1iu4f", "operation": "MATCH_TERM" }, { "field": "CompleteTime", "value": 1626769913, "operation": "GREATER_THAN_OR_EQUAL" } ] |
|
any |
否 |
查询条件。Query 示例如下:
|
[ { "field": "VaultId", "value": "v-0003rf9m17pap3ltpqx5", "operation": "MATCH_TERM" }, { "field": "InstanceId", "value": "i-bp1i20zq2wuzdie9368m", "operation": "MATCH_TERM" }, { "field": "PlanId", "value": "plan-0005vkqhpesqgkd1iu4f", "operation": "MATCH_TERM" }, { "field": "CompleteTime", "value": 1626769913, "operation": "GREATER_THAN_OR_EQUAL" } ] |
|
| Limit |
integer |
否 |
本次查询需要返回的最大数量。
如果只为了获取行数,无需具体数据,可以设置 |
10 |
| NextToken |
string |
否 |
获取下一页快照所需的 Token。 |
caeba0bbb2be03f84eb48b699f0a**** |
| SortBy |
string |
否 |
排序字段。 |
CreatedTime |
| Order |
string |
否 |
排序方式,默认值为 ASC。
|
ASC |
| Edition |
string |
否 |
版本类型,支持 BASIC 和 STANDARD,默认值为 STANDARD。 |
BASIC |
返回参数
|
名称 |
类型 |
描述 |
示例值 |
|
object |
|||
| NextToken |
string |
获取下一页快照所需的 Token。 |
BE |
| RequestId |
string |
请求 ID。 |
473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E |
| Success |
boolean |
请求是否成功。
|
true |
| Limit |
integer |
当前页显示历史快照数量。 |
10 |
| Code |
string |
返回码,200 表示成功。 |
200 |
| Message |
string |
返回信息描述,成功一般返回 successful,错误时会返回相应错误信息。 |
successful |
| TotalCount |
integer |
符合条件的快照总数。 |
20 |
| Snapshots |
object |
||
| Snapshot |
array<object> |
历史快照列表。 |
|
|
array<object> |
|||
| Status |
string |
备份快照任务的状态。取值范围:
|
COMPLETE |
| SnapshotHash |
string |
快照 HASH 值。 |
f2fe... |
| VaultId |
string |
保存备份库快照的仓库 ID。 |
v-0003rf9m17pap3ltpqx5 |
| ActualItems |
integer |
快照实际项目数。 说明
目前仅文件备份可用。 |
6 |
| BackupType |
string |
备份类型。取值为 COMPLETE,表示全量备份。 |
COMPLETE |
| CreateTime |
integer |
仅当 SourceType 取值为 NAS 时,该参数有效。表示文件系统创建时间。UNIX 时间,单位为秒。 |
1607436917 |
| ActualBytes |
integer |
去重后快照实际数据量。单位为字节。 |
600 |
| SourceType |
string |
数据源类型。取值范围:
|
ECS_FILE |
| Prefix |
string |
仅当 SourceType 取值为 OSS 时,该参数有效。表示备份前缀。 |
example/ |
| ClientId |
string |
仅当 SourceType 取值为ECS_FILE时,该参数有效。表示备份客户端 ID。 |
c-********************* |
| BytesTotal |
integer |
数据源总量。单位为字节。 |
1000 |
| ItemsDone |
integer |
备份项目数。 说明
目前仅文件备份可用。 |
8 |
| CompleteTime |
integer |
备份快照完成时间。UNIX 时间,单位为秒。 |
1554347313 |
| Retention |
integer |
备份快照保留天数。 |
7 |
| CreatedTime |
integer |
备份快照的创建时间。UNIX 时间,单位为秒。 |
1554347313 |
| Bucket |
string |
仅当 SourceType 取值为 OSS 时,该参数有效。表示 OSS bucket 名称。 |
hbr-backup-oss |
| ParentSnapshotHash |
string |
父备份的快照 HASH 值。 |
f2fe.. |
| InstanceId |
string |
仅当 SourceType 取值为ECS_FILE时,该参数有效。表示 ECS 实例 ID。 |
i-********************* |
| FileSystemId |
string |
仅当 SourceType 取值为 NAS 时,该参数有效。表示文件系统 ID。 |
005494 |
| ErrorFile |
string |
记录备份失败信息的文件,包含备份部分完成的信息。 |
Item Error Message C:\Program Files (x86)\Symantec\Symantec Endpoint Protection\14.3.558.0000.105\Bin\service.dat Open: open \\?\C:\Program Files (x86)\Symantec\Symantec Endpoint Protection\14.3.558.0000.105\Bin\service.dat: The process cannot access the file because it is being used by another process. C:\ProgramData\McAfee\Agent\data\InstallerFiles\172e8a3b04b7ab0fd0215f4fb7707e3744b37d83b6743b3eacb94447c74dc9af_contrib.ini Open: open \\?\C:\ProgramData\McAfee\Agent\data\InstallerFiles\172e8a3b04b7ab0fd0215f4fb7707e3744b37d83b6743b3eacb94447c74dc9af_contrib.ini: Access is denied. |
| StartTime |
integer |
快照开始时间。UNIX 时间,单位为秒。 |
1554347313 |
| UpdatedTime |
integer |
备份快照的更新时间。UNIX 时间,单位为秒。 |
1554347313 |
| SnapshotId |
string |
备份快照 ID。 |
s-********************* |
| JobId |
string |
备份任务 ID。 |
v-********************* |
| Path |
string |
仅当 SourceType 取值为ECS_FILE时,该参数有效。表示备份的文件路径。 |
["/home"] |
| ItemsTotal |
integer |
数据源项目总数。 说明
目前仅文件备份可用。 |
10 |
| BytesDone |
integer |
增量备份的数据量。单位为字节。 |
800 |
| Paths |
object |
||
| Path |
array |
备份文件路径列表。 |
"/home" |
|
string |
仅当 SourceType 取值为 NAS 时,该参数有效。表示备份的文件路径。 |
"/home" |
|
| InstanceName |
string |
表格存储实例名称。 |
instancename |
| TableName |
string |
表格存储实例的数据表名称。 |
table2 |
| RangeStart |
integer |
备份任务开始执行时间。UNIX 时间,单位为毫秒。 |
1642492553038 |
| RangeEnd |
integer |
备份任务结束执行时间。UNIX 时间,单位为毫秒。 |
1642521709966 |
| ExpireTime |
integer |
快照到期时间,UNIX 时间,单位为秒。 |
1640334062 |
| SourceSnapshotHash |
string |
转归档前快照 HASH 值。 |
qwer*** |
| SourceParentSnapshotHash |
string |
转归档前父快照 HASH 值。 |
qwer*** |
| StorageClass |
string |
存储类型。取值:
|
STANDARD |
| ArchiveTime |
integer |
转归档时间。 |
1640334062 |
| UseCommonNas |
boolean |
是否使用本地 NAS。 |
false |
| Include |
string |
备份任务包含的备份路径。 |
[\"/test/example_cn-huhehaote_3.txt\", \"/test/example_cn-huhehaote_9.txt\", \"/test/example_cn-huhehaote_5.txt\", \"/test/example_cn-huhehaote_1.txt\", \"/test/example_cn-huhehaote_7.txt\"] |
| Exclude |
string |
备份任务不包含的备份路径。 |
[\"/test/example_cn-hangzhou_7.txt\", \"/test/example_cn-hangzhou_1.txt\", \"/test/example_cn-hangzhou_3.txt\", \"/test/example_cn-hangzhou_9.txt\", \"/test/example_cn-hangzhou_6.txt\"] |
| ProtectedDataSize |
integer |
保护的源端数据量,单位 Byte。当 SourceType=ECS_FILE 时,表示已保护的云盘容量。 |
42949672960 |
示例
正常返回示例
JSON格式
{
"NextToken": "BE",
"RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E",
"Success": true,
"Limit": 10,
"Code": "200",
"Message": "successful",
"TotalCount": 20,
"Snapshots": {
"Snapshot": [
{
"Status": "COMPLETE",
"SnapshotHash": "f2fe...",
"VaultId": "v-0003rf9m17pap3ltpqx5",
"ActualItems": 6,
"BackupType": "COMPLETE",
"CreateTime": 1607436917,
"ActualBytes": 600,
"SourceType": "ECS_FILE",
"Prefix": "example/",
"ClientId": "c-*********************",
"BytesTotal": 1000,
"ItemsDone": 8,
"CompleteTime": 1554347313,
"Retention": 7,
"CreatedTime": 1554347313,
"Bucket": "hbr-backup-oss",
"ParentSnapshotHash": "f2fe..",
"InstanceId": "i-*********************",
"FileSystemId": "005494",
"ErrorFile": "Item\tError Message C:\\Program Files (x86)\\Symantec\\Symantec Endpoint Protection\\14.3.558.0000.105\\Bin\\service.dat\tOpen: open \\\\?\\C:\\Program Files (x86)\\Symantec\\Symantec Endpoint Protection\\14.3.558.0000.105\\Bin\\service.dat: The process cannot access the file because it is being used by another process. C:\\ProgramData\\McAfee\\Agent\\data\\InstallerFiles\\172e8a3b04b7ab0fd0215f4fb7707e3744b37d83b6743b3eacb94447c74dc9af_contrib.ini\tOpen: open \\\\?\\C:\\ProgramData\\McAfee\\Agent\\data\\InstallerFiles\\172e8a3b04b7ab0fd0215f4fb7707e3744b37d83b6743b3eacb94447c74dc9af_contrib.ini: Access is denied.",
"StartTime": 1554347313,
"UpdatedTime": 1554347313,
"SnapshotId": "s-*********************",
"JobId": "v-*********************",
"Path": "[\"/home\"]",
"ItemsTotal": 10,
"BytesDone": 800,
"Paths": {
"Path": [
"\"/home\""
]
},
"InstanceName": "instancename",
"TableName": "table2",
"RangeStart": 1642492553038,
"RangeEnd": 1642521709966,
"ExpireTime": 1640334062,
"SourceSnapshotHash": "qwer***",
"SourceParentSnapshotHash": "qwer***",
"StorageClass": "STANDARD",
"ArchiveTime": 1640334062,
"UseCommonNas": false,
"Include": "[\\\"/test/example_cn-huhehaote_3.txt\\\", \\\"/test/example_cn-huhehaote_9.txt\\\", \\\"/test/example_cn-huhehaote_5.txt\\\", \\\"/test/example_cn-huhehaote_1.txt\\\", \\\"/test/example_cn-huhehaote_7.txt\\\"]",
"Exclude": "[\\\"/test/example_cn-hangzhou_7.txt\\\", \\\"/test/example_cn-hangzhou_1.txt\\\", \\\"/test/example_cn-hangzhou_3.txt\\\", \\\"/test/example_cn-hangzhou_9.txt\\\", \\\"/test/example_cn-hangzhou_6.txt\\\"]",
"ProtectedDataSize": 42949672960
}
]
}
}
错误码
访问错误中心查看更多错误码。
变更历史
更多信息,参考变更详情。