Software Development Kit (SDK) and API Discussions

na_ontap_info

dabril
1,975 Views
 So I am working with some automation using Ansible and the NetApp Modules
 the one I am using is na_ontap_info
 and whenever I ran a task with that module, I get this error:
 NetApp API failed. Reason - 401:basic auth failed
 So I checked the account that I am using via SSH and it is working
 and also checked it has console, ontapi and ssh access
 but still not working
1 REPLY 1

leiz
1,931 Views

You need to use localhost and https to communicate.

 

Here is an example of ad-hoc ansible command.

 

"ansible localhost -m na_ontap_info -a "hostname=192.168.0.101 username=admin password=Netapp01 https=true validate_certs=false"

 

Please replace the hostname with your cluster management IP, and same for username and password to see if it works.

Public