PowerShell script exchange
Post Reply
Erwin Linker
Service Provider
Posts: 125
Liked: 11 times
Joined: Mar 30, 2016 12:58 pm
Full Name: Erwin Linker
Location: The Netherlands
Contact:

Faster whay to read restorepoints

Post by Erwin Linker »

Hi All,

I'am busy with making a Powershell scripts that reads all the VM's that are in a Job and gets al off the restorepoints from that VM. At this moment is use the following command;

Code: Select all

Get-VBRRestorePoint -Name TestVM 
But the command feels slow, i takes a long time to complete. Is there a way to get the information a bit faster?
jhoughes
Veeam Vanguard
Posts: 282
Liked: 113 times
Joined: Apr 20, 2017 4:19 pm
Full Name: Joe Houghes
Location: Castle Rock, CO
Contact:

Re: Faster whay to read restorepoints

Post by jhoughes »

Specify the 'Backup' parameter, and your results will be limited to the restore points from a particular backup.

You can get your job, the backups for the job, then the restore points.
Husband, Father, Solutions Architect, Geek | @DenverVMUG & @DenverPSUG leader | International Speaker | Veeam Vanguard | vExpert (PRO) | Cisco Champion
chris.arceneaux
VeeaMVP
Posts: 695
Liked: 374 times
Joined: Jun 24, 2019 1:39 pm
Full Name: Chris Arceneaux
Location: Georgia, USA
Contact:

Re: Faster whay to read restorepoints

Post by chris.arceneaux » 1 person likes this post

Here's a PowerShell trick to speed things up:

Code: Select all

$rps = Get-VBRRestorePoint
$rps | Where-Object {$_.Name -eq "TestVM"}
Essentially, you are gathering all Restore Points in one go in the first line. Then, when you want to pull information for a specific VM, you're referencing the already gathered data.
Erwin Linker
Service Provider
Posts: 125
Liked: 11 times
Joined: Mar 30, 2016 12:58 pm
Full Name: Erwin Linker
Location: The Netherlands
Contact:

Re: Faster whay to read restorepoints

Post by Erwin Linker » 1 person likes this post

Hi Chris,

I looks that the proces is a lot quicker :-).
Post Reply

Who is online

Users browsing this forum: No registered users and 23 guests