Skip to content

Instantly share code, notes, and snippets.

View mobishift2011's full-sized avatar

Ethan mobishift2011

  • Favbuy
  • Shanghai
View GitHub Profile
@mobishift2011
mobishift2011 / python27_on_centos65.md
Created August 14, 2016 03:41 — forked from dalegaspi/python27_on_centos65.md
Installing Python 2.7 on CentOS 6.5

Installing Python 2.7 on Centos 6.5

Centos 6.* comes with Python 2.6, but we can't just replace it with v2.7 because it's used by the OS internally (apparently) so you will need to install v2.7 (or 3.x, for that matter) along with it. Fortunately, CentOS made this quite painless with their Software Collections Repository

sudo yum update # update yum
sudo yum install centos-release-scl # install SCL 
sudo yum install python27 # install Python 2.7

To use it, you essentially spawn another shell (or script) while enabling the newer version of Python: