I am trying to connect to my server using

ssh user@server.com -vv

I get

debug1: read_passphrase: can't open /dev/tty: No such device or address

error or just

Permission denied, please try again.
Permission denied, please try again.
Permission denied (publickey,password).

when I not use -vv option. /dev/tty file does exist. I am logged in as root, so I have access to it. tty command returs


I am remotely connected (using Putty) to server, that I am trying to connects to other server from. It is not a cron job. How can I solve the problem?

  • Does the /dev/tty device exist on both servers: – derchris Mar 25 '11 at 16:20
  • @derchris: Yes, it does exist. I can easily connect to server.com machine from other places. – LukLed Mar 25 '11 at 16:53
  • What would be a main difference between a server you can, and the server you can't connect? Just trying to rule out any OS/version issues. – derchris Mar 25 '11 at 17:12
  • @derchris: I believe this is related to problem with /dev/tty on machine, that I am trying to ssh from, but I don't know how to solve it. – LukLed Mar 25 '11 at 17:16
  • I understand the problem. What I was asking was you said you can connect from somewhere else. So what is the difference between these 2 systems you try to connect from. – derchris Mar 25 '11 at 17:20

What does ls -la /dev/tty show? Is it both world-readable and world-writeable?

$ ls -la /dev/tty

crw-rw-rw- 1 root tty 5, 0 Aug 23 20:58 /dev/tty


That is what you should see. If not, that's your problem.

  • mu /dev/tty was strangely with the "crw-------" rights. Changing to crw-rw-rw- fixed the thing. This is the first time I had to do that in my ubuntu installations. Why were the rights not the good ones ? – Luc Oct 23 '13 at 11:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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