Entering edit mode
23 months ago
Eliveri
▴
350
I have a nextflow pipeline which runs the following argument in script for a process using memory '16 GB':
gatk --java-options "-Xmx16g -Xms16g" SortSam -R $ref -I ${pair_id}.clean.bam -O ${pair_id}.sorted.bam -SO coordinate --CREATE_INDEX true
At first the issue was java.io.IOException: No space left on device
So I referred to the following posts
And added the -Djava.io.tmpdir=`pwd`/tmp
but now I am still having issues. I get error ERROR: Invalid argument '-R'
.
gatk --java-options "-Xmx16g -Xms16g -Djava.io.tmpdir=`pwd`/tmp" SortSam -R $ref -I ${pair_id}.clean.bam -O ${pair_id}.sorted.bam -SO coordinate --CREATE_INDEX true TMP_DIR=`pwd`/tmp
I tried with various combinations
gatk --java-options "-Djava.io.tmpdir=`pwd`/tmp" "-Xmx16g -Xms16g" SortSam -R $ref -I ${pair_id}.clean.bam -O ${pair_id}.sorted.bam -SO coordinate --CREATE_INDEX true TMP_DIR=`pwd`/tmp
Sometimes it does not recognize the "-Djava.io.tmpdir=.."
parameter, sometimes it does not recognize the "-Xmx16g -Xms16g"
parameter, and sometimes it does not recognize -R
after SamSort.
Hi! What kind of error do you get? Could you copy paste it? Also, could you copy paste the actual nextflow code (not just the
gatk
command)? When I callgatk
withinnextflow
I don't add quotes in-Xmx${java_memory}m
. Regarding thetmp
path, maybe it is safer to provide a full path, without callingpwd
and such.for a start You put two values for --java-options . Use
${PWD}
instead of a call topwd
. Furthermore, why using the slow gatk when you can usesamtools sort
?Thank you all,
--TMP_DIR .
solved the issue