Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I started with a box at Google Compute Engine (Google's cloud service) with an account named xyz and an ephemeral IP address.

Let's pretend the ephemeral IP address was

Before I started the process below, I was able to login to xyz@ with a password.

I then attached a static IP address. Let's pretend the static IP address was

I then typed

my@localbox:~$ ssh-copy-id xyz@

The command seem to hang, so I killed the terminal.

I then did a simple

my@localbox:~$ ssh xyz@

Which succeeded without prompting me for a password.

I assumed that my key had made it into my authorized_keys, so I did

xyz@cloudbox:~$ ls -al

To my surprise, .ssh contained only a known_hosts file, not an authorized_keys file.

Additionally, the command

my@localbox:~$ ssh-copy-id xyz@

still hangs when I try it, so it wasn't just a random fluke.

How am I able to login to this account without a password if there's no .ssh/authorized_keys file? Is it related to the cause of ssh-copy-id hanging?

share|improve this question
can you paste the servers sshd.conf? – Gotschi Mar 6 '14 at 18:43
@Gotschi It's almost 100 lines...Are there specific values that are relevant? – Thomas Johnson Mar 6 '14 at 18:49
checking my ssh, the authorized_keys file should be in the .ssh subdirectory So since you logged into, have a look for ~/.ssh/authorized_keys there, or even authorized_keys2 i've heard of that one too. But look in the .ssh subdirectory list files there – barlop Nov 2 '14 at 13:55
I don't know about ssh-copy-id hanging.. here i'm v unsure but I wonder if it uses a password and that isn't working.. or if there's a verbose mode for it like -v or -vvv or if you try not managing to get the public key and it goes to password so you can check if it manages to log in via password.. maybe you could try starting again with configuring it, so first get password working then keys. – barlop Nov 2 '14 at 14:01
Oh actually I figured it out a while after posting this question. It was a SSH control master session that was running in the background. ssh-copy-id hanging with control master is a known bug – Thomas Johnson Nov 3 '14 at 3:24
up vote 0 down vote accepted

The problem was a SSH control master session that was running in the background. ssh-copy-id hanging with control master is a known bug.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.