Hi Matt and Moshe,
I am using Juicer 2.0 and am running into a similar error. I have 3 technical replicates (1F and 1R for each) in the fastq directory. When I run the following command (modified to use "path/to" instead of the full path):
"juicer.sh -d path/to/Juicer -t 20 -z path/to/Pt_aquil_hifiasm_output_may8_nohic.asm.bp.p_ctg.fa -D path/to/juicer/ -p path/to/chrom.sizes &> juicer.log"
juicer is able to complete all alignment and chimera handling for runs 1 and 2, but then seems to fail on the 3rd technical replicate providing this error:
"merging from 1400 files and 20 in-memory blocks...
[E::hts_open_format] Failed to open file ./samtools.20402.5490.tmp.1021.bam
samtools sort: fail to open "./samtools.20402.5490.tmp.1021.bam": Too many open files
***! Failure during chimera handling of..."
my ulimit is set to "ulimit -n 2048"
I have not tried incorporating the -m 3G into the samtools sort function in the juicer.sh script partially. because I am unsure where exactly to incorporate it and I do not want to break the script.
Thank you for your help,
Jacob