How to Install Anaconda on CentOS 7
Boa constrictor is the most mainstream python information science and AI stage, utilized for huge scope information handling, prescient investigation, and logical figuring. Boa constrictor conveyance ships with in excess of 1,000 information bundles, the conda order line apparatus and with a work area graphical UI called Anaconda Navigator.
This instructional exercise will experience the means of downloading and introducing Anaconda for Python 3 on CentOS 7.
Installing Anaconda
At the hour of composing this article, the most recent stable variant of Anaconda is form 5.3.1. Prior to downloading the Anaconda installer content visit the Anaconda Downloads page and check if there is another rendition of Anaconda for Python 3 accessible for download.
CentOS Download Anaconda
Play out the accompanying strides to introduce Anaconda on CentOS 7:
Download the Anaconda Installation Script.
Explore to the/tmp registry and download the Anaconda establishment content utilizing the connection that you duplicated from the Downloads page:
cd /tmp
curl -O https://repo.anaconda.com/archive/Anaconda3-5.3.1-Linux-x86_64.sh
The download may take some time contingent upon your association speed.
Confirm the Data Integrity of the Script.
Utilize the sha256sum order to confirm the content checksum:
sha256sum Anaconda3-5.3.1-Linux-x86_64.sh
You should see a yield like the accompanying:
d4c4256a8f46173b675dd6a62d12f566ed3487f932bab6bb7058f06c124bcc27 Anaconda3-5.3.1-Linux-x86_64.sh
Ensure the hash printed from the order above matches the one accessible at the Anaconda with Python 3 on 64-bit Linux page for your fitting Anaconda rendition.
https://docs.anaconda.com/anaconda/install/hashes/Anaconda3-5.3.1-Linux-x86_64.sh-hash.html
CentOS Anaconda Installer Hash
Run the Anaconda Installation Script
To begin the Anaconda establishment measure run the establishment content:
bash Anaconda3-5.3.1-Linux-x86_64.sh
You should see a yield like the accompanying:
Welcome to Anaconda3 5.3.1
In order to continue the installation process, please review the license
agreement.
Please, press ENTER to continue
Press ENTER to proceed and afterward press ENTER to look through the permit. Whenever you're finished evaluating the permit, you'll be approached to support the permit terms:
Do you accept the license terms? [yes|no]
Type yes to acknowledge the permit and you'll be provoked to pick the establishment area.
Anaconda3 will currently be introduced into this area:
Anaconda3 will now be installed into this location:
/home/linuxize/anaconda3
- Press ENTER to confirm the location
- Press CTRL-C to abort the installation
- Or specify a different location below
The default area is fine for most clients, press ENTER to affirm the area and establishment cycle will proceed.
In the event that you get a blunder saying bunzip2: order not found, introduce the bzip2 bundle with:
sudo yum install bzip2
.
The establishment may take some time and whenever it is finished, the accompanying yield will be shown:
Installation finished.
Do you wish the installer to initialize Anaconda3
in your /home/linuxize/.bashrc ? [yes|no]
In the event that you need to utilize the conda order type yes press ENTER and you'll be introduced the accompanying yield:
Appending source /home/linuxize/anaconda3/bin/activate to /home/linuxize/.bashrc
A backup will be made to: /home/linuxize/.bashrc-anaconda3.bak
For this change to become active, you have to open a new terminal.
Thank you for installing Anaconda3!
The installer will likewise find out if you might want to download and introduce Visual Studio Code.
Anaconda is partnered with Microsoft! Microsoft VSCode is a streamlined
code editor with support for development operations like debugging, task
running and version control.
To install Visual Studio Code, you will need:
- Administrator Privileges
- Internet connectivity
Visual Studio Code License: https://code.visualstudio.com/license
Do you wish to proceed with the installation of Microsoft VSCode? [yes|no]
You can discover more data about Visual Studio on the manager site . On the off chance that you need to introduce Visual Studio Code type yes in any case type no.
To actuate the Anaconda establishment load the new PATH climate variable which was added by the Anaconda installer into the current shell meeting with the accompanying order:
source ~/.bashrc
Confirm the Installation
You can confirm your Anaconda establishment utilizing the conda order. For instance to show data about current conda introduce type:
conda info
active environment : base
active env location : /home/linuxize/anaconda3
shell level : 1
user config file : /home/linuxize/.condarc
populated config files :
conda version : 4.5.11
conda-build version : 3.15.1
python version : 3.7.0.final.0
base environment : /home/linuxize/anaconda3 (writable)
channel URLs : https://repo.anaconda.com/pkgs/main/linux-64
https://repo.anaconda.com/pkgs/main/noarch
https://repo.anaconda.com/pkgs/free/linux-64
https://repo.anaconda.com/pkgs/free/noarch
https://repo.anaconda.com/pkgs/r/linux-64
https://repo.anaconda.com/pkgs/r/noarch
https://repo.anaconda.com/pkgs/pro/linux-64
https://repo.anaconda.com/pkgs/pro/noarch
package cache : /home/linuxize/anaconda3/pkgs
/home/linuxize/.conda/pkgs
envs directories : /home/linuxize/anaconda3/envs
/home/linuxize/.conda/envs
platform : linux-64
user-agent : conda/4.5.11 requests/2.19.1 CPython/3.7.0 Linux/3.10.0-957.1.3.el7.x86_64 centos/7 glibc/2.17
UID:GID : 0:0
netrc file : None
offline mode : False
Updating Anaconda
Refreshing the Anaconda is a pretty straight forward cycle, first update the conda device with:
conda update conda
When incited to affirm the update, type y to continue.
Once conda is refreshed, continue with the Anaconda update:
conda update anaconda
Same similarly as with the past order, when provoked, type y to continue.
You ought to routinely refresh your Anaconda establishment.
Uninstalling Anaconda
On the off chance that you need to uninstall Anaconda from your CentOS framework, follow the means beneath:
Eliminate the Anaconda introduce catalog.
To eliminate the whole Anaconda establishment catalog type:
rm -rf ~/anaconda3
Alter the PATH climate variable.
Alter the ~/.bashrc document and eliminate the code added by the Anaconda installer:
~/.bashrc
# added by Anaconda3 5.3.1 installer
# >>> conda init >>>
# !! Contents within this block are managed by 'conda init' !!
__conda_setup="$(CONDA_REPORT_ERRORS=false '/home/linuxize/anaconda3/bin/conda' shell.bash hook 2> /dev/null)"
if [ $? -eq 0 ]; then
\eval "$__conda_setup"
else
if [ -f "/home/linuxize/anaconda3/etc/profile.d/conda.sh" ]; then
. "/home/linuxize/anaconda3/etc/profile.d/conda.sh"
CONDA_CHANGEPS1=false conda activate base
else
\export PATH="/home/linuxize/anaconda3/bin:$PATH"
fi
fi
unset __conda_setup
# <<< conda init <<<
Eliminate the concealed records.
The accompanying order will eliminate the shrouded records and envelopes that have been made in your client home registry:
rm -rf ~/.condarc ~/.conda ~/.continuum
Conclusion
Since you have downloaded and introduced Anaconda your CentOS framework, you can check the authority Getting begun with conda direct.
In the event that you hit an issue or have input, leave a remark underneath.