TASK ERROR: cannot continue garbage-collection safely, permission denied on: "/run/user/0"

Afox

Renowned Member
Dec 18, 2014
257
14
83
When trying to run the GC on my PBS I get the following:
TASK ERROR: cannot continue garbage-collection safely, permission denied on: "/run/user/0"
I also had this one few times:
TASK ERROR: cannot continue garbage-collection safely, permission denied on: "/run/chrony"
I searched the forum and found this thread which suggested to not put the datastore in the root directory what I then did (moved it to /datastore). Nevertheless the problem persists.

The root filesystem is ext4, versions:

Code:
proxmox-backup-manager versions --verbose
proxmox-backup                3.0.0        running kernel: 6.2.16-4-pve
proxmox-backup-server         3.0.1-1      running version: 3.0.1
pve-kernel-6.2                8.0.3
pve-kernel-5.15               7.4-4
pve-kernel-6.2.16-4-pve       6.2.16-5
pve-kernel-6.2.16-3-pve       6.2.16-3
pve-kernel-5.15.108-1-pve     5.15.108-1
pve-kernel-5.15.102-1-pve     5.15.102-1
ifupdown2                     3.2.0-1+pmx3
libjs-extjs                   7.0.0-3
proxmox-backup-docs           3.0.1-1
proxmox-backup-client         3.0.1-1
proxmox-mail-forward          0.2.0
proxmox-mini-journalreader    1.4.0
proxmox-offline-mirror-helper unknown
proxmox-widget-toolkit        4.0.6
pve-xtermjs                   4.16.0-3
smartmontools                 7.3-pve1
zfsutils-linux                2.1.12-pve1

Output of ls -al /

Code:
ls -al /
total 76
drwxr-xr-x  20 backup backup  4096 Jul 26 06:06 .
drwxr-xr-x  20 backup backup  4096 Jul 26 06:06 ..
lrwxrwxrwx   1 root   root       7 Mar 29 09:20 bin -> usr/bin
drwxr-xr-x   5 root   root    4096 Jul 17 20:21 boot
drwxr-xr-x   3 backup backup  4096 Jul 26 06:06 datastore
drwxr-xr-x  20 root   root    3980 Jul 26 05:55 dev
drwxr-xr-x  84 root   root    4096 Jul 26 06:04 etc
drwxr-xr-x   2 root   root    4096 Dec  9  2022 home
lrwxrwxrwx   1 root   root       7 Mar 29 09:20 lib -> usr/lib
lrwxrwxrwx   1 root   root       9 Mar 29 09:20 lib32 -> usr/lib32
lrwxrwxrwx   1 root   root       9 Mar 29 09:20 lib64 -> usr/lib64
lrwxrwxrwx   1 root   root      10 Mar 29 09:20 libx32 -> usr/libx32
-rw-r--r--   1 backup backup     0 Jun  4 21:09 .lock
drwx------   2 root   root   16384 Jun  4 19:00 lost+found
drwxr-xr-x   2 root   root    4096 Mar 29 09:20 media
drwxr-xr-x   2 root   root    4096 Jun  4 19:02 mnt
drwxr-xr-x   3 backup backup  4096 Jun  4 21:21 ns
drwxr-xr-x   2 root   root    4096 Mar 29 09:20 opt
dr-xr-xr-x 209 root   root       0 Jul 26 05:55 proc
drwx------   4 root   root    4096 Jun 29 19:34 root
drwxr-xr-x  22 root   root     740 Jul 26 06:23 run
lrwxrwxrwx   1 root   root       8 Mar 29 09:20 sbin -> usr/sbin
drwxr-xr-x   2 root   root    4096 Mar 29 09:20 srv
dr-xr-xr-x  13 root   root       0 Jul 26 05:55 sys
drwxrwxrwt   4 root   root    4096 Jul 26 05:55 tmp
drwxr-xr-x  14 root   root    4096 Mar 29 09:20 usr
drwxr-xr-x  11 root   root    4096 Mar 29 09:20 var
 
Turns out a reboot is needed to make the new datastore being used. Also the linked command doesn´t seem to be sufficient anymore. If you for example have a namespace you at least have to also move the ns folder and maybe the .lock file as well.

I also want to warn anyone to run the GC without all necessary files being present as it will mark all chunks as unused and remove them.