Invalid or corrupt jar file
AnsweredI'm getting an invalid or corrupt .jar file error. I found somehow my java had switched to 11 but I changed that back to 8. Also, I switched to a miniconda install where 'gatk -help' actually provides the the help information. Before that I was running it from the extracted .zip gatk folder but after setting the path gatk -help wasn't returning anything. I also used this exact code in December 2020 using gatk-4.1.8.1 and it worked perfectly, though something seems to have broken it and I have no idea what
GATK version: 4.2.0.0
Java: openjdk version "1.8.0_152-release"
OpenJDK Runtime Environment (build 1.8.0_152-release-1056-b12)
OpenJDK 64-Bit Server VM (build 25.152-b12, mixed mode)
Python2: 2.7.18
Python3: 3.8.6
b) Exact command used:
ls *.sorted.bam | parallel --eta -j 20 "gatk --java-options "-Xmx4g" HaplotypeCaller -R ${ref}.fasta -ploidy 1 -I {} -O {.}.g.vcf -ERC GVCF"
c) Entire error log:
Using GATK jar /home/barlex/miniconda3/share/gatk4-4.2.0.0-1/gatk-package-4.2.0.0-local.jar
Running:
java -Dsamjdk.use_async_io_read_samtools=false -Dsamjdk.use_async_io_write_samtools=true -Dsamjdk.use_async_io_write_tribble=false -Dsamjdk.compression_level=2 -Xmx4g -jar /home/barlex/miniconda3/share/gatk4-4.2.0.0-1/gatk-package-4.2.0.0-local.jar HaplotypeCaller -R .fasta -ploidy 2 -I 99.sorted.bam -O 99.sorted.g.vcf -ERC GVCF
ETA: 0s Left: 0 AVG: 0.01s local:0/113/100%/0.0s
Sorry if this is a simple fix but I'm stumped
-
Hi Shaun Clare,
I always recommend starting with the README on this page for help with installing GATK: https://github.com/broadinstitute/gatk
There might be an issue with your command (ls *.sorted.bam | parallel --eta -j 20 "gatk --java-options "-Xmx4g" HaplotypeCaller -R ${ref}.fasta -ploidy 1 -I {} -O {.}.g.vcf -ERC GVCF"). Try running just the GATK command line to see what happens and then you can troubleshoot from there.
Best,
Genevieve
-
Running GATK worked fine and that code had worked previously. I couldn't find the error so I rebuilt my Ubuntu from scratch a while ago and it fixed everything so the code works again.
Thanks,
Shaun
-
Thanks for posting your solution Shaun! Glad you have gotten it to work.
Please sign in to leave a comment.
3 comments