nettings / medianet

A distribution overlay for Raspbian and similar systems to create a JACK-based embedded system for audio processing and streaming. Contract work for [mn] medianet. https://www.medianet-home.de
Other
11 stars 2 forks source link

mn_copy_image complains it can't write host key while disks need to be read-only #120

Closed nettings closed 9 months ago

nettings commented 1 year ago
medianet@mn-basic:/medianet/sbin/50-run_on_pi $ sudo ../mn_copy_image -u medianet -t /local/images -H mn-tarot

Copying image from running system to medianet@mn-tarot:/local/images/2023-06-03-medianet-aarch64-pi4.img.
Checking if boot partition is mounted read-only... succeeded.
Checking if root partition is mounted read-only... succeeded.
Determining used space (= end of third partition) on /dev/mmcblk0... 6442450943 bytes (12288 blocks of 524288 bytes)
Transferring data to medianet@mn-tarot:/local/images/2023-06-03-medianet-aarch64-pi4.img...
The authenticity of host 'mn-tarot (2a02:a463:7bec:1:9b1f:e252:363:172d)' can't be established.
ECDSA key fingerprint is SHA256:G4zz/n67fL8KwKQDSyFrY/UYvCmLZl8rYR/7Uif1A18.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Could not create directory '/root/.ssh' (Read-only file system).
Failed to add the host to the list of known hosts (/root/.ssh/known_hosts).

We should suppress that error message, since the disks need to be read-only at this point to guarantee an uncorrupted image.

nettings commented 1 year ago

A common workaround seems to be -oUserKnownHostsFile=/dev/null, while -o StrictHostKeyChecking=no is also set.