Steps for installing MYSQLDB modules with Yum _python

Source: Internet
Author: User

Objective

This article is mainly about the use of Yum to install MySQLdb module steps, the following words do not say more, to see the detailed introduction bar.

Steps are as follows

MySQLdb depends on the Mysql-devel package, so first we need to install the Mysql-devel package first.

One, you can go to the official website download Mysqldevel rpm package, and then installed on the server.

Second, directly with Yum installation MySQLdb

Yum Install-y Mysqldb-python

Third, verify the MySQLdb module is installed successfully

[root@ip-172-31-1-8 ~]# python
python 2.7.10 (default, Dec 8 2015, 18:25:23) 
[GCC 4.8.3 20140911 (Red Hat 4.8.3-9) ] on linux2
Type ' help ', ' copyright ', ' credits ' or ' license ' for the more information.
>>> import MySQLdb
>>> 
# import does not show any prompts or errors, even if the MySQLdb module package is successfully installed

Summarize

The above is about the use of Yum installation MySQLdb module of all the steps, I hope the content of this article for everyone's study or work can bring certain help, if you have questions you can message exchange.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.