1

I'm trying to run the Java program trimmomatic.jar and I'm getting an error related to "initial heap". Any idea what this is?

java -Xmx500 -jar trimmomatic.jar PE -threads 20 -phred33 ../ERR318658.1.fastq ../ERR318658.2.fastq ERR318658.1_kneaddata.trimmed.1.fastq ERR318658.1_kneaddata.trimmed.single.1.fastq ERR318658.1_kneaddata.trimmed.2.fastq ERR318658.1_kneaddata.trimmed.single.2.fastq

Error:

Error occurred during initialization of VM
Too small initial heap
1
  • 1
    It works when I remove the parameter "-Xmx500" Nov 11 '20 at 10:08
1

As stated in this response :
https://stackoverflow.com/questions/5374455/what-does-java-option-xmx-stand-for/5374501#5374501

This value must a multiple of 1024 greater than 2MB.

and

Append the letter k or K to indicate kilobytes, or m or M to indicate megabytes.

So you should get better results with -Xmx500m because -Xmx500 means you launch the JVM with max memory of 500 bytes, which is far too small AND not a multiple of 1024 !

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.