Ubuntu Version:
24.04 LTSDesktop Environment (if applicable):
xubuntu-desktopProblem Description:
I have installed Ubuntu 24.04 on Raspberry Pi 4 Model b with the file ubuntu-24.04.2-preinstalled-server-arm64+raspi.img.xz
I used preinstalled version because with normal version I had no ethernet network. Now with the preinstalled version I have network but unable to login remotely with SSH.
Relevant System Information:
The board is a Raspberry Pi 4 Model B. 4 GB RAM. 64 GB SD Card, Class 10.
Screenshots or Error Messages:
The verbose output of ssh -v is given below.
gaurab@PiNCPSVPN:~/.ssh$ ssh -v gaurab@192.168.1.170
OpenSSH_8.9p1 Ubuntu-3ubuntu0.13, OpenSSL 3.0.2 15 Mar 2022
debug1: Reading configuration data /home/gaurab/.ssh/config
debug1: /home/gaurab/.ssh/config line 1: Applying options for 192.168.1.170
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: include /etc/ssh/ssh_config.d/*.conf matched no files
debug1: /etc/ssh/ssh_config line 21: Applying options for *
debug1: Connecting to 192.168.1.170 [192.168.1.170] port 22.
debug1: Connection established.
debug1: identity file /home/gaurab/.ssh/id_rsa type 0
debug1: identity file /home/gaurab/.ssh/id_rsa-cert type -1
debug1: identity file /home/gaurab/.ssh/id_ecdsa type -1
debug1: identity file /home/gaurab/.ssh/id_ecdsa-cert type -1
debug1: identity file /home/gaurab/.ssh/id_ecdsa_sk type -1
debug1: identity file /home/gaurab/.ssh/id_ecdsa_sk-cert type -1
debug1: identity file /home/gaurab/.ssh/id_ed25519 type -1
debug1: identity file /home/gaurab/.ssh/id_ed25519-cert type -1
debug1: identity file /home/gaurab/.ssh/id_ed25519_sk type -1
debug1: identity file /home/gaurab/.ssh/id_ed25519_sk-cert type -1
debug1: identity file /home/gaurab/.ssh/id_xmss type -1
debug1: identity file /home/gaurab/.ssh/id_xmss-cert type -1
debug1: identity file /home/gaurab/.ssh/id_dsa type -1
debug1: identity file /home/gaurab/.ssh/id_dsa-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_8.9p1 Ubuntu-3ubuntu0.13
debug1: Remote protocol version 2.0, remote software version OpenSSH_8.9p1 Ubuntu-3ubuntu0.13
debug1: compat_banner: match: OpenSSH_8.9p1 Ubuntu-3ubuntu0.13 pat OpenSSH* compat 0x04000000
debug1: Authenticating to 192.168.1.170:22 as 'gaurab'
debug1: load_hostkeys: fopen /home/gaurab/.ssh/known_hosts: No such file or directory
debug1: load_hostkeys: fopen /home/gaurab/.ssh/known_hosts2: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts2: No such file or directory
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: algorithm: curve25519-sha256
debug1: kex: host key algorithm: ssh-ed25519
debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: SSH2_MSG_KEX_ECDH_REPLY received
debug1: Server host key: ssh-ed25519 SHA256:nhHwSdkEdeoJF0UY6Vx1xNvY/ppkCRodlROPPEX052U
debug1: load_hostkeys: fopen /home/gaurab/.ssh/known_hosts: No such file or directory
debug1: load_hostkeys: fopen /home/gaurab/.ssh/known_hosts2: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts2: No such file or directory
debug1: hostkeys_find_by_key_hostfile: hostkeys file /home/gaurab/.ssh/known_hosts does not exist
debug1: hostkeys_find_by_key_hostfile: hostkeys file /home/gaurab/.ssh/known_hosts2 does not exist
debug1: hostkeys_find_by_key_hostfile: hostkeys file /etc/ssh/ssh_known_hosts does not exist
debug1: hostkeys_find_by_key_hostfile: hostkeys file /etc/ssh/ssh_known_hosts2 does not exist
The authenticity of host '192.168.1.170 (192.168.1.170)' can't be established.
ED25519 key fingerprint is SHA256:nhHwSdkEdeoJF0UY6Vx1xNvY/ppkCRodlROPPEX052U.
This key is not known by any other names
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added '192.168.1.170' (ED25519) to the list of known hosts.
debug1: ssh_packet_send2_wrapped: resetting send seqnr 3
debug1: rekey out after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: ssh_packet_read_poll2: resetting read seqnr 3
debug1: SSH2_MSG_NEWKEYS received
debug1: rekey in after 134217728 blocks
debug1: get_agent_identities: bound agent to hostkey
debug1: get_agent_identities: agent returned 1 keys
debug1: Will attempt key: /home/gaurab/.ssh/id_rsa RSA SHA256:rIc2rkD4ZJvVCfJ8K7trJBTtndfMAEQZs7j1uU3magM agent
debug1: Will attempt key: /home/gaurab/.ssh/id_ecdsa
debug1: Will attempt key: /home/gaurab/.ssh/id_ecdsa_sk
debug1: Will attempt key: /home/gaurab/.ssh/id_ed25519
debug1: Will attempt key: /home/gaurab/.ssh/id_ed25519_sk
debug1: Will attempt key: /home/gaurab/.ssh/id_xmss
debug1: Will attempt key: /home/gaurab/.ssh/id_dsa
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_input_ext_info: server-sig-algs=<ssh-ed25519,sk-ssh-ed25519@openssh.com,ssh-rsa,rsa-sha2-256,rsa-sha2-512,ssh-dss,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,sk-ecdsa-sha2-nistp256@openssh.com,webauthn-sk-ecdsa-sha2-nistp256@openssh.com>
debug1: kex_input_ext_info: publickey-hostbound@openssh.com=<0>
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey
debug1: Next authentication method: publickey
debug1: Offering public key: /home/gaurab/.ssh/id_rsa RSA SHA256:rIc2rkD4ZJvVCfJ8K7trJBTtndfMAEQZs7j1uU3magM agent
debug1: Authentications that can continue: publickey
debug1: Trying private key: /home/gaurab/.ssh/id_ecdsa
debug1: Trying private key: /home/gaurab/.ssh/id_ecdsa_sk
debug1: Trying private key: /home/gaurab/.ssh/id_ed25519
debug1: Trying private key: /home/gaurab/.ssh/id_ed25519_sk
debug1: Trying private key: /home/gaurab/.ssh/id_xmss
debug1: Trying private key: /home/gaurab/.ssh/id_dsa
debug1: No more authentication methods to try.
gaurab@192.168.1.170: Permission denied (publickey).
What I’ve Tried:
I have manually created the ~/.ssh folder and generated the id_rsa and id_rsa.pub files and copied the content of the public key file to authorized_file and have set appropriate permissions, but I’m unable to login. I suspect some configuration files are missing. I have deleted all files I have created because none of them worked.
Now I am looking for advise on possible solution.