Jump to content
linuxserver.io

[Support] Linuxserver.io - Syncthing

165 posts in this topic Last Reply

Recommended Posts

On 5/11/2018 at 7:05 AM, NewKrewLinux said:

I managed to get this to sync with my devices perfectly over LAN using the info I provided below.

 

But I still have one problem. I am unable to directly add a file to a folder via Windows Explorer on my SMB share. That is, I cannot drag and drop a photo into the
//Server/Storage/sync/My_Folder directory to be sent to my other devices. It says "permission denied" in Windows. How do I fix this?

 

 

_________________________________________________________

 

 

Just letting you guys know. I had to swap my interface from "Bridge" to "br0" for this to work properly. Otherwise I also got the issue with it not connecting ever again after 15 mins. Also disabled the relay on all of my devices to first properly work out the LAN issues I was having, because if after a certain time a LAN connection can't be made it'll just move to using a relay and it's sort of hard to work out if it's using the relay (gotta scour the log, or look at the slow speed etc). In addition to that I added the port "22010" to the port mappings before installing the Docker app. Then I changed the listen address in the app to "TCP 22010" because having it set as "default" causes a "connected to myself, not supposed to happen" error every 60 seconds.

 

Then I set the listen address on each of my devices as follows TCP 22011, 22012 etc. and port forwarded these over my router. Not sure if I had to do these 2 steps but I did it anyway.

 

After this I re-enabled the relay so my files can sync when I am away from home. Over LAN I'm able to get just up to 50MB/s transfer speeds (Smartphone is the bottleneck) which is much, much higher than Nextcloud which used to only get me about 10MB/s. Probably due to less overhead and not having to write to a DB etc.

 

Hope this helps someone and thanks for providing this app.

Regarding the 'permission denied' issue. The resolution on this side kicked in after running the /Tools/DockerSafeNewPerms which corrected the directories and their permissions.

 

(update)

Buuuuut. It does seem that anything new/created such as syncing a new folder will inherit the original permissions upon creation and the 'permission denied' kicks in again.

Edited by DirtyHippy
update

Share this post


Link to post

I'm having this same permissions issue.  

 

I just ran DockerSafeNewPerms which fixed all the files created by syncthing, however, I can't modify new files created by syncthing.  Can I somehow pass to the docker to create the files as 777 or some such thing?  

 

Worst off maybe schedule DockerSafeNewPerms to run daily at night... not an ideal solution.  

 

FYI my speed seems fine.  I had to turn off everything but local discovery, and changed my server's ip from dynamic to it's actual ip.  Things go much faster now, although still slower than transferring files in windows explorer.

Share this post


Link to post
9 hours ago, Mysticle31 said:

I'm having this same permissions issue.  

 

I just ran DockerSafeNewPerms which fixed all the files created by syncthing, however, I can't modify new files created by syncthing.  Can I somehow pass to the docker to create the files as 777 or some such thing?  

 

Worst off maybe schedule DockerSafeNewPerms to run daily at night... not an ideal solution.  

 

FYI my speed seems fine.  I had to turn off everything but local discovery, and changed my server's ip from dynamic to it's actual ip.  Things go much faster now, although still slower than transferring files in windows explorer.

Still digging around and since Resilio operates in a similar fashion and we have a thread based on that. There was a mention (thanks to SelfSD) suggesting a variable of UMASK_SET with initially a 0777 but others utilized a 0000 with a good result. Check up on the following responses after that initial post, seemed to work well for them.

 

Share this post


Link to post

This is a syncthing issue, not a docker issue, but thought I'd ask here in case someone has also had this issue:

 

I've just installed Syncthing on 2 unRAID servers. The use-case here is one of the servers is a snapshot backup of the main server.

So My main server (sender) sends all data to the other (receiver) unraid server, with versioning enabled. 

 

On the sender server, i've given syncthing readonly access to the whole array /sync/ -> /mnt/user/

and on the receiver server, I've created a share, and given syncthing read/write access /sync/ -> /mnt/user/syncthing/

 

I've created a folder in the GUI as follows:

source: /sync/MediaServer/Home Videos

send only, no versioning at the moment.

Share with receiver server.

 

This fails because the SOURCE is read-only and syncthing attempts to write to the source folder

I'm not going to give syncthing read/write access to all my data. It should only need read access to read and send the data to the other server.

 

Anyone know how to do this?

 

Syncthing Error message:

Quote

2018-12-26 12:50:14: Saving .stignore: open /sync/MediaServer/Home Videos/.syncthing.tmp.105273867: read-only file system

2018-12-26 12:50:14: Failed to create folder marker: mkdir /sync/MediaServer/Home Videos/.stfolder: read-only file system

2018-12-26 12:50:14: Error on folder "MediaServer / Home Videos" (q4esr-ishsp): folder marker missing

2018-12-26 13:11:35: Saving .stignore: open /sync/MediaServer/Home Videos/.syncthing.tmp.669697141: read-only file system

 OK

 

Edited by jj_uk

Share this post


Link to post

Having a problem getting Syncthing connected to remote server.

 

I'm having problems getting Syncthing to connect to an instance I have running on a seed box.  I've used Syncthing in the past, but this is my first experience in using it as a docker under Unraid.  The gui is showing the listeners as 0/1 (in red) with the following message " tcp://10.0.30.xxx:22000: listen 10.0.30.xxx:22000: bind: cannot assign requested address"

 

I've got 22000 assigned in the docker.  I've tried port forwarding from my router to my ip address of Unraid.  I'm not certain what I'm missing at this point.

I'm running Unraid 6.6.6 in Vlan 30 of my managed switch

 

Anyone have any ideas?

 

Never mind.  I had to completely uninstall the docker and my user settings and then re-install everything.  That fixed the problem.

Edited by Moose_Flunky

Share this post


Link to post

So I've just got Syncthing installed for the first time. Not entirely sure I've gotten it configured correctly; but I was in fact able to transfer some files to the desired folder on Unraid from a remote machine. So that's something... 

 

I recently followed Spaceinvader's video on LetsEncrypt+NGINX to get Nextcloud accessible through the reverse proxy. I'd like to be able to do the same with Syncthing (i.e. https://syncthing.mydomain.com presents me with the syncthing GUI).

Is this possible? Like Nextcloud, does Syncthing require additional configuration (either in the Syncthing appdata files or the LetsEncrypt appdata files)?

 

In addition, not sure if I've got Syncthing configured securely. The GUI listen address is currently 127.0.0.1:8384. Do I need to change this if I want Syncthing to be accessible through a reverse proxy? What about the GUI authentication and "Use HTTPS for GUI" options?

 

Any and all help is much appreciated! I'm currently in the unenviable position of having a little knowledge (i.e. just enough to break things)...

 

P.S. Under "GUI Settings", I see there is a message "The GUI address is overridden by startup options. Changes here will not take effect while the override is in place." Not sure what this means exactly?

Edited by rragu

Share this post


Link to post

I've had it configured with LetsEncrypt+NGINX, but I don't use the GUI part "remotely" - I just do that locally - it transfers files.

 

The GUI listen address for me is my local network address :8384 (i.e. 192.168.0.x:8384)

 

Not sure that helps...

Share this post


Link to post

Hello

 

  I m having a problem or multiple ones to be honest. So I ll try to give out as much information as I can (I tried first to read some othr posts / documentations before posting but it seems I can t find a way to solve my problem - probably due to lack of knowledge). So here it goes

 

   I installed syncthing and during the installation form I filled in 

the host path 2 with the  path /mnt/user/ (it was empty and beneath it mentions greyed out Container Path: /sync)

AppdataConfig Path-> /mnt/user/appdata/syncthing (the default one)

Should I have entered different paths?

Also shouldn't Krusader see the Sync installation path somewhere. I can't find it in none of the above paths I entered during installation

 

 I started syncthing and first thing to do is  set the already created folder Music Data Base which

Krusader can see it  in  this directory ->/media/Music Data Base

in unraid shares tab it uses this path -> /mnt/user/Music Data Base

Why 2 different paths for the same directory? Shouldnt all programs see it at the same place?

So in the share folder inside syncthing i typed /media/Music Data Base and during save got an error message

 

<<2019-02-08 12:03:55: Failed to create folder root directory mkdir /mnt/user: permission denied

2019-02-08 12:03:55: Error on folder "Muz" (s3xqe-civks): folder path missing>>

 

After that I tried /mnt/user/Music Data Base but with the same error message. Ok probably its straightforward what to do due to the message but still i can't figure out what to do

 

Any help would be highly appreciated!!!

 

 

Edited by ieronymous

Share this post


Link to post
46 minutes ago, ieronymous said:

Hello

 

  I m having a problem or multiple ones to be honest. So I ll try to give out as much information as I can (I tried first to read some othr posts / documentations before posting but it seems I can t find a way to solve my problem - probably due to lack of knowledge). So here it goes

 

   I installed syncthing and during the installation form I filled in 

the host path 2 with the  path /mnt/user/ (it was empty and beneath it mentions greyed out Container Path: /sync)

AppdataConfig Path-> /mnt/user/appdata/syncthing (the default one)

Should I have entered different paths?

Also shouldn't Krusader see the Sync installation path somewhere. I can't find it in none of the above paths I entered during installation

 

 I started syncthing and first thing to do is  set the already created folder Music Data Base which

Krusader can see it  in  this directory ->/media/Music Data Base

in unraid shares tab it uses this path -> /mnt/user/Music Data Base

Why 2 different paths for the same directory? Shouldnt all programs see it at the same place?

So in the share folder inside syncthing i typed /media/Music Data Base and during save got an error message

 

<<2019-02-08 12:03:55: Failed to create folder root directory mkdir /mnt/user: permission denied

2019-02-08 12:03:55: Error on folder "Muz" (s3xqe-civks): folder path missing>>

 

After that I tried /mnt/user/Music Data Base but with the same error message. Ok probably its straightforward what to do due to the message but still i can't figure out what to do

 

Any hep would be highly appreciated!!!

 

 

 

You seem to not understand how docker and volume mappings works. Take a look in the Docker FAQ for a better understanding.

Your docker containers will only see the container path and not the host path.

So Krusader will not see syncthings /sync folder. For Krusader to see what syncthing sees in the /sync folder, you need to map the same host path to Krusader (/mnt/user/). Notice that the folder you see in Krusader will be whatever you set it to in the container path.

Share this post


Link to post
14 minutes ago, saarg said:

 

You seem to not understand how docker and volume mappings works. Take a look in the Docker FAQ for a better understanding.

Your docker containers will only see the container path and not the host path.

So Krusader will not see syncthings /sync folder. For Krusader to see what syncthing sees in the /sync folder, you need to map the same host path to Krusader (/mnt/user/). Notice that the folder you see in Krusader will be whatever you set it to in the container path.

   Yes it seems this way but before posted as already mentioned was reading about docker images volumes and containers. All that are theoretical  and in practice its always another thing. Probably with what you ve said in your mind it's like giving me the solution. is there a do this and you re ok kind of answer, because feels like  I m asking in a forum for cars  I have a problem with the suspension and getting an answer like read the car manual and you ll find the answer. I don t want to be offensive in any way but that s how it feels.

 

   I dont thing that I m so different as a person than all the other world. When ti comes to pc h/w, networks, cabling, installation, racks ...etc and  I am asked all kind of info/troubleshooting I just give a straight (and most times a thorough explain even though the one) answer do this .....because that..... Is it so difficult to get once that kind of explanation even once. i am  not the type of guy that  asks in forums, on the contrary, in my life is the one who got tired of giving them, but this project i have with unraid has a time limit and I m already there and haven't figure out yet. So an answer like read the bible and you ll find your faith won t really help in this situation.

 

Thank you though for trying

 

Share this post


Link to post

Hi,

 

I am using Syncthing to sync my main unraid server to my backup system. Works great.

 

I recently made some networking changes to my system and where my unraid servers (and with that dockers) used to be connected with 1gig utp, the situation is now as follows:

 

Main server is connected with 10G SFP+ to my internal network, running on 192.168.1.0/24

Backup server is connected with 1GB SFP+ to my internal network, running on 192.168.1.0/24

 

The main server and backup server have a direct connection with 10G SFP+, these have their own network: 10.10.10.0/24 (primary .1, secundary .2)

 

The two syncthing dockers have ip addresses in the 192.168.1.0/24

 

What I now would like to do is have both syncthing dockers communicate over the 10G private network between the two servers while I can still reach the servers on their 192.168.1.0/24 address.

 

The interfaces all work, if I give the dockers a 10.10.10.0/24 address then they sync fine but the webgui is not reachable anymore..

 

Any idea how I could do this within a docker ? In the end I could use two VM's but I am pretty happy with the docker setup and would like to  keep that..

Share this post


Link to post

FWIW,

 

 add me to the list of users who have given up w/ this app.  Relatively OOTB Unraid install w/ an asus board, 4 WD red drives & samsung nvme for cache.  It likely has to do w/ permissions (I've configured it w/ windows AD authentication), but I just don't feel like fighting with it any more.  Maybe it has to do w/ the other syncthing box being a Synology.  None of the logs made it clear what was going wrong, but it'd just sit at 0% syc'd between the two and, eventually, show it as disconnected.  I'm guessing a few more try/catch blocks within the application and maybe a test writing file data to a target folder could go a long way toward making it more user friendly.

 

This is my first time w/ Unraid, I've only used docker w/ a PiHole machine & I'm a linux newbie.  Anyway, I got rsync working between them & I'll setup some cron jobs to sync the files instead. 

 

 

Share this post


Link to post
Posted (edited)

I am trying to get syncthing to sync to my google drive folder without success. I have mounted a google drive folder with:

mkdir -p /mnt/user/google_syncfolder
rclone mount --buffer-size 256M --fast-list --allow-other gdrive:Dump/ /mnt/user/google_syncfolder &

I can see the mounted folder and all google drive files and can also copy from/to my google drive with the use of a file-browser on unraid.

I have also added the same directory to the path in the syncthing container. But when trying to sync from a remote syncthing-server to the unraid server it just sits at 0% and then throws a sync error.

 

If I look on my google drive I can see that syncthing has created a zero-byte .tmp file for every file I am trying to sync

 

If I change the path in the syncthing container to a regular folder on the unraid server it works without problem. Can anyone explain to me how to solve this?

Edited by Cliff

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.