一、安装依赖组件:
yum install gcc openssl-devel bzip2-devel libffi-devel -y
二、下载解压
cd /tmp
wget https://mirrors.huaweicloud.com/python/3.9.1/Python-3.9.1.tgz
tar -zxvf Python-3.9.1.tgz
三、安装配置
cd Python-3.9.1
./configure --enable-optimizations
make altinstall
四、检查安装状态
python3.9 -V
#Python 3.9.1