dreamcatcher
Posts: 11
Joined: Fri Jun 12, 2020 10:57 am

can't connect raspberry by ssh

Fri Jun 12, 2020 11:07 am

I used the etcher to install ubuntu server 20.04 64bit. when the raspberry start i can't connect by ssh.
I already tried touch a ssh file in system-boot partion.
And I also modify the network-config and setting the wifi config, but only eth0 can get ip , didn't get ip from wifi!


The authenticity of host '192.168.0.102 (192.168.0.102)' can't be established.
ECDSA key fingerprint is SHA256:qjqAHHxVjwIVATSMdakEIPglyQleU2kzA4hx/mhm9OI.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added '192.168.0.102' (ECDSA) to the list of known hosts.
ubuntu@192.168.0.102: Permission denied (publickey).

I don't have a monitor, how can i use raspberry.
Thanks.

arif-ali
Posts: 16
Joined: Tue Jun 02, 2020 9:45 pm
Location: Sheffield, UK

Re: can't connect raspberry by ssh

Fri Jun 12, 2020 4:21 pm

Did you follow the instructions here, https://ubuntu.com/tutorials/how-to-ins ... ntu-server

The default username/password is ubuntu/ubuntu, and it will ask you change the password the first time you login
You can also find me on IRC: arif-ali@freenode

Current rpi's:
3 x rpi4 4GB with Ubuntu 20.04 64bit
1 x rpi4 8GB with Raspberry Pi OS (beta FW for booting from SSD)

Linpack result:
14.401 GFlops, https://gitlab.arif-ali.co.uk:8543/snippets/26

dreamcatcher
Posts: 11
Joined: Fri Jun 12, 2020 10:57 am

Re: can't connect raspberry by ssh

Fri Jun 12, 2020 5:01 pm

arif-ali wrote:
Fri Jun 12, 2020 4:21 pm
Did you follow the instructions here, https://ubuntu.com/tutorials/how-to-ins ... ntu-server

The default username/password is ubuntu/ubuntu, and it will ask you change the password the first time you login
yes I followed the guide, i don't have monitor, the guide page said the monior is not necessary.

User avatar
B.Goode
Posts: 10191
Joined: Mon Sep 01, 2014 4:03 pm
Location: UK

Re: can't connect raspberry by ssh

Fri Jun 12, 2020 5:47 pm

Maybe this advice about getting support with your third-party Operating System might be relevant -
First of all, introductions: I'm Dave Jones. Some of you will know me from things like picamera, piwheels, pisense, gpio-zero and so forth (he says, sounding like Troy McClure). Nowadays, I'm also on the Canonical Foundations team, with responsibility for Ubuntu on the Pi which means:
You can blame me for a lot of the things mentioned on this thread!
This is probably the wrong place to discuss a lot of this; there's absolutely no point complaining to the fine folks at the Pi Foundation about Ubuntu. Bug me instead (see below for more information on how to bug Dave)!
As already mentioned by others, https://ubuntuforums.org/ and https://askubuntu.com/ are good places to ask about things like this. In particular, I trawl the "raspberrypi" tag on the latter in spare moments (which are few and far between in the run-up to a release, but will be a bit more plentiful now).
Ref: viewtopic.php?f=131&t=254649&p=1556639& ... l#p1556639

GlowInTheDark
Posts: 594
Joined: Sat Nov 09, 2019 12:14 pm

Re: can't connect raspberry by ssh

Fri Jun 12, 2020 5:55 pm

Maybe this advice about getting support with your third-party Operating System might be relevant -
Yeah, but...

The problem is that the theory underlying the quote from DJ is that these forums are direct communication between help-seekers and RPi honchos/employees/good-folks/whatevers.

It ignores the fact that this is supposed to be (IMHO - obviously some will disagree) a community - i.e., everyone is entitled and expected to jump in with ideas. So, you are not (at least according to this theory) just communicating with (aka, "bugging") the honchos. The idea is that any one of us may have knowledge/experience with Ubuntu and may be able to help any help-seeker.

At least, that's the way I always heard it should be...
GitD's list of things that are not ready for prime time:
1) IPv6
2) 64 bit OSes
3) USB 3
4) Bluetooth

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 13009
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: can't connect raspberry by ssh

Sat Jun 13, 2020 12:40 am

Please stop the infighting... :twisted: :twisted: :twisted:

dreamcatcher
Posts: 11
Joined: Fri Jun 12, 2020 10:57 am

Re: can't connect raspberry by ssh

Sat Jun 13, 2020 12:59 am

thanks all.

Do I have to use a monitor and network cable for the first time with Ubuntu Server 20.04?

Could you give me a recommend about 64Bit OS for raspberry 4b(not beta OS)?

Thanks all.

dreamcatcher
Posts: 11
Joined: Fri Jun 12, 2020 10:57 am

Re: can't connect raspberry by ssh

Sat Jun 13, 2020 1:06 am

B.Goode wrote:
Fri Jun 12, 2020 5:47 pm
Maybe this advice about getting support with your third-party Operating System might be relevant -
First of all, introductions: I'm Dave Jones. Some of you will know me from things like picamera, piwheels, pisense, gpio-zero and so forth (he says, sounding like Troy McClure). Nowadays, I'm also on the Canonical Foundations team, with responsibility for Ubuntu on the Pi which means:
You can blame me for a lot of the things mentioned on this thread!
This is probably the wrong place to discuss a lot of this; there's absolutely no point complaining to the fine folks at the Pi Foundation about Ubuntu. Bug me instead (see below for more information on how to bug Dave)!
As already mentioned by others, https://ubuntuforums.org/ and https://askubuntu.com/ are good places to ask about things like this. In particular, I trawl the "raspberrypi" tag on the latter in spare moments (which are few and far between in the run-up to a release, but will be a bit more plentiful now).
Ref: viewtopic.php?f=131&t=254649&p=1556639& ... l#p1556639
yeah.
thank you. I already asked at https://askubuntu.com/ after you reply.

But I think this forums have most subjects of raspberry than other places.
Raspberry users experiencing problems first Google search then go here to find information or post a subject for help.

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

Re: can't connect raspberry by ssh

Sat Jun 13, 2020 2:47 am

dreamcatcher wrote:
Sat Jun 13, 2020 12:59 am
Do I have to use a monitor and network cable for the first time with Ubuntu Server 20.04?
I setup my 4B4 with Ubuntu server 20.04 headless, but I don't recall if I had to do anything special. I do recall that configuring WiFi on Ubuntu is seriously messed up (the configuration file formatting is super critical), but using Ethernet was simple.

Looking through my notes it seems I only had to create the empty ssh file and use ubuntu for the default username and password.
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?

dreamcatcher
Posts: 11
Joined: Fri Jun 12, 2020 10:57 am

Re: can't connect raspberry by ssh

Sat Jun 13, 2020 5:09 am

HawaiianPi wrote:
Sat Jun 13, 2020 2:47 am
dreamcatcher wrote:
Sat Jun 13, 2020 12:59 am
Do I have to use a monitor and network cable for the first time with Ubuntu Server 20.04?
I setup my 4B4 with Ubuntu server 20.04 headless, but I don't recall if I had to do anything special. I do recall that configuring WiFi on Ubuntu is seriously messed up (the configuration file formatting is super critical), but using Ethernet was simple.

Looking through my notes it seems I only had to create the empty ssh file and use ubuntu for the default username and password.
I also create the empty ssh file, but can't work

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

Re: can't connect raspberry by ssh

Sat Jun 13, 2020 10:17 am

Did your ssh file have an extension? Windows hides common extensions (like .txt) by default, and Raspbian will accept either ssh or ssh.txt, but I'm not sure if Ubuntu will work with ssh.txt. (anyone know for sure)?
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?

dreamcatcher
Posts: 11
Joined: Fri Jun 12, 2020 10:57 am

Re: can't connect raspberry by ssh

Sat Jun 13, 2020 10:21 am

HawaiianPi wrote:
Sat Jun 13, 2020 10:17 am
Did your ssh file have an extension? Windows hides common extensions (like .txt) by default, and Raspbian will accept either ssh or ssh.txt, but I'm not sure if Ubuntu will work with ssh.txt. (anyone know for sure)?
i used

Code: Select all

touch ssh
in mac

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

Re: can't connect raspberry by ssh

Sun Jun 14, 2020 3:56 am

When it didn't work for you, were you connected to your network by Ethernet? If so, then I don't know why it didn't work for you.

Just gave it another try with a fresh card written with Raspberry Pi Imager
  • Ubuntu 20.04 LTS (Raspberry Pi 3/4)
  • 64-bit server OS for arm64 architectures).
Didn't do anything but add the ssh file to the system-boot partition.

Pi 4B4 was completely headless in router room (only power and Ethernet).

Code: Select all

$ ssh ubuntu@192.168.1.14
The authenticity of host '192.168.1.14 (192.168.1.14)' can't be established.
ECDSA key fingerprint is SHA256:73eb5f20ad7913a8bafe39ea2505c34cdaf77e2f.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '192.168.1.14' (ECDSA) to the list of known hosts.
ubuntu@192.168.1.14's password:
You are required to change your password immediately (administrator enforced)
Welcome to Ubuntu 20.04 LTS (GNU/Linux 5.4.0-1008-raspi aarch64)

 * Documentation:  https://help.ubuntu.com
 * Management:     https://landscape.canonical.com
 * Support:        https://ubuntu.com/advantage

 System information disabled due to load higher than 4.0

 * MicroK8s gets a native Windows installer and command-line integration.

     https://ubuntu.com/blog/microk8s-installers-windows-and-macos

54 updates can be installed immediately.
25 of these updates are security updates.
To see these additional updates run: apt list --upgradable



The programs included with the Ubuntu system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by
applicable law.

WARNING: Your password has expired.
You must change your password now and login again!
Changing password for ubuntu.
Current password:
New password:
Retype new password:
passwd: password updated successfully
Connection to 192.168.1.14 closed.
tim@Legion-Y520:~$ ssh ubuntu@192.168.1.14
ubuntu@192.168.1.14's password:
Welcome to Ubuntu 20.04 LTS (GNU/Linux 5.4.0-1008-raspi aarch64)

 * Documentation:  https://help.ubuntu.com
 * Management:     https://landscape.canonical.com
 * Support:        https://ubuntu.com/advantage

  System information as of Sun Jun 14 03:30:36 UTC 2020

  System load:  2.39              Temperature:           37.5 C
  Usage of /:   7.1% of 28.95GB   Processes:             145
  Memory usage: 10%               Users logged in:       0
  Swap usage:   0%                IPv4 address for eth0: 192.168.1.14

 * MicroK8s gets a native Windows installer and command-line integration.

     https://ubuntu.com/blog/microk8s-installers-windows-and-macos

46 updates can be installed immediately.
17 of these updates are security updates.
To see these additional updates run: apt list --upgradable


Last login: Sun Jun 14 03:29:54 2020 from 192.168.1.10
To run a command as administrator (user "root"), use "sudo <command>".
See "man sudo_root" for details.

ubuntu@ubuntu:~$
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?

dreamcatcher
Posts: 11
Joined: Fri Jun 12, 2020 10:57 am

Re: can't connect raspberry by ssh

Sun Jun 14, 2020 12:21 pm

HawaiianPi wrote:
Sun Jun 14, 2020 3:56 am
When it didn't work for you, were you connected to your network by Ethernet? If so, then I don't know why it didn't work for you.

Just gave it another try with a fresh card written with Raspberry Pi Imager
  • Ubuntu 20.04 LTS (Raspberry Pi 3/4)
  • 64-bit server OS for arm64 architectures).
Didn't do anything but add the ssh file to the system-boot partition.

Pi 4B4 was completely headless in router room (only power and Ethernet).

Code: Select all

$ ssh ubuntu@192.168.1.14
The authenticity of host '192.168.1.14 (192.168.1.14)' can't be established.
ECDSA key fingerprint is SHA256:73eb5f20ad7913a8bafe39ea2505c34cdaf77e2f.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '192.168.1.14' (ECDSA) to the list of known hosts.
ubuntu@192.168.1.14's password:
You are required to change your password immediately (administrator enforced)
Welcome to Ubuntu 20.04 LTS (GNU/Linux 5.4.0-1008-raspi aarch64)

 * Documentation:  https://help.ubuntu.com
 * Management:     https://landscape.canonical.com
 * Support:        https://ubuntu.com/advantage

 System information disabled due to load higher than 4.0

 * MicroK8s gets a native Windows installer and command-line integration.

     https://ubuntu.com/blog/microk8s-installers-windows-and-macos

54 updates can be installed immediately.
25 of these updates are security updates.
To see these additional updates run: apt list --upgradable



The programs included with the Ubuntu system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by
applicable law.

WARNING: Your password has expired.
You must change your password now and login again!
Changing password for ubuntu.
Current password:
New password:
Retype new password:
passwd: password updated successfully
Connection to 192.168.1.14 closed.
tim@Legion-Y520:~$ ssh ubuntu@192.168.1.14
ubuntu@192.168.1.14's password:
Welcome to Ubuntu 20.04 LTS (GNU/Linux 5.4.0-1008-raspi aarch64)

 * Documentation:  https://help.ubuntu.com
 * Management:     https://landscape.canonical.com
 * Support:        https://ubuntu.com/advantage

  System information as of Sun Jun 14 03:30:36 UTC 2020

  System load:  2.39              Temperature:           37.5 C
  Usage of /:   7.1% of 28.95GB   Processes:             145
  Memory usage: 10%               Users logged in:       0
  Swap usage:   0%                IPv4 address for eth0: 192.168.1.14

 * MicroK8s gets a native Windows installer and command-line integration.

     https://ubuntu.com/blog/microk8s-installers-windows-and-macos

46 updates can be installed immediately.
17 of these updates are security updates.
To see these additional updates run: apt list --upgradable


Last login: Sun Jun 14 03:29:54 2020 from 192.168.1.10
To run a command as administrator (user "root"), use "sudo <command>".
See "man sudo_root" for details.

ubuntu@ubuntu:~$

Thank you. I tried again.
And Now I can connect by cable but can't use wifi.

I have installed raspi-config, but can not setting wifi .
Snipaste_2020-06-14_20-18-07.png
Snipaste_2020-06-14_20-18-07.png (75.92 KiB) Viewed 288 times

dreamcatcher
Posts: 11
Joined: Fri Jun 12, 2020 10:57 am

Re: can't connect raspberry by ssh

Mon Jun 15, 2020 4:02 pm

as so far raspi-config network tool can't used in ubuntu server 20.04.
I solved the problem by netplan tool

Code: Select all

cp /etc/netplan/50-cloud-init.yaml /etc/netplan/50-cloud-init.yaml.bak
vim /etc/netplan/50-cloud-init.yaml

Code: Select all

network:
    ethernets:
        eth0:
            dhcp4: true
            optional: true
    version: 2
    wifis:
            wlan0:
                    dhcp4: true
                    access-points:
                            "wifi ssid":
                                    password: "password"

Code: Select all

netplan try
netplan apply

Return to “Ubuntu”