MySQLdb install error - _mysql.c:44:23: error: my_config.h: No such file or directory

If ubuntu : apt-get install mysql-devel If centos/rhel : yum install mysql-devel Then install MySQL-python


you can add manually the header file into mysql include directory (download from github repo):

cd /usr/include/mysql
sudo wget https://raw.githubusercontent.com/paulfitz/mysql-connector-c/master/include/my_config.h -O my_config.h

Retry pip install

sudo pip install MySQL-python

As found here you need to copy my_config.h to /usr/include/mysql, then pip install MySQL-python.