Ted ([info]trak3r) wrote,
@ 2005-06-06 21:53:00
Previous Entry  Add to memories!  Share this!  Next Entry
PHP & PostgreSQL Woes, Part Two and One-Half
I wasted another hour banging my head against getting PHP to talk to PostgreSQL with no luck. At one point I decided to shut down the database just to see if PHP would give me a useful error message. The error changed slightly to:

Warning: pg_connect(): Unable to connect to PostgreSQL server: could not connect to server: No such file or directory Is the server running locally and accepting connections on Unix domain socket "/tmp/.s.PGSQL.5432"?

And here's the kicker: after I started the database back up again, PHP continued to say it could not connect to the server. So I restarted Apache. Nope! How about if I reboot the entire machine? Sorry. I have really screwed something up now... yet all of the configuration files have been restored to their original state (I always make backups).



Create an Account
Forgot your login or password?
Log in with OpenID
English • Español • Deutsch • Русский…