Getting started with Django 1.3.1 and Upon running
python manage.py syncdb
with Python 2.6. I keep getting an error loading mysqldb module: No module named mysqldb message. I have tried doing sudo yum install python-mysql and sudo yum install python-mysqldb
on a CentOS 5 system but I get a “no package found” message and the error persists in django.
What’s the fix for this?
I would like to keep the Python version as 2.6 to preserve other dependencies so reinstalling 2.5 or something is out of the question.
Thanks!
There’s no point using the system packaging tools if you’re using a different Python version to the one provided by the system. You’ll have to use the Python packaging tools instead – eg
easy_install mysqldb.