So yesterday, our savefile tiped us over the sweet 60 FPS performance. We struggled to figure out & pinpoint the culprit.
Overview of the setup :
Server running in linux headless (docker) on a dedicated server baremetal (not some paid/month subscription at a datacenter). The server specs are just a beast. The factorio running was never using more than 100% CPU (so 1 core), barely going over the 100% from times to times (depending on the "action" on the map).
2 players with similar setups :
- AMD Ryzen 7 5800X 4GHZ (pretty good CPU)
- RTX 4070 12GB
- 32 GB RAM DDR5
- 1 player is playing from "localhost" (still had a to do a loopback from public IP)
- godly ISP cnx (2.5 Gbit/s UP/DOWN).
- 1 player is playing from 400Km apart
- problematic ISP cnx (1GBit/s WAN, but LAN setup with CPL only reaching max 30MBit/s, with potential packet loss).
Running Factorio Space Age default mapgen, went a bit deep in our remodeling of the Nauvis base (went 30ish kms east, up to when ore patches hit approx 150M/patch). The full east path is a turret heavy border guarded dual train lane (approx 12k laser turrets). With limited bug control (only so that they dont aggro non stop the border, but no artillery).
Problem :
For the problematic player, the save is running smooth 60FPS (with update tick approx 15) on singleplayer, but running with 4fps most of the time in MP.
After a talk with some community member (https://discord.com/channels/1396775903 ... 4958526534 <- discord topic). We decided to start fixing main potential problems :
- Fulgora sorting station was full, approx 2k bots in the air with items they cannot drop (have to wait a backed up inserter logisitic "junk chest").
- Bugs might be too close to some turrets, even tho they arent aggressive and not engaged in combat (turret in idle state, apparently the AI behind the turrets still target calc bugs up to some default legendary range). We decided to slowly add artillery around our borders.
Solution :
- First fixed the fulgora sorting station, gained approx 1fps out the 60, basically doing nothing
- Then added artillery around the "main base" (nothing around the 30km trench going East), tipped us back on track.
We believe there is something in the Flamethrower (or any turret) AI that makes it particulary bad in calc (over MP ?)
LogFile : Mods : vanilla spaceage, default mapgen
Screenshots :
Debug options Partial Layout of nauvis (cannot fit in one screenshot) Active Chunks around trench (sadly no screenshot around the flamethrowers) Frames back to 60FPS Layout of the mainbase defense border Save files : (approx 100MB)
- With 5FPS : https://drive.google.com/file/d/1oqPAPY ... drive_link
- With partial fix solution (gave us FPS back) : https://drive.google.com/file/d/1oKAYMn ... drive_link