Summary
On Project Zomboid Build 42 (B42), dedicated servers running on machines with 8GB RAM or less may fail to start and throw a Java Memory Error during startup.
This is not a corruption or mod-related issue. It is caused by an overly aggressive default Java heap allocation that exceeds what the system can safely reserve.
Affected Systems
Build 42 ships with a default Java configuration that includes:
-Xmx8g inside ProjectZomboid64.json file
Solution / Workaround
Edit file ProjectZomboid64.json inside your root folder
Find the line "-Xmx8g",
Change to something lower
Recommended values:
System RAM Recommended Xmx
8GB -Xmx6g
6GB -Xmx4g
4GB -Xmx3g
Save and restart the server