PowerShell script exchange
Post Reply
JamesHartley
Lurker
Posts: 1
Liked: never
Joined: Oct 04, 2011 2:03 pm
Full Name: James Hartley
Contact:

File level restore via powershell??

Post by JamesHartley » Oct 06, 2011 1:08 pm

Hi,

Does anyone know if you can restore certain files from a backup, via powershell?
I have run the backup job and restored the whole server via powershell, but can't seem to work out how you would just restore a certain file.

Any help would be appreciated.

Thanks
James

Vitaliy S.
Product Manager
Posts: 22777
Liked: 1526 times
Joined: Mar 30, 2009 9:13 am
Full Name: Vitaliy Safarov
Contact:

Re: File level restore via powershell??

Post by Vitaliy S. » Oct 06, 2011 1:46 pm

Hello James,

You should be using this PowerShell cmdlet to restore individual Windows Guest files:

Code: Select all

Start-VBRWindowsFileRestore
Hope this helps!

jlsung
Influencer
Posts: 21
Liked: never
Joined: Sep 15, 2011 1:41 pm
Contact:

Re: File level restore via powershell??

Post by jlsung » Nov 28, 2011 3:32 pm

Hi,

There is no cmdlet for a Guest OS FLR ?

Vitaliy S.
Product Manager
Posts: 22777
Liked: 1526 times
Joined: Mar 30, 2009 9:13 am
Full Name: Vitaliy Safarov
Contact:

Re: File level restore via powershell??

Post by Vitaliy S. » Nov 28, 2011 3:51 pm

Do you possibly mean "Other OS" FLR cmdlet? If this is the case, then, unfortunately, it is not available at the moment.

AdrianHinton
Enthusiast
Posts: 71
Liked: 6 times
Joined: Apr 07, 2014 10:00 am
Full Name: Adrian Hinton
Contact:

Re: File level restore via powershell??

Post by AdrianHinton » Sep 16, 2014 4:30 am

Hi,

How can I restore a file using the Start-VBRWindowsFileRestore cmdlet? When I look at the drives after I have the session in a variable this is what I see: C:\VeeamFLR\SERVER\Volume0, C:\VeeamFLR\SERVER\Volume1, C:\VeeamFLR\SERVER\Volume2. And I cannot access the mounted drive.

AdrianHinton
Enthusiast
Posts: 71
Liked: 6 times
Joined: Apr 07, 2014 10:00 am
Full Name: Adrian Hinton
Contact:

Re: File level restore via powershell??

Post by AdrianHinton » Sep 16, 2014 4:34 am

I think I'm getting there:

Dir $WFLR.MountSession.MountedDevices.DriveLetter[0]

AdrianHinton
Enthusiast
Posts: 71
Liked: 6 times
Joined: Apr 07, 2014 10:00 am
Full Name: Adrian Hinton
Contact:

Re: File level restore via powershell??

Post by AdrianHinton » Sep 16, 2014 4:52 am

Sorry for the Spam.. I will work out the rest later for myself but I have answered my question.

$WFLR = $null

$WFLR = Get-VBRBackup -Name "Backup-Job" | Get-VBRRestorePoint |
Sort CreationTime -Descending | Select -First 1 | Start-VBRWindowsFileRestore

$WFLR.MountSession.MountedDevices.mountpoint | % {

GCI -Path $_

}

Stop-VBRWindowsFileRestore $WFLR

The above will list the contents of the root directories of the VM's drives and the GCI command in the foreach loop can be modified to perform the finding and copying of the test files. And the files are located by default at C:\VeeamFLR\SERVERNAME\Volume(n) etc.. on the VBR server.

Thank you :)

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

Re: File level restore via powershell??

Post by veremin » Sep 16, 2014 8:55 am

Hi Andrian, we have some examples of using file level restore via PS in the adjacent thread; might be worth reviewing. Thanks.

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest