# Router repeatedly logs failed to set write deadline, connection is fully closed when short-lived client connections (ProxySQL health checks) close

**URL:** <https://openziti.discourse.group/t/router-repeatedly-logs-failed-to-set-write-deadline-connection-is-fully-closed-when-short-lived-client-connections-proxysql-health-checks-close/5313>\
**Category:** Uncategorized\
**Created:** [November 7, 2025, 12:34pm UTC](https://openziti.discourse.group/t/router-repeatedly-logs-failed-to-set-write-deadline-connection-is-fully-closed-when-short-lived-client-connections-proxysql-health-checks-close/5313 "2025-11-07T12:34:20Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![charmpeach](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/charmpeach/32/3900_2.png) [@charmpeach](https://openziti.discourse.group/u/charmpeach)\
**Post date:** [November 7, 2025, 12:34pm UTC](https://openziti.discourse.group/t/router-repeatedly-logs-failed-to-set-write-deadline-connection-is-fully-closed-when-short-lived-client-connections-proxysql-health-checks-close/5313/1 "2025-11-07T12:34:20Z")

</div>

**Describe the bug**

Our edge routers emit an `error` every ~15 seconds:

```auto
{"error":null,"file":"github.com/openziti/ziti/router/xgress_common/connection.go:222","func":"github.com/openziti/ziti/router/xgress_common.(*XgressConn).ReadPayload","level":"error","msg":"failed to set write deadline, connection is fully closed"}

```

This correlates with short-lived connections created by **ProxySQL** health checks. When we stop ProxySQL monitoring, the router errors stop immediately. Business traffic is unaffected, but the router logs are noisy and make operational alerting harder.

**Environment**

- Controller: v1.7.1 (Docker)

- Routers:

**What happened**

- ProxySQL monitoring (default or similar intervals) opens short connections to database backends that traverse Ziti.

- On the router, we see the error above every ~15s (aligned with cleanup/health intervals).

- Stopping ProxySQL monitoring removes the error entirely. Restarting it brings the error back.

---

<div class="post-metadata">

**Author:** ![discourse\_ai\_spam](https://avatars.discourse-cdn.com/v4/letter/d/c68b51/32.png) [@discourse\_ai\_spam](https://openziti.discourse.group/u/discourse_ai_spam)\
**Post date:** [November 7, 2025, 1:35pm UTC](https://openziti.discourse.group/t/router-repeatedly-logs-failed-to-set-write-deadline-connection-is-fully-closed-when-short-lived-client-connections-proxysql-health-checks-close/5313/2 "2025-11-07T13:35:06Z")

</div>



---

<div class="post-metadata">

**Author:** ![system](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/system/32/1_2.png) [@system](https://openziti.discourse.group/u/system)\
**Post date:** [November 7, 2025, 1:58pm UTC](https://openziti.discourse.group/t/router-repeatedly-logs-failed-to-set-write-deadline-connection-is-fully-closed-when-short-lived-client-connections-proxysql-health-checks-close/5313/3 "2025-11-07T13:58:39Z")

</div>



---

<div class="post-metadata">

**Author:** ![TheLumberjack](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/thelumberjack/32/113_2.png) [@TheLumberjack](https://openziti.discourse.group/u/TheLumberjack)\
**Post date:** [November 7, 2025, 1:59pm UTC](https://openziti.discourse.group/t/router-repeatedly-logs-failed-to-set-write-deadline-connection-is-fully-closed-when-short-lived-client-connections-proxysql-health-checks-close/5313/4 "2025-11-07T13:59:17Z")

</div>

Hi @charmpeach welcome to OpenZiti! I see you deleted your post, just checking in that you solved the issue?

---

<div class="post-metadata">

**Author:** ![plorenz](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/plorenz/32/54_2.png) [@plorenz](https://openziti.discourse.group/u/plorenz)\
**Post date:** [November 7, 2025, 3:23pm UTC](https://openziti.discourse.group/t/router-repeatedly-logs-failed-to-set-write-deadline-connection-is-fully-closed-when-short-lived-client-connections-proxysql-health-checks-close/5313/5 "2025-11-07T15:23:25Z")

</div>

Note that there's a PR up to drop this error to debug: [connect events test by plorenz · Pull Request #3347 · openziti/ziti · GitHub](https://github.com/openziti/ziti/pull/3347/files#diff-fd4fe69aa23b32eb5afafc23a971a668cb7857d8bbbf63e84fec58c27f904ef9R222)

---

<div class="post-metadata">

**Author:** ![charmpeach](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/charmpeach/32/3900_2.png) [@charmpeach](https://openziti.discourse.group/u/charmpeach)\
**Post date:** [November 8, 2025, 10:34am UTC](https://openziti.discourse.group/t/router-repeatedly-logs-failed-to-set-write-deadline-connection-is-fully-closed-when-short-lived-client-connections-proxysql-health-checks-close/5313/6 "2025-11-08T10:34:17Z")

</div>

Thx for reply! I recover the post.

Seems a bug that proxysql monitor connect and quit will cause a error in ziti.
