From 2447865167021baf1665755e4377014b3a3b203d Mon Sep 17 00:00:00 2001 From: Niek van der Maas Date: Thu, 27 Aug 2026 14:46:27 +0200 Subject: [PATCH 1/2] openthread_border_router: retry unavailable network RCPs --- openthread_border_router/CHANGELOG.md | 4 ++++ openthread_border_router/config.yaml | 2 +- .../rootfs/etc/s6-overlay/s6-rc.d/socat-otbr-tcp/run | 9 ++++++--- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/openthread_border_router/CHANGELOG.md b/openthread_border_router/CHANGELOG.md index a01692f48..96403acf4 100644 --- a/openthread_border_router/CHANGELOG.md +++ b/openthread_border_router/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## 3.1.2 + +- Keep retrying unavailable network RCPs without crashing the app + ## 3.1.1 - Bump beta to OTBR POSIX version d83ddc62 to test ePSKc / Thread 1.4 Credentials Sharing support ahead of the upstream `release-v2026.09.0` tag diff --git a/openthread_border_router/config.yaml b/openthread_border_router/config.yaml index cf5038cdf..3bf4813e9 100644 --- a/openthread_border_router/config.yaml +++ b/openthread_border_router/config.yaml @@ -1,5 +1,5 @@ --- -version: 3.1.1 +version: 3.1.2 breaking_versions: [3.0.0] slug: openthread_border_router name: OpenThread Border Router diff --git a/openthread_border_router/rootfs/etc/s6-overlay/s6-rc.d/socat-otbr-tcp/run b/openthread_border_router/rootfs/etc/s6-overlay/s6-rc.d/socat-otbr-tcp/run index c81a9ef86..c0023d669 100755 --- a/openthread_border_router/rootfs/etc/s6-overlay/s6-rc.d/socat-otbr-tcp/run +++ b/openthread_border_router/rootfs/etc/s6-overlay/s6-rc.d/socat-otbr-tcp/run @@ -10,6 +10,9 @@ declare network_device network_device=$(bashio::config 'network_device') bashio::log.info "Starting socat TCP client for OTBR daemon..." -exec s6-notifyoncheck -d -s 300 -w 300 \ - "/usr/bin/socat" -d pty,raw,echo=0,link=/tmp/ttyOTBR,ignoreeof \ - "tcp:${network_device}" +# Connect before creating the PTY so readiness is only reported when the +# network RCP is reachable. Keep both connection attempts and readiness checks +# running during an outage. +exec s6-notifyoncheck -d -s 300 -w 300 -n 0 \ + "/usr/bin/socat" -d "tcp:${network_device},forever,interval=10" \ + pty,raw,echo=0,link=/tmp/ttyOTBR,ignoreeof From 5305f9f25104dc13611a5d53d72776ae0e7b2e57 Mon Sep 17 00:00:00 2001 From: Niek van der Maas Date: Thu, 27 Aug 2026 14:57:07 +0200 Subject: [PATCH 2/2] openthread_border_router: Bound network RCP connect attempts --- .../rootfs/etc/s6-overlay/s6-rc.d/socat-otbr-tcp/run | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/openthread_border_router/rootfs/etc/s6-overlay/s6-rc.d/socat-otbr-tcp/run b/openthread_border_router/rootfs/etc/s6-overlay/s6-rc.d/socat-otbr-tcp/run index c0023d669..bde8f7ab2 100755 --- a/openthread_border_router/rootfs/etc/s6-overlay/s6-rc.d/socat-otbr-tcp/run +++ b/openthread_border_router/rootfs/etc/s6-overlay/s6-rc.d/socat-otbr-tcp/run @@ -14,5 +14,6 @@ bashio::log.info "Starting socat TCP client for OTBR daemon..." # network RCP is reachable. Keep both connection attempts and readiness checks # running during an outage. exec s6-notifyoncheck -d -s 300 -w 300 -n 0 \ - "/usr/bin/socat" -d "tcp:${network_device},forever,interval=10" \ + "/usr/bin/socat" -d \ + "tcp:${network_device},connect-timeout=10,forever,interval=10" \ pty,raw,echo=0,link=/tmp/ttyOTBR,ignoreeof