PowerShell script exchange
glukken
Lurker
Posts: 2 Liked: never
Joined: May 16, 2018 8:59 am
Full Name: GLukken
Post
by glukken » May 16, 2018 9:17 am
this post
Hi,
I'm trying to create a scheduled restore of my backup-up VMs by using the Powershell command Start-VBRRestoreVMFiles. Unfortunately I get an error no matter what server type I use as target:
The same problem is described on
https://community.spiceworks.com/topic/ ... ry-7733088
I hope this can be solved soon...
Greetings
Ge.
veremin
Product Manager
Posts: 20732 Liked: 2401 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:
Post
by veremin » May 24, 2018 9:54 pm
this post
Just to be clear - are you trying to automate VM restore or VM files restore? How exactly you assign $Server variable? Thanks.
glukken
Lurker
Posts: 2 Liked: never
Joined: May 16, 2018 8:59 am
Full Name: GLukken
Post
by glukken » May 28, 2018 7:06 am
this post
Yes I'm trying to automate VM restores. I think I kinda found the solution as described on the page mentioned in my question. It still seems odd that the GUI can restore to any server, and the Powershell script can only restore to a server with a HyperV role installed...
Greetings,
Ge.
antipolis
Enthusiast
Posts: 73 Liked: 9 times
Joined: Oct 26, 2016 9:17 am
Contact:
Post
by antipolis » Jan 07, 2019 5:00 pm
this post
resurrecting this thread, but I want to do an annual export/archive of my VMs and the command I used last year does not work anymore
Code: Select all
Add-PsSnapin -Name VeeamPSSnapIn -ErrorAction SilentlyContinue
Connect-VBRServer -Server myserver.mydomain...
$date="01/01/2019"
$server=get-vbrserver -Name "myserver.mydomain...."
$dest="D:\_Archive_2018_ESX_"
Function ExportVM ($vm) {
$point=get-vbrbackup |? {$_.Name -notlike "*(copy)"} |Get-VBRRestorePoint -Name $vm |? {$_.CreationTime -like "$date*"}
Start-VBRRestoreVMFiles -RestorePoint $point -Server $server -Path $dest\$vm
}
#Get-Content esx.txt | % {ExportVM $_}
ExportVM MyTestVM
now results in :
Code: Select all
Start-VBRRestoreVMFiles : Host type in not supported
server referenced by $server is the localhost, just like last year
veremin
Product Manager
Posts: 20732 Liked: 2401 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:
Post
by veremin » Jan 07, 2019 5:22 pm
this post
Seems to be a known issue, indeed. As a workaround, you can enable Hyper-V role on a target server, add it as a Hyper-V host to a backup server and proceed with exporting. Thanks!
antipolis
Enthusiast
Posts: 73 Liked: 9 times
Joined: Oct 26, 2016 9:17 am
Contact:
Post
by antipolis » Jan 08, 2019 10:54 am
this post
this is less than optimal, I really hope it is fixed in U4 (according to spiceworks the issue was introduced in U3)
thanks for your feedback
veremin
Product Manager
Posts: 20732 Liked: 2401 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:
Post
by veremin » Jan 08, 2019 5:15 pm
1 person likes this post
Fixed in Update 4. And there should be a hot fix available for Update 3a which you can request via support ticket. Thanks!
antipolis
Enthusiast
Posts: 73 Liked: 9 times
Joined: Oct 26, 2016 9:17 am
Contact:
Post
by antipolis » Jan 09, 2019 9:51 am
this post
this is great news thanks
veremin
Product Manager
Posts: 20732 Liked: 2401 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:
Post
by veremin » Jan 09, 2019 5:29 pm
this post
You're welcome. Should other questions arise, don't hesitate to let us know. Thanks!
Users browsing this forum: No registered users and 3 guests