Roundcube Community Forum

Release Support => Pending Issues => Topic started by: rjel on October 18, 2007, 01:47:53 PM

Title: Cant connect to a postgres database
Post by: rjel on October 18, 2007, 01:47:53 PM
Hello!

I Have a Debian machine that I'm trying to configure roundcube to work on using Postgres (7.4) as database.

I get the famous (?)

DATABASE ERROR: CONNECTION FAILED!

Unable to connect to the database!
Please contact your server-administrator.

In my browser
In the apache error log the following is printed:
[Thu Oct 18 18:50:28 2007] [error] [client 217.208.191.12] PHP Notice: DB Error: extension not found in /usr/local/roundcubemail-0.1-rc1/program/include/bugs.inc on line 80

The connection string in db.inc.php file looks like this
$rcmail_config['db_dsnw'] = 'pgsql://roundcube:mypassword@localhost/roundcube';

I think I have set up postgres ok
I have turned on tcp/ip sockets (I can for example do >telnet localhost 5432 and get a promt)
added user roundcube and created database (>psql -d roundcube -U roundcube works and password is accepted )

What have I missed?

Thanks a lot in advance.

/Jonas
Title: Re: Cant connect to a postgres database
Post by: till on October 18, 2007, 08:59:40 PM
Check your phpinfo() if PHP has postgres support.
Title: Re: Cant connect to a postgres database
Post by: rjel on October 19, 2007, 03:10:11 AM
Yes

supported databases    MySQL ODBC PostgreSQL Microsoft SQL Server FrontBase Oracle 8 (oci8) Sybase-CT

Any other idea?

/Jonas
Title: Re: Cant connect to a postgres database
Post by: hcl on October 19, 2007, 04:52:40 AM
Hi rjel,

Quote
The connection string in db.inc.php file looks like this
$rcmail_config['db_dsnw'] = 'pgsql://roundcube:mypassword@localhost/roundcube';

You must set privilleges user 'roundcube' and setup the appropriate permissions on this database 'roundcube'
after there, 'flush privilleges'.

Title: Re: Cant connect to a postgres database
Post by: rjel on October 19, 2007, 05:50:44 AM
Done that, any more sugestions.

/Jonas