In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
This article mainly introduces how to install linux python environment, has a certain reference value, friends in need can refer to. I hope you will learn a lot after reading this article. Next, let the editor take you to learn about it.
1. Install python3 under linux
Prepare to compile the environment (if the environment is wrong, you may encounter all kinds of problems, such as wget cannot download the files linked by https)
Yum groupinstall 'Development Tools'yum install zlib-devel bzip2-devel openssl-devel ncurses-devel
2. Download Python3.5 code package
Wget https://www.python.org/ftp/python/3.5.0/Python-3.5.0.tar.xz
In the installation package, there is a README file that writes how to install
Tar Jxvf Python-3.5.0.tar.xzcd Python-3.5.0./configure-- prefix=/usr/local/python3make & & make install
Make a soft chain:
Ln-s / usr/local/python3/bin/python3.5 / usr/local/bin/python3
The installation was successful!
If prompted: Ignoring ensurepip failure: pip 7.1.2 requires SSL/TLS
This is why oenssl is not installed or upgraded:
Yum install openssl-devel
Repeat the compilation scheme python3.5 again:
The final result is as follows:
Prompt to install both pip-7.12 and setuptools successfully!
Both pip3 and pip indicate that there are no errors!
Make a soft chain:
Ln-s / usr/local/python3/bin/pip3.5 / usr/local/bin/pip
Upgrade pip to the latest version:
Pip install-upgrade pip
Pip installed successfully!
Note:-- no-check-certificate means "do not check the certificate" during installation, without adding that it may not be able to install.
two。 Installation package
Requests package:
Pip install requests
Pyquery package:
Pip install pyquery
Pymysql package:
Pip install pymysql thank you for reading this article carefully. I hope it will be helpful for everyone to share how linux installs the python environment. At the same time, I also hope you will support us, pay attention to the industry information channel, and find out if you have any problems. Detailed solutions are waiting for you to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.