Home / Linux  / Install Python 3 on CentOs , RHEL, Fedora CloudLinux

Install Python 3 on CentOs , RHEL, Fedora CloudLinux

Do us a favor with share this post ūüôā

Python 3.5.0  on 7  , 6   7 /6 , CloudLinux

Here Python 3.5.0 has been released on 13 September 2015 . Now Python 3.x version is  available  and   main  improvement on python 3.x  is  Unicode support with saner bytes .More about Python Version 2 and Python Version 3 , you can find on wiki for  python 2 or 3  here .

Update the OS Applications :

Before making installation , you should update the default system . You can run the below command to update CentOs / RHEL applications.

# yum ‚Äďy update

Steps of Python Installation :

Here we are  following python installation from source package, through source package we will download the soruce package from official site and extract the archive file and compile and build the appcalication. Find below steps to download, compile and build.

Download Python 3.5.0 :

# wget https://www.python.org/ftp/python/3.5.0/Python-3.5.0.tgz

Extract Source Archive and build :

# tar xzf Python-3.5.0.tgz    # cd Python-3.5.0

In next steps we are going  to configure the installation directory  on /usr/local, We can change the path .

# ./configure --prefix=/usr/local

Building and installing Python through below make altinstall command , this command will replace the python , which is using by the server.

# make altinstall

Check and Verify Python Version :

# ¬†python3.5 ‚ÄďV    Python 3.5.0
Do us a favor with share this post ūüôā

A Linux Geek with Freelance Contributor, Server/ Cloud Administrator having 6+ Years experience in Open Source and Cloud Technologies.

Review overview
  • Leon October 6, 2015

    Hi Sanchin,

    I’ve followed your tutorial about python 3.5 for Centos 7 but after last step “make altinstall” I have got:

    gcc -pthread -Xlinker -export-dynamic -o python Programs/python.o libpython3.5m.a -lpthread -ldl -lutil -lm
    if test “no-framework” = “no-framework” ; then \
    /usr/bin/install -c python /usr/local/bin/python3.5m; \
    else \
    /usr/bin/install -c -s Mac/pythonw /usr/local/bin/python3.5m; \
    /usr/bin/install: cannot create regular file ‚Äė/usr/local/bin/python3.5m‚Äô: Permission denied
    make: *** [altbininstall] Error 1

    Do you know what went wrong…? I have installed python 3 as admin user not as a root.



Time limit is exhausted. Please reload CAPTCHA.