moonlight-stream / moonlight-ios

GameStream client for iOS/tvOS
GNU General Public License v3.0
989 stars 247 forks source link

Connection Terminated Error for iOS and tvOS #599

Closed bayramog closed 4 months ago

bayramog commented 5 months ago

Describe the bug When I try to connect Sunshine instance from iOS and tvOS Moonlight client, they are creating Connection Terminated error. For same networks and Sunshine client. I can connect without any problem thru macOS client. Steps to reproduce No specific steps. I have a public ip for my Azure VM. All necessary ports are opened. I added sunshine instance with manual ip and port. It recognize and see the instance as running. Trying to connect and they are creating the error.

Screenshots image

image

image

Affected games Not game specific issue.

Other Moonlight clients

Moonlight settings (please complete the following information)

Device details (please complete the following information)

Server PC details (please complete the following information)

oxkenshin commented 5 months ago

I have a similar issue for my iPad pro, but it's fine for my iPad mini 6. After I turned off the IPv6 option in sunshine, the iPad pro works again.

bayramog commented 5 months ago

I have a similar issue for my iPad pro, but it's fine for my iPad mini 6. After I turned off the IPv6 option in sunshine, the iPad pro works again.

I have never turned on IPv6 and it is still IPv4 for me. But again I have the issue 😞

oxkenshin commented 5 months ago

There's a troubleshooting page in sunshine console webpage. The logs could show the error. For me it was something like "WSASendMsg() failed: 10022".

bayramog commented 5 months ago

Yes, I got the same error. But IPv6 already closed for me. And before latest Moonlight update with same configs, it was working. Strange.

There's a troubleshooting page in sunshine console webpage. The logs could show the error. For me it was something like "WSASendMsg() failed: 10022".

oxkenshin commented 5 months ago

I cannot reproduce it now even when I turns the IPv6 option on. None of the options have I touched. Strange.

bayramog commented 5 months ago

I also got new Sunshine nightly build but it doesn't solve it. I have exactly same network with my macOS and my Sunshine host at Azure VM. So all devices are trying to connect from my home network over internet to Azure network. macOS works but Apple TV and iPhone don't. Before Moonlight iOS update , I was able to connect. Nothing changed at both my home network and Azure side. Really interesting one.

WXZhao7 commented 4 months ago

Only iPadOS latest version can't connect with 10022.

WXZhao7 commented 4 months ago

Only iPadOS latest version can't connect with 10022.

I could fix it by changing the public ip in ::ffff:ip to local IP.

cgutman commented 4 months ago

This looks like an Apple kernel bug, but I added a workaround in https://github.com/cgutman/enet/commit/c6bb0e50118d08252eee308de8412751218442d6

This is fixed in v9.0.1 for iOS and tvOS, whichc is now live on the App Store.