Jgrboer
Posts: 6
Joined: Mon Apr 27, 2020 4:42 pm

Problem logging in Raspberry PI

Mon Apr 27, 2020 4:46 pm

Hi there,


I tried to setup my raspberry Pi 3.
Put the latest image on the sd card, put the file SSH on the same sd card...

Put the sd card in the RPI....

When I try to logon to the RPI I receive the following message:
\
ssh_dispatch_run_fatal: Connection to 192.168.1.24 port 22: Invalid key length
jochemgrootenboer@MacBook-Air-********** ~ %

Whats going wrong and what can I do about it..??

Hope somebody can help me...

User avatar
RaspbianUser1
Posts: 204
Joined: Thu Mar 05, 2020 6:34 pm

Re: Problem logging in Raspberry PI

Mon Apr 27, 2020 5:03 pm

I am no expert but I would like to ask and suggest a couple of things.
Question 1:
Are you able to turn your pi on and use it using the HDMI port

Question 2:
Have you actually looked at the pi, using the pi, (not running headless)

Suggestion 1:
look at the pi and just look if ssh is enabled on the pi, you possibly done something wrong (not doubting you)

Suggestion 2:
Make sure you are connecting to the correct internal IP address by going to your 192.168.1.0 page and seeing if the raspberry pi is connected and see its internal ip address, it might not be 192.168.1.24

Hope this helps :)
Running Raspberry Pi OS Full, therefore my comments will be based on that
Using RPI-4B 4GB at 2.1GHz CPU and 700MHz GPU
don't format your sd because someone said so.
Or put your favourite cutlery into your nearest outlet (May result in death) ;)

Jgrboer
Posts: 6
Joined: Mon Apr 27, 2020 4:42 pm

Re: Problem logging in Raspberry PI

Mon Apr 27, 2020 5:59 pm

Sorry,

found the problem, the IP address changed from 24 to 31...... pffff took me a lot of time

thanx for your help

User avatar
RaspbianUser1
Posts: 204
Joined: Thu Mar 05, 2020 6:34 pm

Re: Problem logging in Raspberry PI

Mon Apr 27, 2020 6:32 pm

You will most likely have to change your SSH command every day, week or month as it may be dynamic
Running Raspberry Pi OS Full, therefore my comments will be based on that
Using RPI-4B 4GB at 2.1GHz CPU and 700MHz GPU
don't format your sd because someone said so.
Or put your favourite cutlery into your nearest outlet (May result in death) ;)

User avatar
HawaiianPi
Posts: 5710
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: Problem logging in Raspberry PI

Mon Apr 27, 2020 6:42 pm

Check your router's DHCP settings. Many routers have the ability to reserve an IP address for a device, and if yours does, you can reserve the IP of your Raspberry Pi so it won't change when either are rebooted.
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups...and where is that annoying music coming from?

Jgrboer
Posts: 6
Joined: Mon Apr 27, 2020 4:42 pm

Re: Problem logging in Raspberry PI

Mon Apr 27, 2020 7:58 pm

Normaly the raspberry is connected through WiFi Wich has a fixed ip address, this 24 - 31 address was from the eth0, for weeks it uses the 24 address but last friday it changed from 24 to 31.. now the eth0 is disconnected... it looks strange to me because there was sort of an answer....

Jgrboer
Posts: 6
Joined: Mon Apr 27, 2020 4:42 pm

Re: Problem logging in Raspberry PI

Mon Apr 27, 2020 7:58 pm

Normaly the raspberry is connected through WiFi Wich has a fixed ip address, this 24 - 31 address was from the eth0, for weeks it uses the 24 address but last friday it changed from 24 to 31.. now the eth0 is disconnected... it looks strange to me because there was sort of an answer....

Jgrboer
Posts: 6
Joined: Mon Apr 27, 2020 4:42 pm

Re: Problem logging in Raspberry PI

Mon Apr 27, 2020 7:58 pm

Normaly the raspberry is connected through WiFi Wich has a fixed ip address, this 24 - 31 address was from the eth0, for weeks it uses the 24 address but last friday it changed from 24 to 31.. now the eth0 is disconnected... it looks strange to me because there was sort of an answer....

Jgrboer
Posts: 6
Joined: Mon Apr 27, 2020 4:42 pm

Re: Problem logging in Raspberry PI

Mon Apr 27, 2020 7:58 pm

Normaly the raspberry is connected through WiFi Wich has a fixed ip address, this 24 - 31 address was from the eth0, for weeks it uses the 24 address but last friday it changed from 24 to 31.. now the eth0 is disconnected... it looks strange to me because there was sort of an answer....

User avatar
HawaiianPi
Posts: 5710
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: Problem logging in Raspberry PI

Tue Apr 28, 2020 3:34 am

The IP address might remain the same until the router is rebooted, then all bets are off. On the other hand, if your Pi is not left on all the time, another new device might take that address. That's the nature of DHCP.

If you want it to remain the same, reserve the IP address. However, that will only work if the connection is also the same, in other words, always WiFi (or you could reserve one IP for the Pi's WiFi and another for Ethernet).

I run most of my Pi computers headless, so I have IP reservations in my router for them. That way I know they will always get assigned the same IP, even with a different OS or newly flashed card. No need to mess with OS configuration files or other such nonsense.
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups...and where is that annoying music coming from?

User avatar
FTrevorGowen
Forum Moderator
Forum Moderator
Posts: 5590
Joined: Mon Mar 04, 2013 6:12 pm
Location: Bristol, U.K.
Contact: Website

Re: Problem logging in Raspberry PI

Tue Apr 28, 2020 9:49 am

HawaiianPi wrote:
Tue Apr 28, 2020 3:34 am
...
I run most of my Pi computers headless, so I have IP reservations in my router for them. That way I know they will always get assigned the same IP, even with a different OS or newly flashed card. No need to mess with OS configuration files or other such nonsense.
+1 and I also use reserved IP addresses for other (household members') computers, a habit I got in to when I set up a wired network "backbone" in our previous house, before WiFi became "cheap & cheerful" ;) (There was also a time when an IP provider would only allow one, specified, computer to be connected ie. you had to build/use your own "router" system using, for example, Smoothwall Linux IIRC the name ...)
Trev.
Still running Raspbian Jessie or Stretch on some older Pi's (an A, B1, 2xB2, B+, P2B, 3xP0, P0W, 2xP3A+, P3B+, P3B, B+, and a A+) but Buster on the P4B's. See: https://www.cpmspectrepi.uk/raspberry_pi/raspiidx.htm

Return to “Troubleshooting”