How do I repair MySQL setup - installed incompatible MySQL client

I am trying to port a Django application to Ubuntu/Apache. In doing so I ran into trouble installing the MySQL client: pip install mysqlclient. I tried installing an older version

`pip install mysqlclient==2.1.0

but that seemed to ruin my webmin config. Now I have:

mysql: Can’t read dir of ‘/etc/mysql/mariadb.conf.d/’ (OS errno 2 - No such file or directory) mysql: [ERROR] Stopped processing the ‘includedir’ directive in file /etc/mysql/my.cnf at line 31. mysql: [ERROR] Fatal error in defaults handling. Program aborted!

I feel like I’m in a mess and I’m not sure how to get out of it now.

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Site Moderator
Site Moderator badge
March 17, 2024

Heya @coolmike,

I don’t think you would need to install the mysql client with Pip to be honest. You should be able to achieve this with just using yum or apt depending on what distro you choose.

Try DigitalOcean for free

Click below to sign up and get $200 of credit to try our products over 60 days!

Sign up

Get our biweekly newsletter

Sign up for Infrastructure as a Newsletter.

Hollie's Hub for Good

Working on improving health and education, reducing inequality, and spurring economic growth? We'd like to help.

Become a contributor

Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.

Welcome to the developer cloud

DigitalOcean makes it simple to launch in the cloud and scale up as you grow — whether you're running one virtual machine or ten thousand.

Learn more
DigitalOcean Cloud Control Panel