Skip to content
pop4959 edited this page Feb 12, 2023 · 61 revisions

Frequently Asked Questions

How can I pre-generate faster?

Chunky is designed to run as fast as possible by default. That said, your server hardware and configuration will have a huge impact on chunk generation performance. You'll need to optimize if you want to speed things up. Here are some tips to start:

  • Use a faster CPU. High single threaded performance is important. For example, the Intel Core i9-13900K and AMD Ryzen 9 7950X are both excellent options. Obviously, a faster CPU will generally generate chunks faster.
  • In addition to having a fast CPU, make sure you have enough threads for your server. If not you will be bottlenecked since Modern versions of Minecraft will use many threads for generation. With a host or VPS, these may be called logical cores, virtual CPUs (vCPUs), or similar in your plan.
  • Run the server and world from an SSD. Most HDDs, especially old ones, will not be able to keep up with chunk generation and saving.
  • Allocate enough memory. At least 4GB RAM is recommended. Not having enough may slow chunk generation or even crash your server.
  • Use Aikar's flags for your server's start script. These help tune the Java garbage collector, which is important since constantly loading, generating, and unloading chunks on your server will aggressively cycle through memory.
  • Consider using Paper which supports async chunks, a custom lighting engine, and numerous other improvements which greatly improve chunk generation performance.
  • If using Paper, adjust the number of worker threads used by world generation. This is especially helpful for servers with a low number of available threads. This can be done by adding the -DPaper.WorkerThreadCount=X flag to your start script, where X is the number of threads you have. Remove the flag when you are done generating chunks. Alternatively, this can also be set in config/paper-global.yml via the worker-threads setting. Set it back to its default when done.
  • If using Fabric, try using Lithium for the general improvements to server performance it provides.
  • If using a map plugin or mod such as Dynmap, BlueMap, or Squaremap, try temporarily removing or disabling it during generation. Running them simultaneously will usually cause performance to drop, and running your render afterward tends to produce better results.

Can I pre-generate a world that already exists?

Yes, and it's completely safe. Chunky will skip chunks that already exist, and generate any missing ones.

Will Chunky continue to generate chunks after the server is restarted?

Not by default, but you can toggle the continue-on-restart option in the configuration to enable this feature. You may also have to reload the configuration in-game if you change this while the server is running for it to take effect. Active tasks can be saved manually by running the pause command, and are also automatically saved when the server shuts down normally.

Why is Chunky using all of my RAM?

In most cases it isn't actually Chunky that is using all of your server memory. The chunk pre-generation process itself is very memory intensive as the server will rapidly load and unload chunks. This is fully expected, and is normally not a problem. If your server is crashing, consider increasing the amount of RAM allocated to the server, or reduce it if it's possible you may be over-allocating. Aikar's flags are also recommended which will pre-allocate the memory for you.

How much disk space will my world use?

You can use a tool like tgb's World Size Calculator to get a rough estimation for default world generation. In general, note that world size is not linear, so each small increase in radius results in a much larger overall world. The type of world generation being performed is also a factor. For example, the Minecraft version, dimension, actively used mods, etc.

Can I pre-generate a world using plugins, mods, and data packs?

Yes, most if not all custom world generation will work. This is due to the fact that Chunky doesn't directly generate the chunks itself, but instead delegates this work to the server. If there is a problem it is usually caused by a configuration issue or a problem with the custom world generation you are using. Also note that custom generation tends to be slower than Vanilla and can take much longer to pre-generate.

My custom world generation is not working!

As mentioned above, Chunky isn't directly responsible for generating the chunks. Check to make sure that any modifications are compatible with your server. Also note that modifications will only take effect after they are installed, so you may need to create a new world or generate new chunks to see their impact. Data packs in particular can be tricky, as you may need to create the world and datapacks folder to install the pack before generating the spawn.

My map isn't updating!

Maps rendered by another plugin or mod such as Dynmap, Bluemap, or Squaremap will typically not automatically update themselves after you run chunky. Sometimes you will need to trigger a re-render manually. See map rendering and trimming chunks for more details.

Trim isn't working.

A common pitfall with trim is that it cannot delete chunks that are currently being loaded by the server. This includes chunks that players have loaded or recently loaded in-game, the spawn region, or any force loaded chunks. This is because loaded chunks will be re-saved to disk when the server shuts down. Usually if you make sure chunks aren't loaded and try again it will work.

Known errors

Unknown registry key

No key position_predicate in MapLike

These errors occur most frequently when you are upgrading a map from an older version of Minecraft, and are usually harmless.

java.lang.IllegalStateException: Asynchronous ChunkMapDistance::addPriorityTicket!

java.lang.IllegalStateException: Cannot add a chunk to a region which already has the chunk!

These errors have been known to occur on outdated servers. If you see this, make sure your server software is up-to-date.

java.lang.OutOfMemoryError: GC overhead limit exceeded

Consider increasing the amount of memory you give your server. Also see "Why is Chunky using all of my RAM?" above.

100% CPU usage detected. Mostly caused by server crash. Restarting Gameserver. (SIGTERM)

Some Minecraft server hosts will automatically kill servers with higher than normal CPU usage. This is a given for pre-generation, as higher CPU usage is expected. The only solution is to politely ask your host to remove the restriction, or switch to a better host.

Nag author: 'pop4959' of 'Chunky'

The server will show this warning if tasks aren't shut down quickly enough when the server is stopped. Usually this happens because the chunks that started generating before you stopped the server have not finished yet. This is not a bug, as the server will still have to wait until all chunks are done before shutting down. If you still wish to avoid this, run chunky pause and wait for the task to complete before shutting down your server.

Clone this wiki locally