Re: [ansible-project] failing to connect through ssh

2017-08-22 Thread Dick Visser
Hi



On 22 August 2017 at 08:34, chandana gcp  wrote:
>
> Hi Dick
>
> Thanks a lot for your reply Dick. I tied the same steps as you have 
> suggested in the link, still the error is coming and i have also tried 
> running the playbook as user rather than root, but still error is coming.


Actually, it is a different error, and also a warning (at the end).
To fix one thing at a time - can you make sure the permissions are
fixed, and then run the playbook again?


Dick


>
> TASK [Gathering Facts] 
> *
> fatal: [35.202.234.156]: UNREACHABLE! => {"changed": false, "msg": "Failed to 
> connect to the host via ssh: Warning: Permanently added '35.202.234.156' 
> (ECDSA) to the list of known hosts.\r\nPermission denied 
> (publickey,gssapi-keyex,gssapi-with-mic).\r\n", "unreachable": true}
> fatal: [35.202.50.199]: UNREACHABLE! => {"changed": false, "msg": "Failed to 
> connect to the host via ssh: Warning: Permanently added '35.202.50.199' 
> (ECDSA) to the list of known hosts.\r\nPermission denied 
> (publickey,gssapi-keyex,gssapi-with-mic).\r\n", "unreachable": true}
> fatal: [35.202.232.100]: UNREACHABLE! => {"changed": false, "msg": "Failed to 
> connect to the host via ssh: Warning: Permanently added '35.202.232.100' 
> (ECDSA) to the list of known hosts.\r\nPermission denied 
> (publickey,gssapi-keyex,gssapi-with-mic).\r\n", "unreachable": true}
> fatal: [35.184.19.164]: UNREACHABLE! => {"changed": false, "msg": "Failed to 
> connect to the host via ssh: Warning: Permanently added '35.184.19.164' 
> (ECDSA) to the list of known hosts.\r\nPermission denied 
> (publickey,gssapi-keyex,gssapi-with-mic).\r\n", "unreachable": true}
>  [WARNING]: Could not create retry file 
> '/home/gcpconsole/compute-ansible-gluster/gluster.retry'.
> [Errno 13] Permission denied: 
> u'/home/gcpconsole/compute-ansible-gluster/gluster.retry'
>







-- 
Dick Visser
GÉANT

Want to join us? We're hiring: https://www.geant.org/jobs

-- 
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 ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAL8fbwPg0DVa_Aj%2Bs%3DRitHHcZycybgJhmtjF-J8mthWSSAJS-Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ansible-project] failing to connect through ssh

2017-08-21 Thread Dick Visser
Hi

As the errors state this is a problem with how the SSH keys are set-up.
The github URL has quite elaborate documentation (as usual with Google
tools), and it includes a URL to an even more elaborate page specifically
for setting up SSH keys (for completeness:
https://cloud.google.com/compute/docs/instances/adding-removing-ssh-keys?hl=en
).
Check those steps again.

One hint could be that apparently you're running this playbook as root.
Could it be that you've set up SSH keys in a different/your account, but
that you are running the playbook with 'sudo'? That would explain things.
If that's the case: don't do that. Run the playbook as the user that you've
setup SSH keys for.

Dick

On Mon, 21 Aug 2017 at 17:54,  wrote:

> I used the below example to execute from GIT
> https://github.com/GoogleCloudPlatform/compute-ansible-gluster
>
> *I am getting the following error:*
>
> fatal: [35.184.19.164]: UNREACHABLE! => {"changed": false, "msg": "Failed to 
> connect to the host via ssh: 
> @@@\r\n@WARNING: 
> REMOTE HOST IDENTIFICATION HAS CHANGED! 
> @\r\n@@@\r\nIT IS 
> POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!\r\nSomeone could be 
> eavesdropping on you right now (man-in-the-middle attack)!\r\nIt is also 
> possible that a host key has just been changed.\r\nThe fingerprint for the 
> ECDSA key sent by the remote host 
> is\n05:88:4d:7f:50:ec:21:38:12:d9:b8:0f:b1:29:0c:33.\r\nPlease contact your 
> system administrator.\r\nAdd correct host key in /root/.ssh/known_hosts to 
> get rid of this message.\r\nOffending ECDSA key in 
> /root/.ssh/known_hosts:17\r\nChallenge/response authentication is disabled to 
> avoid man-in-the-middle attacks.\r\nPermission denied 
> (publickey,gssapi-keyex,gssapi-with-mic).\r\n", "unreachable": true}
> fatal: [35.202.50.199]: UNREACHABLE! => {"changed": false, "msg": "Failed to 
> connect to the host via ssh: 
> @@@\r\n@WARNING: 
> REMOTE HOST IDENTIFICATION HAS CHANGED! 
> @\r\n@@@\r\nIT IS 
> POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!\r\nSomeone could be 
> eavesdropping on you right now (man-in-the-middle attack)!\r\nIt is also 
> possible that a host key has just been changed.\r\nThe fingerprint for the 
> ECDSA key sent by the remote host 
> is\n23:8a:d0:e0:50:be:97:9a:c7:64:c1:24:b1:f2:42:1f.\r\nPlease contact your 
> system administrator.\r\nAdd correct host key in /root/.ssh/known_hosts to 
> get rid of this message.\r\nOffending ECDSA key in 
> /root/.ssh/known_hosts:13\r\nChallenge/response authentication is disabled to 
> avoid man-in-the-middle attacks.\r\nPermission denied 
> (publickey,gssapi-keyex,gssapi-with-mic).\r\n", "unreachable": true}
> fatal: [35.193.161.39]: UNREACHABLE! => {"changed": false, "msg": "Failed to 
> connect to the host via ssh: 
> @@@\r\n@WARNING: 
> REMOTE HOST IDENTIFICATION HAS CHANGED! 
> @\r\n@@@\r\nIT IS 
> POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!\r\nSomeone could be 
> eavesdropping on you right now (man-in-the-middle attack)!\r\nIt is also 
> possible that a host key has just been changed.\r\nThe fingerprint for the 
> ECDSA key sent by the remote host 
> is\nc1:65:32:ac:b6:97:a9:ec:55:38:ba:ac:49:1e:5e:6e.\r\nPlease contact your 
> system administrator.\r\nAdd correct host key in /root/.ssh/known_hosts to 
> get rid of this message.\r\nOffending ECDSA key in 
> /root/.ssh/known_hosts:12\r\nChallenge/response authentication is disabled to 
> avoid man-in-the-middle attacks.\r\nPermission denied 
> (publickey,gssapi-keyex,gssapi-with-mic).\r\n", "unreachable": true}
> to retry, use: --limit 
> @/home/gcpconsole/compute-ansible-gluster/gluster.retry
>
> PLAY RECAP 
> 
> 127.0.0.1  : ok=7changed=6unreachable=0failed=0
> 35.184.19.164  : ok=0changed=0unreachable=1failed=0
> 35.193.161.39  : ok=0changed=0unreachable=1failed=0
> 35.202.232.100 : ok=0changed=0unreachable=1failed=0
> 35.202.50.199  : ok=0changed=0unreachable=1failed=0
>
>
> ***
>
> I have added all the necessary key in the GCP console
>
>
>
> Please help me soving this
>
> --
> 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 

[ansible-project] failing to connect through ssh

2017-08-21 Thread gcpconsole
I used the below example to execute from GIT
https://github.com/GoogleCloudPlatform/compute-ansible-gluster

*I am getting the following error:*

fatal: [35.184.19.164]: UNREACHABLE! => {"changed": false, "msg": "Failed to 
connect to the host via ssh: 
@@@\r\n@WARNING: 
REMOTE HOST IDENTIFICATION HAS CHANGED! 
@\r\n@@@\r\nIT IS 
POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!\r\nSomeone could be 
eavesdropping on you right now (man-in-the-middle attack)!\r\nIt is also 
possible that a host key has just been changed.\r\nThe fingerprint for the 
ECDSA key sent by the remote host 
is\n05:88:4d:7f:50:ec:21:38:12:d9:b8:0f:b1:29:0c:33.\r\nPlease contact your 
system administrator.\r\nAdd correct host key in /root/.ssh/known_hosts to get 
rid of this message.\r\nOffending ECDSA key in 
/root/.ssh/known_hosts:17\r\nChallenge/response authentication is disabled to 
avoid man-in-the-middle attacks.\r\nPermission denied 
(publickey,gssapi-keyex,gssapi-with-mic).\r\n", "unreachable": true}
fatal: [35.202.50.199]: UNREACHABLE! => {"changed": false, "msg": "Failed to 
connect to the host via ssh: 
@@@\r\n@WARNING: 
REMOTE HOST IDENTIFICATION HAS CHANGED! 
@\r\n@@@\r\nIT IS 
POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!\r\nSomeone could be 
eavesdropping on you right now (man-in-the-middle attack)!\r\nIt is also 
possible that a host key has just been changed.\r\nThe fingerprint for the 
ECDSA key sent by the remote host 
is\n23:8a:d0:e0:50:be:97:9a:c7:64:c1:24:b1:f2:42:1f.\r\nPlease contact your 
system administrator.\r\nAdd correct host key in /root/.ssh/known_hosts to get 
rid of this message.\r\nOffending ECDSA key in 
/root/.ssh/known_hosts:13\r\nChallenge/response authentication is disabled to 
avoid man-in-the-middle attacks.\r\nPermission denied 
(publickey,gssapi-keyex,gssapi-with-mic).\r\n", "unreachable": true}
fatal: [35.193.161.39]: UNREACHABLE! => {"changed": false, "msg": "Failed to 
connect to the host via ssh: 
@@@\r\n@WARNING: 
REMOTE HOST IDENTIFICATION HAS CHANGED! 
@\r\n@@@\r\nIT IS 
POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!\r\nSomeone could be 
eavesdropping on you right now (man-in-the-middle attack)!\r\nIt is also 
possible that a host key has just been changed.\r\nThe fingerprint for the 
ECDSA key sent by the remote host 
is\nc1:65:32:ac:b6:97:a9:ec:55:38:ba:ac:49:1e:5e:6e.\r\nPlease contact your 
system administrator.\r\nAdd correct host key in /root/.ssh/known_hosts to get 
rid of this message.\r\nOffending ECDSA key in 
/root/.ssh/known_hosts:12\r\nChallenge/response authentication is disabled to 
avoid man-in-the-middle attacks.\r\nPermission denied 
(publickey,gssapi-keyex,gssapi-with-mic).\r\n", "unreachable": true}
to retry, use: --limit 
@/home/gcpconsole/compute-ansible-gluster/gluster.retry

PLAY RECAP 

127.0.0.1  : ok=7changed=6unreachable=0failed=0   
35.184.19.164  : ok=0changed=0unreachable=1failed=0   
35.193.161.39  : ok=0changed=0unreachable=1failed=0   
35.202.232.100 : ok=0changed=0unreachable=1failed=0   
35.202.50.199  : ok=0changed=0unreachable=1failed=0  


***

I have added all the necessary key in the GCP console



Please help me soving this

-- 
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 ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/e2f709d9-2625-4636-b276-c48a90bb240a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.