PowerShell script exchange
Post Reply
yrrah2010
Influencer
Posts: 18
Liked: never
Joined: Jan 26, 2011 7:06 am
Contact:

Rescan vCenter environment

Post by yrrah2010 » Jul 14, 2015 3:05 pm

Within the Veeam console > Backup Infrastructure > Manager servers > vCenter you can rescan the environment (Util.VolumesHostDiscover) and there's an register key to change this interval instead of every 24 hours to more or less hours.
But i want to schedule this task at 17:00 every day with powershell there's an option Rescan-VBREntity how can i use this with rescanning an vCenter environment?
I want to use this because we're reinstalling ESXi host and the UUID changes, when Veeam hasn't done an rescan the backups are failing.

Dima P.
Product Manager
Posts: 10536
Liked: 858 times
Joined: Feb 04, 2013 2:07 pm
Full Name: Dmitry Popov
Location: Prague
Contact:

Re: Rescan vCenter environment

Post by Dima P. » Jul 14, 2015 3:22 pm

Hi yrrah2010,
If I understood correctly, this should do the trick: Get-VBRServer -Type VC | Rescan-VBREntity

yrrah2010
Influencer
Posts: 18
Liked: never
Joined: Jan 26, 2011 7:06 am
Contact:

Re: Rescan vCenter environment

Post by yrrah2010 » Jul 14, 2015 3:30 pm

It wont work when testing but the command is not available is it an v8 feature?

Dima P.
Product Manager
Posts: 10536
Liked: 858 times
Joined: Feb 04, 2013 2:07 pm
Full Name: Dmitry Popov
Location: Prague
Contact:

Re: Rescan vCenter environment

Post by Dima P. » Jul 14, 2015 3:40 pm

I've looked across the previous PS guide and unfortunately can’t find any mentioning of the Rescan-VBREntity cmdlet. It might be added only in v8 (which was used to test the said script from my end).

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

Re: Rescan vCenter environment

Post by veremin » Jul 14, 2015 4:54 pm

The said commandlet has been added in version 8. Try the following script and see whether it meets your expectations:

Code: Select all

$Server = Get-VBRServer -Name "Name of your VC"
Rescan-VBREntity -Entity $Server
Thanks.

scottcarr
Enthusiast
Posts: 35
Liked: never
Joined: Jun 30, 2015 5:25 pm
Full Name: Scott Carr
Contact:

Re: Rescan vCenter environment

Post by scottcarr » Sep 17, 2015 4:55 pm

Where in the registry is the change made to rescan more frequently? I have a customer that is using VMware DRS quite extensively, and has backup jobs failing due to "Object cannot be created" errors.

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests