Microsoft Virtualization Discussions

CDOT PowerShell toolkit 3.2.1 cmdlets

gmf
16,691 Views

Hi All,

 

NetApp newbie here.

 

In the coming month we're going to implement CDOT in our environment, we're currently using the previous version and we have lots of scripts in Orchestrator that uses PowerShell toolkit for provisioning server storage. It's my tasks to review the old scripts we're using and to modify the scripts to adapt it to the new cmdlets introduced in PowerShell toolkit 3.2. I reviewed the documentation and release notes and found out that most of the command have been renamed (actually they set aliases on the psm1 file) to for example Get-Naxxx to Get-Ncxxx. But there are other cmdlets that I cannot find in PowerShell toolkit 3.2.1 like Get-NaSnapmirrorSchedule. while other cmdlets like Get-NaSystemInfo has been renamed to Get-NcNodeInfo in CDOT.


Is there any particular list of updated cmdlets or cmdlets that have been remove that I can review to be able to find out those old cmdlets that we cannot use when moving our scripts to CDOT? Or do I just need to modify the commands to use xxx-Ncxxx instead of xxx-Naxxx? 

 

Thanks in advance.

 

Regards,

gmf

 

21 REPLIES 21

gmf
2,861 Views

 

I finally got it working... I just followed your instructions to create new vserver.

 

5/18/2015 9:10:25 AM [24] Monad P:\> $SnapShotSchedule = '0 2 6@8,12,16,20'

5/18/2015 9:10:50 AM [26] Monad P:\> $rScheduleRetainWeeks = ($SnapshotSchedule).split(" ")[0]
5/18/2015 9:11:16 AM [27] Monad P:\> $rScheduleRetainDays = ($SnapshotSchedule).split(" ")[1]
5/18/2015 9:11:31 AM [28] Monad P:\> $rScheduleRetainHours = ($SnapshotSchedule).split(" ")[2].split("@")[0]
5/18/2015 9:11:45 AM [29] Monad P:\> [int[]]$rScheduleHourlyTimes = ($SnapshotSchedule).split("@")[1].split(",")
5/18/2015 9:12:00 AM [30] Monad P:\> Add-NcJobCronSchedule -Name HourlyTimes -Hour $rScheduleHourlyTimes

JobScheduleName JobScheduleDescription
--------------- ----------------------
HourlyTimes @8:00,12:00,16:00,20:00


5/18/2015 9:12:14 AM [31] Monad P:\> New-NcSnapshotPolicy -Name CDOT -Schedule weekly -Count $rScheduleRetainWeeks -Enabled $true

Policy Enabled SnapshotPolicySchedules
------ ------- -----------------------
CDOT True {weekly (0)}


5/18/2015 9:12:26 AM [32] Monad P:\> Add-NcSnapshotPolicySchedule -Name CDOT -Schedule daily -Count $rScheduleRetainDays

Policy Enabled SnapshotPolicySchedules
------ ------- -----------------------
CDOT True {weekly (0), daily (2)}


5/18/2015 9:12:38 AM [33] Monad P:\> Add-NcSnapshotPolicySchedule -Name CDOT -Schedule hourly -Count $rScheduleRetainHours

Policy Enabled SnapshotPolicySchedules
------ ------- -----------------------
CDOT True {weekly (0), daily (2), hourly (6)}


5/18/2015 9:12:46 AM [34] Monad P:\> Get-NcSnapshotPolicy

Policy Enabled SnapshotPolicySchedules
------ ------- -----------------------
CDOT True {weekly (0), daily (2), hourly (6)}
default True {hourly (6), daily (2), weekly (2)}
none False

 

5/18/2015 9:13:07 AM [35] Monad P:\> Get-NcJobCronSchedule

JobScheduleName JobScheduleDescription
--------------- ----------------------
5min @:00,:05,:10,:15,:20,:25,:30,:35,:40,:45,:50,:55
8hour @2:15,10:15,18:15
avUpdateSchedule @2:00
daily @0:10
hourly @:05
HourlyTimes @8:00,12:00,16:00,20:00
weekly Sun@0:15

 

5/18/2015 9:05:43 AM [9] Monad P:\> New-NcVol -Name TestCDOT -Aggregate a001vi15k01_cha1sanfiler101 -Size 1g -JunctionPath /vol1 -VserverContext cdot_test

Name State TotalSize Used Available Dedupe Aggregate Vserver
---- ----- --------- ---- --------- ------ --------- -------
TestCDOT online 1.0 GB 5% 972.7 MB False a001vi15k01_cha1sanfil... cdot_test


5/18/2015 9:06:29 AM [10] Monad P:\> Get-NcVol

Name State TotalSize Used Available Dedupe Aggregate Vserver
---- ----- --------- ---- --------- ------ --------- -------
root_cdot_test online 20.0 MB 5% 18.9 MB False a001vi15k01_cha1sanfil... cdot_test
TestCDOT online 1.0 GB 5% 972.7 MB False a001vi15k01_cha1sanfil... cdot_test
vol0 online 851.5 MB 76% 202.7 MB False aggr0 cha1sanfiler101


5/18/2015 9:06:36 AM [11] Monad P:\> $rVolTemplate = Get-NcVol -Template
5/18/2015 9:07:52 AM [12] Monad P:\> $rVolTemplate.Name = "TestCDOT"
5/18/2015 9:08:09 AM [13] Monad P:\> $rVolTemplate

Name State TotalSize Used Available Dedupe Aggregate Vserver
---- ----- --------- ---- --------- ------ --------- -------
TestCDOT


5/18/2015 9:08:16 AM [14] Monad P:\> $rVolTemplate.Vserver = "cdot_test"
5/18/2015 9:08:39 AM [15] Monad P:\> $rVolTemplate

Name State TotalSize Used Available Dedupe Aggregate Vserver
---- ----- --------- ---- --------- ------ --------- -------
TestCDOT cdot_test

 

 

5/18/2015 9:08:41 AM [16] Monad P:\> $rUpdateVol = Get-NcVol -Template
5/18/2015 9:08:54 AM [17] Monad P:\> Initialize-NcObjectProperty $rUpdateVol VolumeSnapshotAttributes
5/18/2015 9:09:08 AM [18] Monad P:\> $rUpdateVol.VolumeSnapshotAttributes.SnapshotPolicy="CDOT"
5/18/2015 9:09:17 AM [19] Monad P:\> $rUpdateVol

Name State TotalSize Used Available Dedupe Aggregate Vserver
---- ----- --------- ---- --------- ------ --------- -------

 

5/18/2015 9:13:16 AM [36] Monad P:\> Update-NcVol -Query $rVolTemplate -Attributes $rUpdateVol


NcController : 10.127.135.70
SuccessCount : 1
FailureCount : 0
SuccessList : {TestCDOT}
FailureList : {}

 

5/18/2015 9:13:48 AM [38] Monad P:\> Get-NcVol

Name State TotalSize Used Available Dedupe Aggregate Vserver
---- ----- --------- ---- --------- ------ --------- -------
root_cdot_test online 20.0 MB 5% 18.9 MB False a001vi15k01_cha1sanfil... cdot_test
TestCDOT online 1.0 GB 5% 972.7 MB False a001vi15k01_cha1sanfil... cdot_test
vol0 online 851.5 MB 76% 201.9 MB False aggr0 cha1sanfiler101


5/18/2015 9:14:05 AM [39] Monad P:\> Get-NcVol TestCDOT | select -ExpandProperty VolumeSnapshotAttributes


AutoSnapshotsEnabled : True
NcController : 10.127.135.70
SnapdirAccessEnabled : True
SnapshotCloneDependencyEnabled : False
SnapshotCount :
SnapshotPolicy : CDOT
AutoSnapshotsEnabledSpecified : True
SnapdirAccessEnabledSpecified : True
SnapshotCloneDependencyEnabledSpecified : True
SnapshotCountSpecified : False

 

5/18/2015 9:14:34 AM [40] Monad P:\>

 

 

Thanks @billyd for your help, I really appreciate it 🙂

 

Regards,

Glenn

 

Public