Skip to content

[Bug]: iOS app retries an offline Tailscale environment fast enough to freeze the whole tunnel, so every environment disconnects #37699

Closed as duplicate

Description

@mmmbuford

What happens

With several environments reached over Tailscale HTTPS, powering off one host makes the iOS app lose every environment within about a minute. Threads show "Reconnecting to ..." and the main screen shows "X environments lost connection". Only toggling the iOS VPN recovers, and it fails again about a minute later while the offline environment stays enabled.

Turning the offline environment off in the app stops it immediately.

Cause

This is the Tailscale iOS bug in tailscale/tailscale#21773: repeated traffic to an unreachable peer fills the 64-buffer WireGuard pool and stalls traffic to every peer, and to MagicDNS, until the VPN restarts. T3 Code is the trigger: the app keeps retrying the offline host (other reporters in #21773 measured about every 3-5 s). Two other T3 Code users have already reported this there, and Tailscale has a fix in 1.105.251 (TestFlight unstable track). The current stable release (1.104.7) does not include it.

So the root fix is Tailscale's. But until that reaches stable, any T3 user on iOS + Tailscale loses all environments whenever one host is asleep or off.

Evidence

Repro: iOS app 2.3.0, server 0.1.9, Tailscale iOS 1.104.6, direct Tailscale HTTPS routes. One host powered off, one host (Mac mini) on. A watch on the Mac mini ran tailscale ping to the phone every 5 s (UTC):

16:33:10 - 16:34:22  ping ok, direct, 3-65 ms
~16:34              offline environment re-enabled in T3; app starts retrying it
16:34:27            every ping fails; path falls back to DERP and still fails
16:34:27 - 16:39:25 all pings fail; control plane still reports the phone online
~16:40              VPN toggled; pings ok again
16:45:19            frozen again (offline environment still enabled in T3)
16:46:55            pings ok again
16:46:55 - 16:53    ok to the end of the watch
  • During an earlier outage the same day, Safari on the phone also hung loading the online host, so the whole tunnel was down, not only T3's connections.
  • Before this test, the app's own connection details showed the online host failing the same way: Remote environment endpoint https://<online-host>/.well-known/t3/environment timed out after 10000ms. That host's server.trace.ndjson has no record of those requests. Every request that arrived was answered in a few milliseconds.

Tailscale bug report ID from the phone during the outage: BUG-732766ba1f46c2a2414ca725b2023315e8fb7c2f79750201d47bdb4aa5fef20d-20261116163517Z-eef6a652ee870a35

Suggested mitigation in T3

Retry an environment that has stayed unreachable much less often. The supervisor's backoff is meant to reach 5 minutes, but foreground and network-change wakeups reset it to 1-2 s (resetsRetryBackoff in packages/client-runtime/src/connection/wakeups.ts). #24064 already proposes keeping the backoff across those wakeups. On iOS it would also limit this Tailscale stall, so it may be worth prioritizing.

Workaround

Turn the offline environment off in the app while its host is off, or install Tailscale 1.105.251+ from TestFlight.

Related

Activity

  1. juliusmarminge commented on Nov 16, 2026

    @juliusmarminge
    Member

    This is the same problem as #24064, so I'm closing it in favour of that one. If it is different, say how and it will be reopened.

  2. mmmbuford commented on Nov 16, 2026

    @mmmbuford
    Author

    Agreed that #24064 is the right fix area, and it already has a comment describing this same Tailscale case (tailscale/tailscale#21773). One part it doesn't cover:

    #24064 keeps resetting the retry ladder on every network-changed, and on iOS the only recovery from the Tailscale stall is toggling the VPN. expo-network (SDK 58) checks .other first when it picks the interface type, so if iOS reports the VPN path as using the tunnel interface, the reported type flips between UNKNOWN (VPN on) and WIFI (VPN off). networkPathChanges in apps/mobile/src/connection/platform.ts turns each flip into a network-changed wakeup, which would put the offline host back at 1-2 s retries right after every toggle. That matches what I recorded: after toggling at 16:40 UTC, the tunnel froze again at 16:45 with the offline environment still enabled. I haven't confirmed the type flip on a device.

    Also, #24064 has had conflicts since Nov 15 and is due to auto-close after 7 days. If it closes unmerged, this issue has nothing left to point at.

    Fine to keep this closed if #24064 is updated to cover the network-change case, or a follow-up is tracked.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions