1. Install dependent environment
# yum-y Install zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel readline-devel tk-devel gdbm-devel db4-de Vel libpcap-devel xz-devel
wget https://www.python.org/ftp/python/3.5.2/Python-3.5.2.tgz
3. Create a Python3 directory
# Mkdir/usr/local/python3
4. Unzip the download file and switch the directory
# TAR-ZXVF Python-3.5.2.tgz
# CD Python-3.5.2.tgz
5. Implementation
#./configure--prefix=/usr/local/python3
# Make && make install
6. Create a soft link for Python3
# ln-s/usr/local/python3/bin/python3/usr/bin/python3
7. Create a soft link for Pip3
# ln-s/USR/LOCAL/PYTHON3/BIN/PIP3/USR/BIN/PIP3
8. Test commands Python3 and PIP3
# Python3
# PIP3
The installation retains the original Python command call Python2
Installation Complete
Install Python3 and PIP3 under CentOS and keep Python2