intelligent-agent / Refactor

Linux distro for 3D-printers
https://wiki.iagent.no/wiki/Refactor
GNU Affero General Public License v3.0
28 stars 19 forks source link

SSH access gets disabled automatically #359

Closed eliasbakken closed 1 year ago

eliasbakken commented 1 year ago

How to reproduce: Enable SSH in Reflash, reboot, log in as user debian, shut the board down and boot it again. Observe that SSH is no longer enabled.

eliasbakken commented 1 year ago

I just verified that a reboot also disables ssh access with the same sequence before.

eliasbakken commented 1 year ago

The ssh systemd file reports the following: loaded (8;;file://recore/lib/systemd/system/ssh.service/lib/systemd/system/ssh.service8;;; disabled; vendor preset: enabled) So on first boot, ssh is started, but it is also disabled. It might get disabled by the service armbian-firstrun Here is a part of what it does:

# SSH Keys creation
rm -f /etc/ssh/ssh_host*
read entropy_before </proc/sys/kernel/random/entropy_avail
dpkg-reconfigure openssh-server >/dev/null 2>&1
service sshd restart
read entropy_after </proc/sys/kernel/random/entropy_avail
echo -e "\n### [firstrun] Recreated SSH keys (entropy: ${entropy_before} ${entropy_after})" >>${Log}
eliasbakken commented 1 year ago

This is a Reflash issue.