-
- Novice
- Posts: 9
- Liked: 2 times
- Joined: Nov 20, 2018 12:25 am
- Full Name: Jeff Doty
- Contact:
Restore-VESQLDatabase taking more than 20 hours
Hi All,
Little issue. I have been putting together a script to restore a SQL DB to one of our test servers so it can be refreshed for the Devs on a regular bases. I got to the point where it runs the Restore-VESQLDatabase command and the command runs and light green banner appeared with information on it. It got to the point of "Calculating required space" and has been there for 20 hours, so I am thinking something is messed up. Running this restore from the console doesn't take nearly this long.
Restore-VESQLDatabase -Database $database -ServerName $TargetSvr -InstanceName $TargetInstName -File $dbfiles -TargetPath $TargetFolders -force -GuestCredentials $Mycred -verbose
$database = <database name>
$TargetSvr = <target server>
$TargetInstName = <instance name>
$dbfiles = Get-VESQLDatabaseFile -Database $database
$TargetFolders = <Array of database files, matching $dbfiles results, but with the paths changed>
$Mycred = <My veeam restore credentials, which has rights to both servers>
I haven't canceled the task yet, because (hope springs eternal) and I was not sure if I would get an error code except to say I canceled the job. The job does show up in the UI history with three messages:
1/27/2021 1:04:30 PM Application item level restore started
1/27/2021 1:05:52 PM Restoring item <database name>... (Type: Database; Source: $SourceSvr\$SourceInstName; Target: $TargetSvr\$TargetInstName)
1/27/2021 1:05:57 PM Mounting restore point
Any assistance would be appreciated.
Little issue. I have been putting together a script to restore a SQL DB to one of our test servers so it can be refreshed for the Devs on a regular bases. I got to the point where it runs the Restore-VESQLDatabase command and the command runs and light green banner appeared with information on it. It got to the point of "Calculating required space" and has been there for 20 hours, so I am thinking something is messed up. Running this restore from the console doesn't take nearly this long.
Restore-VESQLDatabase -Database $database -ServerName $TargetSvr -InstanceName $TargetInstName -File $dbfiles -TargetPath $TargetFolders -force -GuestCredentials $Mycred -verbose
$database = <database name>
$TargetSvr = <target server>
$TargetInstName = <instance name>
$dbfiles = Get-VESQLDatabaseFile -Database $database
$TargetFolders = <Array of database files, matching $dbfiles results, but with the paths changed>
$Mycred = <My veeam restore credentials, which has rights to both servers>
I haven't canceled the task yet, because (hope springs eternal) and I was not sure if I would get an error code except to say I canceled the job. The job does show up in the UI history with three messages:
1/27/2021 1:04:30 PM Application item level restore started
1/27/2021 1:05:52 PM Restoring item <database name>... (Type: Database; Source: $SourceSvr\$SourceInstName; Target: $TargetSvr\$TargetInstName)
1/27/2021 1:05:57 PM Mounting restore point
Any assistance would be appreciated.
-
- Veeam Software
- Posts: 3626
- Liked: 608 times
- Joined: Aug 28, 2013 8:23 am
- Full Name: Petr Makarov
- Location: Prague, Czech Republic
- Contact:
Re: Restore-VESQLDatabase taking more than 20 hours
Hi Jeff,
At first sight, it does not seem to be related to PowerShell but to mechanics of the restore process itself. I'd recommend to ask our support engineers to check logs in order to clarify what's going on behind the scenes and to determine the operation which takes most of time. Please don't forget to paste a support case ID for our reference.
Thanks!
At first sight, it does not seem to be related to PowerShell but to mechanics of the restore process itself. I'd recommend to ask our support engineers to check logs in order to clarify what's going on behind the scenes and to determine the operation which takes most of time. Please don't forget to paste a support case ID for our reference.
Thanks!
-
- Novice
- Posts: 9
- Liked: 2 times
- Joined: Nov 20, 2018 12:25 am
- Full Name: Jeff Doty
- Contact:
Re: Restore-VESQLDatabase taking more than 20 hours
Hi PetrM,
Ok, I was afraid of that. I will open a case.
Jeff
Ok, I was afraid of that. I will open a case.
Jeff
-
- Veeam Software
- Posts: 2010
- Liked: 670 times
- Joined: Sep 25, 2019 10:32 am
- Full Name: Oleg Feoktistov
- Contact:
Re: Restore-VESQLDatabase taking more than 20 hours
Hi Jeff,
I think, Petr is right. Your script and restore logic looks correct to me, so there isn't much we can do through the forums here.
It might be worth checking the cause of such performance with support engineers, indeed.
Thanks,
Oleg
I think, Petr is right. Your script and restore logic looks correct to me, so there isn't much we can do through the forums here.
It might be worth checking the cause of such performance with support engineers, indeed.
Thanks,
Oleg
-
- Novice
- Posts: 9
- Liked: 2 times
- Joined: Nov 20, 2018 12:25 am
- Full Name: Jeff Doty
- Contact:
Re: Restore-VESQLDatabase taking more than 20 hours
Ok Case opened: Case #04613417
Who is online
Users browsing this forum: No registered users and 8 guests