access to a remote router is refused via ansible ssh

18 views
Skip to first unread message

Kevin Y

unread,
Jan 2, 2022, 11:47:43 AM1/2/22
to Ansible Project

 I have a question. I am not sure -u is followed by ansible user or the remote router username? The ansible server is at the windows8 desktop. The router can be reached via ssh from the PC, but when using command " ansible lab-hosts -m raw -a "show run" -u ansible -k | grep 'hostname\| system mtu' ", the connection is refused.

If the username and password are "abc" for the router, can I type the command like the below?

ansible lab-hosts -m raw -a "show run" -u abc -k abc | grep 'hostname\| system mtu'

If not, can you provide correct one? thanks

Reply all
Reply to author
Forward
0 new messages