Get a resource representation of the VM guest OS directory.

RESTful knowledge exchange

Get a resource representation of the VM guest OS directory.

Veeam Logoby Mardock » Wed Jan 07, 2015 1:59 pm

Hi,
I try to get a resource representation of the hierarchy of the VM guest OS file system within a VM backup ( Veeam REST API v8.0.0.917).


I'am using the following HTTP request: GET /catalog/vms/{VMNAME}/vmRestorePoints/{ID}/guestfs/{FILEPATH}?action=listAll


I have notice that if I query a path like "C:/Users" or "C:/Windows" the server returs correct response.

Examples:
GET /catalog/vms/{VMNAME}/vmRestorePoints/{ID}/guestfs/C:/Users?action=listAll
GET /catalog/vms/{VMNAME}/vmRestorePoints/{ID}/guestfs/C:/Windows?action=listAll

But, if query a path of livel 2 like "C:/Users/Administrator", "C:/Windows/System32" or level 3 like "C:/Users/Administrator/AppData" (and so on ... )

Examples:
GET /catalog/vms/{VMNAME}/vmRestorePoints/{ID}/guestfs/C:/Users/Administrator?action=listAll
GET /catalog/vms/{VMNAME}/vmRestorePoints/{ID}/guestfs/C:/Users/Administrator/AppData?action=listAll
GET /catalog/vms/{VMNAME}/vmRestorePoints/{ID}/guestfs/C:/Windows/System32?action=listAll

then the server returns the following error:

Code: Select all
<?xml version="1.0" encoding="utf-8"?>
<Error StatusCode="500"
Message="Exception has been thrown by the target of an invocation."
xmlns="http://www.veeam.com/ent/v1.0"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
   <FirstChanceExceptionMessage>Can`t change directory. [Users/Administrator].</FirstChanceExceptionMessage>
   <StackTrace>Veeam.Backup.Interaction.RestAPI.CRestAPICommunicationException:
   Exception has been thrown by the target of an invocation. ---&gt;
   System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---&gt;
   System.Runtime.InteropServices.COMException: Can`t change directory. [Users/Administrator].&#xD;
&#xD;
Server stack trace: &#xD;
   at VeeamGuestIndexerLib.IOibDFBrowser.GetFolders(String rootPath)&#xD;
   at Veeam.Backup.CatalogFsLib.CGuestDataBrowser.GetVmSubFolders(String rootPath)&#xD;
   at Veeam.Backup.CatalogSearchLib.CSearchSession.GetVmSubFolders(Guid taskId, String rootPath)&#xD;
   at Veeam.Backup.CatalogDataService.CCatalogSearcherStub.Veeam.Backup.Interaction.CatalogClient.ICatalogSearcher.GetVmSubFolderNames(Guid sessionId, Guid taskId, String rootPath)&#xD;
   at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(IntPtr md, Object[] args, Object server, Object[]&amp; outArgs)&#xD;
   at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMessage msg)&#xD;
&#xD;
Exception rethrown at [0]: &#xD;
   at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)&#xD;
   at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData&amp; msgData, Int32 type)&#xD;
   at Veeam.Backup.Interaction.CatalogClient.ICatalogSearcher.GetVmSubFolderNames(Guid sessionId, Guid browsetaskId, String rootPath)&#xD;
   at Veeam.Backup.Interaction.CatalogClient.CCatalogSearcherProxy.&lt;&gt;c__DisplayClass21.&lt;Veeam.Backup.Interaction.CatalogClient.ICatalogSearcher.GetVmSubFolderNames&gt;b__20()&#xD;
   --- End of inner exception stack trace ---&#xD;
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)&#xD;
   at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)&#xD;
   at System.Delegate.DynamicInvokeImpl(Object[] args)&#xD;
   at Veeam.Common.Remoting.CRetryableMethod.DoInvoke(Delegate dlg, Object[] args)&#xD;
   at Veeam.Common.Remoting.CRetryableMethod.Invoke[Ret](ActionDelegate`1 dlg)&#xD;
   at Veeam.Backup.Interaction.CatalogClient.CCatalogSearcherProxy.Veeam.Backup.Interaction.CatalogClient.ICatalogSearcher.GetVmSubFolderNames(Guid sessionId, Guid taskId, String rootPath)&#xD;
   at Veeam.Backup.Enterprise.Core.CCatalogHelper.&lt;&gt;c__DisplayClass8.&lt;GetDirectories&gt;b__7(Guid sessionId)&#xD;
   at Veeam.Backup.Enterprise.Core.CCatalogHelper.DoWithCheckingSession[T](SearcherMethodDelegate`1 dlg)&#xD;
   at Veeam.Backup.Enterprise.Core.CCatalogHelper.GetDirectories(Guid browseTaskId, String path)&#xD;
   at Veeam.Backup.Enterprise.RestAPIService.CRestApiCatalogScope.GetDirectoryEntries(String vmRealName, Guid origOibId, String path, COibGuestFsBrowser resolver)&#xD;
   at Veeam.Backup.Enterprise.RestAPIService.CRestApiCatalogScope.GetCatalogVmRestorePointFSEntries(String vmRealName, String origOibIdStr, String path, String typeStr, String pageSizeStr, String pageNumStr)&#xD;
   at Veeam.Backup.Enterprise.RestAPIService.CEnterpriseRestServiceStub.GetCatalogVmRestorePointFSEntriesAll(String vmIdStr, String oibId, String path)&#xD;
   at SyncInvokeGetCatalogVmRestorePointFSEntriesAll(Object , Object[] , Object[] )&#xD;
   at System.ServiceModel.Dispatcher.SyncMethodInvoker.Invoke(Object instance, Object[] inputs, Object[]&amp; outputs)&#xD;
   at System.ServiceModel.Dispatcher.DispatchOperationRuntime.InvokeBegin(MessageRpc&amp; rpc)&#xD;
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage5(MessageRpc&amp; rpc)&#xD;
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage31(MessageRpc&amp; rpc)&#xD;
   at System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean isOperationContextSet)&#xD;
   --- End of inner exception stack trace ---</StackTrace>
</Error>


I do something wrong?

Thank you,
Mardock.
Mardock
Influencer
 
Posts: 19
Liked: never
Joined: Thu Jul 10, 2014 3:40 pm

Re: Get a resource representation of the VM guest OS directo

Veeam Logoby v.Eremin » Tue Jan 13, 2015 1:46 pm

The information has been sent to QA team. Confirmed as a bug. Thanks.
v.Eremin
Veeam Software
 
Posts: 13266
Liked: 968 times
Joined: Fri Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin


Return to RESTful API



Who is online

Users browsing this forum: No registered users and 2 guests