Two ways to install Python3 on Linux servers

Two ways to install Python3 on Linux servers

First method

Alibaba Cloud and Baidu Cloud servers are available! ! !

yum install python3

Second method

1. Download the compressed package of python3.6.5

wget http://cdn.npm.taobao.org/dist/python/3.6.5/Python-3.6.5.tgz

2. Unzip the compressed package

tar -zxvf Python-3.6.5.tgz

3. Installation

cd Python-3.6.5
yum install -y zlib*
yum install -y gcc

If it appears:

insert image description here

cd /etc/yum.repos.d
mv CentOS-Base.repo CentOS-Base.repo.backup

Check the system version:

cat /etc/issue

insert image description here

Select the appropriate version of the source:

http://mirrors.163.com/.help/centos.html
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo
yum clean all
yum makecache

Then directly:

yum install python3

Then it still reports an error. . . .

The reason is that the CentOS6 version cannot install python3 directly from the source, but CentOS7 can! ! !

Summarize

The above are two ways to install Python3 on Linux servers introduced by the editor. I hope it will be helpful to everyone. If you have any questions, please leave me a message and the editor will reply to you in time. I would also like to thank everyone for their support of the 123WORDPRESS.COM website!
If you find this article helpful, please feel free to reprint it and please indicate the source. Thank you!

You may also be interested in:
  • Detailed tutorial on installing Python 3.8.1 on Linux
  • Tutorial on upgrading and installing python 3.8 and configuring pip and yum under Linux
  • Detailed tutorial on installing python3 and corresponding pip environment under linux
  • Install Python 3.6 on Linux and avoid pitfalls
  • How to modify the default Python version when installing Python on Linux
  • Detailed explanation of upgrading Python and installing pip under Linux
  • Python 3.7.0 installation tutorial under Linux
  • How to install Python3 on Linux and coexist with the system's own Python2

<<:  Explanation of the usage scenarios of sql and various nosql databases

>>:  js to realize the production method of carousel

Recommend

Windows 10 + mysql 8.0.11 zip installation tutorial detailed

Prepare: MySQL 8.0 Windows zip package download a...

Discussion on the problem of iframe node initialization

Today I suddenly thought of reviewing the producti...

Detailed explanation of mixed inheritance in Vue

Table of contents The effect of mixed inheritance...

Summary of commonly used CSS encapsulation methods

1. pc-reset PC style initialization /* normalize....

Summary of the differences and usage of plugins and components in Vue

The operating environment of this tutorial: Windo...

SQL Practice Exercise: Online Mall Database User Information Data Operation

Online shopping mall database-user information da...

HTML form component example code

HTML forms are used to collect different types of...

How to use MySQL 5.7 temporary tablespace to avoid pitfalls

Introduction MySQL 5.7 aims to be the most secure...

Gogs+Jenkins+Docker automated deployment of .NetCore steps

Table of contents Environmental Description Docke...

Summary of common docker commands (recommended)

1. Summary: In general, they can be divided into ...

How to set up Windows Server 2019 (with pictures and text)

1. Windows Server 2019 Installation Install Windo...

HTML+CSS+JS realizes the scrolling gradient effect of the navigation bar

Table of contents First look at the effect: accom...

Learn about JavaScript closure functions in one article

Table of contents Variable Scope The concept of c...