Linux下安装MySQLdb模块(Python)
来源:互联网 发布:淘宝怎么贷款最高额度 编辑:程序博客网 时间:2024/05/20 04:30
一、MySQLdb-python模块
https://pypi.python.org/pypi/MySQL-python
`
二、安装依赖包
yum -y install python-devel mysql-devel
`
三、解压文件并修改site.cfg
tar -xf MySQL-python-1.2.3.tar.gz
cd MySQL-python-1.2.3
找到本地MySQL安装目录下的mysql_config,将site.cfg文件中mysql_config修改为该地址,并将threadsafe修改为False.
[root@localhost MySQL-python-1.2.3]# more site.cfg
[options]
# embedded: link against the embedded server library
# threadsafe: use the threadsafe client
# static: link against a static library (probably required for embedded)
embedded = False
threadsafe = False
static = False
# The path to mysql_config.
# Only use this if mysql_config is not on your PATH, or you have some weird
# setup that requires it.
mysql_config = /usr/local/mysql/bin/mysql_config
# The Windows registry key for MySQL.
# This has to be set for Windows builds to work.
# Only change this if you have a different version.
registry_key = SOFTWARE\MySQL AB\MySQL Server 5.0
四、编译和安装
python setup.py build
python setup.py install
- Linux下安装MySQLdb模块(Python)
- Python安装MySQLdb模块(Linux)
- linux下安装MySQLdb模块
- Linux下安装MySQLdb模块
- Linux下安装 MySQLdb模块 MySQL-python 坎坷之路
- 【Python】Linux下安装MySQLdb
- Linux下安装Python MySQLdb
- windows 下安装 python 的 mysqldb 模块
- mac下python安装MySQLdb模块
- Windows下安装Python数据库模块--MySQLdb
- Python下的Mysql模块MySQLdb安装
- windows下python 安装mysqldb模块
- wins下python安装MySQLdb模块
- Linux Ubuntu11.10 python安装MySQLdb模块
- python MySQLdb模块 for linux安装
- 在linux下安装MySQLdb模块
- 在linux下安装MySQLdb模块
- linux下MySQLdb模块简便安装
- oracle存储过程基本使用
- 【SQL之查询】MySQL查询今天、昨天、上周、近30天、去年等的数据的方法
- 二叉树14:把二叉树打印成多行
- HDU5334(构造,思维)
- spring整合redis(集群、主从)
- Linux下安装MySQLdb模块(Python)
- C#实现环信用户和群组操作
- 二叉树15:对称的二叉树
- 递归和栈求解迷宫的最短路径
- 数据回显
- NS3编译遇到的Python相关的问题解决办法
- 图解Linux命令之--ifconfig命令
- c语言中return
- Thymeleaf教程(三)th标签整理