Unconfigured Ad

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • michalkovac
    Member
    • Nov 2010
    • 13

    SAMTOOLS mpileup crash

    Hi,

    anyone has an indea why I'm getting this error message?
    In-----
    samtools mpileup -gf ./Reference_Indexed/Human36.fa ./2007.0214 B.normal.merged.out.bam > normal.test.bcf

    It generates sort of 3GB of data when the crash comes in.
    Out----
    mpileup] 1 samples in 1 input files
    <mpileup> Set max per-sample depth to 8000
    sh: line 24: 7723 Segmentation fault

    It also does not parse the whole bam file when mpileup is piped into bcftools command as is suggested in the manual:
    samtools mpileup -ugf ref.fa aln.bam | bcftools view -bvcg - > var.raw.bcf

    BTW, pileup does not have any problems with the bam file. It has been generated by SAMTOOLS using SAM output of Stampy-BWA aligners.

    Many thanks for any suggestions.
  • KNS
    Member
    • Aug 2010
    • 17

    #2
    There has been a few issues with the output generated by samtools mpileup - see a couple of recent threads including my post "Unstable output from mpileup/samtools" here in the bioinformatics forum. There do not seem to be good answers to this issue for now, but I am hopeful the developer is having a look.

    Comment

    • lh3
      Senior Member
      • Feb 2008
      • 686

      #3
      @michalkovac

      try 0.1.11; if that does not help, could you send me the alignment around the point it breaks? Thanks.

      @KNS

      It is thanksgivings in US. Please give me time. Mpileup has been used for tera bytes of data. It has not segfaulted so far at my hand. There must be something I have not considered in your data. But I can only help if you share me with your data (I cannot reproduce the problem with zee's example). Thank you.
      Last edited by lh3; 11-25-2010, 08:02 PM.

      Comment

      • michalkovac
        Member
        • Nov 2010
        • 13

        #4
        Thanks lh3. I've updated samtools to the latest version though is still crashing. As to the point where the crash actually happens: It completes chr13_random, but does not start assembling chr14.

        Should it help if I send you the link to my bam file?

        Many thanks for you time.
        M.

        Comment

        • lh3
          Senior Member
          • Feb 2008
          • 686

          #5
          Yes. That would be great. Many thanks.

          Comment

          • michalkovac
            Member
            • Nov 2010
            • 13

            #6
            Originally posted by lh3 View Post
            Yes. That would be great. Many thanks.
            Link has been posted to your mail. Many thanks.
            M.

            Comment

            • lh3
              Senior Member
              • Feb 2008
              • 686

              #7
              Please try the latest SVN:

              svn co https://samtools.svn.sourceforge.net...trunk/samtools

              Your example is really helpful. Thank you very much!

              Comment

              • lh3
                Senior Member
                • Feb 2008
                • 686

                #8
                0.1.12 is released, mainly for this bug fix.

                Comment

                • michalkovac
                  Member
                  • Nov 2010
                  • 13

                  #9
                  ^^ many thanks. now it seems to work.

                  Comment

                  • LisaM
                    Junior Member
                    • Jan 2011
                    • 2

                    #10
                    Hi,

                    I'm having a similar problem with mpileup on the newest revision (397).

                    In:
                    samtools mpileup -C50 -gf ref.fasta in.bam > out.bcf

                    Out:
                    [mpileup] 1 samples in 1 input files
                    <mpileup> Set max per-sample depth to 8000
                    Segmentation fault

                    The tool has no problem with the bam file if the fasta file is not included (ie. no -f), so the bam file is ok.

                    However, the default instructions provided in the mpileup manual does work:
                    samtools mpileup -ugf ref.fasta in.bam | bcftools view -bvcg - > var.raw.bcf

                    Any help on this would be much appreciated. Please let me know if you need any additional information.

                    Thanks in advance,
                    Lisa


                    -- UPDATE --

                    I've rerun mpileup a couple of times since, and it looks like it's just the -g or -u tag that's seg faulting. At mpileup -C50 -f, everything seems to run fine. And I also realized that although the default command ran, it did not complete properly, as the resulting .bcf file was not complete.

                    Hope this helps!
                    Last edited by LisaM; 01-14-2011, 04:58 PM.

                    Comment

                    • jmt
                      Junior Member
                      • Jun 2011
                      • 5

                      #11
                      segmentation fault for mpileup

                      I am having troubles getting 'mpileup' to run correctly w/o a segmentation fault.

                      I would like to run 'mpileup' on 2 bam files on a set of sites.

                      I ran the following and got the following error.

                      samtools mpileup -f $INDEX -l $LIST_OF_SITES $BAM1 $BAM2
                      [bam_header_read] EOF marker is absent. The input is probably truncated.
                      [mpileup] 1 samples in 2 input files
                      <mpileup> Set max per-file depth to 8000
                      Segmentation fault

                      However, when I ran on just 1 bam file, it seems to work just fine.

                      samtools mpileup -f $INDEX -l $LIST_OF_SITES $BAM1
                      [mpileup] 1 samples in 1 input files
                      <mpileup> Set max per-file depth to 8000
                      Y 10645915 T 2 Aa IF
                      Y 10646057 G 3 Aaa A>,
                      Y 11726507 T 1 . <
                      Y 11771361 G 1 a F
                      Y 11929118 T 34 ..,,,,,,.,.......,..,.,..,,...,... B?IIA?DFFAFI6DFFFFFF8FDEBAGFHI9IFI
                      Y 19612396 G 1 . 3
                      Y 19612484 G 1 A 3
                      Y 19612796 G 1 . I

                      Could someone tell me what stupid mistake I'm making?

                      Thanks in advance!

                      Comment

                      • michalkovac
                        Member
                        • Nov 2010
                        • 13

                        #12
                        Originally posted by jmt View Post
                        samtools mpileup -f $INDEX -l $LIST_OF_SITES $BAM1 $BAM2
                        [bam_header_read] EOF marker is absent. The input is probably truncated.
                        [mpileup] 1 samples in 2 input files
                        <mpileup> Set max per-file depth to 8000
                        Segmentation fault
                        I'd suggest you run Picard ValidateSamFile on your BAMs. If it doesn't find EOF, some of your SAM/BAM processing steps have not been fully completed.

                        Comment

                        • jmt
                          Junior Member
                          • Jun 2011
                          • 5

                          #13
                          Hi michalkovac,

                          These bam files are the 1000G alignment files from the pilot study. Will running Picard ValidateSamFile correct the EOF error?

                          At the moment I've resorted to running mpileup on the bam files individually one by one and then writing my own script to combine the pileup output. This way seems to work thus far.

                          Comment

                          • rna-analys
                            Junior Member
                            • Nov 2011
                            • 1

                            #14
                            samtools mpileup -d8000 will solve the problem

                            Comment

                            • Idon_Sokolov
                              Junior Member
                              • Jan 2017
                              • 2

                              #15
                              Hello, I´m having the same problem. I´m analysing exome data obtained from exome sequencing. The only step in order to finish my analysis is getting the consensus calls from my samples. This is the command that I´m putting in the console:

                              samtools mpileup -ugf Homo_sapiens.GRCh38.dna.alt.fa.gz Illumina9.0.0_bwamem.sort.rmdup.bam Illumina9.0.0_bwamem.sort.rmdup.readfiltered.bam | bcftools call -vmO z -o illumina9

                              But this is my result:

                              [main] Unrecognized command.
                              [mpileup] 1 samples in 2 input files
                              <mpileup> Set max per-file depth to 8000

                              Please, help me.

                              Thank you for your time.
                              Best regard.

                              Comment

                              Latest Articles

                              Collapse

                              • SEQadmin2
                                Proteomic Platforms: How to Choose the Right Analytical Strategy to Improve Detection and Clinical Applications
                                by SEQadmin2


                                Proteomics platforms are evolving rapidly, with advances in mass spectrometry and affinity-based approaches expanding what researchers can detect and at what scale. As the field moves toward deeper proteome coverage and clinical applications, scientists face an increasingly complex landscape of tools. This article will explore how researchers are navigating these choices to find the right platform for their work.

                                The systematic characterization of the human proteome has
                                ...
                                07-20-2026, 11:48 AM
                              • SEQadmin2
                                Advanced Sequencing Platforms Tackle Neuroscience’s Toughest Genomics Problems
                                by SEQadmin2



                                Genomics studies in neuroscience face a special challenge due to the brain’s complexity and scarcity of samples. Mapping changes in cell type and state using conventional next-generation sequencing methods remains challenging. Advances in technologies like single-cell sequencing, spatial transcriptomics, and long-read sequencing have opened the door to deeper studies of the brain and diseases like Alzheimer’s, amyotrophic lateral sclerosis (ALS), and schizophrenia.
                                ...
                                07-09-2026, 11:10 AM
                              • SEQadmin2
                                Cancer Drug Resistance: The Lingering Barrier to Rising Survival
                                by SEQadmin2



                                Cancer survival rates have significantly increased in the last few decades in the United States, reaching a combined 70% 5-year survival rate by 2021. Behind this number, there are years of research to find new therapies, drug targets, and early detection methods. But there is one core challenge that keeps slowing down these advances, and it’s about drug resistance.

                                There is no single reason why many patients don’t respond to treatment as expected. Cancer is...
                                07-08-2026, 05:17 AM

                              ad_right_rmr

                              Collapse

                              News

                              Collapse

                              Topics Statistics Last Post
                              Started by SEQadmin2, Yesterday, 12:17 PM
                              0 responses
                              10 views
                              0 reactions
                              Last Post SEQadmin2  
                              Started by SEQadmin2, 07-23-2026, 11:41 AM
                              0 responses
                              11 views
                              0 reactions
                              Last Post SEQadmin2  
                              Started by SEQadmin2, 07-20-2026, 11:10 AM
                              0 responses
                              23 views
                              0 reactions
                              Last Post SEQadmin2  
                              Started by SEQadmin2, 07-13-2026, 10:26 AM
                              0 responses
                              37 views
                              0 reactions
                              Last Post SEQadmin2  
                              Working...