宝塔面板centos7/php5.6安装mssql扩展

可以参考:https://blog.csdn.net/21aspnet/article/details/47451253

前面安装FreeTDS啥都很顺,最后安装mssql和pdo_dblib 一直失败。

最后总结,有两个地方要注意:

1 宝塔面板的php路径和phpize路径和文章说的不一样;

2 宝塔的php必须先编译安装,否则无法正常执行下面的脚本

cd /www/server/php/56/src/ext/mssql
/www/server/php/56/bin/phpize
./configure –with-php-config=/www/server/php/56/bin/php-config –with-mssql=/usr/local/freetds/
make && make install

cd /www/server/php/56/src/ext/pdo_dblib/
/www/server/php/56/bin/phpize
./configure –with-php-config=/www/server/php/56/bin/php-config –with-pdo-dblib=/usr/local/freetds/
make && make install

转载自:http://www.cnblogs.com/shaobin86/p/9490381.html

猜你喜欢

转载自blog.csdn.net/u010837612/article/details/81837266