AWS EC2: Install Anaconda on Linux Instance

Michael Galarnyk
2 min readDec 22, 2016

--

  1. Go to Amazon Web Services’ Website (Link)

2. Sign in if you have account, if not make one

3. Click on EC2

4. Press Running Instances. If you don’t have an instance, see part 1 of the tutorial.

5. Select your instance and make sure your key (pem file) matches your key pair name

6. Use the chmod command below (in bold below) to make sure your private key file isn’t publicly viewable

chmod 400 /path_to_key/my_key.pem

7. ssh to your EC2 instance (see below, if you dont know how to ssh, please see part 2

ssh -i /path_to_key/my_key.pem user_name@public_dns_name

8. Copy link address from Anaconda installer archive.

I choose https://repo.continuum.io/archive/Anaconda2-4.1.1-Linux-x86_64.sh

9. In EC2 instance terminal, type

wget https://repo.continuum.io/archive/Anaconda2-4.1.1-Linux-x86_64.sh

10. In EC2 instance terminal, type

bash what_Anaconda_you_downloaded_Linux_x86_64.sh

11. In EC2 instance terminal, type

source .bashrc

Please let me know if you have any questions! You can either leave a comment here or leave me a comment on youtube, or through Twitter. Part 4 is Setting up a Jupyter (IPython) Server (Notebook) on AWS.

If you don’t want to start a Jupyter Server, but want to use a normal Jupyter notebook, please see this other tutorial (Setting up and Using a Jupyter Notebook on AWS).

If you want to learn how to use anaconda, I have a LinkedIn Learning course on Pandas and Matplotlib called Python for Data Visualization. Here is a free preview video.

--

--