Create a view volume in a different directory than source volume with Powershell
Hi,
I want to create a new viewvolume from a replay, but I want the Viewvolume to be created in a different folder than the original as I will map it out to a different server.
How do I get the Volumefolder parameter? The only info in the Cookbook is referenced to have the volume created in the same directory.
I would add one more variable to this list: $ViewVolumeFolder = "ViewVolumeFolder"
Then when you create the view volume:
# Create the view volume in the same folder as the volume $ViewVolume = New-DellScReplayView -ConnectionName $ConnName ` -Instance $Replay ` -Name $ViewVolumeName ` -VolumeFolder $ViewVolumeFolder
Unfortunately I do not have a lab system to test this on to verify.
###### Move newly created voumes to the correct Volume folder ########## # Get the new volume folder $NVolumeFolder = Get-DellScVolumeFolder -ConnectionName $ConnName ` -ScName $ScName ` -FolderPath $SCVolumeFolderPath ` -Name $ScVolumeFolderName # Move the volume
DELL-Bob Mi
2 Intern
•
230 Posts
1269
1
Posted June 20th, 2019 15:00
Hello ATEAGunnar,
Based upon the commands you specified you are using Dell Storage PowerShell SDK.
Looking at the Dell Storage PowerShell SDK Cookbook: http://en.community.dell.com/techcenter/extras/m/white_papers/20441893
Section 3.6.2 Create a view volume on a snapshot
# Assign variables
$ConnName = "DSMDC"
$ScName = "SC 13"
$VolumeName = "SQLData"
$VolumeFolderPath = "Production/SQLDatabase/SQLProd/"
$ViewVolumeName = $VolumeName + " View"
I would add one more variable to this list:
$ViewVolumeFolder = "ViewVolumeFolder"
Then when you create the view volume:
# Create the view volume in the same folder as the volume
$ViewVolume = New-DellScReplayView -ConnectionName $ConnName `
-Instance $Replay `
-Name $ViewVolumeName `
-VolumeFolder $ViewVolumeFolder
Unfortunately I do not have a lab system to test this on to verify.