While modifying permissions for an external storage, I’ve modified accidentally the permissions for the Nextcloud folder
rm: cannot remove '/mnt/ncdata/this-is-a-test-file': Permission denied
Configuring Redis as session handler...
Setting php max children...
stat: cannot stat '/mnt/ncdata': Permission denied
The www-data user doesn't seem to have access rights in the datadir.
Most likely are the files located on a drive that does not follow linux permissions.
Please adjust the permissions like mentioned below.
The found permissions are:
(userID:groupID permissions)
but they should be:
33:0 750
(userID:groupID permissions)
now
I’m using Portainer. I cannot access the console of the container ’ nextcloud-aio-nextcloud’ as it’s stuck in a boot loop.
Here are the permission as seen by the host :
~# ls -la /mnt/appdata/nextcloud/
total 56
drwxr-s---+ 9 www-data root 4096 Mar 23 11:18 .
drwxr-x--- 4 root root 4096 Mar 21 10:38 ..
-rwxr-x---+ 1 www-data root 542 Mar 2 10:23 .htaccess
-rwxr-x---+ 1 www-data root 0 Mar 2 10:23 .ocdata
drwxr-s---+ 6 www-data root 76 Aug 27 2022 admin
drwxr-s---+ 14 www-data root 4096 Dec 31 11:56 appdata_ocpxb13p7l9l
-rwxr-x---+ 1 www-data root 0 Aug 19 2022 audit.log
drwxr-s---+ 7 www-data root 91 Dec 10 19:28 christelle
drwxr-s---+ 2 www-data root 27 Mar 2 10:23 files_external
-rwxr-x---+ 1 www-data root 0 Mar 23 10:44 fingerprint.update
-rwxr-x---+ 1 www-data root 0 Aug 21 2022 flow.log
drwxr-s---+ 2 www-data root 6 Aug 19 2022 gpxpod
-rwxr-x---+ 1 www-data root 0 Mar 2 10:23 index.html
-rwxr-x---+ 1 www-data root 0 Aug 19 2022 nextcloud.log
-rwxr-x---+ 1 www-data root 0 Mar 23 10:44 skip.update
drwxr-s---+ 7 www-data root 91 Aug 20 2022 sylvain
drwxr-s---+ 3 www-data root 4096 Mar 16 14:03 tmp
It’s the folder specified in my docker compose :
NEXTCLOUD_DATADIR=/mnt/appdata/nextcloud
Here what I’ve tried as it’s showed in the log , as root on the host:
The result is the same after the command and a restart.
I’ve got a recent backup, do you think it would solve this problem if I clear /mnt/appdata/nextcloud/ and restore my backup ?
I did restart from the AIO interface and even restared the VM. The logs still show this :
rm: cannot remove '/mnt/ncdata/this-is-a-test-file': Permission denied
Configuring Redis as session handler...
Setting php max children...
stat: cannot stat '/mnt/ncdata': Permission denied
The www-data user doesn't seem to have access rights in the datadir.
Most likely are the files located on a drive that does not follow linux permissions.
Please adjust the permissions like mentioned below.
The found permissions are:
(userID:groupID permissions)
but they should be:
33:0 750
(userID:groupID permissions)
I’m new to Proxmox but I had to enable FUSE on this VM to be able to restore my backup which is not on the root drive (another physical drive) but mounted the same way as the datadir.