I'm new to phpWiki, and wasn't sure which version to go for so thought I'd try the latest.
I got it working ok locally on windows , with PostgreSQL (after a bit if faffing), but now am trying to set it up on my production server. It works ok with flat files as the storage, but won't communicate with PostgreSQL.
I have:
- created a database, created the tables, created a user with permissions on the tables.
edited the config.ini file to have SQL as the database type, and have this DSN
DATABASE_DSN = "pgsql://wiki:wiki@localhost:5432/wiki"
Other PHP applications on the server can access postgres, so I think my pg_hba.conf is ok.
But if I try to view the Wiki in a browser, all I get is a blank page. I put echo's in the code ot establish that it breaks at this line in main.php
$this->_dbi = WikiDB::open($GLOBALS['DBParams']);
But it doesn't throw any errors and I don't know anything about the Pear DB stuff to try debugging it.
So, my question is, should this version work with PostgreSQL, and how can I track down the problem?
Thanks for your help!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
I'm new to phpWiki, and wasn't sure which version to go for so thought I'd try the latest.
I got it working ok locally on windows , with PostgreSQL (after a bit if faffing), but now am trying to set it up on my production server. It works ok with flat files as the storage, but won't communicate with PostgreSQL.
I have:
- created a database, created the tables, created a user with permissions on the tables.
DATABASE_DSN = "pgsql://wiki:wiki@localhost:5432/wiki"
Other PHP applications on the server can access postgres, so I think my pg_hba.conf is ok.
But if I try to view the Wiki in a browser, all I get is a blank page. I put echo's in the code ot establish that it breaks at this line in main.php
$this->_dbi = WikiDB::open($GLOBALS['DBParams']);
But it doesn't throw any errors and I don't know anything about the Pear DB stuff to try debugging it.
So, my question is, should this version work with PostgreSQL, and how can I track down the problem?
Thanks for your help!
Are you sure pgsql is available on port 5432 on the host the web server is running on?
On Linux postgresql just listens on its socket, and now only on localhost via TCP/IP.
Not recommended to connect to the port, better to the socket. Only on Windows TCP/IP is default. It's much slower via the port.
Before the postmaster option was -i, now it's -h hostname.
See listen_addresses in postgresql.conf