Hi all!
Today I had successfully installed nextcloud on a new jail, following this tutorial
https://forums.freenas.org/index.php?threads/how-to-owncloud-using-nginx-php-fpm-and-mysql.17786/
The problem now is a little tricky.
I have some folders that are based on CIFS windows permissions. There is a folder for each user, and only that user can access it.
Inside each folder, the owner is UserX:UserX. So there is a group with the same name of the users.
This works great becouse in that way each user can access to his own directory, and cannot access to others.
So, I have mounted that folders using JAIL mount from the freenas interface. Then I have created in the jail a group with same ID and GroupName of freenas, and I have added these groups on the jail to both www and root user. Basically what I have do is the solution 3 linked here: https://forums.freenas.org/index.ph...plugins-write-permissions-to-your-data.27273/
From windows I see that the permissions on the files are correct (both User1 and the group called User1 has all permissions on each file/folder that is inside the private/User1 folder).
The problem is that if I write from the jail ls User1\ I don't see any file/folder. So, of course also adding these folders on the nextcloud external storage results in a problem.
I think that I miss a stupid thing, but I cannot find how to make that working... Any idea?
PS: I don't want to chage owners of the files/folder.
PPS: I have also rebooted the jail thinking that perhaps was a problem with some cached data of the http server or something like that.
PPPS: I have also tried using samba configuration on nextcloud extenal storage plugin, but in that way also didn't worked
Today I had successfully installed nextcloud on a new jail, following this tutorial
https://forums.freenas.org/index.php?threads/how-to-owncloud-using-nginx-php-fpm-and-mysql.17786/
The problem now is a little tricky.
I have some folders that are based on CIFS windows permissions. There is a folder for each user, and only that user can access it.
root@nextcloud:/mnt/private # ls -la
total 3
drwxrwxr-x+ 4 root wheel 5 Sep 8 21:58 .
drwxr-xr-x 5 root wheel 5 Sep 9 14:46 ..
-rwxrwxr-x+ 1 root wheel 0 Sep 5 13:53 .windows
drwxrwxr-x+ 2 root User1 2 Sep 8 21:58 User1
drwxrwxr-x+ 2 root User2 2 Sep 9 14:52 User2
Inside each folder, the owner is UserX:UserX. So there is a group with the same name of the users.
This works great becouse in that way each user can access to his own directory, and cannot access to others.
So, I have mounted that folders using JAIL mount from the freenas interface. Then I have created in the jail a group with same ID and GroupName of freenas, and I have added these groups on the jail to both www and root user. Basically what I have do is the solution 3 linked here: https://forums.freenas.org/index.ph...plugins-write-permissions-to-your-data.27273/
JAIL:
root@nextcloud:/mnt/private # cat /etc/group | grep -i User1
User1:*:1003:www,root
FREENAS:
[root@freenas] ~# cat /etc/group | grep -i User1
User1:*:1003:User1
From windows I see that the permissions on the files are correct (both User1 and the group called User1 has all permissions on each file/folder that is inside the private/User1 folder).
The problem is that if I write from the jail ls User1\ I don't see any file/folder. So, of course also adding these folders on the nextcloud external storage results in a problem.
root@nextcloud:/mnt/private # ls -la User1/
total 1
drwxrwxr-x+ 2 root User1 2 Sep 9 14:52 .
drwxrwxr-x+ 4 root wheel 5 Sep 8 21:58 ..
I think that I miss a stupid thing, but I cannot find how to make that working... Any idea?
JAIL
[root@freenas] ~# getfacl /mnt/main_volume/private/User1/
# file: /mnt/main_volume/private/User1/
# owner: User1
# group: User1
owner@:rwxpDdaARWcCo-:fd-----:allow
group@:rwxpDdaARWcCo-:fd-----:allow
FREENAS
root@nextcloud:/mnt/private # getfacl User1/
# file: User1/
# owner: root
# group: User1
owner@:rwxpDdaARWcCos:fd----I:allow
group@:rwxpDdaARWcCos:fd----I:allow
everyone@:r-x---a-R-c---:fd----I:allow
PS: I don't want to chage owners of the files/folder.
PPS: I have also rebooted the jail thinking that perhaps was a problem with some cached data of the http server or something like that.
PPPS: I have also tried using samba configuration on nextcloud extenal storage plugin, but in that way also didn't worked
Last edited: