I have a NextcloudPi with LUKS encrypted disks for data and backup.
This means that after a reboot, or when starting the NextcloudPi, I have to login into the NextcloudPi to unlock the encrypted disks and to manually start apache after making the disks available. I normally login over ssh to unlock the LUKS disks.
When I'm trying to login, I do not get the prompt after providing username and password.
The cause seems that the Message of the day (motd) script looks for the /var/run/.ncp-latest-version file, to compose the motd. However, after a reboot this file does not exists directly after a booting the NextcloudPi. I did not figure out exactly when the file is created. Note that on my system apache serving Nextcloud is not started at boot (because of the needed LUKS disks).
Script /etc/update-motd.d/20updates calls /usr/local/bin/ncp-check-updates which looks for /var/run/.ncp-latest-version. I'm not sure if this is the root of the issue though.
After providing the username and password, and when the terminal "hangs", I can press Ctrl-c on a physical console and I do get the bash prompt, and this warning:
ls: cannot access '/var/run/.ncp-latest-version': No such file or directory
When I use this prompt to unlock the disks and start apache, the /var/run/.ncp-latest-version file appears after some time, and all works fine, and I can also ssh into the NextcloudPi again. I do not know what triggers the creation of the /var/run/.ncp-latest-version file creation.
Maybe the motd scripts should be able to handle the missing of the /var/run/.ncp-latest-version, or the .ncp-latest-version file could be in a location that is not cleaned on a reboot.
This issue is related to issue #2132.
System information
NextcloudPi diagnostics
NextcloudPi version v1.58.0
NextcloudPi image NextCloudPi_RaspberryPi_v1.51.3.img
OS Debian GNU/Linux 12 (bookworm). 6.1.21-v8+ (aarch64)
automount yes
USB devices sda
datadir /media/nextcloudpi_data/ncdata/data
data in SD no
data filesystem btrfs
data disk usage 2.8T/5.3T
rootfs usage 9.4G/59G
swapfile /var/swap
dbdir /media/USBdrive/ncdatabase
Nextcloud check ok
Nextcloud version 33.0.7.1
HTTPD service up
PHP service up
MariaDB service up
Redis service up
HPB service up
Postfix service up
Internet check ok
Public IPv4 ***REMOVED SENSITIVE VALUE***
Public IPv6 ***REMOVED SENSITIVE VALUE***
Port 80 open
Port 443 open
IP ***REMOVED SENSITIVE VALUE***
Gateway ***REMOVED SENSITIVE VALUE***
Interface eth0
Certificates ***REMOVED SENSITIVE VALUE***
NAT loopback no
Uptime 30min
I have a NextcloudPi with LUKS encrypted disks for data and backup.
This means that after a reboot, or when starting the NextcloudPi, I have to login into the NextcloudPi to unlock the encrypted disks and to manually start apache after making the disks available. I normally login over ssh to unlock the LUKS disks.
When I'm trying to login, I do not get the prompt after providing username and password.
The cause seems that the Message of the day (motd) script looks for the
/var/run/.ncp-latest-versionfile, to compose the motd. However, after a reboot this file does not exists directly after a booting the NextcloudPi. I did not figure out exactly when the file is created. Note that on my system apache serving Nextcloud is not started at boot (because of the needed LUKS disks).Script
/etc/update-motd.d/20updatescalls/usr/local/bin/ncp-check-updateswhich looks for/var/run/.ncp-latest-version. I'm not sure if this is the root of the issue though.After providing the username and password, and when the terminal "hangs", I can press Ctrl-c on a physical console and I do get the bash prompt, and this warning:
ls: cannot access '/var/run/.ncp-latest-version': No such file or directoryWhen I use this prompt to unlock the disks and start apache, the
/var/run/.ncp-latest-versionfile appears after some time, and all works fine, and I can also ssh into the NextcloudPi again. I do not know what triggers the creation of the/var/run/.ncp-latest-versionfile creation.Maybe the motd scripts should be able to handle the missing of the
/var/run/.ncp-latest-version, or the.ncp-latest-versionfile could be in a location that is not cleaned on a reboot.This issue is related to issue #2132.
System information
NextcloudPi diagnostics