LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 11-11-2015, 10:57 AM   #1
youngstorm
Member
 
Registered: May 2003
Location: USA
Distribution: Fedora 21, RHEL 5,6&7, Windoze 7
Posts: 235

Rep: Reputation: 31
upgrading PHP from 5.3.3 to 5.4.40 breaks


Hello all,

I have a RHEL 6.7 server running:
Apache: 2.2.15
PHP 5.3.3
getenforce => Disabled

As is, its working fine.
The web master for the server tells me that PHP-5.3 will no longer work with Facebook's API and that I need to upgrade to 5.4 or later. Attempting to do this, I have followed the steps at http://developerblog.redhat.com/2013...6-using-rhscl/
The only real change I made was to do: ' rhn-channel --add --channel=rhel-x86_64-server-6-rhscl-1' since the article is a bit dated. Other than that I followed the steps closely. I even got the
Quote:
"[warn] module php5_module is already loaded, skipping"
To solve it, I did 'mv /etc/httpd/conf.d/php.conf /etc/httpd/conf.d/php.conf.php5.3' to keep it from running when Apache starts. I then restarted apache. This is what I get in the error logs.
Quote:
[Wed Nov 11 11:41:59 2015] [notice] caught SIGTERM, shutting down
[Wed Nov 11 11:41:59 2015] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Wed Nov 11 11:41:59 2015] [notice] Digest: generating secret for digest authentication ...
[Wed Nov 11 11:41:59 2015] [notice] Digest: done
[Wed Nov 11 11:41:59 2015] [notice] Apache/2.2.15 (Unix) PHP/5.4.40 mod_ssl/2.2.15 OpenSSL/1.0.1e-fips configured -- resuming normal operations
'httpd -M | grep php' shows:
Quote:
Syntax OK
php5_module (shared)
All I get is a blank page when I try to load the web page instead of executing index.php like it did before. I think I'm missing something simple. Below is my current /etc/httpd/conf.d/php54-php.conf

Does anyone have any ideas how I can make it run index.php properly?
Thank you so much for your time.

Mike


My comment are prefaced by 3 #. Like ### <My comments>

Quote:
#
# PHP is an HTML-embedded scripting language which attempts to make it
# easy for developers to write dynamically generated webpages.
#
<IfModule prefork.c>
LoadModule php5_module modules/libphp54-php5.so
</IfModule>

#
# Cause the PHP interpreter to handle files with a .php extension.
#
<FilesMatch \.php$>

### Shows a blank page instead of running the PHP code.
SetHandler application/x-httpd-php

### Shows the PHP source code instead of running it
#SetHandler application/x-httpd-php5

</FilesMatch>

#
# Allow php to handle Multiviews
#
#AddHandler php5-script .php
AddType text/html .php

### Seems to have no effect
#AddType application/x-httpd-php .php

### Seems to have no effect
#AddType application/x-httpd-php-source .phps

#
# Add index.php to the list of files that will be served as directory
# indexes.
#
DirectoryIndex index.php

#
# 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 "/opt/rh/php54/root/var/lib/php/session"
 
Old 11-12-2015, 02:22 AM   #2
j-ray
Senior Member
 
Registered: Jan 2002
Location: germany
Distribution: ubuntu, mint, suse
Posts: 1,591

Rep: Reputation: 145Reputation: 145
Could be your PHP script contains elements that cause fatal errors with the new PHP version. Put the following to the top of your index.php

<?php //this should already be there...

error_reporting(E_ALL);
ini_set('display_errors', '1');

Next time you call the page it will give out errors if there are some in the script
 
Old 11-12-2015, 04:16 PM   #3
youngstorm
Member
 
Registered: May 2003
Location: USA
Distribution: Fedora 21, RHEL 5,6&7, Windoze 7
Posts: 235

Original Poster
Rep: Reputation: 31
j-ray, Thank you so much. This is exactly what I needed.
 
  


Reply

Tags
php 5 update



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
After upgrading php 5.3.8 to php 5.4.30 php files are not being executed kingkashif Linux - Server 5 06-26-2014 10:15 AM
[SOLVED] Upgrading from F11 to F12 Breaks Google Chrome? mejohnsn Fedora 16 06-16-2010 04:31 AM
upgraded apache and php now php breaks on ' and special characters ckob Linux - Server 4 10-22-2007 09:28 PM
Upgrading libc.so from 2.3.1 to 2.3.2 breaks Mozilla mike_y Slackware 1 09-19-2006 08:48 PM
Upgrading to KDE3.4 breaks Susehelp's search function wabe SUSE / openSUSE 2 06-21-2005 04:35 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 11:08 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration