syncthing-config.5 32 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979
  1. .\" Man page generated from reStructuredText.
  2. .
  3. .TH "SYNCTHING-CONFIG" "5" "Jun 11, 2019" "v1" "Syncthing"
  4. .SH NAME
  5. syncthing-config \- Syncthing Configuration
  6. .
  7. .nr rst2man-indent-level 0
  8. .
  9. .de1 rstReportMargin
  10. \\$1 \\n[an-margin]
  11. level \\n[rst2man-indent-level]
  12. level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
  13. -
  14. \\n[rst2man-indent0]
  15. \\n[rst2man-indent1]
  16. \\n[rst2man-indent2]
  17. ..
  18. .de1 INDENT
  19. .\" .rstReportMargin pre:
  20. . RS \\$1
  21. . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
  22. . nr rst2man-indent-level +1
  23. .\" .rstReportMargin post:
  24. ..
  25. .de UNINDENT
  26. . RE
  27. .\" indent \\n[an-margin]
  28. .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
  29. .nr rst2man-indent-level -1
  30. .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
  31. .in \\n[rst2man-indent\\n[rst2man-indent-level]]u
  32. ..
  33. .SH SYNOPSIS
  34. .INDENT 0.0
  35. .INDENT 3.5
  36. .sp
  37. .nf
  38. .ft C
  39. $HOME/.config/syncthing
  40. $HOME/Library/Application Support/Syncthing
  41. %AppData%/Syncthing
  42. %localappdata%/Syncthing
  43. .ft P
  44. .fi
  45. .UNINDENT
  46. .UNINDENT
  47. .SH DESCRIPTION
  48. .sp
  49. Syncthing uses a single directory to store configuration, crypto keys
  50. and index caches. The location defaults to \fB$HOME/.config/syncthing\fP
  51. (Unix\-like), \fB$HOME/Library/Application Support/Syncthing\fP (Mac),
  52. \fB%AppData%/Syncthing\fP (Windows XP) or \fB%LocalAppData%/Syncthing\fP
  53. (Windows 7+). It can be changed at runtime using the \fB\-home\fP flag. In this
  54. directory the following files are located:
  55. .INDENT 0.0
  56. .TP
  57. .B \fBconfig.xml\fP
  58. The configuration file, in XML format.
  59. .TP
  60. .B \fBcert.pem\fP, \fBkey.pem\fP
  61. The device’s RSA public and private key. These form the basis for the
  62. device ID. The key must be kept private.
  63. .TP
  64. .B \fBhttps\-cert.pem\fP, \fBhttps\-key.pem\fP
  65. The certificate and key for HTTPS GUI connections. These may be replaced
  66. with a custom certificate for HTTPS as desired.
  67. .TP
  68. .B \fBindex\-\fP\fI*\fP\fB\&.db\fP
  69. A directory holding the database with metadata and hashes of the files
  70. currently on disk and available from peers.
  71. .TP
  72. .B \fBcsrftokens.txt\fP
  73. A list of recently issued CSRF tokens (for protection against browser cross
  74. site request forgery).
  75. .UNINDENT
  76. .SH CONFIG FILE FORMAT
  77. .sp
  78. The following shows an example of the default configuration file (IDs will differ):
  79. .INDENT 0.0
  80. .INDENT 3.5
  81. .sp
  82. .nf
  83. .ft C
  84. <configuration version="26">
  85. <folder id="zj2AA\-q55a7" label="Default Folder" path="/Users/jb/Sync/" type="sendreceive" rescanIntervalS="60" fsWatcherEnabled="false" fsWatcherDelayS="10" ignorePerms="false" autoNormalize="true">
  86. <device id="3LT2GA5\-CQI4XJM\-WTZ264P\-MLOGMHL\-MCRLDNT\-MZV4RD3\-KA745CL\-OGAERQZ"></device>
  87. <filesystemType>basic</filesystemType>
  88. <minDiskFree unit="%">1</minDiskFree>
  89. <versioning></versioning>
  90. <copiers>0</copiers>
  91. <pullers>0</pullers>
  92. <hashers>0</hashers>
  93. <order>random</order>
  94. <ignoreDelete>false</ignoreDelete>
  95. <scanProgressIntervalS>0</scanProgressIntervalS>
  96. <pullerPauseS>0</pullerPauseS>
  97. <maxConflicts>\-1</maxConflicts>
  98. <disableSparseFiles>false</disableSparseFiles>
  99. <disableTempIndexes>false</disableTempIndexes>
  100. <paused>false</paused>
  101. <weakHashThresholdPct>25</weakHashThresholdPct>
  102. <markerName>.stfolder</markerName>
  103. </folder>
  104. <device id="3LT2GA5\-CQI4XJM\-WTZ264P\-MLOGMHL\-MCRLDNT\-MZV4RD3\-KA745CL\-OGAERQZ" name="syno" compression="metadata" introducer="false" skipIntroductionRemovals="false" introducedBy="">
  105. <address>dynamic</address>
  106. <paused>false</paused>
  107. </device>
  108. <gui enabled="true" tls="false" debugging="false">
  109. <address>127.0.0.1:8384</address>
  110. <apikey>k1dnz1Dd0rzTBjjFFh7CXPnrF12C49B1</apikey>
  111. <theme>default</theme>
  112. </gui>
  113. <options>
  114. <listenAddress>default</listenAddress>
  115. <globalAnnounceServer>default</globalAnnounceServer>
  116. <globalAnnounceEnabled>true</globalAnnounceEnabled>
  117. <localAnnounceEnabled>true</localAnnounceEnabled>
  118. <localAnnouncePort>21027</localAnnouncePort>
  119. <localAnnounceMCAddr>[ff12::8384]:21027</localAnnounceMCAddr>
  120. <maxSendKbps>0</maxSendKbps>
  121. <maxRecvKbps>0</maxRecvKbps>
  122. <reconnectionIntervalS>60</reconnectionIntervalS>
  123. <relaysEnabled>true</relaysEnabled>
  124. <relayReconnectIntervalM>10</relayReconnectIntervalM>
  125. <startBrowser>true</startBrowser>
  126. <natEnabled>true</natEnabled>
  127. <natLeaseMinutes>60</natLeaseMinutes>
  128. <natRenewalMinutes>30</natRenewalMinutes>
  129. <natTimeoutSeconds>10</natTimeoutSeconds>
  130. <urAccepted>0</urAccepted>
  131. <urSeen>0</urSeen>
  132. <urUniqueID>LFWe2vn3</urUniqueID>
  133. <urURL>https://data.syncthing.net/newdata</urURL>
  134. <urPostInsecurely>false</urPostInsecurely>
  135. <urInitialDelayS>1800</urInitialDelayS>
  136. <restartOnWakeup>true</restartOnWakeup>
  137. <autoUpgradeIntervalH>12</autoUpgradeIntervalH>
  138. <upgradeToPreReleases>false</upgradeToPreReleases>
  139. <keepTemporariesH>24</keepTemporariesH>
  140. <cacheIgnoredFiles>false</cacheIgnoredFiles>
  141. <progressUpdateIntervalS>5</progressUpdateIntervalS>
  142. <limitBandwidthInLan>false</limitBandwidthInLan>
  143. <minHomeDiskFree unit="%">1</minHomeDiskFree>
  144. <releasesURL>https://upgrades.syncthing.net/meta.json</releasesURL>
  145. <overwriteRemoteDeviceNamesOnConnect>false</overwriteRemoteDeviceNamesOnConnect>
  146. <tempIndexMinBlocks>10</tempIndexMinBlocks>
  147. <trafficClass>0</trafficClass>
  148. <weakHashSelectionMethod>auto</weakHashSelectionMethod>
  149. <stunServer>default</stunServer>
  150. <stunKeepaliveSeconds>24</stunKeepaliveSeconds>
  151. <kcpNoDelay>false</kcpNoDelay>
  152. <kcpUpdateIntervalMs>25</kcpUpdateIntervalMs>
  153. <kcpFastResend>false</kcpFastResend>
  154. <kcpCongestionControl>true</kcpCongestionControl>
  155. <kcpSendWindowSize>128</kcpSendWindowSize>
  156. <kcpReceiveWindowSize>128</kcpReceiveWindowSize>
  157. <defaultFolderPath>~</defaultFolderPath>
  158. <minHomeDiskFreePct>0</minHomeDiskFreePct>
  159. <setLowPriority>true</setLowPriority>
  160. </options>
  161. </configuration>
  162. .ft P
  163. .fi
  164. .UNINDENT
  165. .UNINDENT
  166. .SH CONFIGURATION ELEMENT
  167. .INDENT 0.0
  168. .INDENT 3.5
  169. .sp
  170. .nf
  171. .ft C
  172. <configuration version="26">
  173. <folder></folder>
  174. <device></device>
  175. <gui></gui>
  176. <options></options>
  177. <ignoredDevice>5SYI2FS\-LW6YAXI\-JJDYETS\-NDBBPIO\-256MWBO\-XDPXWVG\-24QPUM4\-PDW4UQU</ignoredDevice>
  178. <ignoredFolder>bd7q3\-zskm5</ignoredFolder>
  179. </configuration>
  180. .ft P
  181. .fi
  182. .UNINDENT
  183. .UNINDENT
  184. .sp
  185. This is the root element. It has one attribute:
  186. .INDENT 0.0
  187. .TP
  188. .B version
  189. The config version. Increments whenever a change is made that requires
  190. migration from previous formats.
  191. .UNINDENT
  192. .sp
  193. It contains the elements described in the following sections and these two
  194. additional child elements:
  195. .INDENT 0.0
  196. .TP
  197. .B ignoredDevice
  198. Contains the ID of the device that should be ignored. Connection attempts
  199. from this device are logged to the console but never displayed in the web
  200. GUI.
  201. .TP
  202. .B ignoredFolder
  203. Contains the ID of the folder that should be ignored. This folder will
  204. always be skipped when advertised from a remote device, i.e. this will be
  205. logged, but there will be no dialog about it in the web GUI.
  206. .UNINDENT
  207. .SH FOLDER ELEMENT
  208. .INDENT 0.0
  209. .INDENT 3.5
  210. .sp
  211. .nf
  212. .ft C
  213. <folder id="zj2AA\-q55a7" label="Default Folder" path="/Users/jb/Sync/" type="sendreceive" rescanIntervalS="60" fsWatcherEnabled="false" fsWatcherDelayS="10" ignorePerms="false" autoNormalize="true">
  214. <device id="3LT2GA5\-CQI4XJM\-WTZ264P\-MLOGMHL\-MCRLDNT\-MZV4RD3\-KA745CL\-OGAERQZ"></device>
  215. <filesystemType>basic</filesystemType>
  216. <minDiskFree unit="%">1</minDiskFree>
  217. <versioning></versioning>
  218. <copiers>0</copiers>
  219. <pullers>0</pullers>
  220. <hashers>0</hashers>
  221. <order>random</order>
  222. <ignoreDelete>false</ignoreDelete>
  223. <scanProgressIntervalS>0</scanProgressIntervalS>
  224. <pullerPauseS>0</pullerPauseS>
  225. <maxConflicts>\-1</maxConflicts>
  226. <disableSparseFiles>false</disableSparseFiles>
  227. <disableTempIndexes>false</disableTempIndexes>
  228. <paused>false</paused>
  229. <weakHashThresholdPct>25</weakHashThresholdPct>
  230. <markerName>.stfolder</markerName>
  231. </folder>
  232. .ft P
  233. .fi
  234. .UNINDENT
  235. .UNINDENT
  236. .sp
  237. One or more \fBfolder\fP elements must be present in the file. Each element
  238. describes one folder. The following attributes may be set on the \fBfolder\fP
  239. element:
  240. .INDENT 0.0
  241. .TP
  242. .B id
  243. The folder ID, must be unique. (mandatory)
  244. .TP
  245. .B label
  246. The label of a folder is a human readable and descriptive local name. May
  247. be different on each device, empty, and/or identical to other folder
  248. labels. (optional)
  249. .TP
  250. .B path
  251. The path to the directory where the folder is stored on this
  252. device; not sent to other devices. (mandatory)
  253. .TP
  254. .B type
  255. Controls how the folder is handled by Syncthing. Possible values are:
  256. .INDENT 7.0
  257. .TP
  258. .B sendreceive
  259. The folder is in default mode. Sending local and accepting remote changes.
  260. Note that this type was previously called “readwrite” which is deprecated
  261. but still accepted in incoming configs.
  262. .TP
  263. .B sendonly
  264. The folder is in “send only” mode – it will not be modified by
  265. Syncthing on this device.
  266. Note that this type was previously called “readonly” which is deprecated
  267. but still accepted in incoming configs.
  268. .TP
  269. .B receiveonly
  270. The folder is in “receive only” mode – it will not propagate
  271. changes to other devices.
  272. .UNINDENT
  273. .TP
  274. .B rescanIntervalS
  275. The rescan interval, in seconds. Can be set to zero to disable when external
  276. plugins are used to trigger rescans.
  277. .TP
  278. .B fsWatcherEnabled
  279. If enabled this detects changes to files in the folder and scans them.
  280. .UNINDENT
  281. .INDENT 0.0
  282. .TP
  283. .B fsWatcherDelayS
  284. The duration during which changes detected are accumulated, before a scan is
  285. scheduled (only takes effect if \fBfsWatcherEnabled\fP is true).
  286. .TP
  287. .B ignorePerms
  288. True if the folder should ignore permissions.
  289. .TP
  290. .B autoNormalize
  291. Automatically correct UTF\-8 normalization errors found in file names.
  292. .UNINDENT
  293. .sp
  294. The following child elements may exist:
  295. .INDENT 0.0
  296. .TP
  297. .B device
  298. These must have the \fBid\fP attribute and can have an \fBintroducedBy\fP attribute,
  299. identifying the device that introduced us to share this folder with the given device.
  300. If the original introducer unshares this folder with this device, our device will follow
  301. and unshare the folder (subject to skipIntroductionRemovals being false on the introducer device).
  302. All mentioned devices are those that will be sharing the folder in question.
  303. Each mentioned device must have a separate \fBdevice\fP element later in the file.
  304. It is customary that the local device ID is included in all folders.
  305. Syncthing will currently add this automatically if it is not present in
  306. the configuration file.
  307. .TP
  308. .B minDiskFree
  309. The minimum required free space that should be available on the disk this folder
  310. resides. The folder will be stopped when the value drops below the threshold. Accepted units are
  311. \fB%\fP, \fBkB\fP, \fBMB\fP, \fBGB\fP and \fBTB\fP\&. Set to zero to disable.
  312. .TP
  313. .B versioning
  314. Specifies a versioning configuration.
  315. .UNINDENT
  316. .sp
  317. \fBSEE ALSO:\fP
  318. .INDENT 0.0
  319. .INDENT 3.5
  320. versioning
  321. .UNINDENT
  322. .UNINDENT
  323. .INDENT 0.0
  324. .TP
  325. .B copiers, pullers, hashers
  326. The number of copier, puller and hasher routines to use, or zero for the
  327. system determined optimum. These are low level performance options for
  328. advanced users only; do not change unless requested to or you’ve actually
  329. read and understood the code yourself. :)
  330. .TP
  331. .B order
  332. The order in which needed files should be pulled from the cluster.
  333. The possibles values are:
  334. .INDENT 7.0
  335. .TP
  336. .B random
  337. Pull files in random order. This optimizes for balancing resources among
  338. the devices in a cluster.
  339. .TP
  340. .B alphabetic
  341. Pull files ordered by file name alphabetically.
  342. .TP
  343. .B smallestFirst, largestFirst
  344. Pull files ordered by file size; smallest and largest first respectively.
  345. .TP
  346. .B oldestFirst, newestFirst
  347. Pull files ordered by modification time; oldest and newest first
  348. respectively.
  349. .UNINDENT
  350. .sp
  351. Note that the scanned files are sent in batches and the sorting is applied
  352. only to the already discovered files. This means the sync might start with
  353. a 1 GB file even if there is 1 KB file available on the source device until
  354. the 1 KB becomes known to the pulling device.
  355. .TP
  356. .B ignoreDelete
  357. When set to true, this device will pretend not to see instructions to
  358. delete files from other devices.
  359. .TP
  360. .B scanProgressIntervalS
  361. The interval with which scan progress information is sent to the GUI. Zero
  362. means the default value (two seconds).
  363. .TP
  364. .B pullerPauseS
  365. Tweak for rate limiting the puller when it retries pulling files. Don’t
  366. change these unless you know what you’re doing.
  367. .TP
  368. .B maxConflicts
  369. The maximum number of conflict copies to keep around for any given file.
  370. The default, \-1, means an unlimited number. Setting this to zero disables
  371. conflict copies altogether.
  372. .TP
  373. .B disableSparseFiles
  374. By default, blocks containing all zeroes are not written, causing files
  375. to be sparse on filesystems that support the concept. When set to true,
  376. sparse files will not be created.
  377. .TP
  378. .B disableTempIndexes
  379. By default, devices exchange information about blocks available in
  380. transfers that are still in progress. When set to true, such information
  381. is not exchanged for this folder.
  382. .TP
  383. .B paused
  384. True if this folder is (temporarily) suspended.
  385. .TP
  386. .B weakHashThresholdPct
  387. Use weak hash if more than the given percentage of the file has changed. Set
  388. to \-1 to always use weak hash. Default value is 25.
  389. .TP
  390. .B markerName
  391. Name of a directory or file in the folder root to be used as
  392. marker\-faq\&. Default is “.stfolder”.
  393. .TP
  394. .B fsync
  395. Deprecated since version v0.14.37.
  396. .sp
  397. Transfer updated (from other devices) files to permanent storage before
  398. committing the changes to the internal database.
  399. .TP
  400. .B pullerSleepS
  401. Deprecated since version v0.14.41.
  402. .sp
  403. Tweak for rate limiting the puller. Don’t change these unless you know
  404. what you’re doing.
  405. .UNINDENT
  406. .SH DEVICE ELEMENT
  407. .INDENT 0.0
  408. .INDENT 3.5
  409. .sp
  410. .nf
  411. .ft C
  412. <device id="5SYI2FS\-LW6YAXI\-JJDYETS\-NDBBPIO\-256MWBO\-XDPXWVG\-24QPUM4\-PDW4UQU" name="syno" compression="metadata" introducer="false" skipIntroductionRemovals="false" introducedBy="2CYF2WQ\-AKZO2QZ\-JAKWLYD\-AGHMQUM\-BGXUOIS\-GYILW34\-HJG3DUK\-LRRYQAR">
  413. <address>dynamic</address>
  414. </device>
  415. <device id="2CYF2WQ\-AKZO2QZ\-JAKWLYD\-AGHMQUM\-BGXUOIS\-GYILW34\-HJG3DUK\-LRRYQAR" name="syno local" compression="metadata" introducer="false">
  416. <address>tcp://192.0.2.1:22001</address>
  417. <paused>true<paused>
  418. <allowedNetwork>192.168.0.0/16<allowedNetwork>
  419. </device>
  420. .ft P
  421. .fi
  422. .UNINDENT
  423. .UNINDENT
  424. .sp
  425. One or more \fBdevice\fP elements must be present in the file. Each element
  426. describes a device participating in the cluster. It is customary to include a
  427. \fBdevice\fP element for the local device; Syncthing will currently add one if
  428. it is not present. The following attributes may be set on the \fBdevice\fP
  429. element:
  430. .INDENT 0.0
  431. .TP
  432. .B id
  433. The device ID. This must be written in canonical form, that is without any
  434. spaces or dashes. (mandatory)
  435. .TP
  436. .B name
  437. A friendly name for the device. (optional)
  438. .TP
  439. .B compression
  440. Whether to use protocol compression when sending messages to this device.
  441. The possible values are:
  442. .INDENT 7.0
  443. .TP
  444. .B metadata
  445. Compress metadata packets, such as index information. Metadata is
  446. usually very compression friendly so this is a good default.
  447. .TP
  448. .B always
  449. Compress all packets, including file data. This is recommended if the
  450. folders contents are mainly compressible data such as documents or
  451. text files.
  452. .TP
  453. .B never
  454. Disable all compression.
  455. .UNINDENT
  456. .TP
  457. .B introducer
  458. Set to true if this device should be trusted as an introducer, i.e. we
  459. should copy their list of devices per folder when connecting.
  460. .UNINDENT
  461. .sp
  462. \fBSEE ALSO:\fP
  463. .INDENT 0.0
  464. .INDENT 3.5
  465. introducer
  466. .UNINDENT
  467. .UNINDENT
  468. .INDENT 0.0
  469. .TP
  470. .B skipIntroductionRemovals
  471. Set to true if you wish to follow only introductions and not de\-introductions.
  472. For example, if this is set, we would not remove a device that we were introduced
  473. to even if the original introducer is no longer listing the remote device as known.
  474. .TP
  475. .B introducedBy
  476. Defines which device has introduced us to this device. Used only for following de\-introductions.
  477. .TP
  478. .B certName
  479. The device certificate common name, if it is not the default “syncthing”.
  480. .UNINDENT
  481. .sp
  482. From following child elements at least one \fBaddress\fP child must exist.
  483. .INDENT 0.0
  484. .TP
  485. .B address
  486. Contains an address or host name to use when attempting to connect to this device.
  487. Entries other than \fBdynamic\fP must be prefixed with \fBtcp://\fP (dual\-stack),
  488. \fBtcp4://\fP (IPv4 only) or \fBtcp6://\fP (IPv6 only). Note that IP addresses need
  489. not use tcp4/tcp6; these are optional. Accepted formats are:
  490. .INDENT 7.0
  491. .TP
  492. .B IPv4 address (\fBtcp://192.0.2.42\fP)
  493. The default port (22000) is used.
  494. .TP
  495. .B IPv4 address and port (\fBtcp://192.0.2.42:12345\fP)
  496. The address and port is used as given.
  497. .TP
  498. .B IPv6 address (\fBtcp://[2001:db8::23:42]\fP)
  499. The default port (22000) is used. The address must be enclosed in
  500. square brackets.
  501. .TP
  502. .B IPv6 address and port (\fBtcp://[2001:db8::23:42]:12345\fP)
  503. The address and port is used as given. The address must be enclosed in
  504. square brackets.
  505. .TP
  506. .B Host name (\fBtcp6://fileserver\fP)
  507. The host name will be used on the default port (22000) and connections
  508. will be attempted only via IPv6.
  509. .TP
  510. .B Host name and port (\fBtcp://fileserver:12345\fP)
  511. The host name will be used on the given port and connections will be
  512. attempted via both IPv4 and IPv6, depending on name resolution.
  513. .TP
  514. .B \fBdynamic\fP
  515. The word \fBdynamic\fP (without \fBtcp://\fP prefix) means to use local and
  516. global discovery to find the device.
  517. .UNINDENT
  518. .sp
  519. You can set multiple addresses \fIand\fP combine it with the \fBdynamic\fP keyword
  520. for example:
  521. .INDENT 7.0
  522. .INDENT 3.5
  523. .sp
  524. .nf
  525. .ft C
  526. <device id="...">
  527. <address>tcp://192.0.2.1:22001</address>
  528. <address>tcp://192.0.1.254:22000</address>
  529. <address>dynamic</address>
  530. </device>
  531. .ft P
  532. .fi
  533. .UNINDENT
  534. .UNINDENT
  535. .TP
  536. .B paused
  537. True if synchronization with this devices is (temporarily) suspended.
  538. .TP
  539. .B allowedNetwork
  540. If given, this restricts connections to this device to only this network
  541. (see allowed\-networks).
  542. .UNINDENT
  543. .SH GUI ELEMENT
  544. .INDENT 0.0
  545. .INDENT 3.5
  546. .sp
  547. .nf
  548. .ft C
  549. <gui enabled="true" tls="false" debugging="false">
  550. <address>127.0.0.1:8384</address>
  551. <apikey>l7jSbCqPD95JYZ0g8vi4ZLAMg3ulnN1b</apikey>
  552. <theme>default</theme>
  553. </gui>
  554. .ft P
  555. .fi
  556. .UNINDENT
  557. .UNINDENT
  558. .sp
  559. There must be exactly one \fBgui\fP element. The GUI configuration is also used
  560. by the rest\-api and the event\-api\&. The following attributes may
  561. be set on the \fBgui\fP element:
  562. .INDENT 0.0
  563. .TP
  564. .B enabled
  565. If not \fBtrue\fP, the GUI and API will not be started.
  566. .TP
  567. .B tls
  568. If set to \fBtrue\fP, TLS (HTTPS) will be enforced. Non\-HTTPS requests will
  569. be redirected to HTTPS. When this is set to \fBfalse\fP, TLS connections are
  570. still possible but it is not mandatory.
  571. .TP
  572. .B debugging
  573. This enables profiling and additional debugging endpoints in the rest\-api\&.
  574. .UNINDENT
  575. .sp
  576. The following child elements may be present:
  577. .INDENT 0.0
  578. .TP
  579. .B address
  580. Set the listen address. One address element must be present. Allowed address formats are:
  581. .INDENT 7.0
  582. .TP
  583. .B IPv4 address and port (\fB127.0.0.1:8384\fP)
  584. The address and port is used as given.
  585. .TP
  586. .B IPv6 address and port (\fB[::1]:8384\fP)
  587. The address and port is used as given. The address must be enclosed in
  588. square brackets.
  589. .TP
  590. .B Wildcard and port (\fB0.0.0.0:12345\fP, \fB[::]:12345\fP, \fB:12345\fP)
  591. These are equivalent and will result in Syncthing listening on all
  592. interfaces via both IPv4 and IPv6.
  593. .TP
  594. .B UNIX socket location (\fB/var/run/st.sock\fP)
  595. If the address is an absolute path it is interpreted as the path to a UNIX socket.
  596. (Added in v0.14.52.)
  597. .UNINDENT
  598. .TP
  599. .B user
  600. Set to require authentication.
  601. .TP
  602. .B password
  603. Contains the bcrypt hash of the real password.
  604. .TP
  605. .B apikey
  606. If set, this is the API key that enables usage of the REST interface.
  607. .TP
  608. .B insecureAdminAccess
  609. If true, this allows access to the web GUI from outside (i.e. not localhost)
  610. without authorization. A warning will displayed about this setting on startup.
  611. .TP
  612. .B theme
  613. The name of the theme to use.
  614. .TP
  615. .B authMode
  616. Authentication mode to use. If not present authentication mode (static)
  617. is controlled by presence of user/passward fields for backward compatibility.
  618. .INDENT 7.0
  619. .TP
  620. .B static
  621. Authentication using user and password.
  622. .TP
  623. .B ldap
  624. LDAP authentication. Requires ldap top level config section to be present.
  625. .UNINDENT
  626. .UNINDENT
  627. .SH LDAP ELEMENT
  628. .INDENT 0.0
  629. .INDENT 3.5
  630. .sp
  631. .nf
  632. .ft C
  633. <ldap>
  634. <address>localhost:389</address>
  635. <bindDN>cn=%s,ou=users,dc=syncthing,dc=net</bindDN>
  636. <transport>nontls</transport>
  637. <insecureSkipVerify>false</insecureSkipVerify>
  638. </ldap>
  639. .ft P
  640. .fi
  641. .UNINDENT
  642. .UNINDENT
  643. .sp
  644. The \fBldap\fP element contains LDAP configuration options.
  645. .INDENT 0.0
  646. .TP
  647. .B address
  648. LDAP server address (server:port).
  649. .TP
  650. .B bindDN
  651. BindDN for user authentication.
  652. Special %s variable shoild be used to pass username to LDAP.
  653. .UNINDENT
  654. .sp
  655. transport
  656. .INDENT 0.0
  657. .INDENT 3.5
  658. .INDENT 0.0
  659. .TP
  660. .B nontls
  661. Non secure connection.
  662. .TP
  663. .B tls
  664. TLS secured connection.
  665. .TP
  666. .B starttls
  667. StartTLS connection mode.
  668. .UNINDENT
  669. .UNINDENT
  670. .UNINDENT
  671. .INDENT 0.0
  672. .TP
  673. .B insecureSkipVerify
  674. Skip verification (true or false).
  675. .UNINDENT
  676. .SH OPTIONS ELEMENT
  677. .INDENT 0.0
  678. .INDENT 3.5
  679. .sp
  680. .nf
  681. .ft C
  682. <options>
  683. <listenAddress>default</listenAddress>
  684. <globalAnnounceServer>default</globalAnnounceServer>
  685. <globalAnnounceEnabled>true</globalAnnounceEnabled>
  686. <localAnnounceEnabled>true</localAnnounceEnabled>
  687. <localAnnouncePort>21027</localAnnouncePort>
  688. <localAnnounceMCAddr>[ff12::8384]:21027</localAnnounceMCAddr>
  689. <maxSendKbps>0</maxSendKbps>
  690. <maxRecvKbps>0</maxRecvKbps>
  691. <reconnectionIntervalS>60</reconnectionIntervalS>
  692. <relaysEnabled>true</relaysEnabled>
  693. <relayReconnectIntervalM>10</relayReconnectIntervalM>
  694. <startBrowser>true</startBrowser>
  695. <natEnabled>true</natEnabled>
  696. <natLeaseMinutes>60</natLeaseMinutes>
  697. <natRenewalMinutes>30</natRenewalMinutes>
  698. <natTimeoutSeconds>10</natTimeoutSeconds>
  699. <urAccepted>0</urAccepted>
  700. <urUniqueID></urUniqueID>
  701. <urURL>https://data.syncthing.net/newdata</urURL>
  702. <urPostInsecurely>false</urPostInsecurely>
  703. <urInitialDelayS>1800</urInitialDelayS>
  704. <restartOnWakeup>true</restartOnWakeup>
  705. <autoUpgradeIntervalH>12</autoUpgradeIntervalH>
  706. <keepTemporariesH>24</keepTemporariesH>
  707. <cacheIgnoredFiles>false</cacheIgnoredFiles>
  708. <progressUpdateIntervalS>5</progressUpdateIntervalS>
  709. <limitBandwidthInLan>false</limitBandwidthInLan>
  710. <minHomeDiskFree unit="%">1</minHomeDiskFree>
  711. <releasesURL>https://api.github.com/repos/syncthing/syncthing/releases?per_page=30</releasesURL>
  712. <overwriteRemoteDeviceNamesOnConnect>false</overwriteRemoteDeviceNamesOnConnect>
  713. <tempIndexMinBlocks>10</tempIndexMinBlocks>
  714. <defaultFolderPath>~</defaultFolderPath>
  715. </options>
  716. .ft P
  717. .fi
  718. .UNINDENT
  719. .UNINDENT
  720. .sp
  721. The \fBoptions\fP element contains all other global configuration options.
  722. .INDENT 0.0
  723. .TP
  724. .B listenAddress
  725. The listen address for incoming sync connections. See
  726. \fI\%Listen Addresses\fP for allowed syntax.
  727. .TP
  728. .B globalAnnounceServer
  729. A URI to a global announce (discovery) server, or the word \fBdefault\fP to
  730. include the default servers. Any number of globalAnnounceServer elements
  731. may be present. The syntax for non\-default entries is that of a HTTP or
  732. HTTPS URL. A number of options may be added as query options to the URL:
  733. \fBinsecure\fP to prevent certificate validation (required for HTTP URLs)
  734. and \fBid=<device ID>\fP to perform certificate pinning. The device ID to
  735. use is printed by the discovery server on startup.
  736. .TP
  737. .B globalAnnounceEnabled
  738. Whether to announce this device to the global announce (discovery) server,
  739. and also use it to look up other devices.
  740. .TP
  741. .B localAnnounceEnabled
  742. Whether to send announcements to the local LAN, also use such
  743. announcements to find other devices.
  744. .TP
  745. .B localAnnouncePort
  746. The port on which to listen and send IPv4 broadcast announcements to.
  747. .TP
  748. .B localAnnounceMCAddr
  749. The group address and port to join and send IPv6 multicast announcements on.
  750. .TP
  751. .B maxSendKbps
  752. Outgoing data rate limit, in kibibytes per second.
  753. .TP
  754. .B maxRecvKbps
  755. Incoming data rate limits, in kibibytes per second.
  756. .TP
  757. .B reconnectionIntervalS
  758. The number of seconds to wait between each attempt to connect to currently
  759. unconnected devices.
  760. .TP
  761. .B relaysEnabled
  762. When true, relays will be connected to and potentially used for device to device connections.
  763. .TP
  764. .B relayReconnectIntervalM
  765. Sets the interval, in minutes, between relay reconnect attempts.
  766. .TP
  767. .B startBrowser
  768. Whether to attempt to start a browser to show the GUI when Syncthing starts.
  769. .TP
  770. .B natEnabled
  771. Whether to attempt to perform a UPnP and NAT\-PMP port mapping for
  772. incoming sync connections.
  773. .TP
  774. .B natLeaseMinutes
  775. Request a lease for this many minutes; zero to request a permanent lease.
  776. .TP
  777. .B natRenewalMinutes
  778. Attempt to renew the lease after this many minutes.
  779. .TP
  780. .B natTimeoutSeconds
  781. When scanning for UPnP devices, wait this long for responses.
  782. .TP
  783. .B urAccepted
  784. Whether the user has accepted to submit anonymous usage data. The default,
  785. \fB0\fP, mean the user has not made a choice, and Syncthing will ask at some
  786. point in the future. \fB\-1\fP means no, a number above zero means that that
  787. version of usage reporting has been accepted.
  788. .TP
  789. .B urSeen
  790. The highest usage reporting version that has already been shown in the web GUI.
  791. .TP
  792. .B urUniqueID
  793. The unique ID sent together with the usage report. Generated when usage
  794. reporting is enabled.
  795. .TP
  796. .B urURL
  797. The URL to post usage report data to, when enabled.
  798. .TP
  799. .B urPostInsecurely
  800. When true, the UR URL can be http instead of https, or have a self\-signed
  801. certificate. The default is \fBfalse\fP\&.
  802. .TP
  803. .B urInitialDelayS
  804. The time to wait from startup to the first usage report being sent. Allows
  805. the system to stabilize before reporting statistics.
  806. .TP
  807. .B restartOnWakeup
  808. Whether to perform a restart of Syncthing when it is detected that we are
  809. waking from sleep mode (i.e. a folded up laptop).
  810. .TP
  811. .B autoUpgradeIntervalH
  812. Check for a newer version after this many hours. Set to zero to disable
  813. automatic upgrades.
  814. .TP
  815. .B upgradeToPreReleases
  816. If true, automatic upgrades include release candidates (see
  817. release\-channels).
  818. .TP
  819. .B keepTemporariesH
  820. Keep temporary failed transfers for this many hours. While the temporaries
  821. are kept, the data they contain need not be transferred again.
  822. .TP
  823. .B cacheIgnoredFiles
  824. Whether to cache the results of ignore pattern evaluation. Performance
  825. at the price of memory. Defaults to \fBfalse\fP as the cost for evaluating
  826. ignores is usually not significant.
  827. .TP
  828. .B progressUpdateIntervalS
  829. How often in seconds the progress of ongoing downloads is made available to
  830. the GUI.
  831. .TP
  832. .B limitBandwidthInLan
  833. Whether to apply bandwidth limits to devices in the same broadcast domain
  834. as the local device.
  835. .TP
  836. .B minHomeDiskFree
  837. The minimum required free space that should be available on the
  838. partition holding the configuration and index. Accepted units are \fB%\fP, \fBkB\fP,
  839. \fBMB\fP, \fBGB\fP and \fBTB\fP\&.
  840. .TP
  841. .B releasesURL
  842. The URL from which release information is loaded, for automatic upgrades.
  843. .TP
  844. .B alwaysLocalNet
  845. Network that should be considered as local given in CIDR notation.
  846. .TP
  847. .B overwriteRemoteDeviceNamesOnConnect
  848. If set, device names will always be overwritten with the name given by
  849. remote on each connection. By default, the name that the remote device
  850. announces will only be adopted when a name has not already been set.
  851. .TP
  852. .B tempIndexMinBlocks
  853. When exchanging index information for incomplete transfers, only take
  854. into account files that have at least this many blocks.
  855. .TP
  856. .B unackedNotificationID
  857. ID of a notification to be displayed in the web GUI. Will be removed once
  858. the user acknowledged it (e.g. an transition notice on an upgrade).
  859. .TP
  860. .B trafficClass
  861. Specify a type of service (TOS)/traffic class of outgoing packets.
  862. .TP
  863. .B weakHashSelectionMethod
  864. Specify whether weak hashing is used, possible options are
  865. \fBWeakHashAlways\fP, \fBWeakHashNever\fP and \fBWeakHashAuto\fP\&. Deciding
  866. automatically means running benchmarks at startup to decide whether the
  867. performance impact is acceptable (this is the default).
  868. .TP
  869. .B stunServer
  870. Server to be used for STUN, given as ip:port. The keyword \fBdefault\fP gets
  871. expanded to
  872. \fBstun.callwithus.com:3478\fP, \fBstun.counterpath.com:3478\fP,
  873. \fBstun.counterpath.net:3478\fP, \fBstun.ekiga.net:3478\fP,
  874. \fBstun.ideasip.com:3478\fP, \fBstun.internetcalls.com:3478\fP,
  875. \fBstun.schlund.de:3478\fP, \fBstun.sipgate.net:10000\fP,
  876. \fBstun.sipgate.net:3478\fP, \fBstun.voip.aebc.com:3478\fP,
  877. \fBstun.voiparound.com:3478\fP, \fBstun.voipbuster.com:3478\fP,
  878. \fBstun.voipstunt.com:3478\fP, \fBstun.voxgratia.org:3478\fP and
  879. \fBstun.xten.com:3478\fP (this is the default).
  880. .TP
  881. .B stunKeepaliveSeconds
  882. Interval in seconds between contacting a STUN server to
  883. maintain NAT mapping. Default is \fB24\fP and you can set it to \fB0\fP to
  884. disable contacting STUN servers.
  885. .TP
  886. .B kcpNoDelay, kcpUpdateIntervalMs, kcpFastResend, kcpCongestionControl, kcpSendWindowSize, kcpReceiveWindowSize
  887. Various KCP tweaking parameters.
  888. .TP
  889. .B defaultFolderPath
  890. The UI will propose to create new folders at this path. This can be disabled by
  891. setting this to an empty string.
  892. .UNINDENT
  893. .INDENT 0.0
  894. .TP
  895. .B setLowPriority
  896. Syncthing will attempt to lower its process priority at startup.
  897. Specifically: on Linux, set itself to a separate process group, set the
  898. niceness level of that process group to nine and the I/O priority to
  899. best effort level five; on other Unixes, set the process niceness level
  900. to nine; on Windows, set the process priority class to below normal. To
  901. disable this behavior, for example to control process priority yourself
  902. as part of launching Syncthing, set this option to \fBfalse\fP\&.
  903. .UNINDENT
  904. .SS Listen Addresses
  905. .sp
  906. The following address types are accepted in sync protocol listen addresses:
  907. .INDENT 0.0
  908. .TP
  909. .B Default listen addresses (\fBdefault\fP)
  910. This is equivalent to \fBtcp://0.0.0.0:22000\fP and
  911. \fBdynamic+https://relays.syncthing.net/endpoint\fP\&.
  912. .TP
  913. .B TCP wildcard and port (\fBtcp://0.0.0.0:22000\fP, \fBtcp://:22000\fP)
  914. These are equivalent and will result in Syncthing listening on all
  915. interfaces, IPv4 and IPv6, on the specified port.
  916. .TP
  917. .B TCP IPv4 wildcard and port (\fBtcp4://0.0.0.0:22000\fP, \fBtcp4://:22000\fP)
  918. These are equivalent and will result in Syncthing listening on all
  919. interfaces via IPv4 only.
  920. .TP
  921. .B TCP IPv4 address and port (\fBtcp4://192.0.2.1:22000\fP)
  922. This results in Syncthing listening on the specified address and port, IPv4
  923. only.
  924. .TP
  925. .B TCP IPv6 wildcard and port (\fBtcp6://[::]:22000\fP, \fBtcp6://:22000\fP)
  926. These are equivalent and will result in Syncthing listening on all
  927. interfaces via IPv6 only.
  928. .TP
  929. .B TCP IPv6 address and port (\fBtcp6://[2001:db8::42]:22000\fP)
  930. This results in Syncthing listening on the specified address and port, IPv6
  931. only.
  932. .TP
  933. .B Static relay address (\fBrelay://192.0.2.42:22067?id=abcd123...\fP)
  934. Syncthing will connect to and listen for incoming connections via the
  935. specified relay address.
  936. .INDENT 7.0
  937. .INDENT 3.5
  938. .SS Todo
  939. .sp
  940. Document available URL parameters.
  941. .UNINDENT
  942. .UNINDENT
  943. .TP
  944. .B Dynamic relay pool (\fBdynamic+https://192.0.2.42/relays\fP)
  945. Syncthing will fetch the specified HTTPS URL, parse it for a JSON payload
  946. describing relays, select a relay from the available ones and listen via
  947. that as if specified as a static relay above.
  948. .INDENT 7.0
  949. .INDENT 3.5
  950. .SS Todo
  951. .sp
  952. Document available URL parameters.
  953. .UNINDENT
  954. .UNINDENT
  955. .UNINDENT
  956. .SH SYNCING CONFIGURATION FILES
  957. .sp
  958. Syncing configuration files between devices (such that multiple devices are
  959. using the same configuration files) can cause issues. This is easy to do
  960. accidentally if you sync your home folder between devices. A common symptom
  961. of syncing configuration files is two devices ending up with the same Device ID.
  962. .sp
  963. If you want to use Syncthing to backup your configuration files, it is recommended
  964. that the files you are backing up are in a folder\-sendonly to prevent other
  965. devices from overwriting the per device configuration. The folder on the remote
  966. device(s) should not be used as configuration for the remote devices.
  967. .sp
  968. If you’d like to sync your home folder in non\-send only mode, you may add the
  969. folder that stores the configuration files to the ignore list\&.
  970. If you’d also like to backup your configuration files, add another folder in
  971. send only mode for just the configuration folder.
  972. .SH AUTHOR
  973. The Syncthing Authors
  974. .SH COPYRIGHT
  975. 2014-2019, The Syncthing Authors
  976. .\" Generated by docutils manpage writer.
  977. .