Difference between revisions of "Reducing memory usage"

From Bisq Wiki
Jump to navigation Jump to search
(Created page with "== Default MaxRAM Setting == One of the settings java virtual machines use to calibrate how much physical memory to reserve at startup is called MaxRAM, and there is a good c...")
(No difference)

Revision as of 17:03, 4 April 2020

Default MaxRAM Setting

One of the settings java virtual machines use to calibrate how much physical memory to reserve at startup is called MaxRAM, and there is a good chance your JVM thinks it has more RAM to use than is installed on your machine. To check the default MaxRAM setting, run this java 'version' command:

   java -XX:+UnlockDiagnosticVMOptions -XX:+PrintFlagsFinal -version | grep MaxRAM

Look for the default MaxRAM setting in the output; this machine says

   367: uint64_t MaxRAM                                   = 137438953472                           {pd product} {default}

meaning my OpenJDK 11 JVM's MaxRAM setting is 128 GB, on a machine with only 16 GB RAM.

Experiments has shown that starting Bisq with a 4GB MaxRAM setting more than halves the resident memory consumption when starting a clean Bisq installation (with an empty data directory). Setting MaxRAM = 2GB reduces resident memory usage even more, but setting it any lower (1.5GB) will result in an OutOfMemoryError and crash the app.

As of version 1.2.7, Bisq starts up with a MaxRAM setting of 4GB.