Indexing a reference genome
1
0
Entering edit mode
8.0 years ago
maxgen • 0

I am Mac user trying to run Bowtie on the example data provided in bowtie manual. When I am trying to index the genome file I am getting the following error: Script is:

cd ~ /Users/Desktop/data/bowtie2 
/Users/Anu/Desktop/data/bowtie2/bowtie2-build /Users/Desktop/data/bowtie2/example/reference/lambda_virus.fa 

Error is:
Traceback (most recent call last):
  File "/Users/Anu/Desktop/data/bowtie2/bowtie2-build", line 95, in <module>
    main()
  File "/Users/Anu/Desktop/data/bowtie2/bowtie2-build", line 92, in main
    os.execv(build_bin_spec, argv)
OSError: [Errno 8] Exec format error

Help is appreciated

alignment • 3.2k views
ADD COMMENT
0
Entering edit mode

Is lambda_virus.fa in fasta fomat? Add a base name for your index at the end of the command line. Try

/Users/Anu/Desktop/data/bowtie2/bowtie2-build -f /Users/Desktop/data/bowtie2/example/reference/lambda_virus.fa lambda
ADD REPLY
0
Entering edit mode

Still the same error lambda_virus is in fasta format.....

ADD REPLY
0
Entering edit mode

In addition to the missing base name, as indicated by GenoMax2, your path is wrong. The path to your reference fasta file cannot be /Users/Desktop/data.

I would do the following troubleshooting steps. 1. Correct the path. 2. Add the base name, as suggested by genomax2. 3. Check if you have the latest version of Bowtie2. 4 If you still have problems, copy paste here the Bowtie2 version, the command and the error.

ADD REPLY
0
Entering edit mode

Have you installed and compiled Bowtie2?

The error looks like it might be coming from the OS rather than from Bowtie2.

ADD REPLY
2
Entering edit mode

Since the bowtie2-build seems to be present the error may actually be due an executable that was compiled for a different OS. @maxgen: You may have downloaded linux executables (you appear to be using Mac OS).

ADD REPLY
0
Entering edit mode

Congrats. Pretty sure you found the bug in maxgen's command. I was able to reproduce exactly the same error message on my Mac, by trying to run the Bowtie for Linux.

I'm not really sure why there is a python script calling a C++ program, but the initial bowtie-2-build Python script runs fine initially. It fails at line 92 when it tries to run the C++ program, which was probably compiled for Linux, and not Mac.


blancha@hai04 ~/Downloads/bowtie2-2.2.9$ bowtie2-build Traceback (most recent call last): File "./bowtie2-build", line 95, in <module> main() File "./bowtie2-build", line 92, in main os.execv(build_bin_spec, argv) OSError: [Errno 8] Exec format error

ADD REPLY
0
Entering edit mode
8.0 years ago

The index will be created in the current directory, do you have write permissions?

ADD COMMENT

Login before adding your answer.

Traffic: 2969 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6