Log with PHP Errors for All Accounts?
I just switched all my accounts from running PHP 5.6 to PHP 7.3. I've not detected any issues from the user side (yet). Is there a log I can look at somewhere to find if any accounts' scripts are generating critical E_ERROR level (and E_WARNING would probably be good to see too) for all accounts. Or do I need to examine the PHP error log in all the directories where PHP is being executed from?
-
Trying to answer my own question (LOL) this is the best technique I've come up with. Delete all the error_logs find /home -type f -name error_log -delete Then check to see what error_logs are being written too and then go examine the content find /home -type f -name error_log I'm curious if there is a WHM setting to limit the account PHP error_log sizes to prevent things from potentially getting out of hand (especially during a PHP version upgrade) or are we left to manage these manually? 0 -
Trying to answer my own question (LOL) this is the best technique I've come up with. Delete all the error_logs find /home -type f -name error_log -delete Then check to see what error_logs are being written too and then go examine the content find /home -type f -name error_log
Nice Idea! But, be careful not to delete conf files (I know this is not related).I'm curious if there is a WHM setting to limit the account PHP error_log sizes to prevent things from potentially getting out of hand (especially during a PHP version upgrade) or are we left to manage these manually?
I am not sure, wait until cPanel answers your question.0 -
What I would do, instead of deleting the error log, would be to use WHM's log rotation UI - information on this can be found here:Log Rotation - Version 84 Documentation - cPanel Documentation 0 -
Yes, that's a good feature to use, however right after a system-wide change such as switching to a newer PHP version, it would be more difficult to detect which accounts are generating errors after the change if the error logs are present but only because of past old errors that occurred before the update that were already resolved. If you delete them, then you know which accounts are having issues after the upgrade just by the presence of the error log and you know all the errors in the log occurred after the update. 0 -
Hello !! :) Take a look at the error_log option to set your own logging file too. When the log_errors directive is set to On, any errors reported by PHP would be logged to the server log or the file specified with error_log. You can set these options with 0 -
Hello !! :) Take a look at the error_log option to set your own logging file too. When the log_errors directive is set to On, any errors reported by PHP would be logged to the server log or the file specified with error_log. You can set these options with ini_set too, if you need to. [url=https://appsync.biz/dafont/]Dafont[url=https://showbox.bio/]Showbox[url=https://www.oovoo.onl/adam4adam/]Adam4adam
0
Please sign in to leave a comment.
Comments
6 comments