Centos6 升级python2.6.6-->2.7.6

2016-1-4 echo centos

    最近弄了个美国的VPS,因为要用来搭梯子,shadowsocks只支持Centos6,所以莫办法,只能装个Centos6,后来发现里面的python只有2.6.6,所以升级了下:

    1.下源码,解压,配置./configure,编译make,安装make install,默认安装路径:/usr/local/bin/python2.7,没装gcc,编译不了,sudo yum install gcc-c++

    2.修改符号链接:

    rm -rf /usr/bin/python
    ln -s /usr/local/bin/python2.7 /usr/bin/python

    3.yum用的是2.6的,所以升级之后yum不能用,要修改vim /usr/bin/yum,即 #!/usr/bin/python2.6


    python -V



版权所有: 本文发布于DD'echo
转载请保留原文链接: http://echo.z-dd.net/post-30.html
除非注明,文章均为 echo >> 原创 ,欢迎转载!转载请注明本文地址,谢谢!

友荐云推荐

发表评论:

Copyright @ 2015 DD'echo All rights reserved. Powered by emlog