Ssh into RUT955 "connection refused"

Hi, I cannot connect to my router RUT955 via SSH, I always get a “connection refused” error.
I tried with my phone and with a windows pc in the command line and also with Putty. Always connected to the same WiFi network.

It should be easy…
SSH is enabled, port and IP are correct.
I also tried with “Remote SSH access” ON and OFF.

Firewall all set on “Accept” for the network used.

Can someone help me to troubleshoot this?

hi…

Just simple it…

Do you have telnet or something can do telnet to the ip of the device and use the port 22.

sample…
telnet 192.168.154.5 22
Trying 192.168.154.5…
Connected to 192.168.154.5.
Escape character is ‘^]’.
SSH-2.0-OpenSSH_9.2p1 Raspbian-2+deb12u4
^]
telnet> quit
Connection closed.

Can you share your result?

From a raspberry pi I tried both:

telnet 10.7.3.1 23
Trying 10.7.3.1…
telnet: Unable to connect to remote host: Connection refused

ssh 10.7.3.1 22
ssh: connect to host 10.7.3.1 port 22: Connection refused

Also trying to connect remotely to the WebUI is giving me the error " Connection timed out"

please… use telnet 10.7.3.1 22 (replace the default 23 telnet port with 22 ssh port)

Same error

telnet 10.7.3.1 22
Trying 10.7.3.1…
telnet: Unable to connect to remote host: Connection refused

okay…

It is something with the device…

Can you do CLI, using the web interface of your device?

can you type
netstat -na

look for something listen 22 tcp

Do you need a sample of the screen and the command?

https://wiki.teltonika-networks.com/view/Shell_Commands

yes I can try this. I have access to CLI

Nothing…

so…

No
Proto Recv-Q Send-Q Local Address Foreign Address State

tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN

hum…

Are you up to date? I know… it is a old device…
https://firmware.teltonika-networks.com/7.6.17/RUT9/RUT9_R_00.07.06.17_WEBUI.bin

Please… Just double checking… you did this?

https://wiki.teltonika-networks.com/view/RUT955_Administration

Is this the LAN ip address of the rut955?

Yes and It’s a new configuration. Updated and factory reset few days ago.

I’m not an expert…with that being said, does the firewall have anything to do with SSH?

yes…

Please… type

uci show | grep fire | grep “‘22’”

Result?

no results…

Checking…

Please… give me some minutes…

I did again this and now I have LISTEN on port 22

I did a reboot

I confirm, now SSH is working. I can connect to it.

What happened??

I don’t know… ha ha ha

Maybe an issue… when generating the RSA key?
When you did the reboot… the device fix this!

Well… at least…
You learning some troubleshooting commands…

1 Like

Well…let me download a backup then! :smiley:

Thank you for your help! I really appreciate it!

1 Like

Reason why you could not establish correct SSH to Teltonika is most probably Putty couldn’t negotiate ECDSA key for connection so it automatically closed the connection and refused it, immediately. Putty hold older settings in register and not valid keys - that’s why you could not connect to it.

Teltonika has abandoned RSA keys since 7.4.3 with changelog:
Removed SSH RSA key generation
Added SSH ECDSA key generation

You could re-install fresh installation with Putty, clean register check out if connection would establish. Alternatively, you can use Teraterm to check out if it’s negotating connection properly (most common it will negotiate better than Putty).

Kind Regards,
Robert.