-
-
Notifications
You must be signed in to change notification settings - Fork 32
Open
Description
Running Set-NSLBServer
fails with Invalid nitro action or operation
on NS12.1 49.23.nc. This appears to be related to Update action error #16. I suspect this may be an issue with the other Set
cmdlets in the module - at least on the newer versions of NetScaler.
Expected Behavior
There is no error and the operation completes successfully.
Current Behavior
Invoking Set-NSLBServer
and specifying valid Sesssion, Name, and IPAddress parameters fails:
PS C:\> Set-NSLBServer -Session $session -Name 'servername' -IPAddress '10.0.0.1'
Invoke-RestMethod : { "errorcode": 1240, "message": "Invalid nitro action or operation", "severity": "ERROR" }
At C:\Users\user\Documents\WindowsPowerShell\Modules\NetScaler\1.7.0\Private\_InvokeNSRestApi.ps1:144 char:21
+ $response = Invoke-RestMethod @restParams
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-RestMethod], WebException
+ FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeRestMethodCommand
Possible Solution
The solution appears to be to remove -Action update
from line 87 of Set-NSLBServer.ps1, for example:
_InvokeNSRestApi -Session $Session -Method PUT -Type nshostname -Payload $params # -Action update
Your Environment
- Module Version: 1.7.0
- Operating System: Windows 10 1803 Build 17134.706
- PowerShell Version: 5.1.17134.590
- NetScaler Version: NS12.1
Metadata
Metadata
Assignees
Labels
No labels