Entering edit mode
12.1 years ago
hellbio
▴
520
Hi,
I am using the following command,
java -jar /csc/lohi/dog_tools/picard-tools-1.70/AddOrReplaceReadGroups.jar \
I=bull2.bam \
O=bull2_rg_sorted.bam \
SORT_ORDER=coordinate \
RGID=bull2 \
RGLB=bull2 \
RGPL=Illumina \
RGPU=bull2 \
RGSM=bull2 \
VALIDATION_STRINGENCY=SILENT \
CREATE_INDEX=True \
TMP_DIR=`pwd`/tmp
and it says
Exception in thread "main" net.sf.samtools.util.RuntimeIOException: java.io.IOException: (Too many open files)
Any suggestions to fix this?
MAX_FILE_HANDLES_FOR_READ_ENDS_MAP is a command line parameter for MarkDuplicates function whereas my task is AddOrReplaceReadGroups.jar which doesn't have the parameter.
Any help?
There is even another parameter for that. By looking at the link posted by Noolean you'll find:
Thank you for this information. I was struggling with Picard's
AddOrReplaceReadGroup
in order to sort and add Read Group information while converting my .sam to .bam file.ulimit -n (500,000)
didn't helped but then I usedMAX_RECORDS_IN_RAM=1000000
, which finally enabled my command to run successfully and I got the desired output .bam file.I was having problem with MarkDuplicates and setting
MAX_FILE_HANDLES_FOR_READ_ENDS_MAP
to 1000 as pointed out above does do the trick!Great, I will be happy if you upvote my answer in case it helped you.