Issue with PDO Driver

Hi


I'm attempting to evaluate MySource Matrix on a Ubuntu 8.04 server, but have run into a brick wall with install step_02.php which always gives the following error


    Fatal error: Uncaught exception 'Exception' with message 'Could not create database connection: DBError!:could not find driver' in /home/websites/mysource_matrix/core/include/mysource.inc:2313
    Stack trace:
    #0 /home/websites/mysource_matrix/core/include/mysource.inc(211): MySource->changeDatabaseConnection('db')
    #1 /home/websites/mysource_matrix/core/include/init.inc(231): MySource->init()
    #2 /home/websites/mysource_matrix/install/step_02.php(57): require_once('/home/websites/...')
    #3 {main}
      thrown in /home/websites/mysource_matrix/core/include/mysource.inc on line 2313


Having searched these forums extensively I've taken all the advice in other threads on this issue, but nothing seems to resolive it. I have the following PEAR modules installed

    INSTALLED PACKAGES, CHANNEL PEAR.PHP.NET:
    =========================================
    PACKAGE		  VERSION STATE
    Archive_Tar	  1.3.2   stable
    Console_Getopt   1.2.3   stable
    DB			   1.7.13  stable
    Mail			 1.1.14  stable
    Mail_Mime		1.5.2   stable
    Mail_mimeDecode  1.5.0   stable
    PEAR			 1.7.1   stable
    Structures_Graph 1.0.2   stable
    XML_HTMLSax	  2.1.2   stable
    XML_Parser	   1.3.1   stable


And phpinfo shows the following information for PDO

    PDO
    PDO support enabled
    PDO drivers pgsql
pdo_pgsql
PDO Driver for PostgreSQL	enabled
PostgreSQL(libpq) Version 	8.3.4
Module version 			   1.0.2
Revision 					 $Id: pdo_pgsql.c,v 1.7.2.11 2006/03/14 10:49:18 edink Exp $</pre><br />

I'm sure that there is something else fairly basic that I'm missing - but I can't see from having had a good root around exactly what that would be. Any suggestions gratefully received.

Ian

Edit: Install is MySource Matrix version 3.18.7

Are you able to show your db.inc file?

    <?php
    $db_conf = array (
    		'db' => array (
    				'DSN'	  => 'pgsql:dbname=mysource_matrix',
    				'user'	 => 'matrix',
    				'password' => '****',
    				'type'	 => 'pgsql',
    			   ),
    		'db2' => array (
    				'DSN'	  => 'pgsql:dbname=mysource_matrix',
    				'user'	 => 'matrix',
    				'password' => '****',
    				'type'	 => 'pgsql',
    			   ),
    		'db3' => array (
    				'DSN'	  => 'pgsql:dbname=mysource_matrix',
    				'user'	 => 'matrix_secondary',
    				'password' => '****',
    				'type'	 => 'pgsql',
    			   ),
    		'dbcache' => NULL,
    		'dbsearch' => NULL,
    		);
    
    return $db_conf;
    ?>

Thats odd as it all looks fine.


Did you have everything installed when you started? Sometimes I have had issues when starting an install with a DB driver missing, and starting from a clean copy where you havent ran step_01 helps.



it might help to send the output of strace from the running of the script, might help.



You can send directly to me (jcormack@squiz.co.uk) if you like.

For the record (in case anyone else has the same issue!) this turned out to be two things. Firstly I did not have php5-pgsql installed (doh!) and secondly, although I had installed pdo and pdo-pgsql for some reason the PECL installer had not updated them to the latest version. This was fixed by uninstalling and reinstalling these modules.