While installing Drupal 7 on CentOS 5 PHP 5.2.14 it gives:

PHP extensions	Disabled
Drupal requires you to enable the PHP extensions in the following list (see the system requirements page for more information):
dom

My phpinfo () shows:

'./configure' '--build=x86_64-redhat-linux-gnu' '--host=x86_64-redhat-linux-gnu' '--target=x86_64-redhat-linux-gnu' '--program-prefix=' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib64' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--cache-file=../config.cache' '--with-libdir=lib64' '--with-config-file-path=/etc' '--with-config-file-scan-dir=/etc/php.d' '--disable-debug' '--with-pic' '--disable-rpath' '--without-pear' '--with-bz2' '--with-exec-dir=/usr/bin' '--with-freetype-dir=/usr' '--with-png-dir=/usr' '--with-xpm-dir=/usr' '--enable-gd-native-ttf' '--with-t1lib=/usr' '--without-gdbm' '--with-gettext' '--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-openssl' '--with-pcre-regex' '--with-zlib' '--with-layout=GNU' '--enable-exif' '--enable-ftp' '--enable-magic-quotes' '--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-sysvmsg' '--with-kerberos' '--enable-ucd-snmp-hack' '--enable-shmop' '--enable-calendar' '--without-mime-magic' '--without-sqlite' '--with-libxml-dir=/usr' '--with-xml' '--with-system-tzdata' '--enable-force-cgi-redirect' '--enable-pcntl' '--with-imap=shared' '--with-imap-ssl' '--enable-mbstring=shared' '--enable-mbregex' '--with-ncurses=shared' '--with-gd=shared' '--enable-bcmath=shared' '--enable-dba=shared' '--with-db4=/usr' '--with-xmlrpc=shared' '--with-ldap=shared' '--with-ldap-sasl' '--with-mysql=shared,/usr' '--with-mysqli=shared,/usr/bin/mysql_config' '--enable-dom=shared' '--with-pgsql=shared' '--enable-wddx=shared' '--with-snmp=shared,/usr' '--enable-soap=shared' '--with-xsl=shared,/usr' '--enable-xmlreader=shared' '--enable-xmlwriter=shared' '--with-curl=shared,/usr' '--enable-fastcgi' '--enable-fpm' '--enable-libevent' '--enable-pdo=shared' '--with-pdo-odbc=shared,unixODBC,/usr' '--with-pdo-mysql=shared,/usr' '--with-pdo-pgsql=shared,/usr' '--with-pdo-sqlite=shared,/usr' '--with-pdo-dblib=shared,/usr' '--enable-json=shared' '--enable-zip=shared' '--with-readline' '--enable-dbase=shared' '--with-pspell=shared' '--with-mcrypt=shared,/usr' '--with-mhash=shared,/usr' '--with-tidy=shared,/usr' '--with-mssql=shared,/usr' '--enable-sysvmsg=shared' '--enable-sysvshm=shared' '--enable-sysvsem=shared' '--enable-posix=shared' '--with-unixODBC=shared,/usr' '--with-recode=shared,/usr'

In 'additional .ini files parsed' sections it also lists:

/etc/php.d/curl.ini, /etc/php.d/dbase.ini, /etc/php.d/gd.ini, /etc/php.d/imap.ini, /etc/php.d/json.ini, /etc/php.d/ldap.ini, /etc/php.d/mbstring.ini, /etc/php.d/mcrypt.ini, /etc/php.d/memcache.ini, /etc/php.d/mysql.ini, /etc/php.d/mysqli.ini, /etc/php.d/odbc.ini, /etc/php.d/pdo.ini, /etc/php.d/pdo_mysql.ini, /etc/php.d/pdo_odbc.ini, /etc/php.d/pdo_pgsql.ini, /etc/php.d/pdo_sqlite.ini, /etc/php.d/pgsql.ini, /etc/php.d/snmp.ini, /etc/php.d/xmlrpc.ini, /etc/php.d/zip.ini

cat /etc/php.d/pdo.ini shows:

; Enable pdo extension module
extension=pdo.so

So I am confused if am I good to proceed with installation of Drupal7 or not? Is Drupal7 installation requirements should be corrected or '--enable-pdo=shared' is not the same with '--enable-pdo'? If not the same, what I am supposed to change in my php configuration?

Thanks!

Comments

yngens’s picture

Category: support » bug

It is rather a bug report together with a support request.

David_Rothstein’s picture

Category: bug » support

If you get that warning, it means that PHP itself (not Drupal specifically) doesn't recognize that the dom extension is loaded, and won't be able to use it. I don't think the fact that it was passed in as a configuration option guarantees it is installed correctly (especially since PHP enables this one by default even if it is not passed in).

A little searching suggests that on CentOS specifically, you need to make sure that the php-dom and php-xml packages are both installed before the dom extension can be used. Perhaps that is causing your issue?
http://serverfault.com/questions/170743/enable-php-dom-extension-on-cent...
http://www.hofmockel.org/content/setting-centos-5-drupal-6-dell-poweredg...

yngens’s picture

Status: Active » Closed (fixed)

Thanks David, that made a trick. So in CentOS '--enable-dom=shared' does not necessarily mean that DOM was installed. You have to run 'yum install php-dom
'. Marking this fixed (closed).