Python MySQLdb with SELinux
Couple of permission issues that I notice:

Make sure your credentials for mySQLdb have access to the database.
If you are using IP and Port to connect to the database, try using localhost.
Make sure the user (chmod permissions) have access to the folder where mySQL stores stuff. Sometimes when storing media and things it need permission to the actual folder.
Lastly, I would try to reset Apache server (not the entire machine).
I'm using the mySQLdb module within my django application which is linked to Apache via WSGI.
However I'm getting permission issues (shown below). This is down to SElinux and if I set it to passive everything is ok.

ImproperlyConfigured: Error loading MySQLdb module:
  /opt/django/virtenv/django15/lib/python2.7/site-packages/_mysql.so:
  failed to map segment from shared object: Permission denied

What is the best way to update SELinux to include this without having to turn off the whole the thing. The error is shown below:

ImproperlyConfigured: Error loading MySQLdb module:
  /opt/django/virtenv/django1/lib/python2.7/site-packages/_mysql.so: 
  cfailed to map segment from shared object: Permission denied