rtkbase icon indicating copy to clipboard operation
rtkbase copied to clipboard

Filesystem changes disappear on reboot

Open lansalot opened this issue 1 year ago • 1 comments

Afternoon all

I wanted to add an extra service unit manually to push output to a third caster, so I created a shell script in /home/basegnss, and a unit file in /etc/system/system, enabled it, started, all good.

On reboot, my script and the service unit files disappeared. I've been trying to work out what makes this happen, but to no avail as yet. Weirdly, there was a nohup.out that was left over from my testing that also re-appears in /home/basegnss, so how that made it in there to persist and reappear, not sure either.

basegnss@basegnss:~ $ df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/root        29G  4.6G   23G  17% /
devtmpfs        333M     0  333M   0% /dev
tmpfs           461M     0  461M   0% /dev/shm
tmpfs           185M  1.1M  184M   1% /run
tmpfs           5.0M  4.0K  5.0M   1% /run/lock
/dev/mmcblk0p1  250M   51M  199M  21% /boot
tmpfs            93M     0   93M   0% /run/user/1000
basegnss@basegnss:/etc/systemd/system $ cat /etc/fstab
proc            /proc           proc    defaults          0       0
PARTUUID=c3d522c2-01  /boot           vfat    defaults          0       2
PARTUUID=c3d522c2-02  /               ext4    defaults,noatime  0       1
# a swapfile is not a swap partition, no line here
#   use  dphys-swapfile swap[on|off]  for that

I was looking into the likes of ProtectHome, but from my understanding, that won't affect /etc/systemd/system or /home/basegnss?

basegnss@basegnss:/etc/systemd/system $ find . -exec grep -Hi protect {} \; 2>/dev/null
./dbus-org.bluez.service:ProtectHome=true
./dbus-org.bluez.service:ProtectSystem=full
./multi-user.target.wants/rsync.service:# system protection (which makes /usr, /boot, & /etc read-only) and hide
./multi-user.target.wants/rsync.service:ProtectSystem=full
./multi-user.target.wants/rsync.service:#ProtectHome=on|off|read-only
./multi-user.target.wants/ModemManager.service:ProtectSystem=true
./multi-user.target.wants/ModemManager.service:ProtectHome=true
./multi-user.target.wants/chrony.service:ProtectHome=yes
./multi-user.target.wants/chrony.service:ProtectSystem=full
./multi-user.target.wants/chrony.service:ProtectControlGroups=yes
./multi-user.target.wants/chrony.service:ProtectKernelModules=yes
./multi-user.target.wants/chrony.service:ProtectKernelTunables=yes
./dbus-org.freedesktop.ModemManager1.service:ProtectSystem=true
./dbus-org.freedesktop.ModemManager1.service:ProtectHome=true
./bluetooth.target.wants/bluetooth.service:ProtectHome=true
./bluetooth.target.wants/bluetooth.service:ProtectSystem=full
./chronyd.service:ProtectHome=yes
./chronyd.service:ProtectSystem=full
./chronyd.service:ProtectControlGroups=yes
./chronyd.service:ProtectKernelModules=yes
./chronyd.service:ProtectKernelTunables=yes
./chrony.service:ProtectHome=yes
./chrony.service:ProtectSystem=full
./chrony.service:ProtectControlGroups=yes
./chrony.service:ProtectKernelModules=yes
./chrony.service:ProtectKernelTunables=yes
./default.target.wants/e2scrub_reap.service:ProtectSystem=true
./default.target.wants/e2scrub_reap.service:ProtectHome=read-only

Any help or advice here would be appreciated - and a +1 for the feature request to add multiple bases in the GUI ;)

Thanks!

lansalot avatar Feb 07 '24 11:02 lansalot

Hi! I don't see any reason for the behavior you've described.

Stefal avatar Feb 08 '24 09:02 Stefal