0

I've been working through these two tutorials, in the hopes of setting up a Raspberry Pi to run Owncloud and Resilio Sync in tandem. First, I installed Owncloud and gave it access to a mounted external HDD as recommended in the guide, and it works, but trying to "merge" privileges for the external HDD so that both it and Sync have read/write access to the directory has proven frustrating (i.e. it doesn't work on Sync's end).

Sync is owned by the "pi" user. Owncloud is owned by the "www-data" user. I tried chown-ing Sync to run as "www-data" but that had no positive effect. Here's my current fstab entry:

UUID=[UUID HERE] /mnt/ownclouddrive auto nofail,uid=33,gid=33,umask=0027,dmask=0027,noatime 0 0

Also, it appears I need to fstab the drive in order for Owncloud to work.

What am I overlooking? I'm a novice to Linux, so any help is appreciated. Thank you!

1
  • It's weird that the guide you linked to only has instructions for using an NTFS formatted external drive. It would be better to use a drive formatted with a Linux native filesystem, such as ext4 or xfs (both of which have case-insensitivity options that might be useful if storing files for MS Windows clients), that automatically supports Linux user and group ownership and permissions. It would also be faster because ext4/xfs/etc would be running in kernel space, while ntfs-3g runs in user space as a FUSE module. Commented Feb 28, 2022 at 0:41

1 Answer 1

1

Change the fstab to ...gid=www-data,umask=0007,dmask=0007... to allow group access to the drive. Read man umask.

Then, add user pi to the www-data group: sudo adduser pi www-data. Read man adduser.

Logout and login - groups are set up at login time.

2
  • That did the trick! Thank you waltinator. Commented Feb 27, 2022 at 6:03
  • @qlabsmusic Please click the checkmark to "accept" my answer, if it solved your problem, and might help others. Commented Feb 27, 2022 at 14:03

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.