1

Today i have updated my MacBook to OS X 10.9.

After the update new configs (httpd.config and php.ini) were added and the old configs was renamed previous. I changed the confignames and everything works finde. Everything? No, postgres were not loaded. I created a phpinfo() test.php to check this. And yes, postgres were not loaded.

A view into the apache error log say PHP Fatal error: Call to undefined function pg_connect(). This is the logical response.


EDIT:

I tried the solutions from: here But still the same problem.

I manually installed PDO_postgreswith pecl. Now phpinfo() shows the pdo_pgsql extension and apache can load the dynamic library. But i need the normal pgsql extension. I still get the:

PHP Startup: Unable to load dynamic library '/usr/lib/php/extensions/no-debug-non-zts-20100525/php_pgsql.dll' - dlopen(/usr/lib/php/extensions/no-debug-non-zts-20100525/php_pgsql.dll

error.

How can i install the normal pgsql extensions manually? Pecl don't find the package.

I can successfully connect to my databases with PGAdmin.


Do someone know how i can fix the problem? Have i forgot something to change?

EDIT2:

I solved the problem with installing pgsql extension manually.

Community
  • 1
  • 1
q0re
  • 1,365
  • 17
  • 32

3 Answers3

1

I m not very sure about OS X but this happens in Windows or Linux usually because the OS extensions missing

Patato
  • 1,434
  • 9
  • 12
1

This Problem is also known and discussed here: Enabling PostgreSQL support in PHP on Mac OS X

Additionally I found an other solution, by using PostgresApp (http://postgresapp.com) instead of Brew here (Postgres.app, PHP and Mavericks)

Hope everything is clear now!

Community
  • 1
  • 1
m33x
  • 45
  • 1
  • 7
0

Postgresql seems no longer be part of Mac OSX, but can be easly installed manually e.g. via brew. (http://brew.sh)

This Question / Problem is already known on StackOverflow, just visit Repairing postgresql after upgrade to OSX Mavericks and fix the problem by installing postgresql via Brew and starting it via launchctl.

Hope that works,

cheers

Community
  • 1
  • 1
m33x
  • 45
  • 1
  • 7