syncthing-networking.7 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. .\" Man page generated from reStructuredText.
  2. .
  3. .TH "SYNCTHING-NETWORKING" "7" "August 09, 2015" "v0.11" "Syncthing"
  4. .SH NAME
  5. syncthing-networking \- Firewall Setup
  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 PORT FORWARDS
  34. .sp
  35. If you have a NAT router which supports UPnP, the easiest way to get a working
  36. port forward is to make sure UPnP setting is enabled on both Syncthing and the
  37. router – Syncthing will try to handle the rest. If it succeeds you will see a
  38. message in the console saying:
  39. .INDENT 0.0
  40. .INDENT 3.5
  41. .sp
  42. .nf
  43. .ft C
  44. Created UPnP port mapping for external port XXXXX on UPnP device YYYYY.
  45. .ft P
  46. .fi
  47. .UNINDENT
  48. .UNINDENT
  49. .sp
  50. If this is not possible or desirable you should set up a port forward for port
  51. \fB22000/TCP\fP, or the port set in the \fISync Protocol Listen Address\fP setting.
  52. The external forwarded port and the internal destination port has to be the same
  53. (i.e. 22000/TCP).
  54. .sp
  55. Communication in Syncthing works both ways. Therefore if you set up port
  56. forwards for one device, other devices will be able to connect to it even when
  57. they are behind a NAT network or firewall.
  58. .SH LOCAL FIREWALL
  59. .sp
  60. If your PC has a local firewall, you will need to open the following ports for
  61. incoming traffic:
  62. .INDENT 0.0
  63. .IP \(bu 2
  64. Port \fB22000/TCP\fP (or the actual listening port if you have changed
  65. the \fISync Protocol Listen Address\fP setting.)
  66. .IP \(bu 2
  67. Port \fB21025/UDP\fP (for discovery broadcasts on IPv4)
  68. .IP \(bu 2
  69. Port \fB21026/UDP\fP (for discovery multicasts on IPv6)
  70. .UNINDENT
  71. .SH REMOTE WEB GUI
  72. .sp
  73. To be able to access the web GUI from other computers, you need to change the
  74. \fIGUI Listen Address\fP setting from the default \fB127.0.0.1:8384\fP to
  75. \fB0.0.0.0:8384\fP\&. You also need to open the port in your local firewall if you
  76. have one.
  77. .SS Tunneling via SSH
  78. .sp
  79. If you have SSH access to the machine running Syncthing but would rather not
  80. open the web GUI port to the outside world, you can access it through a SSH
  81. tunnel instead. You can start a tunnel with a command like the following:
  82. .INDENT 0.0
  83. .INDENT 3.5
  84. .sp
  85. .nf
  86. .ft C
  87. ssh \-L 9999:localhost:8384 machine
  88. .ft P
  89. .fi
  90. .UNINDENT
  91. .UNINDENT
  92. .sp
  93. This will bind to your local port 9999 and forward all connections from there to
  94. port 8384 on the target machine. This still works even if Syncthing is bound to
  95. listen on localhost only.
  96. .sp
  97. You can forward multiple ports corresponding to many machines this way, but
  98. because Syncthing uses session cookies for the entire domain (i.e. your local
  99. machine), you will need to connect to each control panel in a separate browser
  100. instance or explicitly issue a browser reload when switching between them.
  101. .SH AUTHOR
  102. The Syncthing Authors
  103. .SH COPYRIGHT
  104. 2015, The Syncthing Authors
  105. .\" Generated by docutils manpage writer.
  106. .