Microsoft Virtualization Discussions
Microsoft Virtualization Discussions
We have upgraded from ONTAP 9.9.1P10 to 9.11.1P9.
We have extensively used the PowerShell Toolkit for automation. After the upgrade many command stopped working, where we received errors that the switch isn't support. We even tried downgrading the toolkit to the previous version but that didn't help against 9.11.
Here is one example, where the switch isn't supported:
New-NcVol -ExcludedFromAutobalance
An example of a switch within command which is no longer working:
Get-NcEmsMessage -StartTime
We get this error:
There was an error Get NcEmsMessage System.ArgumentException: StartTime parameter specified, which is not supported for REST call at System.Management.Automation.MshCommandRuntime.ThrowTerminatingError(ErrorRecord errorRecord) At line:526 char:19 For: $Events = Get-NcEmsMessage -StartTime $startdate | Where-Object { $_.MessageName -notin $Ignore } Reason: ArgumentException, Activity: Get-NcEmsMessage, Category: InvalidArgument
We see on the site (https://docs.netapp.com/us-en/ontap-restmap-9111/volume.html#volume-encryption-conversion-start) that some of the commands say: No REST Equivalent
But we know 100% these commands worked before the upgrade.
Has the Toolkit/REST API been limited?
Solved! See The Solution
Hi,
Did you try using the -Ontapi parameter when connecting to the cluster using Connect-NcController then test the command you are having problems with? By default the latest version of the PSTK will do an ONTAP version check and if running >= ONTAP 9.6 it will attempt to use REST API's unless you explicitly tell it not to by using the -Ontapi parameter which tells the PSTK to revert to using ZAPI for CmdLet's with the context of the cluster connection. That might be a temporary solution for you but longer term ZAPI is being removed in ONTAP 9.13 so you would need to use REST API CLI pass through.
Hope that helps explain it
/Matt
Hey @reuvygroovy. If you find that you're not getting the answer in a timely manner over here in the Community, you might find some success over in the Powershell Toolkit channel in our Discord. If you'd like, you can join us here: https://netappdiscord.com
Hi,
Did you try using the -Ontapi parameter when connecting to the cluster using Connect-NcController then test the command you are having problems with? By default the latest version of the PSTK will do an ONTAP version check and if running >= ONTAP 9.6 it will attempt to use REST API's unless you explicitly tell it not to by using the -Ontapi parameter which tells the PSTK to revert to using ZAPI for CmdLet's with the context of the cluster connection. That might be a temporary solution for you but longer term ZAPI is being removed in ONTAP 9.13 so you would need to use REST API CLI pass through.
Hope that helps explain it
/Matt