Mysql-python installation package: Http://sourceforge.net/projects/mysql-python/files/latest/download
Linux environment is Centos6.6, python2.6.6
The first thing that could go wrong:
1, I download the good file, enter the CD command to go to the installed directory folder, and then use Python to compile the installation package, found an error:
Prompt, unable to find MySQL header file;
So, to remind you to install MySQL for Python, please install Mysql-devel
#Yum install mysql-devel
2, Setuptool installation, because, this problem, I did not find in practice, so, I can only simply take out to say with you:
Install the installation steps below (the following steps must be entered into the directory of the installation files ):
1, the first configuration, two steps:
Find the directory for the Mysql_config file
2, modify the Site.cfg
Here's the topic:
Install
Test: Enter Python environment, import mysqldb module, no error, instructions to install ok!
Download and installation of the CentOS MySQL for Python