Php Laravel Illumb\Database\QueryException:找不到驱动程序错误
我在PHP7.2中使用Centos 7.7,但当我尝试使用laravel迁移db时,会出现此错误。尝试了很多事情,但我解决不了这个问题Php Laravel Illumb\Database\QueryException:找不到驱动程序错误,php,laravel,centos,plesk,Php,Laravel,Centos,Plesk,我在PHP7.2中使用Centos 7.7,但当我尝试使用laravel迁移db时,会出现此错误。尝试了很多事情,但我解决不了这个问题 Illuminate\Database\QueryException : could not find driver (SQL: select * from information_schema.tables where table_schema = forge and table_name = migrations and table_type = 'BAS
Illuminate\Database\QueryException : could not find driver (SQL: select * from information_schema.tables where table_schema = forge and table_name = migrations and table_type = 'BASE TABLE')
at /var/www/vhosts/xxxx.com/saas.xxxx.com/vendor/laravel/framework/src/Illuminate/Database/Connection.php:669
665| // If an exception occurs when attempting to run a query, we'll format the error
666| // message to include the bindings with SQL, which will make this exception a
667| // lot more helpful to the developer instead of just the database's errors.
668| catch (Exception $e) {
> 669| throw new QueryException(
670| $query, $this->prepareBindings($bindings), $e
671| );
672| }
673|
你需要安装驱动程序 试试这个 也会有帮助
您的centos实例缺少php mysql驱动器谢谢,但它显示已安装php-mysqlnd-7.2.25-1.el7.remi.x86_64包,且该包的最新版本和相同问题。。
yum install -y --enablerepo=remi-php72 php-pdo_mysql