also here is a copy are my settings of for ansible.cfg and version I am 
running

ansible 2.7.8

  config file = /etc/ansible/ansible.cfg

  configured module search path = ['/usr/share/ansible']

  ansible python module location = 
/usr/local/lib/python3.6/site-packages/ansible

  executable location = /usr/local/bin/ansible

  python version = 3.6.8 (default, Feb 22 2019, 12:24:32) [GCC 4.4.7 
20120313 (Red Hat 4.4.7-23)]

[root@ansiblevm ansible]#

 

 

 

 

cat ansible.cfg | grep -v "#"

 

 

[defaults]

 

 

library        = /usr/share/ansible/

remote_tmp     = $HOME/.ansible/tmp

forks          = 5

 

 

timeout = 10

 

 

log_path = /var/log/ansible.log

 

 

[inventory]

 

 

[privilege_escalation]

 

[paramiko_connection]

 

[ssh_connection]

 

 

[persistent_connection]

 

 

[accelerate]

 

[selinux]

 

[colors]

[diff]

On Friday, February 22, 2019 at 4:56:07 PM UTC-5, VeGeTa-X wrote:
>
> I am starting out at ansible with a basic playbook to learn ansible I am 
> getting the error message below I know the user and creds are correct I 
> have logged into that switch from
> ansible server can someone please let me know what I am missing?
>
>
>
> #error message
>
> TASK [Gathering Facts] 
> ************************************************************************************************************************************************
>
> fatal: [vegeta01_temp]: UNREACHABLE! => {"changed": false, "msg": "Failed 
> to connect to the host via ssh: 
> \n****************************************************************************Permission
>  
> denied (publickey,password,keyboard-interactive).", "unreachable": true}
>
>
> ---
>
>  
>
> - name: nxos_facts module
>
>   hosts: vegeta_core
>
>   vars:
>
>     ssh:
>
>       host: “{{ansible_host}”
>
>       username: “{{vegeta}”
>
>       password: “{{abc123}”
>
>  
>
>     nxapi:
>
>       host: "{{ ansible_host }}"
>
>       username: "{{ vegeta }}”
>
>       password: "{{ abc123 }}"
>
>       transport: nxapi
>
>       use_ssl: no
>
>       validate_certs: no
>
>       port: 80 
>
>  
>
>  
>
>   tasks:
>
>     - name: nxos_facts ssh
>
>       nxos_facts:
>
>         provider: "{{ssh}}"
>
>  
>
>     - name: nxos_facts nxapi
>
>       nxos_facts:
>
>         provider: "{{ nxapi }}"   
>

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/3db08eee-6d50-4c9d-8d9a-2fcd3b21f09c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to