1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
|
.\" Man page generated from reStructuredText.
.
.
.nr rst2man-indent-level 0
.
.de1 rstReportMargin
\\$1 \\n[an-margin]
level \\n[rst2man-indent-level]
level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
-
\\n[rst2man-indent0]
\\n[rst2man-indent1]
\\n[rst2man-indent2]
..
.de1 INDENT
.\" .rstReportMargin pre:
. RS \\$1
. nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
. nr rst2man-indent-level +1
.\" .rstReportMargin post:
..
.de UNINDENT
. RE
.\" indent \\n[an-margin]
.\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
.nr rst2man-indent-level -1
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-FAQ" "7" "Jun 09, 2022" "v1.20.2" "Syncthing"
.SH NAME
syncthing-faq \- Frequently Asked Questions
.INDENT 0.0
.IP \(bu 2
\fI\%General\fP
.INDENT 2.0
.IP \(bu 2
\fI\%What is Syncthing?\fP
.IP \(bu 2
\fI\%Is it “syncthing”, “Syncthing” or “SyncThing”?\fP
.IP \(bu 2
\fI\%What things are synced?\fP
.IP \(bu 2
\fI\%Is synchronization fast?\fP
.IP \(bu 2
\fI\%How does Syncthing differ from BitTorrent/Resilio Sync?\fP
.IP \(bu 2
\fI\%Is there an iOS client?\fP
.IP \(bu 2
\fI\%Should I keep my device IDs secret?\fP
.UNINDENT
.IP \(bu 2
\fI\%Troubleshooting\fP
.INDENT 2.0
.IP \(bu 2
\fI\%Where are the Syncthing logs?\fP
.IP \(bu 2
\fI\%Why is the sync so slow?\fP
.IP \(bu 2
\fI\%Why does it use so much CPU?\fP
.IP \(bu 2
\fI\%Why is the setup more complicated than BitTorrent/Resilio Sync?\fP
.IP \(bu 2
\fI\%Why do I get “Host check error” in the GUI/API?\fP
.IP \(bu 2
\fI\%My Syncthing database is corrupt\fP
.IP \(bu 2
\fI\%Why do I see Syncthing twice in task manager?\fP
.IP \(bu 2
\fI\%How can I view the history of changes?\fP
.IP \(bu 2
\fI\%Does the audit log contain every change?\fP
.IP \(bu 2
\fI\%Why does Syncthing connect to this unknown/suspicious address?\fP
.UNINDENT
.IP \(bu 2
\fI\%Usage\fP
.INDENT 2.0
.IP \(bu 2
\fI\%What if there is a conflict?\fP
.IP \(bu 2
\fI\%How do I serve a folder from a read only filesystem?\fP
.IP \(bu 2
\fI\%I really hate the .stfolder directory, can I remove it?\fP
.IP \(bu 2
\fI\%Am I able to nest shared folders in Syncthing?\fP
.IP \(bu 2
\fI\%How do I rename/move a synced folder?\fP
.IP \(bu 2
\fI\%How do I configure multiple users on a single machine?\fP
.IP \(bu 2
\fI\%Does Syncthing support syncing between folders on the same system?\fP
.IP \(bu 2
\fI\%When I do have two distinct Syncthing\-managed folders on two hosts, how does Syncthing handle moving files between them?\fP
.IP \(bu 2
\fI\%Can I help initial sync by copying files manually?\fP
.IP \(bu 2
\fI\%Is Syncthing my ideal backup application?\fP
.IP \(bu 2
\fI\%How can I exclude files with brackets ([]) in the name?\fP
.IP \(bu 2
\fI\%How do I access the web GUI from another computer?\fP
.IP \(bu 2
\fI\%I don’t like the GUI or the theme. Can it be changed?\fP
.IP \(bu 2
\fI\%How do I upgrade Syncthing?\fP
.IP \(bu 2
\fI\%Where do I find the latest release?\fP
.IP \(bu 2
\fI\%How do I run Syncthing as a daemon process on Linux?\fP
.IP \(bu 2
\fI\%How do I increase the inotify limit to get my filesystem watcher to work?\fP
.IP \(bu 2
\fI\%How do I reset the GUI password?\fP
.UNINDENT
.UNINDENT
.SH GENERAL
.SS What is Syncthing?
.sp
Syncthing is an application that lets you synchronize your files across multiple
devices. This means the creation, modification or deletion of files on one
machine will automatically be replicated to your other devices. We believe your
data is your data alone and you deserve to choose where it is stored. Therefore
Syncthing does not upload your data to the cloud but exchanges your data across
your machines as soon as they are online at the same time.
.SS Is it “syncthing”, “Syncthing” or “SyncThing”?
.sp
It’s \fBSyncthing\fP, although the command and source repository is spelled
\fBsyncthing\fP so it may be referred to in that way as well. It’s definitely not
SyncThing, even though the abbreviation \fBst\fP is used in some
circumstances and file names.
.SS What things are synced?
.sp
The following things are \fIalways\fP synchronized:
.INDENT 0.0
.IP \(bu 2
File contents
.IP \(bu 2
File modification times
.UNINDENT
.sp
The following may be synchronized or not, depending:
.INDENT 0.0
.IP \(bu 2
File permissions (when supported by file system; on Windows only the
read only bit is synchronized)
.IP \(bu 2
Symbolic links (synced, except on Windows, but never followed)
.UNINDENT
.sp
The following are \fInot\fP synchronized;
.INDENT 0.0
.IP \(bu 2
File or directory owners and Groups (not preserved)
.IP \(bu 2
Directory modification times (not preserved)
.IP \(bu 2
Hard links (followed, not preserved)
.IP \(bu 2
Windows junctions (synced as ordinary directories; require enabling in
\fBthe configuration\fP on a per\-folder
basis)
.IP \(bu 2
Extended attributes, resource forks (not preserved)
.IP \(bu 2
Windows, POSIX or NFS ACLs (not preserved)
.IP \(bu 2
Devices, FIFOs, and other specials (ignored)
.IP \(bu 2
Sparse file sparseness (will become sparse, when supported by the OS & filesystem)
.UNINDENT
.SS Is synchronization fast?
.sp
Syncthing segments files into pieces, called blocks, to transfer data from one
device to another. Therefore, multiple devices can share the synchronization
load, in a similar way to the torrent protocol. The more devices you have online,
the faster an additional device will receive the data
because small blocks will be fetched from all devices in parallel.
.sp
Syncthing handles renaming files and updating their metadata in an efficient
manner. This means that renaming a file will not cause a retransmission of
that file. Additionally, appending data to existing files should be handled
efficiently as well.
.sp
Temporary files are used to store partial data
downloaded from other devices. They are automatically removed whenever a file
transfer has been completed or after the configured amount of time which is set
in the configuration file (24 hours by default).
.SS How does Syncthing differ from BitTorrent/Resilio Sync?
.sp
The two are different and not related. Syncthing and BitTorrent/Resilio Sync accomplish
some of the same things, namely syncing files between two or more computers.
.sp
BitTorrent Sync, now called Resilio Sync, is a proprietary peer\-to\-peer file
synchronization tool available for Windows, Mac, Linux, Android, iOS, Windows
Phone, Amazon Kindle Fire and BSD. [1] Syncthing is an open source file
synchronization tool.
.sp
Syncthing uses an open and documented protocol, and likewise the security
mechanisms in use are well defined and visible in the source code. Resilio
Sync uses an undocumented, closed protocol with unknown security properties.
.IP [1] 5
\fI\%https://en.wikipedia.org/wiki/Resilio_Sync\fP
.SS Is there an iOS client?
.sp
There are no plans by the current Syncthing team to officially support iOS in the foreseeable future.
.sp
iOS has significant restrictions on background processing that make it very hard to
run Syncthing reliably and integrate it into the system.
.sp
However, there is a commercial packaging of Syncthing for iOS that attempts to work within these limitations. [2]
.IP [2] 5
\fI\%https://www.mobiussync.com\fP
.SS Should I keep my device IDs secret?
.sp
No. The IDs are not sensitive. Given a device ID it’s possible to find the IP
address for that device, if global discovery is enabled on it. Knowing the device
ID doesn’t help you actually establish a connection to that device or get a list
of files, etc.
.sp
For a connection to be established, both devices need to know about the other’s
device ID. It’s not possible (in practice) to forge a device ID. (To forge a
device ID you need to create a TLS certificate with that specific SHA\-256 hash.
If you can do that, you can spoof any TLS certificate. The world is your
oyster!)
.sp
\fBSEE ALSO:\fP
.INDENT 0.0
.INDENT 3.5
device\-ids
.UNINDENT
.UNINDENT
.SH TROUBLESHOOTING
.SS Where are the Syncthing logs?
.sp
Syncthing logs to stdout by default. On Windows Syncthing by default also
creates \fBsyncthing.log\fP in Syncthing’s home directory (run \fBsyncthing
\-\-paths\fP to see where that is). The command line option \fB\-\-logfile\fP can be
used to specify a user\-defined logfile.
.sp
If you’re running a process manager like systemd, check there. If you’re
using a GUI wrapper integration, it may keep the logs for you.
.SS Why is the sync so slow?
.sp
When troubleshooting a slow sync, there are a number of things to check.
.sp
First of all, verify that you are not connected via a relay. In the “Remote
Devices” list on the right side of the GUI, double check that you see
“Address: <some address>” and \fInot\fP “Relay: <some address>”.
[image]
.sp
If you are connected via a relay, this is because a direct connection could
not be established. Double check and follow the suggestions in
firewall\-setup to enable direct connections.
.sp
Second, if one of the devices is a very low powered machine (a Raspberry Pi,
or a phone, or a NAS, or similar) you are likely constrained by the CPU on
that device. See the next question for reasons Syncthing likes a faster CPU.
.sp
Third, verify that the network connection is OK. Tools such as iperf or just
an Internet speed test can be used to verify the performance here.
.SS Why does it use so much CPU?
.INDENT 0.0
.IP 1. 3
When new or changed files are detected, or Syncthing starts for the
first time, your files are hashed using SHA\-256.
.IP 2. 3
Data that is sent over the network is compressed (optionally) and
encrypted (always). When receiving data it must be decrypted and then (if
compressed) decompressed.
.IP 3. 3
There is a certain amount of housekeeping that must be done to track the
current and available versions of each file in the index database.
.IP 4. 3
By default Syncthing uses periodic scanning every hour when watching for
changes or every minute if that’s disabled to detect
file changes. This means checking every file’s modification time and
comparing it to the database. This can cause spikes of CPU usage for large
folders.
.UNINDENT
.sp
Hashing, compression and encryption cost CPU time. Also, using the GUI
causes a certain amount of extra CPU usage to calculate the summary data it
presents. Note however that once things are \fIin sync\fP CPU usage should be
negligible.
.sp
To minimize the impact of this, Syncthing attempts to \fBlower the
process priority\fP when starting up.
.sp
To further limit the amount of CPU used when syncing and scanning, set the
environment variable \fBGOMAXPROCS\fP to the maximum number of CPU cores
Syncthing should use at any given moment. For example, \fBGOMAXPROCS=2\fP on a
machine with four cores will limit Syncthing to no more than half the
system’s CPU power.
.SS Why is the setup more complicated than BitTorrent/Resilio Sync?
.sp
Security over convenience. In Syncthing you have to setup both sides to
connect two devices. An attacker can’t do much with a stolen device ID, because
you have to add the device on the other side too. You have better control
where your files are transferred.
.sp
This is an area that we are working to improve in the long term.
.SS Why do I get “Host check error” in the GUI/API?
.sp
Since version 0.14.6 Syncthing does an extra security check when the GUI/API
is bound to localhost \- namely that the browser is talking to localhost.
This protects against most forms of \fI\%DNS rebinding attack\fP <\fBhttps://en.wikipedia.org/wiki/DNS_rebinding\fP> against the GUI.
.sp
To pass this test, ensure that you are accessing the GUI using an URL that
begins with \fBhttp://localhost\fP, \fBhttp://127.0.0.1\fP or \fBhttp://[::1]\fP\&. HTTPS
is fine too, of course.
.sp
If you are using a proxy in front of Syncthing you may need to disable this
check, after ensuring that the proxy provides sufficient authentication to
protect against unauthorized access. Either:
.INDENT 0.0
.IP \(bu 2
Make sure the proxy sets a \fBHost\fP header containing \fBlocalhost\fP, or
.IP \(bu 2
Set \fBgui.insecureSkipHostcheck\fP in the advanced settings, or
.IP \(bu 2
Bind the GUI/API to a non\-localhost listen port.
.UNINDENT
.sp
In all cases, username/password authentication and HTTPS should be used.
.SS My Syncthing database is corrupt
.sp
This is almost always a result of bad RAM, storage device or other hardware.
When the index database is found to be corrupt Syncthing cannot operate and
will note this in the logs and exit. To overcome this delete the \fI\%database
folder\fP <\fBhttps://docs.syncthing.net/users/config.html#description\fP> inside
Syncthing’s home directory and re\-start Syncthing. It will then need to
perform a full re\-hashing of all shared folders. You should check your
system in case the underlying cause is indeed faulty hardware which may put
the system at risk of further data loss.
.SS Why do I see Syncthing twice in task manager?
.sp
One process manages the other, to capture logs and manage restarts. This
makes it easier to handle upgrades from within Syncthing itself, and also
ensures that we get a nice log file to help us narrow down the cause for
crashes and other bugs.
.SS How can I view the history of changes?
.sp
The web GUI contains a \fBRecent Changes\fP button under the device list which
displays changes since the last (re)start of Syncthing. With the \fB\-\-audit\fP
option you can enable a persistent, detailed log of changes and most
activities, which contains a \fBJSON\fP formatted sequence of events in the
\fB~/.config/syncthing/audit\-_date_\-_time_.log\fP file.
.SS Does the audit log contain every change?
.sp
The audit log (and the \fBRecent Changes\fP window) sees the changes that your
Syncthing sees. When Syncthing is continuously connected it usually sees every change
happening immediately and thus knows which node initiated the change.
When topology gets complex or when your node reconnects after some time offline,
Syncthing synchronises with its neighbours: It gets the latest synchronised state
from the neighbour, which is the \fIresult\fP of all the changes between the last
known state (before disconnect or network delay) and the current state at the
neighbour, and if there were updates, deletes, creates, conflicts, whic
|