search
LoginSignup
23
Help us understand the problem. What are the problem?

More than 5 years have passed since last update.

posted at

Python 2.7 インストール(yum)(CentOS 6.8)

インストール

[root@localhost ~]# yum -y install centos-release-scl-rh
[root@localhost ~]# yum -y install python27

動作確認

[root@localhost ~]# python --version
Python 2.6.6
[root@localhost ~]# scl enable python27 bash
[root@localhost ~]# python --version
Python 2.7.8
[root@localhost ~]# exit

自動有効設定

[root@localhost ~]# python --version
Python 2.6.6
[root@localhost ~]# echo 'source /opt/rh/python27/enable' > /etc/profile.d/python27.sh
[root@localhost ~]# source /etc/profile
[root@localhost ~]# python --version
Python 2.7.8

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
What you can do with signing up
23
Help us understand the problem. What are the problem?