[0.15.6 and 7] Crash on game start on linux 64 bit

Things that we don't consider worth fixing at this moment.
Post Reply
nepp95
Long Handed Inserter
Long Handed Inserter
Posts: 62
Joined: Wed Apr 16, 2014 6:48 pm
Contact:

[0.15.6 and 7] Crash on game start on linux 64 bit

Post by nepp95 »

Hello,

The latest versions of Factorio (not tested on my linux setup before 0.15) crash the game during the loading of game sprites. Mostly nearing the end between 85 and 90%. Sporadically it comes through, and there are no problems playing the game or whatsoever. But 99% of the times, it just crashes on game start.

I'm using this setup: (works fine on my other windows setup!)
OS: Linux Ubuntu 17.04 64bit
CPU: Intel Core i3 M370 @ 2.4ghz
GPU: ATI Mobility Radeon HD 5470 with 512mb memory
Mem: 3GB

Probably wondering how I can even play games...
cat factorio-current.log
cat config.ini
Using no mods.
Tried running through steam, native installation, not through wine. Have also tried running the Factorio binary through the terminal.

I'm thinking of a memory problem because it doesn't crash at the same point every time. It's always between 85% and 90%. In the logfiles, the amount of 'atlas bitmaps created' differences from each start.

It shouldn't though. Works fine on my Windows 10 64 bit setup, on the exact same laptop. My windows uses much more memory. Maybe it could be because of the "new" unity 8 that comes with Ubuntu 17.04? I think that draws a lot of video memory.

nepp95
Long Handed Inserter
Long Handed Inserter
Posts: 62
Joined: Wed Apr 16, 2014 6:48 pm
Contact:

Re: [0.15.6 and 7] Crash on game start on linux 64 bit

Post by nepp95 »

Update;

Tried running factorio binary through gdb. Magic. It worked. I now have no idea how this can be, since gdb itself took 1GB of memory even before running the binary! :mrgreen:

It is unplayable through gdb though, because of my low memory.

Commands below outputted in bold and color.
Complete terminal output of gdb
After the first "run" command, I remembered that by default with a new ubuntu 17.04 installation, swapfiles are turned off. So I created one of 6G, enabled it, and then ran again.

-EDIT-

Now I run it normally again with swap added, it works, and instead of 172 seconds, it only took 61 to load. :mrgreen: Maybe a good one to investigate why it does work on Windows with 3GB (which uses more than 0.5GB for Windows itself), but not on Linux unless you add swap. Not game breaking though as it has an easy fix.

posila
Factorio Staff
Factorio Staff
Posts: 5201
Joined: Thu Jun 11, 2015 1:35 pm
Contact:

Re: [0.15.6 and 7] Crash on game start on linux 64 bit

Post by posila »

nepp95 wrote:After the first "run" command, I remembered that by default with a new ubuntu 17.04 installation, swapfiles are turned off. So I created one of 6G, enabled it, and then ran again.

-EDIT-

Now I run it normally again with swap added, it works, and instead of 172 seconds, it only took 61 to load. :mrgreen: Maybe a good one to investigate why it does work on Windows with 3GB (which uses more than 0.5GB for Windows itself), but not on Linux unless you add swap. Not game breaking though as it has an easy fix.
It is kind of surprising it loads when running in GDB and does not without GDB. The log doesn't show crash so I assume it was just killed by OS because it ran out of memory. The reason might by OpenGL not destroying textures immediatelly, so there are leftover coppies of some sprites that were put to the sprite atlas. But that is just a guess.

I think the result of this will be for us to either to default sprite quality to low on computers with <4 GB RAM, or just increase minimum system requirements.

nepp95
Long Handed Inserter
Long Handed Inserter
Posts: 62
Joined: Wed Apr 16, 2014 6:48 pm
Contact:

Re: [0.15.6 and 7] Crash on game start on linux 64 bit

Post by nepp95 »

Yes, but there seems to be a difference on linux and windows. Computer is the same, only the software running on it changes. Maybe linux kills processes faster than windows, which would indeed make it impossible for the devs to do anything about it. Or it may be the linux game support / drivers.
FactorioBot wrote:
  • The game will default to low sprite quality on computers with less than 2.5GB RAM. (47525)
Guess that worked. After some research on what the difference is why it works on windows "out of the box" and linux needs some adjustment, I found out:

Linux has a swap file, which is not always present and must be created manually. Windows has an equivalent of the swap file built in, called the paging file. This is created on installing the OS, and thus is always present. Being able to drop things fast from the memory is crucial in playing games with low-end memory hardware. This is done to the swap/paging file. Not present = not fast enough = no memory = crash!

Nothing to be fixed, but maybe a future reference if someone complains about the game crashing on linux with low-end hardware :)

Post Reply

Return to “Won't fix.”