PLEASE HELP - After updates (16 today) apache server won't come on

ok I got it - thanks Joe
here is what I see in the
“look at line 27 of /etc/httpd/conf.d/php.conf”

#
# The following lines prevent .user.ini files from being viewed by Web clients.
#
#<Files ".user.ini">
#    <IfModule mod_authz_core.c>
#        Require all denied
#    </IfModule>
#    <IfModule !mod_authz_core.c>
#        Order allow,deny
#        Deny from all
#        Satisfy All
#    </IfModule>
#</Files>
#
#
# Allow php to handle Multiviews
#
AddType text/html .php
#
#
# Add index.php to the list of files that will be served as directory
# indexes.
#
DirectoryIndex index.php
#
#mod_php options
<IfModule  mod_php5.c>
    #
    # Cause the PHP interpreter to handle files with a .php extension.
    #
    <FilesMatch \.php$>
       # SetHandler application/x-httpd-php
    </FilesMatch>

    #
    # Uncomment the following lines to allow PHP to pretty-print .phps
    # files as PHP source code:
    #
<FilesMatch \.phps$>
    #SetHandler application/x-httpd-php-source
</FilesMatch>
#
    #
    # Apache specific PHP configuration options
    # those can be override in each configured vhost
    #
#    php_value session.save_handler "files"
#    php_value session.save_path    "/var/lib/php/session"
#    php_value soap.wsdl_cache_dir  "/var/lib/php/wsdlcache"
#</IfModule>

In the above - I Think LINE 27 is as below
IfModule mod_php5.c

DirectoryIndex index.php
#
#mod_php options
<IfModule  mod_php5.c>
    #
    # Cause the PHP interpreter to handle files with a .php extension.
    #
    <FilesMatch \.php$>
       # SetHandler application/x-httpd-php
    </FilesMatch>

    #
    # Uncomment the following lines to allow PHP to pretty-print .phps
    # files as PHP source code:
    #
<FilesMatch \.phps$>
    #SetHandler application/x-httpd-php-source
</FilesMatch>
#
    #
    # Apache specific PHP configuration options
    # those can be override in each configured vhost
    #
#    php_value session.save_handler "files"
#    php_value session.save_path    "/var/lib/php/session"
#    php_value soap.wsdl_cache_dir  "/var/lib/php/wsdlcache"
#</IfModule>

I suspect this means you’ve installed mod_php. That would be a mistake.

Show me the output of this command:

rpm -qa|grep php

To get your sites back online, edit that php.conf file and comment out (put a # as the first character) every line that isn’t already commented out. You only need the contents of that file if mod_php is installed, and mod_php should not be installed. If it is installed, things will break again in the future, but just commenting out those lines and restarting httpd will get your sites online again, most likely.

[root@vmi431722 ~]# rpm -qa|grep php
php-pdo-5.6.40-39.el7.remi.x86_64
php-mbstring-5.6.40-39.el7.remi.x86_64
php-tidy-5.6.40-39.el7.remi.x86_64
php-pecl-zip-1.22.2-1.el7.remi.5.6.x86_64
php-php-gettext-1.0.12-1.el7.noarch
sclo-php72-php-pecl-imagick-3.4.4-3.el7.x86_64
rh-php72-php-zip-7.2.24-1.el7.x86_64
rh-php72-php-xmlrpc-7.2.24-1.el7.x86_64
phpMyAdmin-4.4.15.10-6.el7.noarch
gd3php-2.3.3-7.el7.remi.x86_64
php-xml-5.6.40-39.el7.remi.x86_64
php-bcmath-5.6.40-39.el7.remi.x86_64
php-pecl-ssh2-0.13-3.el7.remi.5.6.x86_64
rh-php72-php-pear-1.10.5-1.el7.noarch
rh-php72-php-devel-7.2.24-1.el7.x86_64
rh-php72-php-mbstring-7.2.24-1.el7.x86_64
php-pecl-imagick-im6-3.7.0-7.el7.remi.5.6.x86_64
php72-php-common-7.2.34-19.el7.remi.x86_64
php-xmlrpc-5.6.40-39.el7.remi.x86_64
php-odbc-5.6.40-39.el7.remi.x86_64
php-soap-5.6.40-39.el7.remi.x86_64
php-snmp-5.6.40-39.el7.remi.x86_64
php-mcrypt-5.6.40-39.el7.remi.x86_64
php-tcpdf-6.2.26-1.el7.noarch
rh-php72-runtime-1-2.el7.x86_64
rh-php72-php-cli-7.2.24-1.el7.x86_64
rh-php72-php-pdo-7.2.24-1.el7.x86_64
rh-php72-php-mysqlnd-7.2.24-1.el7.x86_64
rh-php72-php-opcache-7.2.24-1.el7.x86_64
php72-php-pecl-ssh2-1.4-2.el7.remi.x86_64
php-common-5.6.40-39.el7.remi.x86_64
php72-php-json-7.2.34-19.el7.remi.x86_64
php-5.6.40-39.el7.remi.x86_64
php-mysqlnd-5.6.40-39.el7.remi.x86_64
php-gd-5.6.40-39.el7.remi.x86_64
php-fedora-autoloader-1.0.1-2.el7.noarch
php-opcache-5.6.40-39.el7.remi.x86_64
php-imap-5.6.40-39.el7.remi.x86_64
php-tcpdf-dejavu-sans-fonts-6.2.26-1.el7.noarch
wbm-php-pear-1.6-1.noarch
sclo-php72-php-pecl-ssh2-1.2-1.el7.x86_64
rh-php72-php-json-7.2.24-1.el7.x86_64
rh-php72-php-xml-7.2.24-1.el7.x86_64
rh-php72-1-2.el7.x86_64
rh-php72-php-bcmath-7.2.24-1.el7.x86_64
php72-runtime-7.2-1.el7.remi.x86_64
php-cli-5.6.40-39.el7.remi.x86_64
php-fpm-5.6.40-39.el7.remi.x86_64
rh-php72-php-process-7.2.24-1.el7.x86_64
rh-php72-php-gd-7.2.24-1.el7.x86_64
rh-php72-php-pspell-7.2.24-1.el7.x86_64
php-pear-1.10.13-5.el7.remi.noarch
php72-php-pecl-imagick-im6-3.7.0-7.el7.remi.x86_64
php-pecl-jsonc-1.3.10-2.el7.remi.5.6.x86_64
php-process-5.6.40-39.el7.remi.x86_64
php-ldap-5.6.40-39.el7.remi.x86_64
rh-php72-php-common-7.2.24-1.el7.x86_64
rh-php72-php-fpm-7.2.24-1.el7.x86_64
[root@vmi431722 ~]#

There it is. You really should not have done that. I beg folks constantly not to do that. It’s in the guidelines: Forum Guidelines: Please read before posting!

If you followed our documentation for installing extra PHP versions this wouldn’t happen to you.

I’m so sorry Joe, I didn’t install it - I had a IT guy who is now not available do it all for me then I just basically upload all the websites here…

Anyways the only lines that don’t have the hash are as below

AddType text/html .php

DirectoryIndex index.php

<FilesMatch \.php$>

Should I add the hash at the beginning of these?
would that help?

Once again, I don’t know how to be more clear.

Joe and Ilia - Got it working
Helped me so much - Thanks a million :+1:

1 Like

This topic was automatically closed 8 days after the last reply. New replies are no longer allowed.