Discuss NetApp solutions for Microsoft Private Cloud and the Hyper-V platform, including FlexPod Datacenter, OnCommand Plug-in for Microsoft, and ONTAP PowerShell Toolkit.
Discuss NetApp solutions for Microsoft Private Cloud and the Hyper-V platform, including FlexPod Datacenter, OnCommand Plug-in for Microsoft, and ONTAP PowerShell Toolkit.
When I use this command get-ncdisk 1.0.1 |fl and I get a output like this Some property like [DiskInventoryInfo], It not give me a value,and It give me [DataONTAP.C.Types.StorageDisk.DiskInventoryInfo] What's it mean? And how to get more detail information? Thanks
... View more
Hello, OnTap 9.12.1P11 FAS2720 & AFF-0300 PSTK : 9.14.1 Prior to our update of OnTAP our scripts to report on snapshot usage ran by simply executing the Get-NcSnapshot cmdlet. After the upgrade, running our script our script returned errors and research shows that the PSTK checks the version of OnTap and defaults to REST-API rather than ZAPI. Our script was quickly fixed by forcing ZAPI usage with the -ZAPICALL argument on the Connect-NcController cmdlet. I'd prefer to use the REST-API as I can see ZAPI is now being deprecated. Using the REST API the Get-NcSnapshot cmdlet usage changes and seems to mandate the use of the -volume argument. I re-wrote the line in the script to loop through the list of volumes and push the results into a variable. This is working, but it is exceptionally slow. One volume (on SSD storage) took over 7 minutes to get a list of snapshots on the volume (there were 32 snapshots). Another volume took over 22 minutes (again 32 snapshots and again on SSD storage). These timings were obtained by writing out to a log file. Is there a quicker way to get this information? Old code using ZAPI : $snapshots = Get-NcSnapshot -controller $controller New code using REST API: $volumes = Get-NcVol -controller $controller
$snapshots = ForEach ($volume in $volumes){
Get-NcSnapshot -volume $volume -WarningAction SilentlyContinue
}
There is a similar article that references the changes where someone was trying to use the Get-NcSnapshot command and had issues getting the list of snapshots for their volumes (https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/Powershell-Pipe-issues/td-p/445340) and I based the new code used above on the information in the article. Thank you!
... View more
Customer is asking the following question. Any thoughts are appreciated. REST has already been suggested, but the customer is focused on PS. Is there a PS cmdlet equiv to the following cli cmds: volume flexcache create -vserver eu-vfilerc-01 -volume amc_cifs_prd_apps01 -origin-volume cifs_prd_apps01 -size 50GB -origin-vserver am-vfilerc-01 -aggr-list aggr1_sata_19 # flexcache prepopulate start -cache-vserver eu-vfilerc-01 -cache-volume amc_cifs_prd_apps01 -path-list <path> We can’t see anything obvious in the PS toolkit help.
... View more
I have a script that runs get-ncvol ...the connect... and get-ncvol work fine. I want to get some snapmirror info with "get-nasnapmirrorschedule" Seems it requires credentialsparameter??!. Does anyone know what the format of get-nassnapmirrorschedule is? $username = "xxxxx" $pwdTxt = Get-Content "C:\Scripts\Storage\xxxxx.txt" $securePwd = $pwdTxt | ConvertTo-SecureString $credObject = New-Object System.Management.Automation.PSCredential -ArgumentList $username, $securePwd $global:CurrentNcController = $null connect-nccontroller $cluster -credential $credObject get-ncvol ********************************************** I tried to use "get-nasnapmirrorschedule -Controller xxxx" and it errors...wanting credentials. get-nasnapmirrorschedule : Incorrect credentials for xxxxx At C:\scripts\storage\testing-snapmirror\Snapmirror-check.ps1:32 char:1 + get-nasnapmirrorschedule -Controller xxxxx + CategoryInfo : InvalidOperation: (bmina:NaController) [Get-NaSnapmirrorSchedule], NaAuthException + FullyQualifiedErrorId : ApiException,DataONTAP.PowerShell.SDK.Cmdlets.Snapmirror.GetNaSnapmirrorSchedule
... View more