Solved

Browse all versions of a guest file for a specific VM with API DoBrowse

  • 26 January 2023
  • 2 replies
  • 105 views

Badge +1

Hello,

I’m used to use your API, but in this case, I can't get what I want 😪

Use case : Before perform a single file restore operation, I need to see all versions of a guest file for a VM backuped without agent (agentless) .

I use the DoBrowse API, but I have no usable results.

{{ServerUrl}}/DoBrowse (POST) with body:

}
{
"opType": 0,
"queries": [
{
"type": 1,
"queryId": "countQuery",
"aggrParam": {
"field": 0,
"aggrType": 4
}
},
{
"type": 4,
"queryId": "dataQuery",
"dataParam": {
"sortParam": {
"ascending": true,
"sortBy": [
38,
0
]
},
"paging": {
"firstNode": 0,
"pageSize": 15,
"skipNode": 0
}
}
}
],
"mode": {
"mode": 1
},
"paths": [
{
"path": "\\50003816-5EF5-1648-8ED1-0FD0B08F024C\\var\\log\\cron"
}
],
"options": {
"showDeletedFiles": true,
"restoreIndex": true
},
"entity": {
"subclientId": 26475,
"applicationId": 106,
"clientName": "myhostname",
"instanceId": 119,
"clientId": 3903
},
"timeRange": {
"fromTime": 1643207640,
"toTime": 1674743640
}


}

The poor response is (Status code : 200) :

{
"browseResponses": [
{
"respType": 0,
"workerId": "69973",
"doClientSideSortingAndPaging": false,
"session": {
"sessionId": "1674744084-69973"
},
"browseResult": {
"queryId": "countQuery",
"aggrResultSet": [
{
"result": 0,
"groupbyValue": "",
"count": 0
}
]
}
}
]
}

Wath is the correct request to obtain all versions for a specific guest file (during the retention period of course) ?

Current version : 11.24.86

Regards,

icon

Best answer by Damian Andre 27 January 2023, 00:46

View original

2 replies

Userlevel 7
Badge +23

Hey @mjc 

Have you been able to do this outside of the API? I only ask because by default Commvault would not have an index of the VM backups to know all the versions or even have a file list. The VM backups need to be indexed to get this sort of data otherwise it needs to establish a live browse.

https://documentation.commvault.com/2022e/essential/144093_file_indexing_version_2.html

Before tackling the API stuff, just wanted to make sure the infrastructure is set up to enable this to work.

Badge +1

Hello, thanks to @Damian Andre . You’re right, this option is not yet enabled on our configuration. 

I see that your refered to version 2 that still available with 2022E version. We’re update to this version asap and I come back if necessary.

 

Regards,

Reply