Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-234995

OutOfMemory crash upon attempting to save a world with very large amounts of block entities

    XMLWordPrintable

Details

    • Bug
    • Status: Open
    • Resolution: Unresolved
    • 1.17.1, 21w37a, 21w38a, 21w39a, 21w40a, 21w41a, 21w42a, 21w43a, 21w44a, 1.18 Pre-release 1, 1.18 Pre-release 4, 1.18 Pre-release 5, 1.18 Release Candidate 3
    • None
    • Confirmed
    • Crash, Performance
    • Very Important

    Description

      The bug

      Very large amounts of block entities (in this case, furnaces) cause intense server-side lag (MC-117075) and use up excessive memory. This will cause the world to fail to save, and the game to run out of memory and crash. This does not happen on superflat worlds with furnaces.

      To reproduce

      1. Create a new world and switch to spectator mode.
      2. Execute /fill ~50 ~ ~50 ~-50 ~2 ~-50 furnace and create multiple layers of tens of thousands of furnaces in the world.
      3. Continue to execute the commands up to y=255 until about a million furnaces are placed.
      4. Notice how extreme lag occurs, and observe the Mem usage steadily going up.
      5. Quit the world.
      6. The world will get stuck in the saving world screen, until failing to save and crashing due to java.lang.OutOfMemoryError: Java heap space.

      Attachments

        1. 2021-08-21_20_00_32-New World-1_17_1.zip
          2.09 MB
        2. 2021-10-31-1.log
          20 kB
        3. 2021-11-09_21.58.07.png
          2021-11-09_21.58.07.png
          60 kB
        4. crash-2021-09-24_22.31.29-server.txt
          4 kB
        5. crash-2021-10-04_19.57.02-client.txt
          4 kB
        6. crash-2021-11-14_21.41.58-server.txt.zip
          2 kB
        7. crash-2021-11-27_22.33.07-client.txt
          5 kB
        8. deobf_crash-2021-09-24_22.31.29-server.txt
          6 kB
        9. deobf_crash-2021-11-27_22.33.07-client.txt
          9 kB
        10. error_log_(abridged).txt
          3 kB
        11. latest_2.log
          27 kB
        12. latest.log
          41 kB
        13. latest-1.log
          24 kB

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ampolive [Helper] ampolive
              Votes:
              7 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                CHK: