#18447 [Fbk->Bgs]: Error-Log File is overwritten for every new Error

From: Date: Wed, 11 Sep 2002 16:44:26 +0000
Subject: #18447 [Fbk->Bgs]: Error-Log File is overwritten for every new Error
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-19151@lists.php.net to get a copy of this message
ID: 18447 Updated by: sniper@php.net Reported By: akorthaus@web.de -Status: Feedback +Status: Bogus Bug Type: Unknown/Other Function Operating System: Linux PHP Version: 4.1.2 New Comment: Thank you for taking the time to report a problem with PHP. Unfortunately you are not using a current version of PHP -- the problem might already be fixed. Please download a new PHP version from http://www.php.net/downloads.php If you are able to reproduce the bug with one of the latest versions of PHP, please change the PHP version on this bug report to the version you tested and change the status back to "Open". Again, thank you for your continued support of PHP. Previous Comments: ------------------------------------------------------------------------ [2002-07-20 20:57:49] sniper@php.net No other idea but is is the log file writable by anyone? (And do try 4.2.1, I still can't reproduce this..) ------------------------------------------------------------------------ [2002-07-20 17:05:16] akorthaus@web.de OK, you´re right, the Problem is more difficult. It only doesn´t work with logging Errors, if I try to start a PHP-Script form SHELL, this way: I´ve got the following lines into my ~/.bashrc PATH="$PATH":"$HOME"/bin export PATH In "/bin" I´ve got my important scripts I often use, so I can start a script in "bin/file.php" from every directory only by writing "file.php". But - if I start a script this way, no errors are logged, if I´m in "/temp/logs" I can use "file.php", than no errors are logged, but if I write ../../bin/file.php logging works perfectly! Do you have an idea why this happens? ------------------------------------------------------------------------ [2002-07-20 12:33:59] sniper@php.net I can not reproduce this with PHP 4.2.1. (CGI) Make that filename for the log to be absolute, e.g.: error_log=/tmp/php-log.txt ------------------------------------------------------------------------ [2002-07-20 04:52:00] akorthaus@web.de Hi! I´ve run php as CGI-Version with Apache. Because I don´t want errors to be shown on the website, I changed the following values of php.ini: display_errors = Off // so no Errors are displayd anymore log_errors = On // Errors should be logged error_log = log.txt // into this file It works fine, but there is only the last error in this log-file, old errors are overwritten. I think error-logs should log ALL errors. If I try from SHELL: php script.php 2>>log.txt it works, but I can´t open all my PHP-Scripts from SHELL and I don´t want to use 2>> every time ;-) rgds Andreas Korthaus ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=18447&edit=1

« previous php.bugs (#19151) next »