Devices showing Disconnected on same LAN

Just installed SyncThing on my laptop (Windows 8.1) and Android (Galaxy S4 jellybean), neither can “see” the other - both showing disconnected (I’ve setup one folder to sync).

Both devices are on the same LAN - verified both show in router.

Router has UPnP enabled, and is showing port opened for SyncThing on laptop (SyncThing is reporting success for UPnP).

Firewall on laptop has SyncThing enabled (permitted on both public and private nets)

The laptop shows Global Discovery:OK

Phone shows Global Discovery: 0/1 (what does this indicate?)

Since neither device will see the other, I tried configuring the devices in ST with their actual IP’s, assuming it was a discovery problem. They still show disconnected/never seen.

If there’s some documentation that explains this and I just missed it, please point me in the right direction. It seems like ST should be pretty straightforward, and I must be missing a config step.


Can you actually ping the other device?

LOL…good basic question, but yes, I can ping the devices. (As an IT guy, I can appreciate being asked to start with the basics).

Rebooted the phone and now it shows “Global Discovery: Ok”, so that’s something.

Since both devices are now showing Discovery is working, I’ve reconfigured both to use dynamic discovery for target IP’s.

Unfortunately, laptop and phone still both show the other as not connected. :-/

I’m not missing a step am I? All you do is install the “server” component/client on the PC, and th eclient on Android, share a folder GUID and ta-da…right? Discovery should enable the devices to find each other’s address?

Interestingly, this documentation says the forwarded ports on the router must match externally/internally…i.e. they need to be 22000/22000. My UPnP config shows the external port was different from the internal for both devices. Internall both were using 22000, but externally something completely different, yet both devices reported connectivity to Global Discovery.

As a test, I’m going to manually configure both devices to use different ports (22100 and 22200 respectively) and manually configure port forwarding on the router so the external and internal ports match for each device (e.g. laptop gets 22100 and phone gets 22200). Maybe there’s a UPnP failure (not that I’m very fond of UPnP anyway…but what you gonna do when you need dynamic allocation?).



Even after manually configuring the router to use specific ports for each device, and disabling UPNP in Syncthing on each device, devices still don’t see each other.

Taking Android out of the loop, I’m now trying between my desktop (Windows 7, firewall disabled) and my laptop (Win8.1, firewall enabled and properlyy configured).

Both machines report “OK” for Global discovery, but when I add them to each other’s config and try to share a folder it shows “Disconnected” on both.

What could I possibly be missing at this point? I have a simple network (desktop, 2 laptops, iPad, 2 Androids, 1 Netgear router/wifi access point, cable modem).

Frustrating to have spent 4 hours on this with no success for basic functions. Sigh.

So manual port mapping will only work if local and remote ports are the same (as syncthing is unaware what the external port is, hence advertises the internal one).

You can run syncthing with STTRACE=discovery which will show you some discovery info, but it’s very strange that the devices cannot find each other over lan.

Also, if you setup IPs and ports manually, it should defenately work, unleas you setup something wrong. I suggest you join IRC so I can help you out further or post some screenshots of you config tabs.

Thanks for verifying how I thought it worked. Seems this is one aspect which may need some work - either the UPnP component of ST isn’t working correctly, or there’s a problem with UPnP in my router. Would be interested to hear from others who are using multiple devices. I never studied up on exactly how UPnP is supposed to work.

I’ve completed manual port forwards for all devices, other than the Android it fixed my problems.

For the Android it took a couple reboots after wiping the config, reconfiguring it’s port, reconfiguring the router port forwarding and resetting the sync folders in ST. Now it seems to work.

Thanks for everyone’s help - the quick response is very much appreciated.

Using ST in the LAN doesn’t need any Port-Forwarding or UPnP. I’ve had setup my devices with local discovery and in the settings and in the ‘Adress’-Field of the remote device ‘dynamic’ and it worked … I didn’t need to touch ther firewall (WIN7 64 Pro)

Have you read ? After wich point of the explanation is it not as expectedt ?

Just for the record, there is a multicast weirdness on Windows which sometimes breaks UPnP.

Sorry I wasn’t clear about the port forwarding/UPnP issue - I think I focused on the ports when Discovery was showing as failing on different devices (since discovery was failing internally as well). When I noticed the router had a different external port than internal for UPnP-configured forwarding, I wondered why that happened when the documentation specified the same port externally/internally. Clearly UPnP isn’t the most robust protocol (or Netgear’s implementation is less than great).

I’d read the Getting Started guide, but it’s truly a “getting started” guide, not an architectural overview, so while it got me started, it wasn’t going to provide much insight into why certain aspects weren’t working as expected.

It does seem odd that sync wouldn’t work locally, regardless of the port forwarding. At this point I think there were a couple issues occurring simultaneously, which I mistook for having a common cause (seeing discovery was failing took me down the path of resolving that issue, then I got hungup on port forwarding issues).

In hindsight, I should’ve left the Android issue and moved to testing between the two pc’s first, and then worked on Android.

It’s all working now - local sync between 2 PC’s and an Android, even with the Android on 4G.

In the end, I’d say the Android’s local-sync problem was a fluke, and that for whatever reason a reset of ST settings and (another) reboot of the phone seemed to resolve the local sync issues. Manually configuring port forwarding resolved the other sync issues (though it seems my local sync doesn’t work unless the ports are properly forwarded…as if my devices are relying on global discovery and local discovery is failing - I’ll have to research that some more).

I have to say, I like that you have to enable the sync on both ends before it can work. Once I get my sync plan worked out, it’ll be interesting to see how ST does for battery power on my Galaxy. I’ve already throttled the sync for photos so it doens’t hammer the phone when I’m actually using it.

Thanks again for the very responsive help. Looks like ST has a good community behind it already - hopefully it’ll help ST continue to grow.

Same internal and external port apply only on manual portforwarding, not UPnP, as

said before. I don’t know how UPnP works, but I suspect that it somehow report used internal/external ports back to device which requested UPnP.

Now that’s a detail with UPnP/Port Forwarding that I didn’t realize (and makes sense with manual forwarding) - not knowing the internals of UPnP I didn’t realize it reports the external to the requestor so it can transmit that to a target. Of course in hindsight this makes sense, as I recall there being some kind of malware a couple years ago that abused this feature.

Thanks for the followup - it really helps to hash this stuff out. Perhaps a clarification on the wiki page would be useful (or did I just not read it that closely?).