briank1179
Posts: 29
Joined: Wed Jun 29, 2016 4:40 pm

SSH Not Connecting

Sat Aug 06, 2016 10:37 pm

When I try to connect to my Raspberry Pi via PuTTy I get "access denied" after entering the password. I know the Pi is connected to the network because I can ping its IP address from the PC with no issues. Even tried connecting SSH through the Pi's terminal and get "Permission denied" after inputting the password. Double checked that I'm using the correct password. I have two Pi's with the same Raspbian image and I'm unable to connect to either via SSH. Restarted the router just to check that possible issue off.
Any suggestions on what to look for would be greatly appreciated.

Thank you

User avatar
nl3prc
Posts: 160
Joined: Sun Jul 24, 2016 12:39 pm
Location: Den Helder the netherlands

Re: SSH Not Connecting

Sun Aug 07, 2016 12:43 pm

maybe you use the wrong username normaly ssh is set to not accept root user tot loggin
you have to use pi as username and i think that the password is raspberry

User avatar
nl3prc
Posts: 160
Joined: Sun Jul 24, 2016 12:39 pm
Location: Den Helder the netherlands

Re: SSH Not Connecting

Sun Aug 07, 2016 12:58 pm


briank1179
Posts: 29
Joined: Wed Jun 29, 2016 4:40 pm

Re: SSH Not Connecting

Sun Aug 07, 2016 6:54 pm

Thanks for the information, but I'm a bit confused. Based on information I gleaned from the internet, when I use raspi-config, it allows the user to change the password in "advanced options". If the user changes the password, wouldn't that "new" password be what is needed to login through "SSH". For a test when I tried to Pi's default password, "raspberry", it still gave me "access denied". Using PuTTy shouldn't I be able to access the Pi with it's assigned IP address and it's assigned password?
Based on the forum link submitted I'm not sure I understand. If I use raspi-config, "Advanced Options", to change the password, isn't that new password what is needed for future logins, such as PuTTy?

Again, I really appreciate the help.

User avatar
nl3prc
Posts: 160
Joined: Sun Jul 24, 2016 12:39 pm
Location: Den Helder the netherlands

Re: SSH Not Connecting

Sun Aug 07, 2016 7:05 pm

i used passwd to change the password

like this if you are logged in with user pi

sudo passwd root

be aware that you use small print for the user not capital print

briank1179
Posts: 29
Joined: Wed Jun 29, 2016 4:40 pm

Re: SSH Not Connecting

Sun Aug 07, 2016 9:05 pm

Thank you very much!! That helped. It also pointed out a "beginners" mistake I was making in that when it asked for the user's name I was entering the hostname.

Again, I very much appreciate all the your help!!!

User avatar
DougieLawson
Posts: 36515
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: SSH Not Connecting

Sun Aug 07, 2016 9:14 pm

You can test ssh on the local system.

ssh [email protected] or ssh [email protected].
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

User avatar
rurwin
Forum Moderator
Forum Moderator
Posts: 4258
Joined: Mon Jan 09, 2012 3:16 pm
Contact: Website

Re: SSH Not Connecting

Sun Aug 07, 2016 10:38 pm

DougieLawson wrote:You can test ssh on the local system.

ssh [email protected] or ssh [email protected].
Which reminds me of another gotcha. If you just type

Code: Select all

ssh machinename
It will try to login with the username that you are logged-in as on the PC that you are typing the command on, which most of the time isn't pi or any other valid account on the RaspPi.

klricks
Posts: 6613
Joined: Sat Jan 12, 2013 3:01 am
Location: Grants Pass, OR, USA
Contact: Website

Re: SSH Not Connecting

Mon Sep 05, 2016 1:58 am

supra wrote:@briank1179
Try this:

Code: Select all

sudo rpi-update.
.
Please do not suggest rpi-udate to fix random problems. Rpi-update should only be used when told to do so for very specific problems. It should only be used by advanced users who know how to fix any problems that it may cause (or be prepared to re-image the OS).
Unless specified otherwise my response is based on the latest and fully updated Raspbian Buster w/ Desktop OS.

User avatar
nl3prc
Posts: 160
Joined: Sun Jul 24, 2016 12:39 pm
Location: Den Helder the netherlands

Re: SSH Not Connecting

Mon Sep 05, 2016 9:25 am

rpi-update is used to update your kernel and modules and wil have no efect on your inlog users

if you want to update your packages use apt-get update first and than apt-get upgrade

Return to “Beginners”