Seqanswers Leaderboard Ad

Collapse

Announcement

Collapse
No announcement yet.
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • BWA sampe fails - invalid BAM binary header (

    Hi,
    I am trying to use BWA for analysing human whole exome PE data (Illumina HiSeq) for the first time.
    I downloaded the hg19 genome as a reference as indexed it with bwa index.
    Then aligned with bwa aln with the following format of command (for eacg fastq file):

    nohup bwa aln ~/work_area/hg19_genome/hg19_chromFa.tar.gz SG1177_2_sequence.txt > SG1177_2_aln_sa.sai &

    from the ~10Gb fastq files I got ~1.3 Gb sai files.

    But when I am trying to use sampe to get the sam files, it doesn't work, and the output file contains the following comments:
    [bam_header_read] invalid BAM binary header (this is not a BAM file).
    [bam_header_read] invalid BAM binary header (this is not a BAM file).
    [bwa_read_seq] the maximum barcode length is 63.
    then the list of chromosomes
    and end.

    Here is the sampe command I used:
    nohup bwa sampe ~/work_area/hg19_genome/hg19_chromFa.tar.gz SG1177_1_aln_sa.sai SG1177_2_aln_sa.sai SG1177_1_sequence.txt SG1177_2_sequence.txt &

    What did I do wrong?

    Many thanks in advance!

  • #2
    Hello,

    According to the bwa documentation, the reference should be a FASTA file.


    http://bio-bwa.sourceforge.net/bwa.shtml


    Your reference is hg19_chromFa.tar.gz -- this is a compressed archive likely containing many files.

    Sébastien Boisvert

    Originally posted by Lilach View Post
    Hi,
    I am trying to use BWA for analysing human whole exome PE data (Illumina HiSeq) for the first time.
    I downloaded the hg19 genome as a reference as indexed it with bwa index.
    Then aligned with bwa aln with the following format of command (for eacg fastq file):

    nohup bwa aln ~/work_area/hg19_genome/hg19_chromFa.tar.gz SG1177_2_sequence.txt > SG1177_2_aln_sa.sai &

    from the ~10Gb fastq files I got ~1.3 Gb sai files.

    But when I am trying to use sampe to get the sam files, it doesn't work, and the output file contains the following comments:
    [bam_header_read] invalid BAM binary header (this is not a BAM file).
    [bam_header_read] invalid BAM binary header (this is not a BAM file).
    [bwa_read_seq] the maximum barcode length is 63.
    then the list of chromosomes
    and end.

    Here is the sampe command I used:
    nohup bwa sampe ~/work_area/hg19_genome/hg19_chromFa.tar.gz SG1177_1_aln_sa.sai SG1177_2_aln_sa.sai SG1177_1_sequence.txt SG1177_2_sequence.txt &

    What did I do wrong?

    Many thanks in advance!

    Comment


    • #3
      solution

      After solving the prolem, I am writing here the solution, in case somebody else will search for a solution for this proble:

      The problem was not in giving hg19_chromFa.tar.gz as a reference file. BWA knows to work with it.

      The reason for the problem was that I tried to run the bwa commands in the background (in nohup...&) or via a Putty SSH terminal (that crashed in the middle).
      This command should NOT be executed in the background, so the only way to run it in a far computer in by VPN. Then, run it without nohup ... &.

      Comment


      • #4
        Yeah, incompatibility with nohup has been reported on other threads on Seqanswers.

        Comment


        • #5
          The program screen is useful for that kind of workflow.

          You can start your things in a screen, close your window. After that, you can re-ssh to
          your box and reconnect to your screen. In one screen, you can have several tabs too.

          Sébastien

          Comment

          Latest Articles

          Collapse

          • seqadmin
            Strategies for Sequencing Challenging Samples
            by seqadmin


            Despite advancements in sequencing platforms and related sample preparation technologies, certain sample types continue to present significant challenges that can compromise sequencing results. Pedro Echave, Senior Manager of the Global Business Segment at Revvity, explained that the success of a sequencing experiment ultimately depends on the amount and integrity of the nucleic acid template (RNA or DNA) obtained from a sample. “The better the quality of the nucleic acid isolated...
            03-22-2024, 06:39 AM
          • seqadmin
            Techniques and Challenges in Conservation Genomics
            by seqadmin



            The field of conservation genomics centers on applying genomics technologies in support of conservation efforts and the preservation of biodiversity. This article features interviews with two researchers who showcase their innovative work and highlight the current state and future of conservation genomics.

            Avian Conservation
            Matthew DeSaix, a recent doctoral graduate from Kristen Ruegg’s lab at The University of Colorado, shared that most of his research...
            03-08-2024, 10:41 AM

          ad_right_rmr

          Collapse

          News

          Collapse

          Topics Statistics Last Post
          Started by seqadmin, Yesterday, 06:37 PM
          0 responses
          8 views
          0 likes
          Last Post seqadmin  
          Started by seqadmin, Yesterday, 06:07 PM
          0 responses
          8 views
          0 likes
          Last Post seqadmin  
          Started by seqadmin, 03-22-2024, 10:03 AM
          0 responses
          49 views
          0 likes
          Last Post seqadmin  
          Started by seqadmin, 03-21-2024, 07:32 AM
          0 responses
          66 views
          0 likes
          Last Post seqadmin  
          Working...
          X