Installing Anaconda on Linux Mint without messing up preinstalled Python?

7,438

In my experience, if you install Anaconda as the user (not to the system with sudo), it will install all its files, including its python version, to your specified directory in your Home. Only Anaconda support files are put into your system folders, so there is no interference with the operation of existing programs. In order to use the Anaconda programs you must start a session from a terminal and make two entries from your Home: 1) "cd Anaconda3/bin" , then 2) "source activate". These entries modify the system $PATH to put the Anaconda programs as the first items in system search path. After you have finished with Anaconda you return the system to the normal $PATH by entering "source deactivate" at the terminal prompt.

Share:
7,438
James Draper
Author by

James Draper

Updated on September 18, 2022

Comments

  • James Draper
    James Draper almost 2 years

    I've used on Anaconda with Python 3.x on Windows for years now. It has tons of features that out of the box that I use every day that cannot be easily installed on the bare-bones Python 2.7 that Linux Mint ships with.

    I've installed Anaconda3 on previous Linux Mint systems using Anaconda's docs for installing on Linux and it worked okay but I think that it might have screwed up those previous installations by letting Anaconda make Python 3 the default python on the path. Every now and when I would try to install basic applications through apt-get install they would fail and Python was sometimes be mentioned in the error messages. Also I've read that you can break the system by installing python 3 as path; here is one example.

    So I noticed in the installation guide linked above that conda requires that Anaconda be pretended to the path;

    The installer prompts “Do you wish the installer to prepend the Anaconda<2 or 3> install location to PATH in your /home//.bashrc ?” Enter Yes.

    NOTE: If you enter “No”, you must manually add the path to Anaconda or conda will not work.

    I don't know if that means Python 3 and Anaconda will be prepended to the path or just Anaconda?

    Long story short what are the best practices for installing Anaconda3 on a Linux system?

    UPDATE: I still haven't found an answer to this question but I was able to find some relevent information on this question from askubuntu.

    There one user says to install with caution because:

    Anaconda seems to install their own version of moc (for building Qt apps), which may conflict with the system libraries if you compile when /home/USER/anaconda3/bin is in your path.

    In my experience one should not install Anaconda on linux mint using the method recommended by their website. I've noticed problems installing and using other unrelated software after installing Anaconda3 system-wide.