OpenSSH with Yocto for the LS1021A TWR Key Problem

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

OpenSSH with Yocto for the LS1021A TWR Key Problem

902 Views
stuartrubin
Contributor III

I am having trouble building and running OpenSSH with Yocto for the LS1021A TWR board. The bitbake process seems to run fine, and the board boots. When the OpenSSH initialization starts and the key is generated, the key file cannot be written.

Starting OpenBSD Secure Shell server: sshd generating ssh RSA key... EXT2-fs (ram0): error: read_inode_bitmap: Cannot read inode bitmap - block_group = 34, inode_bitmap = 278530 Saving key "/etc/ssh/ssh_host_rsa_key" failed: Input/output error

It seems that /etc/ssh is mounted as read-only. For example:

root@ls1021atwr:/etc/ssh# touch file.txt
EXT2-fs (ram0): error: read_inode_bitmap: Cannot read inode bitmap - block_group = 34, inode_bitmap = 278530
touch: file.txt: Input/output error

I've tried adding OpsnSSH In my recipe a few different ways:

IMAGE_INSTALL += "packagegroup-core-ssh-openssh"

--OR--

CORE_IMAGE_EXTRA_INSTALL += " openssh"

CORE_IMAGE_EXTRA_INSTALL += " openssh-sftp"

CORE_IMAGE_EXTRA_INSTALL += " openssh-sftp-server"

Any ideas on how to get the folder writeable? Any workaround?

Thanks!

0 Kudos
1 Reply

443 Views
yipingwang
NXP TechSupport
NXP TechSupport

Hello Stuart Rubin,

I checked SDK 2.0 images on LS1021ATWR, there is no problem to create files in /etc/ssh folder.

Please check whether your Linux Kernel boot parameters is correct, please refer to the following.

root=/dev/ram rw console=ttyS0,115200 ramdisk_size=1000000


Have a great day,
TIC

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos