I have recently bought a raspberry pi, and I have installed raspbian on it. I decided to change the default password, but after that every time I tried to login to ssh, it said permission denied. I tryed to change the password again, but it said invalid password. The only way I could change the password was with sudo. After that it worked a while but the next day it said invalid password again! I have no idea why it keeps changing but I need it to stop. Any ideas?Also, I have enabled ssh through raspi-config
Did you change your password through SSH or with a physical keyboard attached?– 88weighedSep 29, 2017 at 11:49
You might check if the keyboard settings are correct. The default keyboard setup is English (UK). If you are setting your password from a layout other than English (UK), you will actually set your password to something different than you want. For instance, if you think you're typing an @ (shift + 2), you're actually typing ".
Keyboard layout can be changed through raspi-config. Hope this helps.
Are you connecting by WIFI? if so my answer might help as you need to do some setup.
Have you ever been able to SSH into the pi before the password change? If you have a keyboard and monitor setup run the raspi-config
The first option you can set "User password" for example for the username "pi".
then under "Interfacing Options" enable SSH.
Yes, I have enabled ssh through raspi-config– CamdenSep 28, 2017 at 23:04
Is your pi connected to your router? I think you have not setup your WIFI Sep 29, 2017 at 0:23
updated my answer hope it helps. Sep 29, 2017 at 0:33
im commenting on my pi! of course internet is set up– CamdenSep 29, 2017 at 1:34
is your pi user account locked? what happens if you passwd -u <your-username> Sep 29, 2017 at 1:46