I’m trying to use syncthing to sync files between my phone and my laptop, both of which are connected to my school’s wifi.
What’s strange is that they don’t seem to want to connect over LAN. For example, if you look here on the syncthing docs you can see that syncthing listens by default on the addresses tcp://0.0.0.0:22000 and quic://0.0.0.0:22000
I think the tcp and quic parts of those urls are a reference to the problem. When I start an HTTP server on my laptop I can access it through my phone and then acess my laptop’s files (on 0.0.0:22000). Same with FTP server. Using my laptop’s local IP.
So what exactly is the problem? The two devices are aware of each other, they’ve discovered each other and are on the other’s list. They just stay in the “disconnected” state.
I don’t have any tools to test whether my laptop or phone really is unable to use tcp and quic. If anyone knows one, that would be helpful, too.
I think it is discovery related, I set the listening address on my laptop to tcp://0.0.0.0:8888 and the corresponding address on my phone to its local address plus port number, syncing seems to work.
So it seems like syncthing can’t create a LAN connection using global discovery, because info about local IP address isn’t sent to the discovery server? That makes sense I suppose. (it would be nice to have some kind of error message about it, though)
If you hard code the IP address for the other server on each device, your problem should resolve itself. You don’t want to involve relay servers if you don’t have to.