0

I'm trying to SSH into gcloud. I'm currently inside ~/.ssh and have some VNC keys stored in there that was given to me. I have followed instructions with gauth login and set my project id to clear-mountain-94802. Here is the image of what I see after I respond 'y' to overwriting my files with the command gcloud compute ssh clear-mountain-94802 --verbosity=debug

https://i.stack.imgur.com/WYR72.jpg

It just gets stuck at "DEBUG: Executing command: [u'/cygdrive/c/WINDOWS/System32/OpenSSH/ssh-keygen', u'-t', u'rsa', u'-f', u'/home/D/.ssh/google_compute_engine']".

When I ctrl+c, it then shows "DEBUG: Subprocess [19348] got [2]". I'm at a loss as to why this is.

I'm running Windows 10 with a cygwin install.

Update#1: When I ran it again and it got stuck, I ctrl+c again and this time, I see this: ERROR: gcloud crashed (OSError): [Errno 13] Permission denied

Update#2: Just to verify if the ssh-keygen command exists, I looked in my folder and the exe file does indeed exist. I ran another command found in the screenshot below, and it hangs again. Not sure what is going on here. https://i.stack.imgur.com/ERTLG.jpg

Andrew
  • 21
  • 1
  • 3
  • No idea if that is the case here but cryptographic key generation such as with ssh-keygen usually depends on sufficient unpredictable entropy (good truly random data) which is often in short supply on (freshly booted) virtual servers – HBruijn Aug 16 '18 at 09:20
  • gcloud compute ssh will fully manage your SSH keys, however, make sure you are running the SDK in an elevated prompt (run as admin) and make sure that you (the user) have sufficient IAM permissions in your project to copy metadata and use service accounts – Patrick W Aug 17 '18 at 15:55
  • @PatrickW I right clicked on cygwin and "ran as administrator". Is this sufficient? Also, I am not sure what you mean by IAM permissions. How do I go about checking this? – Andrew Aug 18 '18 at 03:40
  • @PatrickW Also, the real command I'm trying to run just hangs, which is why I thought running ssh-keygen would be the first step: https://imgur.com/a/OTpvgmy Here's the real command I need to run: gcloud compute --project "clear-mountain-94802" ssh --zone "us-central1-c" "ajc" – Andrew Aug 18 '18 at 03:54
  • Yeah right clicking and choosing "run as admin" should do it. It seems that the current managed key pair is corrupted and not being replaced. Is this happening when you connect to any instance or just one specific VM? – Patrick W Aug 21 '18 at 15:41

0 Answers0