I just updated some CiviCRM staging/test sites to 5.57.1 and my log viewer seems to be broken. This is Drupal 7 site

I get something like the following error for all sites:

Unable to read entries from logfile at /var/www/html/mysite/sites/default/files/civicrm/ConfigAndLog/CiviCRM.1_3d2d307c1a3c8afb45487079.log

If I look in the directory ConfigAndLog I can see the file permissions are 644 owner is www-data. The Directory is 664 with www-data as owner.

The log file listed above is not there though, instead I find two active log files:


One appears to be the summary and one the stacktrace.

They are an hour or so old. Their last entries are messages confirming a successful upgrade to 5.57.1... yay.

I have cleared every imaginable cache many times. What is going on here? Is log creation failing? I had to update my SITE_KEY configuration on this upgrade, could that have broken it? Any other suggestions?

1 Answer 1


That error is a bit misleading and usually just means "you have no new messages yet" and I think that's what it means this time. There was a recent change in core to prefix log file names with the domain id, so that's where the 1_ is coming from. The hash is different from the earlier one because you said you cleared cache which will change that hash.

If you want to double-check, just add \Civi::log()->info('hi'); in any civi form file, then visit that page, then check the log. For example, just after line 240 in CRM/Activity/Form/Activity.php add \Civi::log()->info('hi'); (in 5.57.1 it's line 233 but doesn't matter - just somewhere in that function), and then visit Contacts -> New Activity. Then check the log. It should say "hi" in the log.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.