Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash seemingly related to Fake IP feature #350

Open
SDGNelson opened this issue Oct 28, 2024 · 7 comments
Open

Crash seemingly related to Fake IP feature #350

SDGNelson opened this issue Oct 28, 2024 · 7 comments

Comments

@SDGNelson
Copy link

We've received reports from several hosts of Unturned (AppID 304930) that their servers intermittently crash if Fake IP is enabled. Here's a crash dump from a Windows server which reports the crash happening in steamclient64.dll:

Unturned.exe.23712.dmp

I asked a couple of hosts running into the crash to enable verbose output from ISteamNetworkingUtils::SetDebugOutputFunction. The log files are hundreds of thousands of lines, so I've cut out the last hundred or so before the crashes here:

SteamNetworkingSockets Log 1.txt
SteamNetworkingSockets Log 2.txt

The frequency of the "we didn't know about a session on that relay for this connection" messages seems to increase gradually while the server is running.

Any help you can provide would be greatly appreciated! I'm not sure whether this is a bug on my end or not.

@RBMKBlaze
Copy link

RBMKBlaze commented Dec 4, 2024

image

After this it just stops without exiting and basically kills the game.

@RBMKBlaze
Copy link

Hey, any update on this?

@soerr
Copy link

soerr commented Jan 18, 2025

I have also realized the crashes happen more often when there are alot of players on the server.

@Lancer-TG
Copy link

We need a fix for this, would help the playerbase a lot to have easier to make servers

@SDGNelson
Copy link
Author

Commenting to update everyone following this thread (members of the Unturned plugin dev community AFAIK 😅):

On January 7th we received a comment on the help site ticket that the issue had been escalated internally.

However, it looks like the ticket has been closed out. I'm not sure whether this means it is an issue on my end, or whether it automatically closed because I didn't comment on the "escalated internally" comment. I've submitted a follow-up help site ticket hoping for clarification.

I would typically assume it's an issue on my end, but I can't think of what the cause would be: As far as I'm aware our Steam Networking Sockets implementation has been fairly solid except when Fake IP is enabled. (If that's not the case - i.e., if anyone is running into Unturned server crashes without Fake IP enabled - please let me know!) The Fake IP API on the server side is very straightforward, as simple as:

  • We call BeginAsyncRequestFakeIP immediately before LogOn or LogOnAnonymous. Per the documentation, we don't wait for the result before logging on because the request is queued until login completes.
  • When creating server sockets (e.g., CreateListenSocketIP), we also call CreateListenSocketP2PFakeIP.

It's possible I'm missing something, but I didn't find any gotchas in the Fake IP documentation: https://partner.steamgames.com/doc/api/ISteamNetworkingSockets#1

If it is a SNS/GNS bug, I imagine it's a difficult prioritization issue for the devs at Valve. As far as I'm aware Fake IP isn't widely used (yet?), Unturned is a relatively small/niche game, and they're working on the networking for many big/critical projects like CS2 and Dota 2.

@Lancer-TG
Copy link

Any alternative to safelly host at the moment?

@SDGNelson
Copy link
Author

Another quick follow up: The help site ticket was indeed closed automatically and has now been re-opened.

Any alternative to safelly host at the moment?

If your server doesn't need to be publicly visible on the server list, the easiest option is to join by server code which also uses SDR.

For publicly visible servers, a few hosts are using proxies for the A2S queries to mitigate denial of service attacks. Anycast proxies are the most effective albeit rather contentious. We have some changes to anycast proxies pending for the next update, and will announce them soon - we just have an unusually high number of WIP announcements to finish sorting out. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants