HI. I have instaled a WEB server with Postgresql on CentOS 6.2. PostgreSQL, versin 9.1.3 x64 from EntrrpriseDB base *.run*. PHP with PDO from YUM using reposity versions. On start apache does not get error. PHP LOG under, with PDO error. *PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/modules/pdo_pgsql.so' - libpq.so.5: failed to map segment from shared object: Permission denied in Unknown on line 0 *PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/modules/pdo_pgsql.so' - libpq.so.5: failed to map segment from shared object: Permission denied in Unknown on line 0 PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/modules/xsl.so' - libxslt.so.1: failed to map segment from shared object: Permission denied in Unknown on line 0 [Tue Mar 27 09:35:17 2012] [notice] Apache/2.2.15 (Unix) DAV/2 PHP/5.3.3 mod_ssl/2.2.15 OpenSSL/1.0.0-fips configured -- resuming normal operations I try to reinstall all PHP modules and get this messages Installing : php-xml-5.3.3-3.el6_2.6.x86_64 14/24 Installing : php-intl-5.3.3-3.el6_2.6.x86_64 15/24 Installing : php-embedded-5.3.3-3.el6_2.6.x86_64 16/24 */sbin/ldconfig: /opt/PostgreSQL/psqlODBC/lib/libpq.so.5 is not a symbolic link* Installing : php-soap-5.3.3-3.el6_2.6.x86_64 17/24 Installing : php-mbstring-5.3.3-3.el6_2.6.x86_64 18/24 Installing : php-snmp-5.3.3-3.el6_2.6.x86_64 19/24 PostgreSQL an APACHE runs normal and PHP does not recognize php_pgsql/pdo_pgsql. How i fix this mess? Thanks. -------------------------------------- Rudinei Dias
Leonard den Ottolander
2012-Mar-27 13:15 UTC
[CentOS] Problem with PHP / Postgresql on CentOS6.2
Hello Rudinei, On Tue, 2012-03-27 at 09:49 -0300, Rudinei Dias wrote:> I have instaled a WEB server with Postgresql on CentOS 6.2. > PostgreSQL, versin 9.1.3 x64 from EntrrpriseDB base *.run*.> PostgreSQL an APACHE runs normal and PHP does not recognize > php_pgsql/pdo_pgsql. > > How i fix this mess?By not mixing dependent packages from different repos, unless you are prepared to fix and rebuild them. Is there any reason you cannot use the postgresql distributed with the distro? If you do have to use a more recent version it's usually the easiest approach to either use a Fedora SRPM or to use the RHEL SRPM and pop in a more recent tarball. In either case you might have to fix the SPEC file to remove stale patches, update/fix dependencies etc. YMMV. Regards, Leonard. -- mount -t life -o ro /dev/dna /genetic/research
From: Rudinei Dias <rudinei.dias at gmail.com>> *PHP Warning:? PHP Startup: Unable to load dynamic library > '/usr/lib64/php/modules/pdo_pgsql.so' - libpq.so.5: failed to map > segment > from shared object: Permission denied in Unknown on line 0 > *PHP Warning:? PHP Startup: Unable to load dynamic library > '/usr/lib64/php/modules/pdo_pgsql.so' - libpq.so.5: failed to map > segment > from shared object: Permission denied in Unknown on line 0 > PHP Warning:? PHP Startup: Unable to load dynamic library > '/usr/lib64/php/modules/xsl.so' - libxslt.so.1: failed to map segment > from > shared object: Permission denied in Unknown on line 0If it is only a posgresql problem, why does php complain about xsl.so too? Permission denied... SELinux? JD
On 03/27/12 5:49 AM, Rudinei Dias wrote:> HI. > > I have instaled a WEB server with Postgresql on CentOS 6.2. > PostgreSQL, versin 9.1.3 x64 from EntrrpriseDB base *.run*. > PHP with PDO from YUM using reposity versions. >use the postgres developer group's RPM's, not the entterpriseDB installer. # rpm -ivh http://yum.postgresql.org/9.1/redhat/rhel-6-x86_64/pgdg-centos91-9.1-4.noarch.rpm ... # yum install postgresql91-{server,contrib,devel) ... # service postgresql-9.1 initdb (then edit your .conf files in /var/lib/pgsql/9.1/data # chkconfig postgresql-9.1 on # service postgresql-9.1 start done. this will properly integrate with the base repository's php-pgsql and pdo. -- john r pierce N 37, W 122 santa cruz ca mid-left coast
On Wednesday, March 28, 2012 08:08:09 AM Rudinei Dias wrote:> Thanks, John. > that is was i look for. > The postgreSQL documentation about yum/centos/rhel must be updated.[Mostly for the archives.....] The CentOS AdditionalRepositories Wiki page provides the links necessary to find the latest PostgreSQL packages; see http://wiki.centos.org/AdditionalResources/Repositories The PostgreSQL packaging team does a fine job of dealing with the issues that will arise when a core package is updated in this way, but, at the same time, if you use them you will be making your CentOS install 'non-stock' and thus support is more difficult (on real RHEL, installing anything not in the official RHN repos can void your support entirely....). I once did that work, alone, but now there is a great team making a good repo for the latest (and older versions, up to a point) PostgreSQL. And I use their 9.1 packages on C4, C5, and C6 to good effect. YMMV, of course.
Reasonably Related Threads
- CESA-2012:0093 Critical CentOS 6 php Update
- CentOS-announce Digest, Vol 84, Issue 3
- After performing a reboot in VM (Virtualbox), log user on gnome not display the desktop.
- CEBA-2012:0342 CentOS 6 libvirt Update
- CESA-2012:0095 Moderate CentOS 6 ghostscript Update