SSH to Raspberry Pi from ubuntu failed


#1

Hello Guys,
I am trying to ssh into my new raspberry pi 3 from my laptop. I don’t have a hdmi monitor, hence I am trying to setup a headless connection. The led in pi and LAN port are blinking. My laptop (Ubuntu) shows that ‘wireless connection 1’ is established. But when I ssh, it shows ‘connection refused’. I have connected to my raspberry pi to laptop locally, no static ip. I don’t know reason for my problem. Any Idea friends ??

Thanks


#2

Hi,

I am confused. What do you mean ‘locally’ ? How did you find the ip address of the raspberry pi ? Whats the output when you ping the ip address ? Ping and share the output.

ping -c4 xx.xx.xx.xx


#3

Thanks for the replay.

In the ipv4 settings, I have chosen the option ‘Link-Local-Only’ to connect to the pi.

wired

Pinging raspberrypi.local which gives the ip address. But ssh still refuse to connect. Any Idea?


#4

Its seems like every thing with your raspberry pi is working fine except ssh. Since you have a headless setup, I am eager to ask, have you enabled the ssh after preparing bootable sdcard ??


#5

Do I need enable ssh ? From my understanding ssh is enable by default in raspbian Os. Correct me if I am wrong. If I am wrong, please tell me how to enable ssh in raspbian OS?


#6

Of course, you have to enable ssh if you opt for headless setup. SSH is not enabled by default in raspbian OS. In order enable SSH you have to connect sdcard to your pc. Then go to the boot partition, create an empty file and rename it to ssh .Make sure the file should not have any extensions like .txt or .doc. During boot time, the raspbian OS will identify the ssh file and automatically enable ssh.

Regards


#7

Thanks @Programmer
Your trick have done the job for me. I have successfully enabled the ssh and now every thing works very well.

Thank you so much!!