# "Failed to exchange Hello messages" from Android nodes?

**URL:** https://forum.syncthing.net/t/failed-to-exchange-hello-messages-from-android-nodes/17201
**Category:** Support
**Created:** [August 8, 2021, 7:21pm UTC](https://forum.syncthing.net/t/failed-to-exchange-hello-messages-from-android-nodes/17201 "2021-08-08T19:21:07Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![andrekir](https://forum.syncthing.net/user_avatar/forum.syncthing.net/andrekir/32/10595_2.png) [@andrekir](https://forum.syncthing.net/u/andrekir)
#### Post date: [August 8, 2021, 7:21pm UTC](https://forum.syncthing.net/t/failed-to-exchange-hello-messages-from-android-nodes/17201/1 "2021-08-08T19:21:07Z")

</div>

Greetings friends!

Ran into some error messages trying to migrate into a new Syncthing node inside a Docker container with all files encrypted. Haven’t noticed any consequence besides the error message itself, and seems to come only from my Android nodes.

What could be causing this? Happy to provide any more info if needed.

- Logs are from a fresh install of an encrypted “cloud” Syncthing accessed through public IP (99.99.99.99), port forwarded into a Docker container in bridge network mode.

- 2 Syncthing on Android produce the “Failed to exchange Hello messages” in the logs.
- 1 Syncthing on MacOs with identical setup did not produce the messages.

All versions are 1.18.1

2021-08-08 18:21:58 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 172.17.0.2:22000-99.99.99.99:42290/tcp-server/TLS1.3-TLS\_AES\_128\_GCM\_SHA256: write tcp 172.17.0.2:22000-\>99.99.99.99:42290: write: connection reset by peer 2021-08-08 18:23:05 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 172.17.0.2:22000-99.99.99.99:42293/tcp-server/TLS1.3-TLS\_AES\_128\_GCM\_SHA256: write tcp 172.17.0.2:22000-\>99.99.99.99:42293: write: connection reset by peer 2021-08-08 18:24:11 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 172.17.0.2:22000-99.99.99.99:42298/tcp-server/TLS1.3-TLS\_AES\_128\_GCM\_SHA256: write tcp 172.17.0.2:22000-\>99.99.99.99:42298: write: connection reset by peer 2021-08-08 18:25:17 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 172.17.0.2:22000-99.99.99.99:42302/tcp-server/TLS1.3-TLS\_AES\_128\_GCM\_SHA256: write tcp 172.17.0.2:22000-\>99.99.99.99:42302: write: connection reset by peer 2021-08-08 18:26:24 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 172.17.0.2:22000-99.99.99.99:42307/tcp-server/TLS1.3-TLS\_AES\_128\_GCM\_SHA256: write tcp 172.17.0.2:22000-\>99.99.99.99:42307: write: connection reset by peer 2021-08-08 18:27:30 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 172.17.0.2:22000-99.99.99.99:42312/tcp-server/TLS1.3-TLS\_AES\_128\_GCM\_SHA256: write tcp 172.17.0.2:22000-\>99.99.99.99:42312: write: connection reset by peer 2021-08-08 18:28:02 Connection to ANDROID2-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 172.17.0.2:22000-99.99.99.99:59883/tcp-server/TLS1.3-TLS\_AES\_128\_GCM\_SHA256 closed: read timeout 2021-08-08 18:28:37 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 172.17.0.2:22000-99.99.99.99:42319/tcp-server/TLS1.3-TLS\_AES\_128\_GCM\_SHA256: write tcp 172.17.0.2:22000-\>99.99.99.99:42319: write: connection reset by peer 2021-08-08 18:29:43 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 172.17.0.2:22000-99.99.99.99:42322/tcp-server/TLS1.3-TLS\_AES\_128\_GCM\_SHA256: write tcp 172.17.0.2:22000-\>99.99.99.99:42322: write: connection reset by peer 2021-08-08 18:30:49 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 172.17.0.2:22000-99.99.99.99:42328/tcp-server/TLS1.3-TLS\_AES\_128\_GCM\_SHA256: write tcp 172.17.0.2:22000-\>99.99.99.99:42328: write: connection reset by peer

Similar messages appear every other minute.

---

<div class="post-metadata">

### Author: ![AudriusButkevicius](https://forum.syncthing.net/user_avatar/forum.syncthing.net/audriusbutkevicius/32/277_2.png) [@AudriusButkevicius](https://forum.syncthing.net/u/AudriusButkevicius)
#### Post date: [August 8, 2021, 8:51pm UTC](https://forum.syncthing.net/t/failed-to-exchange-hello-messages-from-android-nodes/17201/2 "2021-08-08T20:51:08Z")

</div>

Check the logs on the other side, but most likely some sort of connection issue/firewall.

---

<div class="post-metadata">

### Author: ![andrekir](https://forum.syncthing.net/user_avatar/forum.syncthing.net/andrekir/32/10595_2.png) [@andrekir](https://forum.syncthing.net/u/andrekir)
#### Post date: [August 8, 2021, 9:20pm UTC](https://forum.syncthing.net/t/failed-to-exchange-hello-messages-from-android-nodes/17201/3 "2021-08-08T21:20:29Z")

</div>

Nothing. Last log message on ANDROID1 side:

`2021-08-08 12:54:45 Sent usage report (version 3)`

While on the Encrypted Syncthing side every other minute:

`2021-08-08 21:12:29 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 172.17.0.2:22000-99.99.99.99:55684/tcp-server/TLS1.3-TLS_AES_128_GCM_SHA256: write tcp 172.17.0.2:22000->99.99.99.99:55684: write: connection reset by peer`

Question: Why is port 55684 used here for 99.99.99.99 instead of 22000? (172.17.0.2:22000-\>99.99.99.99:55684)

---

<div class="post-metadata">

### Author: ![Nummer378](https://forum.syncthing.net/user_avatar/forum.syncthing.net/nummer378/32/5958_2.png) [@Nummer378](https://forum.syncthing.net/u/Nummer378)
#### Post date: [August 8, 2021, 9:55pm UTC](https://forum.syncthing.net/t/failed-to-exchange-hello-messages-from-android-nodes/17201/4 "2021-08-08T21:55:42Z")

</div>

> [@andrekir](#):
>
> Question: Why is port 55684 used here for 99.99.99.99 instead of 22000? (172.17.0.2:22000-\>99.99.99.99:55684)

TCP client vs TCP server. Syncthing’s TCP server listens on port 22000 by default, but for outgoing TCP connections the OS kernel chooses a port (except if syncthing also reuses the server port for outgoing connections, which may not be supported in all scenarios).

---

<div class="post-metadata">

### Author: ![andrekir](https://forum.syncthing.net/user_avatar/forum.syncthing.net/andrekir/32/10595_2.png) [@andrekir](https://forum.syncthing.net/u/andrekir)
#### Post date: [August 8, 2021, 10:24pm UTC](https://forum.syncthing.net/t/failed-to-exchange-hello-messages-from-android-nodes/17201/5 "2021-08-08T22:24:54Z")

</div>

> [@Nummer378](#):
>
> TCP client vs TCP server. Syncthing’s TCP server listens on port 22000 by default, but for outgoing TCP connections the OS kernel chooses a port (except if syncthing also reuses the server port for outgoing connections, which may not be supported in all scenarios).

Interesting. This could be due to a double NAT from the Network bridge added for the Docker container (subnet 172.17.0.X). But why would the MacOS client with the same settings be unaffected?

Hopefully someone with more knowledge than me on Syncthing running in Docker containers can chime in. Maybe “network\_mode: host” is mandatory using a public IP with port forwarding?

---

<div class="post-metadata">

### Author: ![andrekir](https://forum.syncthing.net/user_avatar/forum.syncthing.net/andrekir/32/10595_2.png) [@andrekir](https://forum.syncthing.net/u/andrekir)
#### Post date: [August 12, 2021, 12:32am UTC](https://forum.syncthing.net/t/failed-to-exchange-hello-messages-from-android-nodes/17201/6 "2021-08-12T00:32:54Z")

</div>

No change after setting Docker Compose to use “network\_mode: host”.

Of total 3 devices connected (same settings) only occurs with ANDROID1.

```
2021-08-12 00:21:17 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 192.168.1.99:22000-99.99.99.99:55000/tcp-server/TLS1.3-TLS_AES_128_GCM_SHA256: write tcp 192.168.1.99:22000->99.99.99.99:55000: write: connection reset by peer
2021-08-12 00:22:23 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 192.168.1.99:22000-99.99.99.99:55074/tcp-server/TLS1.3-TLS_AES_128_GCM_SHA256: write tcp 192.168.1.99:22000->99.99.99.99:55074: write: connection reset by peer
2021-08-12 00:23:35 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 192.168.1.99:22000-99.99.99.99:55124/tcp-server/TLS1.3-TLS_AES_128_GCM_SHA256: write tcp 192.168.1.99:22000->99.99.99.99:55124: write: connection reset by peer
2021-08-12 00:24:41 Failed to exchange Hello messages with ANDROID1-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX-XXXXXXX at 192.168.1.99:22000-99.99.99.99:55008/tcp-server/TLS1.3-TLS_AES_128_GCM_SHA256: write tcp 192.168.1.99:22000->99.99.99.99:55008: write: connection reset by peer

```

Moved all devices into a local network (192.168.X.X), changed settings on both ends and still getting spammed “Failed to exchange Hello messages” for ANDROID1 on my public IP (99.99.99.99 and not 192.168.X.X).

Weird. Running out of ideas.

---

<div class="post-metadata">

### Author: ![bt90](https://forum.syncthing.net/user_avatar/forum.syncthing.net/bt90/32/18565_2.png) [@bt90](https://forum.syncthing.net/u/bt90)
#### Post date: [August 12, 2021, 5:30am UTC](https://forum.syncthing.net/t/failed-to-exchange-hello-messages-from-android-nodes/17201/7 "2021-08-12T05:30:13Z")

</div>

Android version? The reason i’m asking is that Android 11 breaks local discovery.

It’s fixed in the forked app but the issue isn’t solved in the official app yet.

> <https://github.com/Catfriend1/syncthing-android/pull/800>
>
> Purpose:
> \- Acquire MulticastLock for local discovery to work on Android 11 (fix…es #735)
> 
> Solution:
> \- https://stackoverflow.com/questions/13221736/android-device-not-receiving-multicast-package

> <https://github.com/syncthing/syncthing-android/issues/1663>
>
> Android has new restrictions in 11 (that might or might not yet apply to syncthi…ng-android targeting 10) regarding multi/broadcasts that prevent local discovery as it stands.
> 
> There's a fix in catfriends fork:  
> https://forum.syncthing.net/t/local-discovery-problem-on-android-11/16093/18  
> https://github.com/golang/go/issues/40569#issuecomment-841846847  
> Something about acquiring some lock in the wrapper code.
> 
> I previously expected the solution to be doing local discover in java code, and then adding the discovered addresses to the device through the config. Unless there's any major drawbacks in catfriends method, that variant is definitely preferable (because simpler).

---

<div class="post-metadata">

### Author: ![andrekir](https://forum.syncthing.net/user_avatar/forum.syncthing.net/andrekir/32/10595_2.png) [@andrekir](https://forum.syncthing.net/u/andrekir)
#### Post date: [August 12, 2021, 12:53pm UTC](https://forum.syncthing.net/t/failed-to-exchange-hello-messages-from-android-nodes/17201/8 "2021-08-12T12:53:34Z")

</div>

> [@bt90](#):
>
> Android version?

Android ver 8 and 9.

---

<div class="post-metadata">

### Author: ![system](https://forum-uploads.syncthingcdn.net/original/2X/0/0b50e0a202b22ae6a67190759e8c868805b8ed9f.png) [@system](https://forum.syncthing.net/u/system)
#### Post date: [September 11, 2021, 12:54pm UTC](https://forum.syncthing.net/t/failed-to-exchange-hello-messages-from-android-nodes/17201/9 "2021-09-11T12:54:02Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
