简体   繁体   中英

I cannot install pdo_pgsql.so to use PostgreSQL in PHP

I have a site that use PostgreSQL database but I found that my RHEL 5 system lacks of pdo_pgsql.so file. I have spent several hours trying to install it but it was impossible.

When using "rpm -i" command with a lot RPMs found in Internet, I always got dependencies problems.

Last command I have issued before posting here was:

rpm -i http://yum.postgresql.org/9.1/redhat/rhel-5-i386/pgdg-redhat91-9.1-5.noarch.rpm

The output to that command was: package pgdg-redhat91-9.1-5 is already installed

And in fact, PostgreSQL database is up and running. The only missing file is pdo_pgsql.so.

I have used "find . / -name pdo_pgsql.so" to see if that file is somewhere in the disk, but without success.

Can you point me to the right direction, please?

These are relevant versions:

  • psql (PostgreSQL) 9.1.2
  • PHP 5.3.27 (cli) (built: Dec 8 2013 19:01:03)
  • Server version: Apache/2.4.1 (Unix)
  • Red Hat Enterprise Linux Server release 5 (Tikanga)

Cheers Jaime

I have recompiled last PHP version with Postgres support option and the problem was solved. However, it is strange, because version of PHP I had before worked with postgres. For some reaon, it stopped working,

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM