Python – How to install Python 2.7.4 OR 3.3.1 on an Amazon AMI

amazon-amiamazon-web-servicespythonyum

I have an EC2 instance running a standard AMI, and have exhausted the limit of my abilities with yum and similar avenues to update python to 2.7.4 or 3.3.1 for a library I need to use.

Unfortunately, while I can install 2.6.X with very little effort, and 2.7.3 with only slightly more, I can't seem to find a way to get my desired version on this AMI short of compiling from source.

Is this my only route? I am not experienced enough with compiling packages from source to feel confident that will be done correctly.

Additionally, should I uninstall the older versions of Python that were added through yum before installing my desired version?

Best Answer

Options:

Download and compile from source. Not that hard, then just use the #!/usr/local/bin/python or whatever location you install to.

Another option is to install/setup the EPEL repo which has the 2.7 and 3 packages and just do the yum install.