今天安装 MySQLdb,需要mysql_config 但是系统找不到,报如下错误信息:
# which mysql_config
/usr/bin/which: no mysql_config in (/usr/local/java/jdk1.6.0_43/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin)
原因是没有安装mysql的devel包,我这用的percona 方式安装mysql数据库,解决方法如下:
# yum install Percona-Server-devel-55.x86_64
# which mysql_config
/usr/bin/mysql_config