[0.13.5 LAN game crashes with more than 10 mods

This subforum contains all the issues which we already resolved.
heartbreakkim
Burner Inserter
Burner Inserter
Posts: 9
Joined: Wed Jul 06, 2016 7:25 pm
Contact:

[0.13.5 LAN game crashes with more than 10 mods

Post by heartbreakkim »

When I start a default settings LAN game with more than 10 mods, the attached crash happens within around 30 seconds. It doesn't matter what combination of mods, as long as there's more than 10. Attached is the log and mods folder. I tried to screenshot but this time the alert didn't appear, the game just froze. My partner can also reproduce this on a different Mac.

Steps to make a game/reproduce:

* Enable 11 or more mods
* Play -> Multiplayer -> New game -> Generate -> Lan -> Start

Alert message:
'Unexpected error occurred. You can help us to solve the problem by posting the contents of the log file on the Factorio forums
Result:

Have to force quit Factorio as it's unresponsive.

Versions:
Factorio 0.13.5 (build 23107, mac, steam)
Operating system: Mac OS X 10.11.5
Can someone please close (originally thought it was the mods causing the issue)?:
viewtopic.php?f=51&t=28395&p=180276#p180276
viewtopic.php?f=49&t=28444
Attachments
mods.zip
(8.53 MiB) Downloaded 136 times
crash.log
(7.25 KiB) Downloaded 132 times
Loewchen
Global Moderator
Global Moderator
Posts: 9307
Joined: Wed Jan 07, 2015 5:53 pm
Contact:

Re: [0.13.5 LAN game crashes with more than 10 mods

Post by Loewchen »

94.215 Info PosixUDPSocket.cpp:50: Opening socket at port 0
I have seen that before, can not find where though.
mr_oyster_meister
Manual Inserter
Manual Inserter
Posts: 1
Joined: Sat Jul 09, 2016 10:31 am
Contact:

Re: [0.13.5 LAN game crashes with more than 10 mods

Post by mr_oyster_meister »

Happens for me too with the same symptoms.
Using Factorio 0.13.6 under OS X 10.10.5. Also had the same error with Factorio 0.13.3
Attachments
crash.log
(6.56 KiB) Downloaded 131 times
heartbreakkim
Burner Inserter
Burner Inserter
Posts: 9
Joined: Wed Jul 06, 2016 7:25 pm
Contact:

Re: [0.13.5 LAN game crashes with more than 10 mods

Post by heartbreakkim »

On Linux Mint 17.3 and Windows 10 it works as expected with Factorio 0.13.6.


Looks like an OSX thing.
Kortak
Manual Inserter
Manual Inserter
Posts: 3
Joined: Sat Jul 02, 2016 4:54 am
Contact:

Re: [0.13.5 LAN game crashes with more than 10 mods

Post by Kortak »

hmm...strange.

I have 18 mods installed and the only thing I play is LAN with someone in my home...no errors
This was in all versions up to 0.13.7


(windows 64 bit version by the way )

edit: ah i see its on MAC..
NotABiter
Fast Inserter
Fast Inserter
Posts: 124
Joined: Fri Nov 14, 2014 9:05 am
Contact:

Re: [0.13.5 LAN game crashes with more than 10 mods

Post by NotABiter »

Based on the bit of the log that bobingabout quoted here: viewtopic.php?f=51&t=28395#p180050

My guess is that adding more mods is causing UDP packets to get large enough to exceed your MTU.

(One could partially confirm this by using a network sniffer and seeing if max packet size does indeed increase as you add more mods. The other part is checking the MTU size for your network stack and seeing if that packet size is getting close to the MTU.)

IF that's the case, then:

You might be able to fix it by adjusting the MTU on your mac, e.g.: https://support.zen.co.uk/kb/Knowledgeb ... .6-to-10.9
(disclaimer: I don't use a mac and have no idea if that link is actually useful.)

The only way for the game to automatically overcome the issue would be to bust up its current packets into multiple smaller packets (and then reassemble them on the receiver) so each individual packet stays below your MTU.
bk5115545
Fast Inserter
Fast Inserter
Posts: 123
Joined: Sun Apr 03, 2016 7:00 pm
Contact:

Re: [0.13.5 LAN game crashes with more than 10 mods

Post by bk5115545 »

The devs could probably fix this by sending Mod ID's and version numbers instead of full mod names. They could then binary compress the data part of the packet (maybe with some pre-shared AVL tree embedded into each game version) to amplify the savings.
There would still be a limit but it might be much higher (2x or 3x higher).

Or they could change the protocol for client+server startup to receive packets that list mods until a known message is received (like recieve mod packets until the message "END_OF_MOD_LIST" is seen).
This would mean that the server could host a basically unlimited number of mods but might make the connection process significantly slower (but only the connection process).
heartbreakkim
Burner Inserter
Burner Inserter
Posts: 9
Joined: Wed Jul 06, 2016 7:25 pm
Contact:

Re: [0.13.5 LAN game crashes with more than 10 mods

Post by heartbreakkim »

NotABiter wrote:Based on the bit of the log that bobingabout quoted here: viewtopic.php?f=51&t=28395#p180050

My guess is that adding more mods is causing UDP packets to get large enough to exceed your MTU.

(One could partially confirm this by using a network sniffer and seeing if max packet size does indeed increase as you add more mods. The other part is checking the MTU size for your network stack and seeing if that packet size is getting close to the MTU.)

IF that's the case, then:

You might be able to fix it by adjusting the MTU on your mac, e.g.: https://support.zen.co.uk/kb/Knowledgeb ... .6-to-10.9
(disclaimer: I don't use a mac and have no idea if that link is actually useful.)

The only way for the game to automatically overcome the issue would be to bust up its current packets into multiple smaller packets (and then reassemble them on the receiver) so each individual packet stays below your MTU.
Thanks for the suggestion, I'm on El Capitan (10.11) following this link https://support.apple.com/kb/PH21660?lo ... cale=en_US my mac's already set to the max MTU size (1500) :(
nefreyu
Manual Inserter
Manual Inserter
Posts: 4
Joined: Fri Jul 29, 2016 9:34 pm
Contact:

Re: [0.13.5 LAN game crashes with more than 10 mods

Post by nefreyu »

Same issue here on OSX with LAN multiplayer. Can have 8 or 9 mods, but with 10 it always crashes, might indeed have to do with the length of the mod-names.

Any work around possible? I'm having a hard time selecting which 8 mods to play with, would really like to use a few more :)

Most relevant part of the log:

Code: Select all

  87.639 Info GameActionHandler.cpp:2709: MapTick(6) processed PlayerJoinGame peerID(0) playerIndex(0) mode(create)
Factorio crashed. Generating symbolized stacktrace, please wait ...
#0  0x1005b9c02 in Logger::logStacktrace(StackTraceInfo*) (in factorio) (Logger.cpp:382)
#1  0x1004c54a7 in LANServerGameUpdater::sendFullState() (in factorio) (ServerGameUpdater.cpp:275)
#2  0x1004c50a8 in LANServerGameUpdater::run() (in factorio) (ServerGameUpdater.cpp:252)
#3  0x100b3cfa5 in boost::(anonymous namespace)::thread_proxy(void*) (in factorio) + 165
#4  0x10690ac4f in 0x10690ac4f
#5  0x10690ab9f in 0x10690ab9f
#6  0x10690a3d5 in 0x10690a3d5
  90.799 Error ServerGameUpdater.cpp:275: Failed sending LAN game broadcast: Sendto failed: Message too long
Attachments
factorio-previous.log
(6.82 KiB) Downloaded 104 times
nefreyu
Manual Inserter
Manual Inserter
Posts: 4
Joined: Fri Jul 29, 2016 9:34 pm
Contact:

Re: [0.13.5 LAN game crashes with more than 10 mods

Post by nefreyu »

WORKAROUND

The problem is the max UPD-package limit, by default OSX has limited the maximum UDP-package to be 9216. This can be increased (until you reboot) with the following command:

Code: Select all

sudo sysctl -w net.inet.udp.maxdgram=20000

As per StackOverflow (second answer): http://stackoverflow.com/questions/2281 ... e-too-long

*update
While this seems to work for new games, resuming an old save with more mods still gives the same error for me :(
respectTheCode
Manual Inserter
Manual Inserter
Posts: 1
Joined: Mon Aug 08, 2016 1:34 pm
Contact:

Re: [0.13.5 LAN game crashes with more than 10 mods

Post by respectTheCode »

This appears to only impact the server. With a Windows server and a Mac client everything works. With a Mac server the game hangs when any OS views the Play on LAN screen.
doktorstick
Fast Inserter
Fast Inserter
Posts: 219
Joined: Fri Aug 12, 2016 10:22 pm
Contact:

Re: [0.13.5 LAN game crashes with more than 10 mods

Post by doktorstick »

Can confirm this exists in the latest version 0.13.15 on Mac OS X (El Capitan) with 29 mods.

Code: Select all

  53.247 Error ServerGameUpdater.cpp:275: Failed sending LAN game broadcast: Sendto failed: Message too long
Factorio crashed. Generating symbolized stacktrace, please wait ...
kovarex
Factorio Staff
Factorio Staff
Posts: 8207
Joined: Wed Feb 06, 2013 12:00 am
Contact:

Re: [0.13.5 LAN game crashes with more than 10 mods

Post by kovarex »

Solved in the 0.14.x version
Post Reply

Return to “Resolved Problems and Bugs”