Samtools command not found
1
0
Entering edit mode
3.2 years ago

Hi there!

I installed samtools according to the instructions from here: https://gatk.broadinstitute.org/hc/en-us/articles/360041320571--How-to-Install-all-software-packages-required-to-follow-the-GATK-Best-Practices

I downloaded the samtools tar file version 1.11. Unpacked it with:

tar xvjk samtools-1.11.tar.bz2

Went to the samtools directory with

cd

And then

make

Added it to my path with:

export = PATH="$path/to/folder/:$PATH"

Opened a new shell, and ran

samtools

and I get the error:

samtools command not found

Does anyone know what I am doing wrong here? Thanks.

error • 6.3k views
ADD COMMENT
0
Entering edit mode

Opened a new shell, and ran

That export command was local to the shell you had open. If you open another shell then you have to export in that shell or add this permanently to your .bashrc or relevant shell file.

BTW command should be

export PATH=$path/to/folder/:$PATH
ADD REPLY
0
Entering edit mode
3.2 years ago

in export = PATH="$path/to/folder/:$PATH" replace "$path/to/folder/" by your actual path to the folder where are located your samtools binaries.

ADD COMMENT
2
Entering edit mode

Even in this case the poster may get the same error after opening the new shell, because export command do not carry over. The OP will need to put this export command into .bashrc before opening the new shell, or use samtools in the same shell where the export command was issued.

ADD REPLY
0
Entering edit mode

Thanks for the replies. Even when I use the same shell, I get the same error. Any other ideas? Thanks.

ADD REPLY
0
Entering edit mode

Do you see a file called samtools in the directory (perhaps in bin folder) after you do make. It may be easiest to install samtools using conda.

ADD REPLY
0
Entering edit mode

Thank you so much for the help! I ended up editing the .bashrc and adding samtools to the path that way, and that worked!!! Working fine now.

ADD REPLY
0
Entering edit mode

yes I did do that I just didn't bother to put it in the post haha thx.

ADD REPLY

Login before adding your answer.

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