解决:python安装mysqldb模块报 EnvironmentError: mysql_config not found
最近学习python操作mysql需要安装mysqldb模块
出现EnvironmentError: mysql_config not found
经网上查看,需要安装mysql客户端开发库libmysqlclient-dev
sudo apt-get install libmysqlclient-dev
所以安装mysql及mysqldb的正确操作应为
- 安装数据库
sudo apt-get install mysql-server
- 安装开发库(支持mysql_config)
sudo apt-get install libmysqlclient-dev 如果是MariaDB
sudo apt-get install libmariadbclient-dev
- 安装mysqldb
pip install mysql-python
解决:python安装mysqldb模块报 EnvironmentError: mysql_config not found的更多相关文章
- windows(32位 64位)下python安装mysqldb模块
windows(32位 64位)下python安装mysqldb模块 www.111cn.net 编辑:mengchu9 来源:转载 本文章来给各位使用在此windows系统中的python来安装一个 ...
- python安装mysqlclient模块报fatal error: Python.h:解决方法
在搭建Flask框架安装mysqlclient模块时候老是报fatal error: Python.h:错误,折腾老半天,百度了老半天看了不少大神帖子,就是没解决, 后来发现这不是个BUG,都是自己的 ...
- centos7 安装mysql--python模块出现EnvironmentError: mysql_config not found和error: command 'gcc' failed with exit status 1
要想使python可以操作mysql 就需要MySQL-python驱动,它是python 操作mysql必不可少的模块. 下载地址:https://pypi.python.org/pypi/MySQ ...
- 解决python2安装MySQL-python模块报错
今天电脑重装系统,所有软件都重装一遍,MySQLdb模块一直装不好,纠结了好久,终于解决,方法分享给大家. MySQLdb模块安装: 1.下载MySQL-pyhon模块,网站为:https://pyp ...
- python安装MySQLdb模块
以Ubuntu下安装为例: 下载地址:https://pypi.python.org/pypi/MySQL-python/ 解压后直接进入解压目录运行安装命令. python setup.py ins ...
- Python 安装MySQLdb模块遇到报错及解决方案:_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory
一.问题 系统:win7 64位 在下载MySQL-python-1.2.5.zip,使用python setup.py install 安装时,出现以下报错: _mysql.c(42) : fata ...
- mac下python安装MySQLdb模块
参考:http://blog.csdn.net/yelyyely/article/details/41114449 1.调整到anaconda下的python 2.安装有关程序 brew instal ...
- Windows下python 安装Mysqldb模块
CMD执行 pip install mysql-python 报错如下: 1.如果报类似 Microsoft Visual C++ 9.0 is required < Unable to fin ...
- Mac OS X 下安装python的MySQLdb模块
参考资料: mac os x下python安装MySQLdb模块 http://www.codeif.com/post/1073/ MAC OSX使用Python安装模块有关问题 http:// ...
随机推荐
- Linux ssh黄金参数
Linux ssh黄金参数 命令: -o ConnectionAttempts= -o PasswordAuthentication=no -o StrictHostKeyChecking=no cp ...
- OutOfMemoryError系列(2): GC overhead limit exceeded
原因分析 JVM抛出 java.lang.OutOfMemoryError: GC overhead limit exceeded 错误就是发出了这样的信号: 执行垃圾收集的时间比例太大, 有效的运算 ...
- 【Leetcode周赛】从contest-71开始。(一般是10个contest写一篇文章)
Contest 71 () Contest 72 () Contest 73 (2019年1月30日模拟) 链接:https://leetcode.com/contest/weekly-contest ...
- ubuntu 安装php xdebug
windows 安装xdebug https://www.jetbrains.com/help/phpstorm/configuring-xdebug.html 一.下载 下载与PHP版兼容的Xdeb ...
- Halo(十三)
Spring Boot Actuator 请求跟踪 Spring Boot Actuator 的关键特性是在应用程序里提供众多 Web 接口, 通过它们了解应用程序运行时的内部状况,且能监控和度量 S ...
- ceph优化记录 ceph.conf优化详解
https://cloud.tencent.com/developer/article/1173069 记录一下一些ceph优化的设置,部分内容来自网络,有些请根据自己需求相应修改 1. Kerne ...
- 常见HTTP错误代码
了解更多HTTP错误代码 一些常见的状态码为: 200 - 服务器成功返回网页404 - 请求的网页不存在503 - 服务不可用详细分解: 1xx(临时响应)表示临时响应并需要请求者继续执行操作的状态 ...
- this.$nextTick 与window.setTimeout
两个都可以设置运行先后.前者,方式: this.$nextTick(() => { this.$refs.orgAddOrUpdate.init(row, isAdd) }) 其中orgAddO ...
- CocoaPods中pod search报错的解决办法
pod search报错的原因: 每次使用pod search命令的使用会在该目录下生成一个search_index.json文件,会逐渐的增大,文件达到一定大小后,ruby解析里面的json字符就会 ...
- flex布局滚动问题,子元素无法全部显示的解决办法
flex布局使用起来非常方便,对于水平垂直居中的需求,很容易就能实现.但是前不久,在做全屏弹窗遮罩登录的时候,遇到了flex布局滚动的一个问题,在此记录一下. 问题重现 理想情况下,当然是下面的状态, ...