Just to keep the list in the loop, this was posted over on seqanswers too
and the cause ended up being that "-Sbt" was needed rather than just "-bt".
Version 0.1.18 was being used, but even there -t looks like it forces -S in
the code, so it's still unclear why this happened (perhaps a transient
filesystem error caused a malformed BAM file and all that was needed was
rerunning the conversion). But in any case, Marine was able to get the file
converted.
Devon
--
Devon Ryan, Ph.D.
Email: [email protected]
Laboratory for Molecular and Cellular Cognition
German Centre for Neurodegenerative Diseases (DZNE)
Ludwig-Erhard-Allee 2
53175 Bonn
Germany
<[email protected]>
On Wed, Jun 4, 2014 at 2:49 PM, Thomas W. Blackwell <[email protected]>
wrote:
> Marine -
>
> The command lines look good. Could this be a local file system
> problem -- "no space left on device", or something like that ?
> Or a typing error in one of the file names ? I'm just guessing,
> but that's what I would look for.
>
> Oh, just remembered: a favorite error of mine used to be making
> <out.prefix> the same as the name of the unsorted input .bam file.
> When I do that, the unsorted .bam file gets deleted from the file
> system before it is ever read. The two file names have to be
> different.
>
> - tom blackwell -
>
> On Wed, 4 Jun 2014, Marine Rohmer wrote:
>
> > Hello Samtools team,
> >
> > I try to convert some SAM files to BAM files following the FAQ method :
> > First indexing my reference fasta file (I have no header in my SAM file)
> > :
> > samtools faidx ref.fa
> > Then converting my SAM file to BAM file :
> > samtools view -bt ref.fa.fai aln.sam > aln.bam
> >
> > Until here, everything seems fine, but...
> >
> > When trying to sort my BAM file :
> > samtools sort aln.bam aln-sorted
> > I instantly get :
> > [bam_header_read] invalid BAM binary header (this is not a BAM file).
> > [bam_sort_core] truncated file. Continue anyway.
> > Seegmentation fault (core dumped)
> >
> > I really don't understand what is happening. My SAM file seems OK.
> > Several weeks ago I've already done that on another data and everything
> > went fine... Could someone tell me what is wrong ?
> > I'd be very grateful if someone could help me !!! :)
> >
> > Hoping I'm writing to good mailing list
> >
> > Best regards,
> >
> > Marine
> >
> >
> >
> ------------------------------------------------------------------------------
> > Learn Graph Databases - Download FREE O'Reilly Book
> > "Graph Databases" is the definitive new guide to graph databases and
> their
> > applications. Written by three acclaimed leaders in the field,
> > this first edition is now available. Download your free book today!
> > http://p.sf.net/sfu/NeoTech
> > _______________________________________________
> > Samtools-help mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/samtools-help
> >
>
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Samtools-help mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/samtools-help
>
------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Samtools-help mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/samtools-help