This is a bit strange. I have two computer. One where the OS is Ubuntu and the other where it is a Windows 10 VM. From the first computer, I SSH my VM and I got this

jeremie@jeremie-ThinkStation-D30:~$ ssh 192.168.x.x
The authenticity of host '192.168.x.x (192.168.x.x)' can't be established.
ECDSA key fingerprint is SHA256:4OuK3XcaFN5whW9exSrOYb8nnom+dqGt8DyF6Yjg5V0.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '192.168.x.x' (ECDSA) to the list of known hosts.
jeremie@192.168.x.x's password: 
Permission denied, please try again.
jeremie@192.168.x.x's password: 
Permission denied, please try again.
jeremie@192.168.x.x's password: 
jeremie@192.168.x.x: Permission denied (publickey,password,keyboard-interactive).

Be aware that I installed Bash/Ubuntu on my Windows VM. I had to set a username and password.

Why am I getting a rejection even though I enter the right password? Where is my error?


If I try with the same computer, i.e. my VM is hosted, I get the same problem using the same keyboard.

  • Just to be clear, you are trying to SSH from Ubuntu to a Windows10 VM running in some other computer (or as a VM in your Ubuntu)? Is any of these systems using/expecting a non-QWERTY keyboard (I know it shouldn't make any difference, but it"s Windows, so I expect the unexpected). – xenoid Mar 24 '20 at 20:40
  • @xenoid I tried the very simple password '1234abcd' and I got the same problem. What do you suggest? – J.Doe Mar 24 '20 at 20:42
  • Are you sure the username is correct? – Daniel B Mar 24 '20 at 20:44
  • From Win10 VM, if I run cat /etc/passwd, one of the line is jeremie:x:1000:1000:,,,:/home/jeremie:/bin/bash. I gues the username is fine. Also when I run ssh ip_address, by default ssh add the username when it asked me the password. It looks like jeremie@ip_address's password – J.Doe Mar 24 '20 at 20:49
  • @J.Doe if you aren't all-QWERTY I would suggest a layout-agnostic password, between QWERTY and AZERTY, ERTYUIOPSDFGHJKLXCVBN are common (in other words, avoid AZQWM, punctuation, numbers), at least until you have ascertained proper support for your keyboard layout. You can also bypass the problem by using key-based login. – xenoid Mar 24 '20 at 20:52

Could be that your keyboard layout somehow changed from, say, QWERTY to AZERTY, perhaps by hitting the Alt-Shift combo, or that you hit CapsLock by accident when typing,.

Also remember that in Windows, pressing the CapsLock key on the left side of your keyboard won't have the same effect it has by default in Ubuntu.

  • What do you suggest? – J.Doe Mar 24 '20 at 20:42
  • Restart your VM, and on the logon screen, when your password box is open and ready to take in your typing, check the bottom right corner for the system language currently in use. If it's the one you chose during install, or customized later to your liking, then your password should work. Make sure NumLock is active if you're using an extended keyboard, with a numeric keypad. Push come to shove, reinstall Windows in your VM. I know it's a pain in the rear, but if you can't access your Windows VM, you might as well save yourself some time. Just use the Shift key for upper case, not CapsLock. – user1019780 Mar 24 '20 at 20:46

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.