3

I have not used my RPi for a while and forgot the SSH parameters. I am positive the SSH is enabled, it used to work and I have not changed anything. Is there a way to "scan" for RPi SSH from my PC ? Or do I have to physically connect to RPi to find out ?

2
  • 1
    Which OS is your PC running? @Arkadiusz Drabczyk has mentioned a solution for (I think) GNU/Linux but we do not know that that is what you are using. BTW If you have not read through the tour yet it could give you something extra to wave around your Avatar until the end of this years WinterBash as well as helping to introduce you to this corner of the Stack Exchange network. – SlySven Dec 25 '20 at 1:15
  • This is not actually a Pi question as you need a PC program. A search for port scanner will show 100s - please choose one from a reputable company. Make sure it runs LAN side and does not check you router ports! – user115418 Dec 27 '20 at 11:50
1

You can use nmap to check open ports on your RPi:

$ nmap raspberrypi
Starting Nmap 7.80 ( https://nmap.org ) at 2020-12-24 17:24 CET
Nmap scan report for raspberrypi (192.168.1.169)
Host is up (0.0092s latency).
Other addresses for raspberrypi (not scanned): fdd4:6b0c:9a70::616
rDNS record for 192.168.1.169: raspberrypi.lan
Not shown: 999 closed ports
PORT   STATE SERVICE
22/tcp open  ssh

Nmap done: 1 IP address (1 host up) scanned in 2.20 seconds

Use IP address instead of raspberrypi hostname if there is no DNS server in your network. Notice that nmap will show the name of the protocol which it believes is working on the given port so if you set SSH to use another port, say 2222 you will get:

$ nmap raspberrypi
Starting Nmap 7.80 ( https://nmap.org ) at 2020-12-24 17:26 CET
Nmap scan report for raspberrypi (192.168.1.169)
Host is up (0.012s latency).
Other addresses for raspberrypi (not scanned): fdd4:6b0c:9a70::616
rDNS record for 192.168.1.169: raspberrypi.lan
Not shown: 999 closed ports
PORT     STATE SERVICE
2222/tcp open  EtherNetIP-1

Nmap done: 1 IP address (1 host up) scanned in 0.65 seconds
0
1

We don't know what operating system you are using on the PC. But just use your SSH client and connect to the RasPi using username pi and destination name raspberrypi. On a Unix like system it would look

pc ~$ ssh pi@raspberrypi

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.