Sync Nextcloud using "File System", EACCESS permission denied

A linux beginner here, please don't mind if this is a rookie question,

I am using pi400 arm64 bullseyes. Installed Nextcloud personal cloud uses. Recently I have managed to install arm64 version of Joplin, it went well.

Since I am using this pi400 as Nextcloud server, files are stored locally, I then use "File System" method to sync all the notes, it works perfectly on my other PCs, but when I tried to do the same on pi400, Joplin came with

"Error: Error: Error: EACCES: permission denied, open '/var/www/nextcloud/data/archiechan/files/locks/1_1_0b6678a179984c4da8b6cecf75cebdaa.json'. Path: /var/www/nextcloud/data/archiechan/files/locks/1_1_0b6678a179984c4da8b6cecf75cebdaa.json. Path: /var/www/nextcloud/data/archiechan/files/locks/1_1_0b6678a179984c4da8b6cecf75cebdaa.json"

I was thinking it might be related to the Nextcloud "data" folder's permission I set earlier with "chmod +x 750" permission, I then changed to "chmod +x 777" error remains.

What have I done wrong?

Didn't you get any errors when setting those permissions? Because your chmod command looks like it shouldn't work. chmod +x 777 adds the execute permission the file (or directory) 777, not to the directory you're currently in. You'd want to do something like this: sudo chmod -R 0750 /var/www/nextcloud/data/

That being said: Don't set the permissions to 777 with this command. Using 777 as a permission is generally a really bad idea, and from some quick online searching, it seems that Nextcloud won't work if that last number is set to anything other that 0 and will give you this error:

Your data directory is readable by other users Please change the permissions to 0770 so that the directory cannot be listed by other users.

The fact that you'll get this error tells me that Nextcloud assumes it's the only application that edits those files and probably won't work well if other applications like Joplin edit those files. If you want to try it anyway, you could add the user that runs Joplin to the group that runs Nextcloud, but I wouldn't recommend it. (But I don't use Nextcloud myself, so maybe some else can tell me I wrong).

I would recommend one of these options

  1. See if you can set the sync target on you pi400 to Nextcloud, like you do with your other computers.
  2. Don't use Joplin on the same computer as Nextcloud. Nextcloud is server software, Joplin is client software. It might be possible to run them both on the same computer, but in general you want server software to run on a server, and client software to run on your pc.

Thank for the reply, much appreciated.

All my other 3 computers are using Windows 10, installed Nextcloud client and synced with "File System" on Joplin, without a problem.

Only reason I use Joplin on my pi400 nextcloud server is that I use it as a desktop in my lounge room, it'll be such an easy job if I have the the Joplin installed and write my notes on time.

I could still use "Nextcloud/Webdav" with my "http://my.web.ip/nextcloud/remote.php/Joplin/ to sync the notes, but it went incredibly slow. I guess it had something to do with how I Backup & Restore my nextcloud folder when I move from Buster to Bullseyes. (Sync works, but slow, that's why on PC I choose to sync with "File System")

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.