Add JVM_EXPERIMENTAL_PERFORMANCE configuration to enable compact object headers and transparent huge pages in the JVM.
This commit is contained in:
1 parent
49af536786
commit
be08756c36
3 files changed
+57
-38
No files matched your search
@@ -38,27 +38,28 @@ podman run -d --name zomboidforge \
|
||||
|
||||
Unset variables keep the value in the server `.ini` (or the game default).
|
||||
|
||||
| Variable | Default | |
|
||||
|-------------------------------|--------------------------|-----------------------------------------------------------------------------------------------------------------------------|
|
||||
| `SERVER_NAME` | `zomboidforge` | Server config name (`/data/Server/<name>.ini`) |
|
||||
| `SERVER_PASSWORD` | | Password clients need to join (`.ini` `Password`) |
|
||||
| `PUBLIC` | | `true`/`false`: listed in the in-game server browser |
|
||||
| `PUBLIC_NAME` | | Name in the server browser |
|
||||
| `PORT` | `16261` | Game port (`-port`) |
|
||||
| `UDP_PORT` | `16262` | Direct connection port (`-udpport`) |
|
||||
| `UPNP` | | `true`/`false`: UPnP port mapping on the router (`.ini` `UPnP`); `false` recommended (see below) |
|
||||
| `ADMIN_USERNAME` | `admin` | First start only |
|
||||
| `ADMIN_PASSWORD` | | Required on the first start, ignored afterwards |
|
||||
| `SERVER_PRESET` | | Sandbox preset for a new server: `Apocalypse`, `Extinction`, `Outbreak`, `Rising`, `SixMonthsLater` |
|
||||
| `MODS` | | Mod IDs, Build 42 format: `\ModA;\ModB` |
|
||||
| `WORKSHOP_ITEMS` | | Workshop item IDs: `123;456` |
|
||||
| `RCON_PASSWORD` | | Written into the `.ini` on every start; RCON is disabled without it |
|
||||
| `JVM_MIN_HEAP` | JVM default | `-Xms`; unused heap memory is returned to the system only down to this size |
|
||||
| `JVM_MAX_HEAP` | 75 % of the memory limit | `-Xmx`; `8g` when the container has no memory limit |
|
||||
| `JVM_UNCOMMIT_DELAY` | `60` | Seconds after which unused heap memory is returned to the system (`-XX:ZUncommitDelay`) |
|
||||
| `STEAM` | `1` | `0` runs the server without Steam |
|
||||
| `SOFT_RESET` | | `true` starts once in soft reset mode (`-Dsoftreset`); unset it afterwards |
|
||||
| `ZF_EXPERIMENTAL_PERFORMANCE` | `false` | `true`/`false`: performance changes that alter timing or resource use (more threads, shorter waits); overrides `forge.toml` |
|
||||
| Variable | Default | |
|
||||
|--------------------------------|--------------------------|-----------------------------------------------------------------------------------------------------------------------------|
|
||||
| `SERVER_NAME` | `zomboidforge` | Server config name (`/data/Server/<name>.ini`) |
|
||||
| `SERVER_PASSWORD` | | Password clients need to join (`.ini` `Password`) |
|
||||
| `PUBLIC` | | `true`/`false`: listed in the in-game server browser |
|
||||
| `PUBLIC_NAME` | | Name in the server browser |
|
||||
| `PORT` | `16261` | Game port (`-port`) |
|
||||
| `UDP_PORT` | `16262` | Direct connection port (`-udpport`) |
|
||||
| `UPNP` | | `true`/`false`: UPnP port mapping on the router (`.ini` `UPnP`); `false` recommended (see below) |
|
||||
| `ADMIN_USERNAME` | `admin` | First start only |
|
||||
| `ADMIN_PASSWORD` | | Required on the first start, ignored afterwards |
|
||||
| `SERVER_PRESET` | | Sandbox preset for a new server: `Apocalypse`, `Extinction`, `Outbreak`, `Rising`, `SixMonthsLater` |
|
||||
| `MODS` | | Mod IDs, Build 42 format: `\ModA;\ModB` |
|
||||
| `WORKSHOP_ITEMS` | | Workshop item IDs: `123;456` |
|
||||
| `RCON_PASSWORD` | | Written into the `.ini` on every start; RCON is disabled without it |
|
||||
| `JVM_MIN_HEAP` | JVM default | `-Xms`; unused heap memory is returned to the system only down to this size |
|
||||
| `JVM_MAX_HEAP` | 75 % of the memory limit | `-Xmx`; `8g` when the container has no memory limit |
|
||||
| `JVM_UNCOMMIT_DELAY` | `60` | Seconds after which unused heap memory is returned to the system (`-XX:ZUncommitDelay`) |
|
||||
| `JVM_EXPERIMENTAL_PERFORMANCE` | `false` | `true`/`false`: `-XX:+UseCompactObjectHeaders` and `-XX:+UseTransparentHugePages` (see below) |
|
||||
| `STEAM` | `1` | `0` runs the server without Steam |
|
||||
| `SOFT_RESET` | | `true` starts once in soft reset mode (`-Dsoftreset`); unset it afterwards |
|
||||
| `ZF_EXPERIMENTAL_PERFORMANCE` | `false` | `true`/`false`: performance changes that alter timing or resource use (more threads, shorter waits); overrides `forge.toml` |
|
||||
|
||||
Notes:
|
||||
|
||||
@@ -76,6 +77,9 @@ Notes:
|
||||
rest stays for native memory. The startup briefly needs a large heap; with 8 players
|
||||
exploring, the heap held up to 4.4 GB of live data in tests. A limit below about 6 GB is
|
||||
not recommended. Without a limit the heap is `8g`, as in vanilla.
|
||||
- **Huge pages:** `JVM_EXPERIMENTAL_PERFORMANCE=true` maps the heap with transparent huge pages
|
||||
only when the host's `/sys/kernel/mm/transparent_hugepage/shmem_enabled` is `advise` or
|
||||
`always` (a container cannot change it); otherwise the JVM logs a warning and runs without them.
|
||||
- **Stopping:** `SIGTERM` triggers the game's own save-and-quit. Allow enough time for large worlds.
|
||||
|
||||
For local testing use `compose.yaml` (`podman compose up --build`, settings from `.env`).
|
||||
|
||||
Reference in new issue
Block a user