Установка PDO sqlite3 драйвера на Ubuntu
joomla
pdo_mysql
rockgallery
vgkk
I was surprised to find PDO sqlite support wasn’t included by default with PHP 5 on my Ubuntu (10.04) virtual machine. You can check which drivers are available with this small snippet of code (assuming you run this from the command line):
Update: Long story short, I tried the following command on this web server and it worked without any hiccups. Try this first and see where it gets you, the rest of the article may dig you out of a hole if things break.
For whatever reason, my local Ubuntu VM I develop on had some issues, I originally wrote this blog post around the problems I encountered then.
I initially tried installing the php5-sqlite
package:
This appeared to install successfully but did not enable the sqlite driver in PHP. I then tried to install the sqlite driver via PECL but this failed to install both pdo and pdo_sqlite.
$ sudo pecl install pdo
...
make: *** [pdo_dbh.lo] Error 1
ERROR: `make' failed
$ sudo pecl install pdo_sqlite
...
configure: error: Cannot find php_pdo_driver.h.
ERROR: `/tmp/pear/temp/PDO_SQLITE/configure' failed
Это говорит о том, что нарушена текущая установка pdo драйвера.
Для решения проблемы надо переустановить компоненты php5.