CentOS6.5+Python2.7+ GIT +IPython
作者:互联网
下载vmware12:
链接:http://pan.baidu.com/s/1kUGhZyZ 密码:rdv8
下载centos6.8镜像:
http://mirrors.163.com/centos/6.8/isos/x86_64/CentOS-6.8-x86_64-minimal.iso
系统安装:
安装过程(见centos6.5安装文档)
配置网络:
# vim /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
HWADDR=00:0c:29:55:8c:95
TYPE=Ethernet
UUID=fa5330f5-8b74-4db6-8285-e3689ecbc133
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=none
IPADDR=192.168.1.63
NETMASK=255.255.255.0
DNS2=8.8.8.8
GATEWAY=192.168.1.1
DNS1=192.168.1.1
其它安装:
本地yum源的配置
#vim /etc/yum.repo.d/centos6.7.repo
[name]
name=centos6.7
baseurl=file:///mnt
enabled=1
gpgcheck=0
#mount /dev/cdrom/mnt
mount: block device /dev/sr0 is write-protected, mountingread-only
关闭防火墙并加入开机启动:
/etc/init.d/iptables stop 关闭防火墙
关闭selinux
#setenforce 0 临时关闭
RPM源安装:
# rpm -ivhhttp://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
Python源码安装:
#yum install –y gcc gcc-c++ readline-devel
#yum install -y mysql mysql-server mysql-devel zlibzlib-devel
#wget https://www.python.org/ftp/python/2.7.6/Python-2.7.6.tgz
#tar zxvf Python-2.7.6.tgz
#cd Python-2.7.6
#./configure
#make && make install
#rm /usr/bin/python
#ln /usr/local/bin/python2.7 /usr/bin/
#ln /usr/local/bin/python2.7 /usr/bin/python
PIP2.7安装
wget https://bootstrap.pypa.io/get-pip.pypython2.7get-pip.py
pip2.7 install flask
pip2.7 install MySQL-python
GIT安装
# yum install curl-devel expat-devel gettext-developenssl-devel zlib-devel gcc perl-ExtUtils-MakeMaker
# wgethttps://www.kernel.org/pub/software/scm/git/git-1.9.4.tar.gz
# tar xzf git-1.9.4.tar.gz
# cd git-1.9.4
# make prefix=/usr/local/git all
# make prefix=/usr/local/git install
# echo "export PATH=$PATH:/usr/local/git/bin">> /etc/bashrc
# source /etc/bashrc
#Mysql 配置文件修改
#vim /etc/my.conf
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
# Disabling symbolic-links is recommended to preventassorted security risks
symbolic-links=0
default-character-set = utf8
character_set_server = utf8
[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
default-character-set = utf8
[client]
default-character-set = utf8
到此为止配置python环境安装结束
标签:GIT,python,devel,IPython,git,usr,install,mysql,CentOS6.5 来源: https://blog.51cto.com/xinsz08/2700344