Bug 77199 - php logging oddities
php logging oddities
Status: CLOSED WONTFIX
Product: Red Hat Linux
Classification: Retired
Component: php (Show other bugs)
8.0
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Joe Orton
David Lawrence
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2002-11-02 17:44 EST by Carl T. Miller
Modified: 2007-04-18 12:48 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2005-02-03 07:06:27 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Carl T. Miller 2002-11-02 17:44:43 EST
Description of Problem:
A php script that worked with RH73 wouldn't work with RH80.  I turned on logging
and set the log file to /var/log/httpd/php_errors in the /etc/php.ini file. 
After this the script worked.  (Why would this make any difference?)

When I put an error in the script to test the logging feature, nothing was
logged.  Just to be sure, I created the log file and changed ownership to
apache:apache.  Tried again, and again no log entry was made, although now
errors appeared in the html output.

Am I missing something, or should logging errors be as simple as setting these
two lines in /etc/php.ini?

log_errors = on
error_log = /var/log/httpd/php_errors
Comment 1 Joe Orton 2002-11-04 07:00:13 EST
Since the directory /var/log/httpd is only read&writable by root, PHP will not
be able to open a log file at /var/log/httpd/php_log.

There are a few things which changed in the PHP configuration in 8.0;
register_globals is now off by default, as is short_open_tag, maybe one of these
affects your script too.
Comment 2 Carl T. Miller 2002-11-05 18:30:16 EST
Actually I had already turned on short_open_tag and the register_globals didn't
make any difference.  As I said, the script ran perfectly after I changed the
logging option.  Maybe I should set the logging option back to the original
setting and see what happens.

Thanks for pointing out permissions on /var/log/httpd.  I'll see if changing the
permissions makes any difference.
Comment 3 Joe Orton 2002-11-29 05:22:10 EST
Did you work out what the problem was here?
Comment 4 Joe Orton 2005-02-03 07:06:27 EST
Thanks for the report.  This is a mass bug update; since this release
of Red Hat Linux is no longer supported, please either:

a) try and reproduce the bug with a supported version of Red Hat
Enterprise Linux or Fedora Core, and re-open this bug as appropriate
after changing the Product field, or,

b) if relevant, try and reproduce this bug using the current version
of the upstream package, and report the bug upstream.

c) report the bug to the Fedora Legacy project who may wish to
continue maintenance of this package.

Note You need to log in before you can comment on or make changes to this bug.