I have 2 VPS in DigitalOcean. I was able to SSH into them with password before today. But now, when I try to SSH with my machine which is Kali Linux, after type the password, I get this response:

packet_write_wait: Connection to X.X.X.X port 22: Broken pipe

I tried to add SSH key of my machine (I am not sure did it right) but no success. I know the problem is in Kali because I can SSH into with my other machine which is Windows.

What can be the problem?

  • 1
    I'm having the same problem when trying to push code to Gitlab over SSH. It only started happening a couple of days ago. I fixed it by using Git over HTTPS, but I don't know what the cause of the problem is. Hopefully, someone will be able to figure it out. For the record, I'm using Manjaro Linux with all the latest updates installed. – Cromulent Sep 6 '18 at 13:30
  • I suspected from some configuration or environment variables on my machine after checking ssh logs. The connection is actually opening but closed immediately after. So I thought give it a change to connect using something differentthan regular terminal. I tried yakuake but no succes. Then I tried Putty and that worked. However I have still no idea of the main cause of the problem – displayme Sep 7 '18 at 20:26

I had the exact same problem in Kali and Parrot distros and have been looking for a solution for quit some time.

I was able to fix it by adding this to my ssh_config or ~/.ssh/config file:

IPQoS reliability

I hope this helps for you also...

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.