This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Bwa Index Segmentation Fault

I am having problem in indexing .fa file using bwa - any help would be greatly appreciated.

I am trying to index Homo_sapiens.GRCh37 ...fa file using the command

bwa index -p myGenome -a bwtsw /directory/myGenome.fa

but it keeps giving me the following error

[bwaindex] Pack FASTA... 56.76 sec [bwaindex] Reverse the packed sequence... Segmentation fault

Can someone please help me with possible suggestion to fix this. Thank you.

bwa index

can you please give a little more info about your OS and the version of bwa you are using? It is amazing how few people know about how to make a proper bug-report these days.

Thanks so much for your time in looking into post and replying. Actually I figured it out - I didn't know that to index human genome using bwa, need atleast 2gb of memory. So it was more hardware related issue. Thanks again.

1 answer

I want to use this occasion to give some advice on how to write a good bug report not only in bioinformatics. To do that, try to take the point of view of the person to debug the software, they need a reproducible example, otherwise they might respond, "sorry works for me". There are various versions of software and OS. a good report (for a lokal tool) contains at least 4 things:

  1. The version of the software and how it was built (moist software has a --version switch)
  2. The OS and its version (give the output of uname -a)
  3. The exact command or what you did exactly, in particular this case required to post the input data.
  4. The exact error message

In addition, information about hardware and memory would be required, because memory is so obivously an issue here.

Example:

$ bwa
Program: bwa (alignment via Burrows-Wheeler transformation)
Version: 0.5.7 (r1310)

(downloaded from sourceforge)

$ uname -a
Darwin MyMac.local 10.8.0 Darwin Kernel Version 10.8.0: Tue Jun  7 16:33:36 PDT 2011;         root:xnu-1504.15.3~1/RELEASE_I386 i386

bwa index -p myGenome -a bwtsw myGenome.fa (make the file myGenome.fa downloadable)
Some nasty error message ... core dumped

Oh, and my machine has only 1 GB of memory!

You only had points 3 and 4 partially.

Agreed. Sorry again.

don't worry, at least we got a template now. And, if out of memory, the program should say so and not segfault.

Log in to answer this question.