Data Backup and Recovery
Data Backup and Recovery
Hello,
I am trying to clone a backup of some SQL-Server databases to another server and everything works great when i let SnapCenter controle the mountpoint with AutoAssignMountPoint.
Full command:
New-SmClone -BackupName "SQL01_USRDB1_SQL01_01-08-2023_19.30.04.9781" -Resources @{"Host"="SQL01.domain.com";"Type"="SQL Database";"Names"="SQL01\TestDatabase,SQL01\Provar,SQL01\EfterPolicy"} -CloneToInstance "SQL02" -AutoAssignMountPoint -Suffix "_PS-Clone" -LogRestoreType None -AppPluginCode "SMSQL"
But i want to controle the mountpoint, so i try to use AssignMountPointUnderPath, but i can not get it to work.
Full command:
New-SmClone -BackupName "SQL01_USERDB01_SQL01_01-08-2023_19.30.04.9781" -Resources @{"Host"="SQL01.domain.com";"Type"="SQL Database";"Names"="SQL01\TestDatabase,SQL01\Provar,SQL01\EfterPolicy"} -CloneToInstance "SQL02" -AssignMountPointUnderPath 'c:\MountPoint\CloneMount\' -Suffix "_PS-Clone" -LogRestoreType None -AppPluginCode "SMSQL"
The error i get is: New-SmClone : Input string was not in a correct format.
I have tried all variations on the path i can come up with (single quote, double quote, without quote, with double backslaches, with and without backslash on the end) but all of them give the same error.
If i use a path that does not exist, it gives another error: New-SmClone : Invalid mount path: Path does not exist
Wich is logical... And indicates that it is using the string and the overall command is ok.
If i look in the command reference guide, https://library.netapp.com/ecm/ecm_download_file/ECMLP2880726
in the example in the beginning they use both AutoAssignMountPoint and AssignMountPointUnderPath.
If i try that i get another error: New-SmClone : Please provide only one option from AutoAssignMountPoint and AssignMountPointUnderPath.
So now i am stuck. My hope is that someone out there have a solution for this.
We use SnapCenter 4.6 and the powershell version on the server is 5.1.
Regards,
Daniel
Solved! See The Solution
Hi Daniel,
Sorry I can't get it to work either.
I've just spent a couple of hours setting this up in a test environment and tested it with SnapCenter 4.5, 4.6 and 4.7p1 on Windows 2016.
Can only confirm the issue.
What happens if you remove the trailing "/" in the path?
Yes, unfortunately it gives the same error message.
I have tried:
'c:\MountPoint\CloneMount\'
'c:\MountPoint\CloneMount'
'c:\\MountPoint\\CloneMount\\'
'c:\\MountPoint\\CloneMount'
"c:\MountPoint\CloneMount\"
"c:\MountPoint\CloneMount"
"c:\\MountPoint\\CloneMount\\"
"c:\\MountPoint\\CloneMount"
c:\MountPoint\CloneMount\
c:\MountPoint\CloneMount
c:\\MountPoint\\CloneMount\\
c:\\MountPoint\\CloneMount
And now you got me to try with "/" instead of "\", which I hadn't thought of, but it gives the same message: New-SmClone : Input string was not in a correct format.
But as i said, "funny" thing is, that if i use a path that not exists like 'c:\MountPoint\Foo\', it gives me: New-SmClone : Invalid mount path: Path does not exist.
Hi Daniel,
Sorry I can't get it to work either.
I've just spent a couple of hours setting this up in a test environment and tested it with SnapCenter 4.5, 4.6 and 4.7p1 on Windows 2016.
Can only confirm the issue.
Hello,
Thank you for trying this out.
Looks like i will have to look into registering a bug instead.
As an small update I just installed 4.9P1 and tried. It is still the same.