SRA-toolkit installation: "fastq-dump not found"
1
0
Entering edit mode
10 months ago
BioGuy • 0

Hello, I'm trying to install SRA-toolkit om my Mac (Apple M2).

When I first install it in the terminal the shell manages to find the binary when I write:

which fastq-dump

And I get an output similar to the one in the guide:

/Users/JoeUser/sratoolkit.3.0.0-mac64/bin/fastq-dump

However, when I close my terminal and again write:

which fastq-dump

I get the output:

fastq-dump not found

This is even though I have appended the path to the binary

export PATH=$PATH:$PWD/sratoolkit.3.0.0-mac64/bin

And changed the SRA-toolkit to the one I have downloaded which is 3.0.5.

I cannot figure out why I this error occurs.

All help is appreciated.

Thank you very much.

fastq SRA-toolkit • 1.8k views
ADD COMMENT
1
Entering edit mode

can you type in the full path rather than $PWD?

export PATH=$PATH:$PWD/sratoolkit.3.0.0-mac64/bin

ADD REPLY
3
Entering edit mode
10 months ago
GenoMax 142k

You need to either do export PATH=$PATH:/path_to/sratoolkit.3.0.0-mac64/bin each time you start a new terminal or add this line to your shell initialization preference file like .bash_profile (for bash shell). Since you appear to be on macOS you may be using zsh as your default shell. If that is your case then add that line to .zshenv file in your home directory. This would ensure that the PATH is correctly set when you start a new terminal.

ADD COMMENT
0
Entering edit mode

This solved my issue, thank you so much. Have a great day.

ADD REPLY
0
Entering edit mode

Hi, I install sratoolkit.3.0.7-mac64 and then I run fastq-dump on sratoolkit.3.0.7-mac64/bin directory. It still says fastq-dump not found. Do you know any possible reason?

ADD REPLY
0
Entering edit mode

Have you tried using full path to the executable? Check above $PATH solution as well.

ADD REPLY
0
Entering edit mode

I added those two lines below into .bash_profile and .zshenv, but it still doesn't work.

export PATH=$PATH:'/Users/sratoolkit.3.0.7-mac64/bin'
export PATH=$PATH:./

The only way to run it is in Users/sratoolkit.3.0.7-mac64/bin and ./fastq-dump

I don't know how to export PATH so I can just run it on home directory.

ADD REPLY
0
Entering edit mode

Don't use the single quotes in your export command around directory path. Also the second line is not required.

Once you make the changes open a new terminal so the changes are read during initialization.

ADD REPLY
0
Entering edit mode

I added PATH to .zshrc and it works now!

ADD REPLY

Login before adding your answer.

Traffic: 2230 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