Skip to content

Performance and memory ​

VanillaMine is tuned to run vanilla gameplay (mobs, redstone, the vanilla generator) on small and large servers alike. The defaults are good for most servers; this page explains the few settings worth knowing.

Performance profile ​

performance-profile in server.properties picks how the server uses resources. Both profiles play exactly the same: same gameplay, mobs, terrain and view distance.

ProfileForWhat changes
performance (default)Dedicated machines, servers with players most of the timeMemory and CPU kept ready for a smoother server.
economySmall plans, servers that are often emptyUnused chunks unloaded after 10 s (instead of 30), smaller world caches (4 MB instead of 16 MB per world), at most 2 async workers, 1 chunk generation worker, idle workers stopped after 60 s (instead of 300). New chunks can take a little longer to appear.

With 100 bots exploring a fresh world, economy used about 15% less memory at the same TPS and CPU. rendimiento and ahorro are accepted too. The profile is logged at startup.

The pocketmine.yml settings marked [profile] in the reference follow the profile while they keep their shipped value; any value you set yourself wins.

PHP binaries ​

Use the VanillaMine PHP binaries: their chunkutils2 extension runs the hot paths natively (chunk serialization, lighting, random ticks, entity physics, pathfinding). The server also starts with older binaries, without those speed-ups.

The PHP JIT cuts the server's PHP CPU by about 5-30%, depending on the load. PHP-Binaries ship it off; the Pterodactyl egg turns it on (PHP_JIT=tracing). Elsewhere, change this line of bin/php/php.ini (the JIT buffer is already set):

ini
opcache.jit=tracing

Memory ​

Most of the memory of a fresh server is the vanilla world generator: every async worker that generates terrain holds its own copy (~150-200 MB).

  • settings.async-workers: auto uses the cores the container may use (CPU limit and pinning are respected), minus 2, between 2 and 4 workers.
  • chunk-generation.max-workers (default 2): only these workers generate terrain; the others stay small.
  • memory.async-worker-idle-timeout (default 300 s): idle workers are stopped and give their memory back.
  • On a host with little RAM, use the economy profile, a lower view-distance, and pre-generate the world before opening it to players.

Ticks and players ​

  • chunk-ticking.simulation-distance (default 4): the radius of chunks around each player where mobs and blocks tick, like the simulation distance of Bedrock worlds. Players still see view-distance chunks.
  • chunk-sending.fast-spawn (default on): spawn chunks are prepared while the player is still logging in, so joins take about a second less.
  • auto-save.tick-budget-ms (default 5): autosaves are spread over ticks instead of freezing the server.
  • mobs.disabled-worlds: worlds without mobs (lobbies), with no mob AI cost at all.

Measuring ​

/status shows TPS, tick load and memory; a healthy server keeps 20 TPS. To see where the tick time goes, run /timings on, play for a few minutes, then /timings report.

VanillaMine is a fork of PocketMine-MP. Not affiliated with the PMMP team or Mojang.