Recently i've created Symfony3 project by command:
symfony new myproject
The project uses mysql and it works fine.
After that i've created demo project to study symfony best practices:
symfony demo
Project was created successfully. Config.php shows, that everything is ok. app_dev.php was successfully opened in my web browser. But when i try to open "http://localhost/app_dev.php/ru/blog/" (there is a public part of the app) 500 internal server error will appear. /app_dev.php/ru/blog/ shows:
Error message:
An exception occured in driver: could not find driver
500 Internal Server Error - DriverException
2 linked Exceptions:
PDOException »
PDOException »
Critical part in call stack:
CRITICAL - Uncaught PHP Exception Doctrine\DBAL\Exception\DriverException: "An exception occured in driver: could not find driver" at /var/www/symfony_demo/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/AbstractSQLiteDriver.php line 85
I've read all stack exchange issues about PDO Exception, but none helps me...
I use Ubuntu, Nginx.
Mysql, sqlite, php5-sqlite, sqlite3, libsqlite3-dev are installed. Nginx and php5-fpm are restarted. php.ini SQLite 3.x driver for PDO Wez Furlong.
Demo app parameters.yml:
database_driver: pdo_sqlite
database_host: 127.0.0.1
database_port: null
database_name: null
database_user: root
database_password: null
database_path: '%kernel.root_dir%/data/blog.sqlite'
mailer_transport: smtp
mailer_host: 127.0.0.1
mailer_user: null
mailer_password: null
locale: en
secret: secret_value_for_symfony_demo_application
php.ini file:
[sqlite]
; http://php.net/sqlite.assoc-case
;sqlite.assoc_case = 0
[sqlite3]
;sqlite3.extension_dir =
I have no idea, what is the reason of the problem and how to resolve it.
Help please!
Just install:
sudo apt install php-sqlite3
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With