Syncthing under FreeBSD 10.0 guest in Virtualbox / disconnected

Hi there,

thank you very much for Syncthing. I installed Syncthing (now v 0.9.17) under my FreeBSD 10.0 guest on Virtualbox 4.3.16 in Mac OS X, added two more nodes (between which syncing works well), but when I start Syncthing on my Virtualbox guest I get (the IDs changed):

[monitor] 19:22:31 INFO: Starting syncthing [4KSSL] 19:22:31 INFO: syncthing v0.9.17 (go1.3.1 freebsd-amd64 default) jenkins@build.syncthing.net 2014-09-18 10:01:08 UTC [4KSSL] 19:22:31 INFO: My ID: AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA [4KSSL] 19:22:31 INFO: Starting web GUI on http://127.0.0.1:8080/ [4KSSL] 19:22:32 INFO: Performing initial repository scan [4KSSL] 19:22:35 INFO: No UPnP gateway detected [4KSSL] 19:22:35 INFO: Starting local discovery announcements [4KSSL] 19:22:35 INFO: Local discovery over IPv6 unavailable [4KSSL] 19:22:35 INFO: Starting global discovery announcements [4KSSL] 19:22:35 OK: Ready to synchronize default (read-write) [4KSSL] 19:22:35 INFO: Node BBBBBBBBBBBBBBBBBBBBB is “bbbb” at [dynamic] [4KSSL] 19:22:35 INFO: Node CCCCCCCCCCCCCCCCCCCC is “cccc” at [dynamic] [4KSSL] 19:22:35 INFO: Node AAAAAAAAAAAAAAAAAAAAAA is “aaaa” at [dynamic] [4KSSL] 19:22:35 INFO: Starting usage reporting

and the two added nodes stay disconnected on my FreeBSD client. There are obviously some problems showing up above. What could have went wrong here? Is it the network configuration in Virtualbox that causes this problem?

Thank you very much for any answer and thank you very much for your work…

If you manually enter the ip for a node, rather than using local discovery, can it connect? (for either direction)

Wow, when I put in the local ip address (the other nodes are laptops using the same router), then I can connect. Could it be that there is a problem with ipv6 since it says that the discovery does not work? When I remember this right, I can ssh to the hosts ipv6 address but not back (or it is the other way around, I have to test this again :))…

If you run syncthing with STTRACE=net it should tell you more.

Thank you for your reply. When using ‘dynamic’ again instead of the local ips of the other nodes and when starting syncthing using SSTRACE=net on the FreeBSD guest, I get:

[monitor] 2014/09/21 14:02:50.989516 monitor.go:63: INFO: Starting syncthing [4KSSL] 2014/09/21 14:02:51.778165 main.go:312: INFO: syncthing v0.9.17 (go1.3.1 freebsd-amd64 default) jenkins@build.syncthing.net 2014-09-18 10:01:08 UTC [4KSSL] 2014/09/21 14:02:51.779509 main.go:313: INFO: My ID: AAAAAAAAAAAAAAAAAAAAAAAAAAAAA [4KSSL] 2014/09/21 14:02:51.810663 main.go:482: INFO: Starting web GUI on http://127.0.0.1:8080/ [4KSSL] 2014/09/21 14:02:52.438767 main.go:512: INFO: Performing initial repository scan [4KSSL] 2014/09/21 14:02:55.460817 main.go:639: INFO: No UPnP gateway detected [4KSSL] 2014/09/21 14:02:55.461958 main.go:641: DEBUG: UPnP: read udp4 0.0.0.0:10271: i/o timeout [4KSSL] 2014/09/21 14:02:55.462849 main.go:987: INFO: Starting local discovery announcements [4KSSL] 2014/09/21 14:02:55.463629 discover.go:84: INFO: Local discovery over IPv6 unavailable [4KSSL] 2014/09/21 14:02:55.465065 main.go:992: INFO: Starting global discovery announcements [4KSSL] 2014/09/21 14:02:55.466958 main.go:567: OK: Ready to synchronize default (read-write) [4KSSL] 2014/09/21 14:02:55.468684 main.go:583: INFO: Node BBBBBBBBBBBBBBBBBBBBBBBBBB is “bbbb” at [dynamic] [4KSSL] 2014/09/21 14:02:55.471605 main.go:583: INFO: Node CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC is “ccccc” at [dynamic] [4KSSL] 2014/09/21 14:02:55.471702 main.go:583: INFO: Node AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA is “aaaa” at [dynamic] [4KSSL] 2014/09/21 14:02:55.471814 main.go:852: DEBUG: listening on 0.0.0.0:22000 [4KSSL] 2014/09/21 14:02:55.471880 usage_report.go:97: INFO: Starting usage reporting

Having a speedport W502V modem, I have no global ipv6 support. But when the two other nodes in my local network get started, the message ’Local discovery over IPv6 unavailable’ doesn’t show up.

So you have ipv4 discovery not working, for some reason: “UPnP: read udp4 0.0.0.0:10271: i/o timeout” and ipv6 discovery unavailable. I don’t know why that is though, this is likely operating system level rather than syncthing level. Firewall? Restricted virtual network card?

Thank you again for your answer. Sorry, I am quite new to this stuff :slight_smile: and to Unix, had I read more about networking, I could have seen the problem too. My FreeBSD guest has ipv4 discovery enabled: root# sysctl net.inet.tcp.path_mtu_discovery net.inet.tcp.path_mtu_discovery: 1 And it seems that I have no firewall running. But I came across some posts that suggest that Virtualbox under Mavericks could be responsible here. I will research further and post the answer here if I am successful in finding the solution.

It works, hurra! It wasn’t an error in virtualbox, it was in principle me not reading enough the virtualbox manual :smile: . I use NAT networking in Virtualbox and I had simply to forward the port 22000 from the host to my FreeBSD guest as it is suggested somewhere here in the documentation. Thank you so much for syncthing from an enthusiastic FreeBSD user :).

If you’ve set up VirtualBox with a NAT network connection, it’s technically on a separate network segment from the rest of your network, so local discovery will not work. If you use a bridged connection, it might (but I’ve seen issues with broadcasts and multicasts with Virtualbox, I forget what usually works and what doesn’t). The IPv6 warning is not an issue, it’ll still run over IPv4.