#9.13 required perms

1 messages · Page 1 of 1 (latest)

dark oracle
#

So since we updated Ontap to 9.12 I've had issues with sporadically failing jobs.
Ive updated the PS toolkit from 9.9.1 to 9.13 and now cannot for the life of me get a simple connect-nccontroller to be successful due to constant 401 unauthorized.

The account in testing with worked prior to updates, did required permissions / roles change?
I'm running Ontap 9.12.1p2 currently and it's bombing out on numerous clusters.

dark oracle
#

Yeah works with -zapicall enabled

dark oracle
#

Well, back to my issues pre-updating of running into

ERROR  ]  Execution finished with the following error (winrm-exec.py:332)[root]
[ERROR  ]  get-ncaggr : Unable to find API: aggr-get-iter on admin vserver prodfiler
At C:\scripts\username\aggr_scrape_slack_post_webhook_1.ps1:51 char:14
+     $aggrs = get-ncaggr #| Where-Object {(!($_.name -match "aggr0"))}
+              ~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (prodfiler.domain.net:NcController) [Get-NcAggr], EAPINO 
   TFOUND
    + FullyQualifiedErrorId : ApiException,DataONTAP.C.PowerShell.SDK.Cmdlets.Aggr.GetNcAggr
 
get-ncaggr : Unable to find API: aggr-get-iter on admin vserver drfiler
At C:\scripts\username\aggr_scrape_slack_post_webhook_1.ps1:51 char:14
+     $aggrs = get-ncaggr #| Where-Object {(!($_.name -match "aggr0"))}
+              ~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (drfiler.domain.net:NcController) [Get-NcAggr], EAPINO 
   TFOUND
    + FullyQualifiedErrorId : ApiException,DataONTAP.C.PowerShell.SDK.Cmdlets.Aggr.GetNcAggr_.name
celest gulch
dark oracle
#

Rest access isn't controlled via the traditional security login command set is it

celest gulch
#

You need http access to your cluster. Create a user:
::> security login create -user-or-group-name testuser -application http -authentication-method password -role admin

Test REST API access with curl:
# curl -X GET -u testuser:password -k "https://<ip_address>/api/cluster?fields=version"

If you need custom roles you can use "traditional" roles (security login role create) or rest-roles (security login rest-role create). ONTAP will map the traditional roles to rest access. So you should be fine with existing roles that were used for ZAPI.