You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Dear all,
I am using tailscale to access HA remotely on IOS 26. It used to work flawlessly but since a few weeks, there is frequent disconnection (using a webpage or HA companion). Remote connexion works perfectly when I access my tailscale network from a PC.
Do you have any idea where the problem come from?
Steps to reproduce
No response
Are there any recent changes that introduced the issue?
No response
OS
IOS
OS version
IOS 26
Tailscale version
1.90.4
Other software
Home Assistant companion
Bug report
No response
Reacted by Chris Drackett, Mike Dalrymple, vww1978, vwkd, Coda, wmTJc9IK0Q, Evan Stoll, Alexander Vranas, paps, May Zhong and 7 more
I don’t know if my issue is exactly the same, but I’ve just gotten an iPhone a few weeks ago and I noticed the same behavior. In my case, it’s DNS causing all the hangs and timeouts.
I’m serving DNS via Tailscale itself, and don’t have any problems with my Linux or android clients.
Toggling Tailscale off and on again seems to temporarily fix the problem, and it seems fine when I’m actively using the phone, but it gets pretty confused if the phone has been sitting idle for awhile.
It also does not seem to be related to whether an exit node is being used.
Glad to hear I am not the only one experiencing that glitch.
From time to time, I see the following warning in Tailscale: MagicSock Function Not Running.
In Tailscale, VPN On Demand and Detect MagicDNS are on.
It seems to be the same problem as the one described in this old post which is now closed: #14320
Just adding that I am also experiencing the same frequent disconnects in iOS ever since I started using a mullvad exit node. I either get the MagicSock error mentioned above, or a DNS error. Mostly happens whenever I leave the house and connect to celular and then try to re-connect to wifi. I can usually solve it by toggling Tailscale on and off in the iOS app, but sometimes that doesn't work and I need to disable my exit node as well.
I’m seeing the exact same issue here where it works fine until I open the Home Assistant app on iOS. Within seconds, I lose connectivity - the dashboard will open and show up-to-date data, but within ~5 seconds the connection is lost and I have no internet connectivity in either the HA app or anything else on the phone. The only solution is to disable and re-enable Tailscale and not re-open HA.
This started happening a few days ago and had been fine until then.
Reacted by Mike Dalrymple, shall4, vww1978, Fernando and robroll
I'm running 1.92.3 and I've been traveling for the holidays. I have my Adguard server configured as a global nameserver in the Tailscale admin console.
At home I use VPN On Demand so I'm usually not relying on Tailscale at home. But the past few days visiting family (where it should remain connected all the time) I've noticed very frequent times where all network gets jammed, and the only way to resolve it is to launch the Tailscale app. At startup it is disconnected but without any intervention with me it quickly connects and then everything on the phone works fine.
I disabled VPN On Demand altogether but that hasn't seemed to fix anything.
Same for me, although it used to be more stable before. I actually thought it's my VPN breaking down, but it seems to be related to the HA starting. Could be memory related, as mentioned in some other threads.
Weird but I had an exit node offline from a few weeks. As soon as that exit node went back online, I was able to access the second exit node (the one I couldnt access from IOS) from IOS without any disconnection.
This behavior was reported to Tailscale.
Weird but I had an exit node offline from a few weeks. As soon as that exit node went back online, I was able to access the second exit node (the one I couldnt access from IOS) from IOS without any disconnection. This behavior was reported to Tailscale.
Interesting, I had an exit node go offline at right around the same time too. It’s a remote node that I haven’t been able to bring back online yet unfortunately.
I am seeing the same issue and was able to grab the logs from the Home Assistant Companion App following the failure. I fed them to Chat-GPT and came up with the following information:
On iOS 26.2.0 (iPhone 16 Pro Max), enable Tailscale (v1.92.3).
Verify tunnel works by accessing another service over Tailscale (e.g., Blue Iris) — traffic flows normally.
Open Home Assistant iOS Companion App (v2026.1.1) configured to use a direct Tailscale IP only (no MagicDNS).
Home Assistant works normally for ~60 seconds.
After ~60 seconds:
Home Assistant traffic stalls (WebSocket stops receiving data).
Shortly after, all traffic over the Tailscale tunnel stops, including previously working services.
Tailscale UI still shows the tunnel as connected.
Cycling Tailscale off/on in iOS Settings immediately restores connectivity.
Repeating step 3 reproduces the failure consistently.
Relevant Home Assistant iOS app log excerpts (redacted)
I’m seeing the exact same issue here where it works fine until I open the Home Assistant app on iOS. Within seconds, I lose connectivity - the dashboard will open and show up-to-date data, but within ~5 seconds the connection is lost and I have no internet connectivity in either the HA app or anything else on the phone. The only solution is to disable and re-enable Tailscale and not re-open HA.
This started happening a few days ago and had been fine until then.
Yes, same for me. Everything works well until I open the HA app and then after a few seconds I loose connectivity.
Connecting to multiple Home Assistant instances via direct Tailscale IPs (e.g. 100.96.167.2:8123). After some seconds/minutes of using HA (app or browser), all Tailscale traffic from the phone stops until I toggle Tailscale off/on or delete/re-add the VPN profile.
If it is useful, my problem was resolved as soon as all devices running HA were back online. The problem started when one of my HA was offline for a few weeks (my internet was down).
I was having a similar issue to the one described here.
In my case, I have Tailscale, and HomeAssistant. I have 2 instances of HomeAssistant (different homes).
For months, I had been battling this disconnects where HA iOS app would work for 5-10 seconds upon reconnecting Tailscale, then it would stop working until I forced a disconnect then connect to Tailscale. More annoyingly the issue affected other services besides HomeAssistant.
Somehow, uninstalling the second home from the HA iOS app fixed this.
Same on me with Orca App (onorca.dev) . I connect to Tailscale open Orca after a few minutes i lose connectivity and i have to disconnect tailscale and connect it again
Reacted by Ove Andersen, Davi Alves de Azevedo, Clintswood, murilo, Bart and Louis Le
I also experience this often still, on public and beta iOS 26 ; 15 Pro Max (early population hardware rev iirc)
The MagicSock function ReceivelPv4 is not running. You might experience connectivity issues.
Code: magicsock-receive-func-error
Magicsock Function Name: ReceivelPv4
Reacted by Mehul Rao, David Driscoll, Adam Pinter and Boris Evstratov
Adding another report with the same symptoms, plus a reading of the code that may explain why a stall never heals. The code reading is not confirmed on a device.
Environment: iPhone 15 Pro Max, iOS 26.6.2, Tailscale iOS app 1.104.2 (problems seen on that version). In Orca the phone is paired with two hosts: a Linux node (running daemon 1.104.1, CLI 1.104.2, running orca serve) that is normally up, and a macOS node (1.104.4) that is normally offline or asleep. I keep the Mac paired on purpose, so an offline peer is a normal state here. Depending on the moment the path is direct over the LAN or via DERP (hel).
Symptom: the app on the phone is Orca mobile (https://github.com/stablyai/orca), which holds a long-lived WebSocket to the host over its Tailscale address. The connection stalls in place while it is still shown as connected, usually in the middle of streamed output, or right after switching apps. Toggling Tailscale off and on recovers it. It is unpredictable, and the in-app log viewer clears too fast for me to catch the moment, so I have no Receive func line. I have not checked whether other apps stop at the same time. Several of you above fixed this by removing or reviving an offline peer. I won't remove the Mac, since I want to reach it whenever it is on, so if an offline peer is what triggers this (I have not confirmed that the app keeps retrying it), that is a case Tailscale needs to tolerate rather than something I can work around.
Bug report ID from 2026-10-30 10:58Z (not necessarily taken during a stall): BUG-5c7ddcce96a63a64d3a96b492bf51b2e5c1bad4bea7995bfd110ddc83cfedd3f-20261030105805Z-453abc5bdcf6a400
What the code does (tailscale/tailscale at 5a05ac1, VERSION 1.105.0, and tailscale/wireguard-go db3888e688e9):
The magicsock-receive-func-error warning comes from health.checkReceiveFuncsLocked: it fires when a receive func (ReceiveIPv4) is neither inside a call nor gaining calls between two checks. Nothing acts on it; it only sets the warnable.
Conn.mkReceiveFunc returns any ReadBatch error to wireguard-go, and RebindingUDPConn.ReadBatch retries only when the failing pconn is no longer the current one.
In wireguard-go RoutineReceiveIncoming, a returned error ends that goroutine for good if it is a non-temporary net.Error, or after 10 consecutive errors (about 3 s with the 333 ms sleeps). Only net.ErrClosed is a normal exit. Nothing restarts it until the Bind is closed and reopened, which is what toggling the tunnel does.
The send side already has recovery: Conn.maybeRebindOnError (called from sendUDPBatch and sendUDP) rebinds and re-STUNs on errors known to be healed by it. I found no equivalent on the receive path.
If that is right, a burst of read errors on the UDP socket (extension suspended, network path change, resource pressure) leaves the tunnel unable to receive while it still looks connected, which matches the stalls here and in the Home Assistant reports. Suggestion: treat non-closing read errors in mkReceiveFunc as retryable (rebind and keep reading), or have the missing state from the health check trigger a rebind instead of only a warning. The error text from Receive func ReceiveIPv4 exiting with error: in the uploaded logs for a bug report taken during a stall would confirm or refute this.
I opened a draft PR with a possible fix for the receive-side gap described in my earlier comment: #22084
It makes mkReceiveFunc rebind (throttled, shared with the send path) and retry with a bounded backoff on a read error, instead of returning it to wireguard-go, which would end the receive routine. It is a defensive change: the read error that occurs on iOS is still unconfirmed, so a log line from a stall would help to verify it. Comments on the approach are welcome there.
This happens during outbound uploads, and I have also reproduced it by simply opening certain applications.
The IPNExtension memory usage in the captured logs was stable at approximately 32–32.5 MB. No Jetsam event or Network Extension crash was observed at the time of the original failure.
Could you check whether a ReceiveIPv4 read error or receive-goroutine termination occurs before stopTunnel in my bug report?
I'm wondering whether the receive-side failure addressed by this PR could be related to the subsequent Network Extension teardown, or whether these are separate problems.
I have a fresh bug report from October 30, 2026, available for investigation.
Thanks for the details. I can't open Tailscale bug reports (only Tailscale staff can look them up by ID), so I can't tell from here whether a ReceiveIPv4 error comes before your stopTunnel. What I can add from the code and from Apple's side:
NEProviderStopReason raw value 17 is .internalError, which Apple only describes as the provider encountering an internal error (docs). One developer forum report ties it to the system process nesessionmanager being killed (in that case by jetsam), after which the system tore down the tunnel (thread). That is a single forum reply, not an official explanation.
stopTunnel is called by iOS on the app side. I found no handling of it in this repo (tailscale/tailscale), so a receive routine ending would not by itself make iOS stop the tunnel.
The failure the PR is aimed at looks different: the tunnel stays up and says connected, but the receive routine has ended, so nothing arrives until the Bind is reopened. In your case the OS stops the tunnel. So I think these are probably separate problems, though I can't rule out a link.
Two ways to tell them apart:
In your bug report or the app's log viewer, look for Receive func ReceiveIPv4 exiting with error: shortly before the stopTunnel line. If it isn't there, it is likely the separate problem.
With the iPhone attached to a Mac, Console.app (select the device in the sidebar) filtered to nesessionmanager, IPNExtension and jetsam around the failure would show whether nesessionmanager itself was killed. The extension's own ~32 MB stays well under typical limits, which would not show that.
If you can paste the few log lines around stopTunnel (without IPs or keys), I am happy to look.
Thanks. I already included an anonymized log excerpt in issue #21355, but I'm reposting the relevant section here.
These are the lines immediately preceding and following stopTunnel (local timestamps, IPs and node identifiers redacted):
09:22:38 wg: [<peer-2>] - Received handshake initiation / Sending handshake response
09:22:38 Accept: ICMPv4{<peer-2-ip>:0 > <this-device-ip>:0} 84
09:22:38 Accept: ICMPv4{<this-device-ip>:0 > <peer-2-ip>:0} 84
09:22:39 open-conn-track: timeout opening (TCP <this-device-ip>:57365 => ...)
09:22:41 swiftNetMon: Path evaluated - unchanged
09:22:43 stopTunnel: "unhandled reason, NEProviderStopReason.rawValue = 17"
09:22:43 Persistency maintained for stop reason unhandled reason
09:22:43 LinkChange: minor
09:22:43 swiftNetMon: Path evaluated - unchanged
09:22:43 network update from Swift: connected=true, expensive=false
09:22:43 wg: Failed to write packets to TUN device: write /dev/tun: destination address required
09:22:44 wg: Failed to write packets to TUN device: write /dev/tun: bad file descriptor
09:22:45 wg: Failed to write packets to TUN device: write /dev/tun: bad file descriptor
09:22:46 wg: Failed to write packets to TUN device: write /dev/tun: bad file descriptor
09:22:48 wg: [<peer-2>] - Receiving keepalive packet
In this excerpt, I don't see Receive func ReceiveIPv4 exiting with error: before stopTunnel.
Interestingly, WireGuard handshakes and ICMP traffic were still working shortly before the tunnel was stopped. The network path was also reported as unchanged.
The first visible anomaly is open-conn-track: timeout opening, approximately 4 seconds before stopTunnel.
Does this sequence provide any clues about why iOS invokes stopTunnel with reason 17?
The full bug report is available to Tailscale staff if further investigation is needed.
No Receive func ... exiting with error before stopTunnel, and the receive path was still alive: handshake initiation/response, ICMP accepted both ways, and a keepalive received at 09:22:48, after the stop. So I think this is a different problem from the receive-routine exit that wgengine/magicsock: rebind and retry when a UDP receive fails #22084 is about.
The interesting part is after the stop. Persistency maintained for stop reason unhandled reason suggests the app keeps the Go backend running when it does not recognise the reason. The TUN writes then fail with destination address required and then repeated bad file descriptor, while WireGuard keeps receiving. That looks like the backend running on a TUN fd that iOS has already closed. If the app still shows connected at that point, it would match the "connected but nothing passes until toggled" reports in this issue. That logic is in the iOS app layer, which is not in this repo, so I can't confirm it, but the repeated bad file descriptor seems worth pointing the Tailscale iOS team at.
Nothing in the excerpt explains reason 17. The open-conn-track: timeout opening four seconds earlier fits a stalled upload and may be a symptom rather than a cause.
To look for the system side: on the iPhone, Settings, Privacy & Security, Analytics & Improvements, Analytics Data. Entries named JetsamEvent-*, nesessionmanager-* or IPNExtension-* with a timestamp around 09:22:43 would show whether the system process was killed or crashed.
Thanks, this clarifies the likely failure boundary.
I understand that the log excerpt I originally posted shows the aftermath of an iOS-initiated tunnel teardown, rather than a WireGuard receive-side failure.
I have a fresh reproduction from October 30, 2026, with a bug report generated immediately after the failure:
I’ve added fresh kernel and provider-lifecycle evidence to #21355: #21355 (comment). It confirms nesessionmanager highwater kills and retained suspended providers.
Activity
tdalbo92 commentedon Nov 18, 2025
I don’t know if my issue is exactly the same, but I’ve just gotten an iPhone a few weeks ago and I noticed the same behavior. In my case, it’s DNS causing all the hangs and timeouts.
I’m serving DNS via Tailscale itself, and don’t have any problems with my Linux or android clients.
Toggling Tailscale off and on again seems to temporarily fix the problem, and it seems fine when I’m actively using the phone, but it gets pretty confused if the phone has been sitting idle for awhile.
It also does not seem to be related to whether an exit node is being used.
gregwelldone commentedon Nov 19, 2025
Glad to hear I am not the only one experiencing that glitch.
From time to time, I see the following warning in Tailscale: MagicSock Function Not Running.
In Tailscale, VPN On Demand and Detect MagicDNS are on.
It seems to be the same problem as the one described in this old post which is now closed:
#14320
jenks6797 commentedon Nov 24, 2025
Just adding that I am also experiencing the same frequent disconnects in iOS ever since I started using a mullvad exit node. I either get the MagicSock error mentioned above, or a DNS error. Mostly happens whenever I leave the house and connect to celular and then try to re-connect to wifi. I can usually solve it by toggling Tailscale on and off in the iOS app, but sometimes that doesn't work and I need to disable my exit node as well.
abstractvector commentedon Dec 23, 2025
I’m seeing the exact same issue here where it works fine until I open the Home Assistant app on iOS. Within seconds, I lose connectivity - the dashboard will open and show up-to-date data, but within ~5 seconds the connection is lost and I have no internet connectivity in either the HA app or anything else on the phone. The only solution is to disable and re-enable Tailscale and not re-open HA.
This started happening a few days ago and had been fine until then.
grahams commentedon Dec 24, 2025
I'm running 1.92.3 and I've been traveling for the holidays. I have my Adguard server configured as a global nameserver in the Tailscale admin console.
At home I use VPN On Demand so I'm usually not relying on Tailscale at home. But the past few days visiting family (where it should remain connected all the time) I've noticed very frequent times where all network gets jammed, and the only way to resolve it is to launch the Tailscale app. At startup it is disconnected but without any intervention with me it quickly connects and then everything on the phone works fine.
I disabled VPN On Demand altogether but that hasn't seemed to fix anything.
cthulu commentedon Dec 28, 2025
Same for me, although it used to be more stable before. I actually thought it's my VPN breaking down, but it seems to be related to the HA starting. Could be memory related, as mentioned in some other threads.
gregwelldone commentedon Dec 30, 2025
Weird but I had an exit node offline from a few weeks. As soon as that exit node went back online, I was able to access the second exit node (the one I couldnt access from IOS) from IOS without any disconnection.
This behavior was reported to Tailscale.
abstractvector commentedon Dec 30, 2025
Interesting, I had an exit node go offline at right around the same time too. It’s a remote node that I haven’t been able to bring back online yet unfortunately.
shall4 commentedon Jan 11, 2026
I am seeing the same issue and was able to grab the logs from the Home Assistant Companion App following the failure. I fed them to Chat-GPT and came up with the following information:
On iOS 26.2.0 (iPhone 16 Pro Max), enable Tailscale (v1.92.3).
Verify tunnel works by accessing another service over Tailscale (e.g., Blue Iris) — traffic flows normally.
Open Home Assistant iOS Companion App (v2026.1.1) configured to use a direct Tailscale IP only (no MagicDNS).
Home Assistant works normally for ~60 seconds.
After ~60 seconds:
Cycling Tailscale off/on in iOS Settings immediately restores connectivity.
Repeating step 3 reproduces the failure consistently.
Relevant Home Assistant iOS app log excerpts (redacted)
WebSocket: disconnecting; permanently: default, error:
Optional(HAKit.HAReconnectManagerError.lateFireReset)
Adding event: Background fetch activated
failed request … NSURLErrorDomain Code=-1001 "The request timed out."
… http://100.x.y.z:8123/api/
out of time for background task webhook-send
out of time for background task background-fetch
Notes
NSURLErrorDomain -1001indicates timeouts (not DNS, TLS, or connection refusal).vww1978 commentedon Feb 18, 2026
Yes, same for me. Everything works well until I open the HA app and then after a few seconds I loose connectivity.
mikaelSchalin commentedon Mar 4, 2026
Yes, same for me.
iPhone 12 mini, iOS 26.3, Tailscale 1.94.1.
Connecting to multiple Home Assistant instances via direct Tailscale IPs (e.g. 100.96.167.2:8123). After some seconds/minutes of using HA (app or browser), all Tailscale traffic from the phone stops until I toggle Tailscale off/on or delete/re-add the VPN profile.
Bug report ID:
BUG-9aa6f1a1f25d3d70d3dd0088d03fa1fd4bd5e5db9ab3a528ec9c27932fd61595-20260304165634Z-7fdb570
gregwelldone commentedon Mar 4, 2026
If it is useful, my problem was resolved as soon as all devices running HA were back online. The problem started when one of my HA was offline for a few weeks (my internet was down).
vww1978 commentedon Mar 4, 2026
2 remaining items
Koff commentedon Apr 18, 2026
I was having a similar issue to the one described here.
In my case, I have Tailscale, and HomeAssistant. I have 2 instances of HomeAssistant (different homes).
For months, I had been battling this disconnects where HA iOS app would work for 5-10 seconds upon reconnecting Tailscale, then it would stop working until I forced a disconnect then connect to Tailscale. More annoyingly the issue affected other services besides HomeAssistant.
Somehow, uninstalling the second home from the HA iOS app fixed this.
zer0rg commentedon Sep 17, 2026
Same on me with Orca App (onorca.dev) . I connect to Tailscale open Orca after a few minutes i lose connectivity and i have to disconnect tailscale and connect it again
TG-Techie commentedon Oct 22, 2026
I also experience this often still, on public and beta iOS 26 ; 15 Pro Max (early population hardware rev iirc)
luben93 commentedon Oct 30, 2026
Adding another report with the same symptoms, plus a reading of the code that may explain why a stall never heals. The code reading is not confirmed on a device.
Environment: iPhone 15 Pro Max, iOS 26.6.2, Tailscale iOS app 1.104.2 (problems seen on that version). In Orca the phone is paired with two hosts: a Linux node (running daemon 1.104.1, CLI 1.104.2, running
orca serve) that is normally up, and a macOS node (1.104.4) that is normally offline or asleep. I keep the Mac paired on purpose, so an offline peer is a normal state here. Depending on the moment the path is direct over the LAN or via DERP (hel).Symptom: the app on the phone is Orca mobile (https://github.com/stablyai/orca), which holds a long-lived WebSocket to the host over its Tailscale address. The connection stalls in place while it is still shown as connected, usually in the middle of streamed output, or right after switching apps. Toggling Tailscale off and on recovers it. It is unpredictable, and the in-app log viewer clears too fast for me to catch the moment, so I have no
Receive funcline. I have not checked whether other apps stop at the same time. Several of you above fixed this by removing or reviving an offline peer. I won't remove the Mac, since I want to reach it whenever it is on, so if an offline peer is what triggers this (I have not confirmed that the app keeps retrying it), that is a case Tailscale needs to tolerate rather than something I can work around.Bug report ID from 2026-10-30 10:58Z (not necessarily taken during a stall): BUG-5c7ddcce96a63a64d3a96b492bf51b2e5c1bad4bea7995bfd110ddc83cfedd3f-20261030105805Z-453abc5bdcf6a400
What the code does (tailscale/tailscale at 5a05ac1, VERSION 1.105.0, and tailscale/wireguard-go db3888e688e9):
magicsock-receive-func-errorwarning comes fromhealth.checkReceiveFuncsLocked: it fires when a receive func (ReceiveIPv4) is neither inside a call nor gaining calls between two checks. Nothing acts on it; it only sets the warnable.Conn.mkReceiveFuncreturns anyReadBatcherror to wireguard-go, andRebindingUDPConn.ReadBatchretries only when the failing pconn is no longer the current one.RoutineReceiveIncoming, a returned error ends that goroutine for good if it is a non-temporarynet.Error, or after 10 consecutive errors (about 3 s with the 333 ms sleeps). Onlynet.ErrClosedis a normal exit. Nothing restarts it until the Bind is closed and reopened, which is what toggling the tunnel does.Conn.maybeRebindOnError(called fromsendUDPBatchandsendUDP) rebinds and re-STUNs on errors known to be healed by it. I found no equivalent on the receive path.If that is right, a burst of read errors on the UDP socket (extension suspended, network path change, resource pressure) leaves the tunnel unable to receive while it still looks connected, which matches the stalls here and in the Home Assistant reports. Suggestion: treat non-closing read errors in
mkReceiveFuncas retryable (rebind and keep reading), or have themissingstate from the health check trigger a rebind instead of only a warning. The error text fromReceive func ReceiveIPv4 exiting with error:in the uploaded logs for a bug report taken during a stall would confirm or refute this.Happy to test a build or collect more logs.
luben93 commentedon Oct 30, 2026
I opened a draft PR with a possible fix for the receive-side gap described in my earlier comment: #22084
It makes
mkReceiveFuncrebind (throttled, shared with the send path) and retry with a bounded backoff on a read error, instead of returning it to wireguard-go, which would end the receive routine. It is a defensive change: the read error that occurs on iOS is still unconfirmed, so a log line from a stall would help to verify it. Comments on the approach are welcome there.Inhum commentedon Oct 30, 2026
I have a related but slightly different issue on an iPhone 13 running iOS 18.7.8, documented in [#21355](#21355).
In my case, the tunnel is actually stopped by iOS, with:
stopTunnel: "unhandled reason, NEProviderStopReason.rawValue = 17"This happens during outbound uploads, and I have also reproduced it by simply opening certain applications.
The IPNExtension memory usage in the captured logs was stable at approximately 32–32.5 MB. No Jetsam event or Network Extension crash was observed at the time of the original failure.
Could you check whether a
ReceiveIPv4read error or receive-goroutine termination occurs beforestopTunnelin my bug report?I'm wondering whether the receive-side failure addressed by this PR could be related to the subsequent Network Extension teardown, or whether these are separate problems.
I have a fresh bug report from October 30, 2026, available for investigation.
luben93 commentedon Oct 30, 2026
Thanks for the details. I can't open Tailscale bug reports (only Tailscale staff can look them up by ID), so I can't tell from here whether a
ReceiveIPv4error comes before yourstopTunnel. What I can add from the code and from Apple's side:NEProviderStopReasonraw value 17 is.internalError, which Apple only describes as the provider encountering an internal error (docs). One developer forum report ties it to the system processnesessionmanagerbeing killed (in that case by jetsam), after which the system tore down the tunnel (thread). That is a single forum reply, not an official explanation.stopTunnelis called by iOS on the app side. I found no handling of it in this repo (tailscale/tailscale), so a receive routine ending would not by itself make iOS stop the tunnel.Two ways to tell them apart:
Receive func ReceiveIPv4 exiting with error:shortly before thestopTunnelline. If it isn't there, it is likely the separate problem.nesessionmanager,IPNExtensionandjetsamaround the failure would show whethernesessionmanageritself was killed. The extension's own ~32 MB stays well under typical limits, which would not show that.If you can paste the few log lines around
stopTunnel(without IPs or keys), I am happy to look.Inhum commentedon Oct 30, 2026
Thanks. I already included an anonymized log excerpt in issue #21355, but I'm reposting the relevant section here.
These are the lines immediately preceding and following
stopTunnel(local timestamps, IPs and node identifiers redacted):In this excerpt, I don't see
Receive func ReceiveIPv4 exiting with error:beforestopTunnel.Interestingly, WireGuard handshakes and ICMP traffic were still working shortly before the tunnel was stopped. The network path was also reported as unchanged.
The first visible anomaly is
open-conn-track: timeout opening, approximately 4 seconds beforestopTunnel.Does this sequence provide any clues about why iOS invokes
stopTunnelwith reason 17?The full bug report is available to Tailscale staff if further investigation is needed.
luben93 commentedon Oct 30, 2026
Thanks, that helps. From your excerpt:
Receive func ... exiting with errorbeforestopTunnel, and the receive path was still alive: handshake initiation/response, ICMP accepted both ways, and a keepalive received at 09:22:48, after the stop. So I think this is a different problem from the receive-routine exit that wgengine/magicsock: rebind and retry when a UDP receive fails #22084 is about.Persistency maintained for stop reason unhandled reasonsuggests the app keeps the Go backend running when it does not recognise the reason. The TUN writes then fail withdestination address requiredand then repeatedbad file descriptor, while WireGuard keeps receiving. That looks like the backend running on a TUN fd that iOS has already closed. If the app still shows connected at that point, it would match the "connected but nothing passes until toggled" reports in this issue. That logic is in the iOS app layer, which is not in this repo, so I can't confirm it, but the repeatedbad file descriptorseems worth pointing the Tailscale iOS team at.open-conn-track: timeout openingfour seconds earlier fits a stalled upload and may be a symptom rather than a cause.To look for the system side: on the iPhone, Settings, Privacy & Security, Analytics & Improvements, Analytics Data. Entries named
JetsamEvent-*,nesessionmanager-*orIPNExtension-*with a timestamp around 09:22:43 would show whether the system process was killed or crashed.Inhum commentedon Oct 30, 2026
Thanks, this clarifies the likely failure boundary.
I understand that the log excerpt I originally posted shows the aftermath of an iOS-initiated tunnel teardown, rather than a WireGuard receive-side failure.
I have a fresh reproduction from October 30, 2026, with a bug report generated immediately after the failure:
BUG-c3190445f66eb600b1792e35c6f28f23337a7da2340b95fed7fed97f338304ca-20261030120529Z-10ddbe7519f8f951Could someone from the Tailscale iOS team inspect this report?
In particular, I'd like to understand:
stopTunnelwithNEProviderStopReasonInternalError (17)?nesessionmanagerkilled, crashed, or restarted around that time?JETSAM_REASON_MEMORY_HIGHWATERaffectingnesessionmanager?Persistency maintained for stop reason unhandled reasonbehavior expected, or could the iOS client handle this stop reason differently?The
IPNExtensioncrash report from 16:38 on the same day is a separate, earlier incident and should not be correlated with this reproduction.Inhum commentedon Nov 3, 2026
I’ve added fresh kernel and provider-lifecycle evidence to #21355: #21355 (comment). It confirms nesessionmanager highwater kills and retained suspended providers.
keithslater commentedon Nov 13, 2026
Was there any solution? I have the same issue with Orca.
zer0rg commentedon Nov 13, 2026
No, I changed to Herdr and now works well. I don't know why the hell this happens with Orca and other services