PowerShell script exchange
Post Reply
vbogda
Novice
Posts: 8
Liked: never
Joined: Dec 11, 2014 2:19 pm
Full Name: Val Bogda
Contact:

Restore to original location

Post by vbogda »

Hi All,

I am looking for a way of finding the original location of a backup object so that I can pass it to the Host parameter of the Start-VBRRestoreVM CmdLet.

Thanks
veremin
Product Manager
Posts: 20400
Liked: 2298 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:

Re: Restore to original location

Post by veremin »

I believe you can query backup job to find out job objects, assign required one to a variable, and, then, use something like .GetItem() or .Item to explore vSphere object and information about its original location. Thanks.
vbogda
Novice
Posts: 8
Liked: never
Joined: Dec 11, 2014 2:19 pm
Full Name: Val Bogda
Contact:

Re: Restore to original location

Post by vbogda »

That's what I thought as well. However, I can't find anything in Object that will give me this information. There's Location but that's not what the Start-VBRRestoreVM command requires.

I found a way of finding the original location by utilising the Find-VBRViEntity command which gives me what I want in VmHostName but it feels like it should be possible to drill down to this information starting from the Backup job.
veremin
Product Manager
Posts: 20400
Liked: 2298 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:

Re: Restore to original location

Post by veremin »

Once the required object was assigned have you tried to explore its available methods? Some of them like Item or GetItem() should point to vSphere VM object that contains information about the host VM resides on. Thanks.
Post Reply

Who is online

Users browsing this forum: Taran and 16 guests