Installing Anaconda on a Linux machine is quite an easy task! Anaconda will help you manage Python tools for coding, data science, and machine learning. Just follow along this guide to get it installed very conveniently. You don’t need any tech skills! Just copy and paste those commands. Let’s get started!
Step 1: Check Your Linux System
Before installing Anaconda, check if your Linux system is 64-bit or 32-bit. Most modern Linux systems are 64-bit. Open the terminal (press Ctrl+Alt+T
) and type:
uname -m
If you see “x86_64,” your system is 64-bit. If it says “i686,” it’s 32-bit. Anaconda works best with 64-bit systems.
Why this matters: Using the wrong installer can cause errors. Always check your system first!
Step 2: Download the Anaconda Installer
Visit the Anaconda official website. Click the “Linux” option. Copy the link for the latest Python 3.x version (64-bit or 32-bit).
Open your terminal and type:
wget https://repo.anaconda.com/archive/Anaconda3-2023.03-Linux-x86_64.sh
Replace the link with the one you copied. This downloads the installer to your computer.
Tip: If wget
isn’t installed, use sudo apt install wget
(for Debian/Ubuntu) first.
Step 3: Run the Installer
After downloading, run the installer script. Type:
bash Anaconda3-2023.03-Linux-x86_64.sh
Replace the filename with yours. Press Enter.
The installer asks you to review the license agreement. Press Enter
to scroll. Type “yes” to agree.
Next, choose the install location. Press Enter
to use the default path (/home/yourname/anaconda3
).
Important: Say “yes” when asked, “Do you wish the installer to initialize Anaconda3?” This updates your system’s PATH.
Step 4: Activate Anaconda
Close and reopen your terminal. Type:
conda list
If you see a list of packages, Anaconda is installed! If not, manually activate it with:
source ~/anaconda3/bin/activate
Troubleshooting: If you see “conda: command not found,” check your PATH or re-run the installer.
Step 5: Test Your Installation
Create a test environment to ensure Anaconda works. Type:
conda create --name test_env python=3.9
conda activate test_env
If the environment activates, you’re good to go! Delete it later with:
conda deactivate
conda env remove --name test_env
Fun fact: Environments let you use different Python versions for projects.
Why Use Anaconda?
Anaconda simplifies Python and package management. It’s perfect for:
- Installing libraries like NumPy, Pandas, and TensorFlow.
- Creating isolated environments for projects.
- Avoiding version conflicts between tools.
Bonus: Anaconda Navigator offers a user-friendly app for managing packages.
Keep Anaconda Updated
Update Anaconda regularly for new features and security fixes. Type:
conda update conda
conda update anaconda
Note: Always back up your projects before updating.
Uninstall Anaconda (If Needed)
To remove Anaconda, delete its folder:
rm -rf ~/anaconda3
Then, remove hidden config files:
rm -rf ~/.condarc ~/.conda ~/.continuum
Warning: Uninstalling removes all environments and packages.
Final Thoughts
You’ve learned how to install Anaconda in Linux! Now explore data science, machine learning, or coding projects. Share this guide with friends who need help. Happy coding!
FAQs
1. How do I check if Anaconda is installed?
Type conda list
in the terminal. If packages appear, it’s installed.
2. Can I install Anaconda without admin rights?
Yes! Install it in your home folder instead of system directories.
3. What if the terminal says “conda command not found”?
Run source ~/anaconda3/bin/activate
or re-run the installer and select “yes” for PATH setup.