error_log in public_html?
can someone tell me how the error_log in public_html get created and logged? we have a site that is not getting theirs updated.
Thanks
-
Hello @ca2236 This is created by enabling error logging for the PHP version. You can enable it by going to WHM>>Software>>MultiPHP INI Editor -> Editor Mode ; Log errors to specified file. PHP's default behavior is to leave this value ; empty. ; http://php.net/error-log ; Example: ;error_log = php_errors.log ; Log errors to syslog. ;error_log = syslog error_log = error_log
; Log errors to specified file. PHP's default behavior is to leave this value ; empty. ; http://php.net/error-log ; Example: ;error_log = php_errors.log ; Log errors to syslog. ;error_log = syslog error_log = error_log0 -
Thanks, However, I have a follow up question, on sites that do have the error_log working, it doesn't have this in the multiPHP INI Editor. It just is the text version of Basic typically. Is this due to using inherited php settings on multi php manager and it pulls from a global setting? If so.. Why is that working for the local file when the above code doesn't exist? Sorry for asking, just trying to grasp this. 0 -
It's possible this is set locally for those domains, within their respective php.ini, if you're running wordpress you can also enable error logging in the wp-config. 0 -
Ok Thanks, are the respective php.ini files inside of the public_html? I would imagine to be so. also, I know this is outside of cpanel specifically 0 -
Yea, they should be, they can also be in /home/$user but most commonly found in /home/$user/public_html - you'd be looking for any .ini file most commonly there's user.ini, local.ini and php.ini 0 -
Thanks, This might be out of scope of cpanel, it still doesn't appear to log. when pasting ; Log errors to specified file. PHP's default behavior is to leave this value ; empty. ; PHP: Runtime Configuration - Manual ; Example: ;error_log = php_errors.log ; Log errors to syslog. ;error_log = syslog error_log = error_log do I need a full path in error_log = 0 -
Hi @ca2236 What's set for this: error_reporting = E_ALL & ~E_NOTICE
It should be uncommented and appear just as it does above0 -
There was nothing in the php.ini . I had to add everything you posted to me. I can add this and let you know. 0 -
Hi @ca2236 This should also be helpful: How to Display and Log PHP Errors | InMotion Hosting Are you by chance running php-fpm on these domains? If so it's going to be in a different location. Those are located at /home/$user/logs/domain_tld.php.error.log 0 -
We are not. Thanks for all of these links, what is confusing is that the other sites do not have all these specific settings declared in /home//public_html/php.ini or the MultiPHP INI editor. However, it is working. 0 -
Hi @ca2236 There's a multitude of differences that could be present, I am glad it's working now though! Thanks! 0
Please sign in to leave a comment.
Comments
11 comments