How to install BLAST in ubuntu? How to use the command terminal to install it?
2 answers
In case you have sufficient privileges and don't fancy the latest release, the by far easiest option is the Ubuntu/Debian package manager apt.
sudo apt install ncbi-blast+
This answer should help you.
1.Retrieve blast executables (if not already done) in the terminal:
1.1 Download the executables with the command:
wget ftp://ftp.ncbi.nlm.nih.gov/blast/executables/blast+/LATEST/ncbi-blast-2.10.0+-x64-linux.tar.gz
1.2 Decompress the archive and rename it:
tar zxvf ncbi-blast-2.10.0+-x64-linux.tar.gz
mv ncbi-blast-2.10.0+ blast
rm ncbi-blast-2.10.0+-x64-linux.tar.gz
1.3 Add a folder for blast databases
cd blast
mkdir db
cd...
1.4 you become administrator (you enter your password):
sudo su
1.5 You place the executables in /usr/share to make them usable by everyone:
mv blast /usr/share.
chmod a+w+r /usr/share/blast/db
export PATH="$PATH:/usr/share/blast/bin"
export BLASTDB="/usr/share/blast/db/"
exit
You will need to put the two export lines in files likes ~/.bash_profile or ~/.bashrc for executables o be available across all sessions.
2.Retrieves the databases (if needed for example with SwissProt DB, needs admin rights)
cd /usr/share/blast/db
cp ../bin/update_blastdb.pl .
perl update_blastdb.pl swissprot
tar zxvf swissprot.tar.gz
rm swissprot.tar.gz
Done :)
Log in to answer this question.
Best option would be to use
conda. Take a look at bioconda documentation. Once you havecondainstalled it can be as simple asby far the easiest option is conda! Install it on your linux system if you haven't already:
https://docs.conda.io/projects/conda/en/latest/user-guide/install/linux.html
You may also consider to use a Docker image for BLAST, like the ones available at the pegi3s Bioinformatics Docker Images Project: https://hub.docker.com/r/pegi3s/blast