[ Syncthing ] Continuous Replication/Cluster Sync

Discussion on apps, protocols, APIs, specifications, and more. You are welcome to join us as a TOS app developer!
User avatar
EgorA
Posts: 9
Joined: 18 Apr 2022, 22:18

Re: [ Syncthing ][ 1.20.1.0 ]Continuous Replication/Cluster Sync

Post by EgorA »

outkastm wrote: 10 May 2022, 01:39 up to 1.20.1.0
Do port it to TOS5 please!
User avatar
outkastm
Posts: 1185
Joined: 29 Dec 2020, 23:52

Re: [ Syncthing ][ 1.20.1.0 ]Continuous Replication/Cluster Sync

Post by outkastm »

waiting TOS5 app packaging tool
User avatar
scout71
Posts: 50
Joined: 02 Oct 2021, 07:26
Italy

Re: [ Syncthing ][ 1.20.1.0 ]Continuous Replication/Cluster Sync

Post by scout71 »

outkastm wrote: 13 May 2022, 06:01 waiting TOS5 app packaging tool
In the meantime, thanks for all the work! Then, I would also like to evaluate this app in comparison with Resilio. I have read good opinions on both of them. I hope this too will arrive soon. Have you tried them? Which one do you suggest? Thanks again
User avatar
outkastm
Posts: 1185
Joined: 29 Dec 2020, 23:52

Re: [ Syncthing ][ 1.20.3.0 ]Continuous Replication/Cluster Sync

Post by outkastm »

up to 1.20.3.0 and added TOS5 version
User avatar
scout71
Posts: 50
Joined: 02 Oct 2021, 07:26
Italy

Re: [ Syncthing ][ 1.20.3.0 ]Continuous Replication/Cluster Sync

Post by scout71 »

A thousand thanks! I immediately tried it. But I ask one thing, what path should I put for the shared folder on the TNAS? SyncThing always says "permission denied"
User avatar
outkastm
Posts: 1185
Joined: 29 Dec 2020, 23:52

Re: [ Syncthing ][ 1.20.3.0 ]Continuous Replication/Cluster Sync

Post by outkastm »

Folder permissions are very strict in TOS5

The app is running as user syncthing with group syncthing. Is recommended to not run as superuser.
By default, syncthing user have read/write access only to the default path /Volume1/Sync

So for the newly added folders in Syncthing app you have to choose /Volume1/Sync/NewFolder1; /Volume1/Sync/NewFolder2; etc

If you want to use any other folder from /Volume1 you have to:

- uninstall existing SyncThing app
- download again the file and install it
- Create a new group in TOS5 (as example SyncThingShare)
- From TOS5 give to group SyncThingShare read/write access to desired folder
- connect with ssh and add the user syncthing to group SyncThingShare

Code: Select all

usermod -aG SyncThingShare "syncthing"

- now you should be able to add the folder in SyncThing app
User avatar
scout71
Posts: 50
Joined: 02 Oct 2021, 07:26
Italy

Re: [ Syncthing ][ 1.20.3.0 ]Continuous Replication/Cluster Sync

Post by scout71 »

outkastm wrote: 27 Jul 2022, 07:05 Folder permissions are very strict in TOS5

The app is running as user syncthing with group syncthing. Is recommended to not run as superuser.
By default, syncthing user have read/write access only to the default path /Volume1/Sync

So for the newly added folders in Syncthing app you have to choose /Volume1/Sync/NewFolder1; /Volume1/Sync/NewFolder2; etc

If you want to use any other folder from /Volume1 you have to:

- uninstall existing SyncThing app
- download again the file and install it
- Create a new group in TOS5 (as example SyncThingShare)
- From TOS5 give to group SyncThingShare read/write access to desired folder
- connect with ssh and add the user syncthing to group SyncThingShare

Code: Select all

usermod -aG SyncThingShare "syncthing"

- now you should be able to add the folder in SyncThing app
I tried to follow the procedures you said. In fact, from SSH I found the existence of the user "syncthing" but he is not mentioned among the users in the control panel and in the group created for Syncthing (the group is visible instead). I then tried to create a folder in the default "Sync" directory and it actually works but I don't see it from the control panel among the existing folders (I only find it via SSH). Unfortunately following your steps still doesn't work, I'll try again tomorrow but I really followed the instructions step by step. :roll: :cry:
User avatar
scout71
Posts: 50
Joined: 02 Oct 2021, 07:26
Italy

Re: [ Syncthing ][ 1.20.3.0 ]Continuous Replication/Cluster Sync

Post by scout71 »

Fortunately after the last update I see the "Sync" folder so everything is fine, I just need to save the material there. Thanks again!
User avatar
outkastm
Posts: 1185
Joined: 29 Dec 2020, 23:52

Re: [ Syncthing ][ 1.20.3.0 ]Continuous Replication/Cluster Sync

Post by outkastm »

Only the users and groups created from TOS are visible in the interface (not the ones created from ssh)

I've changed a bit the behaviour of the app to require no connection in ssh
  • Access to /Volume1/Sync
If you don't see the Sync folder in TOS5 shared folders, you just need to create it.
Syncthing app has full access by default to this path /Volume1/Sync

Image
  • Access to any other folder
1) Syncthing app is running as user syncthing which is by default part of the group allusers (you won't see this in TOS only SSH)

To give Syncthing app access to any other folder, edit that share location with read/write permission for group allusers

2) If you you don't want to give acces to allusers for that folder, just create another group called exactly syncthingapp

After Syncthing app is restarted, the user syncthing is made automatically part of the new group syncthingapp

Image

Code: Select all

uid=1014(syncthing) gid=4(allusers) groups=4(allusers),7(syncthingapp)
Give read/write access for any needed folder to group syncthingapp, to make it accessible by Syncthing app

I hope now is more simple
User avatar
scout71
Posts: 50
Joined: 02 Oct 2021, 07:26
Italy

Re: [ Syncthing ][ 1.20.3.0 ]Continuous Replication/Cluster Sync

Post by scout71 »

Thank you so much for the time you dedicate to us
Post Reply