Uploaded image for project: 'Spigot'
  1. Spigot
  2. SPIGOT-6763

spigot 1.17 takes much more memory use than spigot 1.16

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved (View Workflow)
    • Minor
    • Resolution: Invalid
    • None
    • None
    • This server is running CraftBukkit version 3262-Spigot-dc75aca-f0f801e (MC: 1.17.1) (Implementing API version 1.17.1-R0.1-SNAPSHOT)
    • no plugins
    • Yes

    Description

      as described in title, I find that spigot 1.17 takes much more memory usage than 1.16 on OracleJDK16 and zuluOpenJDK17 both of which are based on hotspot JVM. But for OpenJDK16 with openj9 JVM, the memory usage is much less and very close to the 1.16 memory usage.

      I build the spigot via OracleJDK16 for spigot 1.17.1 and 1.16.5 and start the server with no plugins.Here is my start script. Each time i will start the server and wait for 1 minutes after the CPU usage drop close to zero.

       

      @echo off
      title testServer
      set JAVA_HOME=C:\Program Files\Java\jdk-16.0.2
      set CLASSPATH=.;%JAVA_HOME%\lib\dt.jar;%JAVA_HOME%\lib\tools.jar;
      set PATH=%JAVA_HOME%\bin;
      java -Xms1G -Xmx12G -jar spigot.jar nogui

       

      the third to fifth lines are used to set java path, I change it to test different JDK. The JVM parameters are the same for the following tests.

       

      The result is as following:

      OracleJDK16, spigot 1.17.1

      OracleJDK16, spigot 1.16.5

      OpenJDK16, spigot 1.17.1

      The first three tests were made in my computer with windows 10 professional and 16G RAM.And if when testing in my windows server with 128G RAM, it takes more RAM usage(with OracleJDK16)

      And the zulu OpenJDK16 also consumes much more RAM usage in 1.17.

      I have tested paper too, it behaves normal both for hotspot and j9vm and takes much less memory space.

       

      Though when updating to a higher version of minecraft server usually means more CPU and RAM usage, but I think the doubled memory usage is abnormal. You might want to tell me that I should make xms=xmx. But anyway, a lower memory usage is much more better, is not it?

       

      Attachments

        1. image-2021-10-18-12-07-18-078.png
          17 kB
          1055Lab
        2. image-2021-10-18-12-10-30-833.png
          18 kB
          1055Lab
        3. image-2021-10-18-12-13-18-275.png
          14 kB
          1055Lab
        4. image-2021-10-18-12-20-37-776.png
          67 kB
          1055Lab
        5. image-2021-10-18-12-28-14-560.png
          71 kB
          1055Lab

        Activity

          People

            Unassigned Unassigned
            1055Lab 1055Lab
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: