PowerShell script exchange
Post Reply
manfred.milhofer
Novice
Posts: 7
Liked: 2 times
Joined: Apr 01, 2025 10:58 am
Full Name: Manfred Milhofer
Contact:

Veeam Explorers PowerShell Reference

Post by manfred.milhofer »

Hello

I have a case open with Veeam support - Case # 07707688 - "Trying to achieve unattended restore on Windows"

The support engineer has suggested that I try using the PowerShell approach documented here:

https://helpcenter.veeam.com/docs/backu ... ml?ver=120

But I can't get past step 1, here is what I get when I try to run this:

Code: Select all

---------------------------------------------------- start PowerShell snippet -------------------------------------------

Welcome to the Veeam Backup and Replication PowerShell Toolkit!

To list available commands, type Get-VBRCommand
To open online documentation on all available commands, type Get-VBRToolkitDocumentation

© Veeam Software Group GmbH. All rights reserved.


PS C:\Users\manfred.milhofer> $restorepoint = Get-VBRApplicationRestorePoint -Oracle
>> Start-VEORRestoreSession -RestorePoint $restorepoint[0]
>>
Cannot index into a null array.
At line:2 char:1
+ Start-VEORRestoreSession -RestorePoint $restorepoint[0]
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray

PS C:\Users\manfred.milhofer>

---------------------------------------------------- end PowerShell snippet -------------------------------------------
Is anyone able to point me in the right direction?
Thanks
Manfred
david.domask
Veeam Software
Posts: 2735
Liked: 629 times
Joined: Jun 28, 2016 12:12 pm
Contact:

Re: Veeam Explorers PowerShell Reference

Post by david.domask »

Hi Manfred,

>Cannot index into a null array.

Here Powershell is telling that $restorepoint is empty -- $restorepoint[0] tells Powershell to read the first element from the array $restorepoint, but looks like $restorepoint didn't populate correctly.

Can you explain a bit more about the situation? I understand you're doing Oracle restores, but how were they backed up?

1. VM backup (Vmware, HyperV, etc)
2. RMAN Plugin
2.1 If RMAN, what mode was it operating in?

Just it looks like Get-VBRApplicationRestorePoint wasn't able to find any. If you run it without the -Oracle parameter, do you see your restore points?
David Domask | Product Management: Principal Analyst
manfred.milhofer
Novice
Posts: 7
Liked: 2 times
Joined: Apr 01, 2025 10:58 am
Full Name: Manfred Milhofer
Contact:

Re: Veeam Explorers PowerShell Reference

Post by manfred.milhofer »

Hi David

Thanks for getting back to me.
The backups were created using Oracle RMAN plugin from VBR.

I tried the Get-VBRApplicationRestorePoint command without the -Oracle switch, but the result was exactly the same.

Thanks
Manfred
david.domask
Veeam Software
Posts: 2735
Liked: 629 times
Joined: Jun 28, 2016 12:12 pm
Contact:

Re: Veeam Explorers PowerShell Reference

Post by david.domask »

Got it, I think there's just a minor confusion but it's not always the clearest.

You want:

Get-VEORRMANBackup
Start-VEORRMANRestoreSession

Check the examples on those pages, you start with fetching the backup and then pass the VEORRMANBackup object to Start-VEORRMANRestoreSession.

Get-VBRApplicationRestorePoint is meant for image level backups of physical/virtual machines with Application Aware Processing, but I can get the confusion a bit. I will ask the tech writers managing these user guide pages to please make it a bit more clear on both pages.
David Domask | Product Management: Principal Analyst
manfred.milhofer
Novice
Posts: 7
Liked: 2 times
Joined: Apr 01, 2025 10:58 am
Full Name: Manfred Milhofer
Contact:

Re: Veeam Explorers PowerShell Reference

Post by manfred.milhofer » 1 person likes this post

Hi David

Thanks so much for that. I would have been floundering for some time without your direction.

Regards
Manfred
david.domask
Veeam Software
Posts: 2735
Liked: 629 times
Joined: Jun 28, 2016 12:12 pm
Contact:

Re: Veeam Explorers PowerShell Reference

Post by david.domask »

Happy I could help Manfred; were you able to get your restores going?

A hint on our Powershell reference, you can check the applicable types of backups (hypervisors) based on the "Applies to" section on each page; for example from Get-VBRApplicationRestorePoint:
Applies to

Platform: VMware, Hyper-V, Veeam Agent
Doesn't necessarily help with discovery of the correct cmdlet, but hopefully will save you some time when testing.
David Domask | Product Management: Principal Analyst
manfred.milhofer
Novice
Posts: 7
Liked: 2 times
Joined: Apr 01, 2025 10:58 am
Full Name: Manfred Milhofer
Contact:

Re: Veeam Explorers PowerShell Reference

Post by manfred.milhofer »

Hi David

I'll have a go at an actual restore next week I think.

Thanks
Manfred
Post Reply

Who is online

Users browsing this forum: No registered users and 13 guests