I am developing a website on a server I only have access to MySQL and FTP, so all commands I run are through the b374k php shell . I am experiencing a Laravel problem with SQL driver. I tried switching to file-hosted SQLite (in database/database.sqlite), but the thrown exception is the same as when using MySQL. The input & output of the console is as follows:

   php artisan migrate:refresh --seed
    [Illuminate\Database\QueryException]
could not find driver (SQL: select * from sqlite_master where type = 'table ' and name = migrations)
 [Doctrine\DBAL\Driver\PDOException]
could not find driver
 [PDOException]
could not find driver

The Apache extensions installed on the server are:

    /etc/php/5.6/apache2/conf.d/10-mysqlnd.ini, 
/etc/php/5.6/apache2/conf.d/10-opcache.ini,
 /etc/php/5.6/apache2/conf.d/10-pdo.ini,
 /etc/php/5.6/apache2/conf.d/15-xml.ini, 
/etc/php/5.6/apache2/conf.d/20-calendar.ini,
 /etc/php/5.6/apache2/conf.d/20-ctype.ini, 
/etc/php/5.6/apache2/conf.d/20-curl.ini,
 /etc/php/5.6/apache2/conf.d/20-dom.ini, 
/etc/php/5.6/apache2/conf.d/20-exif.ini, 
/etc/php/5.6/apache2/conf.d/20-fileinfo.ini, 
/etc/php/5.6/apache2/conf.d/20-ftp.ini, /etc/php/5.6/apache2/conf.d/20-gd.ini, 
/etc/php/5.6/apache2/conf.d/20-gettext.ini, 
/etc/php/5.6/apache2/conf.d/20-iconv.ini, 
/etc/php/5.6/apache2/conf.d/20-json.ini, 
/etc/php/5.6/apache2/conf.d/20-mbstring.ini, 
/etc/php/5.6/apache2/conf.d/20-mcrypt.ini, 
/etc/php/5.6/apache2/conf.d/20-mysql.ini, 
/etc/php/5.6/apache2/conf.d/20-mysqli.ini, 
/etc/php/5.6/apache2/conf.d/20-pdo_mysql.ini,
 /etc/php/5.6/apache2/conf.d/20-phar.ini, 
/etc/php/5.6/apache2/conf.d/20-posix.ini, 
/etc/php/5.6/apache2/conf.d/20-readline.ini, 
/etc/php/5.6/apache2/conf.d/20-shmop.ini, 
/etc/php/5.6/apache2/conf.d/20-simplexml.ini, 
/etc/php/5.6/apache2/conf.d/20-sockets.ini,
 /etc/php/5.6/apache2/conf.d/20-sysvmsg.ini,
 /etc/php/5.6/apache2/conf.d/20-sysvsem.ini,
 /etc/php/5.6/apache2/conf.d/20-sysvshm.ini,
 /etc/php/5.6/apache2/conf.d/20-tokenizer.ini, 
/etc/php/5.6/apache2/conf.d/20-wddx.ini,
 /etc/php/5.6/apache2/conf.d/20-xmlreader.ini, 
/etc/php/5.6/apache2/conf.d/20-xmlwriter.ini, 
/etc/php/5.6/apache2/conf.d/20-xsl.ini, 
/etc/php/5.6/apache2/conf.d/20-zip.ini

What can be the problem and how can I fix it? (I don't have access to root bash)

推荐答案

If you can, run :

composer update

composer require doctrine/dbal

It looks like you have a missing dependency

Edit:

You might need to comment out the following in your php.ini file.

;extension=pdo_mysql.so

Taken from this post: Laravel 5 PDOException Could Not Find Driver . I think I had to do something exactly like this when setting up laravel on digital ocean.

Php相关问答推荐

PHP日期操作,将多个日期输出为格式化字符串

在内部API请求之后,在响应客户端之前,是否忘记了PHP中的Header()?

莫德克斯.当我try 使用pThumb为手机压缩图像时,没有任何react

使用随机生成器在MYSQL中创建唯一ID-定义一个数组来存储已知ID是否安全

Laravel withOnly不限制查询

在WooCommercel邮箱通知上添加来自Apaczka插件的选定交付点

如何在 apache Laragon - laravel 10 中允许方法 DELETE?

防止 WooCommerce 在前端加载全尺寸图像

如何使用 AJAX、PHP 和 MYSQL 在 Select 项目时在文本框中填充数据

用自定义代码替换 WooCommerce 单一产品简短描述

PHP Laravel 迁移文件不创建关系

标签打印机的 CSS

如何处理 Null 上的 array_shift() ?

如何从 URL 核心 PHP 中的 API 获取 JSON?

使用 Laravel 和 Vue 进行图像表单验证

如何将文件上传添加到 WooCommerce 结帐?

Laravel 路由参数中的 ":" 是什么?

在 GA4 Data API V1 Beta 中使用 inListFilter 过滤器时出错

使用 GROUP_CONCAT 规范化/转置来自查询的数据

在 DomPDF 和 Laravel 中使用内联 css