cancel
Showing results for 
Search instead for 
Did you mean: 

Can't SSH into st-example-image-qt image.

BSunw.1
Associate III

I have successfully built the st-example-image-qt using Bitbake (see first image) and have successfully downloaded it to the stm32mp157c-dk2 board (see second image). But now I cannot SSH into the board. When I use the ip add show eth0 command I can only see the inet6 ip and not inet. Then I tried to follow this article, https://wiki.st.com/stm32mpu/wiki/How_to_perform_ssh_connection, but there is no /etc/init.d/sshd directory and I can't use apt install as I have no wifi connection on the board. Anyone else have this issue with the qt example image?

EDIT 1: I also tried this article with no luck although now I do see an inet IP address when I manually set it with the ifconfig command I still can't SSH in, https://wiki.st.com/stm32mpu/wiki/How_to_configure_ethernet_interface. More information, I am using an Ubuntu virtual box as my host computer and using a usb 3 ethernet to USB adapter so not sure if that has anything to do with it? I did try this on a native linux computer with an ethernet port and got the same results.

EDIT 2: I got the ssh to work if I plug the board directly into my router but still won't work with ethernet plugged from board directly to computer.

2 REPLIES 2
Bernard PUEL
ST Employee

Hello,

Recently ssh server moved from openssh to dropbear, so that's why the wiki article is not updated (sorry for that). It will be done shortly but it won't change your issue.

I did make a trial on my side on ubuntu 18.4 with a home gateway (both DK2 and host PC connected to the gateway) and it works fine:

stmcust@stmcust-HP-EliteBook-840-G5:~/v1.2.0/$ ssh root@192.168.1.78

The authenticity of host '192.168.1.78 (192.168.1.78)' can't be established.

RSA key fingerprint is SHA256:Jm+8xJJgh3RlrtX/t32/+i+nuZQlYIPsqh0+9NALkgM.

Are you sure you want to continue connecting (yes/no)? yes

Warning: Permanently added '192.168.1.78' (RSA) to the list of known hosts.

root@stm32mp1:~# systemctl | grep drop

dropbear@3-192.168.1.78:22-192.168.1.71:43846.service loaded active running SSH Per-Connection Server (192.168.1.71:43846)

dropbearkey.service loaded active exited SSH Key Generation

system-dropbear.slice loaded active active system-dropbear.slice

dropbear.socket loaded active listening dropbear.socket

root@stm32mp1:~#

As you can see a systemd service is started at every ssh connection to the dropbear server, you should see it.

Then if the static connection is not working:

  • This can be due to VM
  • This can be due to systemd that is managing network interface by default (see networkd.service). I did not try but you may stop systemd network service and configure statically your network interface or configure your interface with systemd (a wiki page is under review on that topic).

Bernard PUEL
ST Employee
  • systemd network config:

Board $> ls /lib/systemd/network

50-wired.network 52-static.network.static 80-container-vz.network

50-wired.network.static 80-container-host0.network 99-default.link

51-wireless.network.sample 80-container-ve.network

  • example of static config file:

52-static.network.static:

[Match]
 
Name=eth0
 
 
 
[Network]
 
DNS=192.168.72.254
 
Address=192.168.72.2/24
 
Gateway=192.168.72.254