Hello, I did the following steps: 1. Prinseq 2. Sickle 3. BWA for Illumina and 4. SAM to BAM 5. MarkDuplicates After MakrDuplicates, I got the following error: [bam_header_read] EOF marker is absent. The input is probably truncated. [bam_header_read] invalid BAM binary header (this is not a BAM file). [bam_index_core] Invalid BAM header.[bam_index_build2] fail to index the BAM file. Fatal error: Exit code 1 ()
Picked up _JAVA_OPTIONS: -Xmx2048m -Xms256m Ignoring SAM validation error: ERROR: Record 579, Read name NS500334:41:HLLLKBGXX:3:21601:2035:8235, MAPQ should be 0 for unmapped read. Exception in thread "main" htsjdk.samtools.SAMException: Value was put into PairInfoMap more than once. 370: C_BATCH2:NS500334:41:HLLLKBGXX:1:21102:18509:10014 at htsjdk.samtools.CoordinateSortedPairInfoMap.ensureSequenceLoaded(CoordinateSortedPairInfoMap.java:132) at htsjdk.samtools.CoordinateSortedPairInfoMap.remove(CoordinateSortedPairInfoMap.java:86) at picard.sam.markduplicates.util.DiskBasedReadEndsForMarkDuplicatesMap.remove(DiskBasedReadEndsForMarkDuplicatesMap.java:61) at picard.sam.markduplicates.MarkDuplicates.buildSortedReadEndLists(MarkDuplicates.java:285) at picard.sam.markduplicates.MarkDuplicates.doWork(MarkDuplicates.java:114) at picard.cmdline.CommandLineProgram.instanceMain(CommandLineProgram.java:206) at picard.cmdline.PicardCommandLine.instanceMain(PicardCommandLine.java:95) at picard.cmdline.PicardCommandLine.main(PicardCommandLine.java:105) [bam_header_read] bgzf_check_EOF: Invalid argument
I was able to fix it with samtools view -h Galaxy62-\[SAM-to-BAM_on_data_10_and_data_54__converted_BAM\].bam | grep -v null | samtools view -bS - > Galaxy62.bam
I just wonder whether it is possible to do it anyhow to fix it in Galaxy or is it possible to fix the FASTQ files after PrinSeq and Sickle?
Thank you in advance.
Mic