Replace python 2.7 default installed on Centos/Oracle Linux 6,7 by python 3.8

1/Set up wget by http/https proxy:

Add below lines to /etc/wgetrc::

http_proxy = http://IP Proxy>:<Port>

https_proxy = http://<IP Proxy>:<Port>

2/Export http_proxy and https_proxy env:

export http_proxy=http://IP Proxy>:<Port>

export https_proxy=http://IP Proxy>:<Port>

3/Download source and install python 3.8.2:

                tar -xzvf Python-3.8.2.tgz   

               cd Python-3.8.2

               ./configure –enable-optimizations make altinstall

-Relink python in /usr/bin/python

             cd /usr/bin/

             ln -sf /usr/local/bin/python3.8 python

-Recheck version after re-link python:

           python -V


Please enter your comment!
Please enter your name here