[Oxyd] [0.18.28] Stuck on waiting to save map

This subforum contains all the issues which we already resolved.
User avatar
Cooldude2606
Fast Inserter
Fast Inserter
Posts: 103
Joined: Sat Sep 16, 2017 9:04 pm
Contact:

[Oxyd] [0.18.28] Stuck on waiting to save map

Post by Cooldude2606 »

When trying to connect to some multiplayer games it will get stuck on the waiting for server to save map screen. This happans on multiple servers and is more frequent on servers with small maps. I also know, through hosting the deadicated server, that multiple people will experience this while connecting to our server. Our server has non blocking saving enabled if this has any effect. Below are the server logs and client logs when I have the issue. The logs include me pressing esc to cancel the connection as it will just hang with no further log activity. From what I can make of the logs the client never receives mapReadyForDownload and then everything just hangs. The invalid packet states are common to both successful joins and failed joins, and downloading the map never has any issues once it starts.
Server Logs Fail
Client Logs Fail
Server Logs Success
Client Logs Success
--- Developer for Explosive Gaming and Clusterio. Please contact me via our Discord. ---
User avatar
Cooldude2606
Fast Inserter
Fast Inserter
Posts: 103
Joined: Sat Sep 16, 2017 9:04 pm
Contact:

Re: [0.18.28] Stuck on waiting to save map

Post by Cooldude2606 »

To clarify, I have reported this issue before and have had it classed as not a bug. However, this has continually occured since my last report, and people playing on our servers have been reporting this issue to me. I am therefore opening another report as I believe that there is an underlying issue which has not been resolved.

I can also capture a tcpdump/wireshark capture for both the client and server if it would help with debugging.

Here is my previous report from 0.17.44 and a similar report from 0.15.6.
--- Developer for Explosive Gaming and Clusterio. Please contact me via our Discord. ---
Rseding91
Factorio Staff
Factorio Staff
Posts: 14348
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [0.18.28] Stuck on waiting to save map

Post by Rseding91 »

I've seen this multiple times before but nobody knows how to reproduce it reliably.

If you can reproduce it (even not reliably) a full process dump of the client and server (assuming it's running windows?) will let me debug it and figure out what's happening.
If you want to get ahold of me I'm almost always on Discord.
User avatar
Cooldude2606
Fast Inserter
Fast Inserter
Posts: 103
Joined: Sat Sep 16, 2017 9:04 pm
Contact:

Re: [0.18.28] Stuck on waiting to save map

Post by Cooldude2606 »

The server is running linux headless, will this still be of use? Details for the server and client are below.
Also, when you say process dump, do you mean a net capture or some kind of memory dump?
Server Details
Client Details
--- Developer for Explosive Gaming and Clusterio. Please contact me via our Discord. ---
Rseding91
Factorio Staff
Factorio Staff
Posts: 14348
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [0.18.28] Stuck on waiting to save map

Post by Rseding91 »

Cooldude2606 wrote: Sat May 30, 2020 10:31 pm The server is running linux headless, will this still be of use?
To me; no. I'm not even sure if there is such a thing on linux.

So, there's nothing I can do about this - maybe one of the linux developers could assist.
If you want to get ahold of me I'm almost always on Discord.
User avatar
Cooldude2606
Fast Inserter
Fast Inserter
Posts: 103
Joined: Sat Sep 16, 2017 9:04 pm
Contact:

Re: [Oxyd] [0.18.28] Stuck on waiting to save map

Post by Cooldude2606 »

We have done some testing with our server, as well as getting some feedback from other server hosters, and we believe that the banlist might be the cause of the error.

First we filtered our banlist to only include valid usernames (containing alphanumeric characters and ._-) and limited it to bans which included a reason and where the reason contained only ascii characters (without control characters like \n)

We then ran tests with our banlist (On) and then with an empty banlist (Off) allowing upto 10 seconds for the server to save the map, the results follow:
On - 0/3 Successful; Off - 3/3 Successful; On - 0/3 Successful; Off - 3/3 Successful;
On - 1/3 Successful; Off - 3/3 Successful; On - 0/3 Successful

We then stopped as it seamed to be conclusive that the ban list was the cause of these issues, hope this information is helpful.
If you would like me to send the ban list please ask, I would rather send it via dms to avoid posting it publicly.
--- Developer for Explosive Gaming and Clusterio. Please contact me via our Discord. ---
Rseding91
Factorio Staff
Factorio Staff
Posts: 14348
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [Oxyd] [0.18.28] Stuck on waiting to save map

Post by Rseding91 »

Is your banlist some huge-ass multiple MB of text? Because it gets sent to connecting players when joining servers to allow a given peer to know if someone is banned or not when using the /ban/unban commands.
If you want to get ahold of me I'm almost always on Discord.
mark9064
Burner Inserter
Burner Inserter
Posts: 8
Joined: Sun Feb 11, 2018 11:23 am
Contact:

Re: [Oxyd] [0.18.28] Stuck on waiting to save map

Post by mark9064 »

LOL, we have ~1000 bans on the banlist in total, at a size of 100KiB. I don't think this size is unreasonable, as a large public server the banlist gets to this size after a few years. If you're wondering why no-one else is complaining, other communities have taken to starting games with empty banlists, and then watching the join log for anyone on the real banlist and banning them as soon as they join. This works around the problem of Factorio sending a large banlist which seems to break things, but feels like a solution for a problem that shouldn't exist.

Since these files are just text, compressing them works nicely, dropping the size by a factor of 4 when using GZIP.
Rseding91
Factorio Staff
Factorio Staff
Posts: 14348
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [Oxyd] [0.18.28] Stuck on waiting to save map

Post by Rseding91 »

Ok, 100 KB isn't unreasonable but still annoying that it's synced at all. I didn't like it when it was added but saw no other way to do it better at the time. This might give a starting point for figuring out what's happening with stuck saving.
If you want to get ahold of me I'm almost always on Discord.
James_Hackett
Burner Inserter
Burner Inserter
Posts: 11
Joined: Fri Jul 19, 2019 12:55 pm
Contact:

Re: [Oxyd] [0.18.28] Stuck on waiting to save map

Post by James_Hackett »

Hi Oxyd, any further development on this issue or is there a post I'm missing?
Oxyd
Former Staff
Former Staff
Posts: 1428
Joined: Thu May 07, 2015 8:42 am
Contact:

Re: [Oxyd] [0.18.28] Stuck on waiting to save map

Post by Oxyd »

Hi, and yes, there is a development: It should be fixed for 1.1.0. Thanks for all the information!
jackazzm
Manual Inserter
Manual Inserter
Posts: 4
Joined: Mon Jul 15, 2019 12:35 am
Contact:

Re: [Oxyd] [0.18.28] Stuck on waiting to save map

Post by jackazzm »

Hello, This issue is plaguing one of the biggest MP servers on factorio quite a lot so it seems to not be totally fixed as of yet
User avatar
Klonan
Factorio Staff
Factorio Staff
Posts: 5289
Joined: Sun Jan 11, 2015 2:09 pm
Contact:

Re: [Oxyd] [0.18.28] Stuck on waiting to save map

Post by Klonan »

jackazzm wrote: Mon Oct 04, 2021 5:06 pm Hello, This issue is plaguing one of the biggest MP servers on factorio quite a lot so it seems to not be totally fixed as of yet
Can you provide more details, what part is not fixed yet?
Can you make a new bug report with new steps to reproduce, with logs?
jackazzm
Manual Inserter
Manual Inserter
Posts: 4
Joined: Mon Jul 15, 2019 12:35 am
Contact:

Re: [Oxyd] [0.18.28] Stuck on waiting to save map

Post by jackazzm »

Klonan wrote: Mon Oct 04, 2021 7:10 pm
jackazzm wrote: Mon Oct 04, 2021 5:06 pm Hello, This issue is plaguing one of the biggest MP servers on factorio quite a lot so it seems to not be totally fixed as of yet
Can you provide more details, what part is not fixed yet?
Can you make a new bug report with new steps to reproduce, with logs?
It is exactly as OP states, whole server is stuck while 1 player is waiting for the server to save map to them. It is paused until the player decides to abort the connection process so it is very frustrating to have the whole game paused for an unforseen time.
User avatar
Klonan
Factorio Staff
Factorio Staff
Posts: 5289
Joined: Sun Jan 11, 2015 2:09 pm
Contact:

Re: [Oxyd] [0.18.28] Stuck on waiting to save map

Post by Klonan »

jackazzm wrote: Tue Oct 05, 2021 11:41 am
It is exactly as OP states, whole server is stuck while 1 player is waiting for the server to save map to them. It is paused until the player decides to abort the connection process so it is very frustrating to have the whole game paused for an unforseen time.
Sure, but between then and now the code has changed, so we would need new server logs to help us pinpoint the problem
User avatar
distortions864
Fast Inserter
Fast Inserter
Posts: 125
Joined: Thu Apr 20, 2017 12:56 am
Contact:

Re: [Oxyd] [0.18.28] Stuck on waiting to save map

Post by distortions864 »

With auth (public game) on, I have been able to reproduce the bug on 1.1.50.

If changing state from(InGameSavingMap) to(InGame) transition to oldState(ConnectedWaitingForMap) newState(ConnectedDownloadingMap) takes longer than a second or two... its locked. Even on huge maps.

I'm not sure I should post the steps to reproduce, because it happens for me 100% of the time. I also posted on the discord in #programming

Here is the map and settings I was using at the time, when trying to reproduce it.
http://m45sci.xyz/u/fact/locker-repoduce.zip
Server and client were ubuntu 20, connecting to my own server locally (but through the server browser)
Last edited by distortions864 on Tue Jan 18, 2022 12:12 pm, edited 1 time in total.
M45 Science: A Factorio Community since 2017! https://m45sci.xyz/
User avatar
distortions864
Fast Inserter
Fast Inserter
Posts: 125
Joined: Thu Apr 20, 2017 12:56 am
Contact:

Re: [Oxyd] [0.18.28] Stuck on waiting to save map

Post by distortions864 »

--Update: Someone sent me a link to the other post about this, for the moment I have made my servers reboot on lock.
M45 Science: A Factorio Community since 2017! https://m45sci.xyz/
Post Reply

Return to “Resolved Problems and Bugs”