End of script output before headers: index.php

With Matomo 3.6.1, PHP 7.2, MySQL 5.7, the Apache error log is filled with the following error.

End of script output before headers: index.php, referer: https://.../index.php?module=CoreHome&action=index&date=today&period=day&idSite=6&updated=1
End of script output before headers: index.php, referer: https://.../index.php?module=CoreHome&action=index&date=today&period=day&idSite=6&updated=2
End of script output before headers: index.php, referer: https://.../index.php?module=CoreHome&action=index&idSite=1&period=day&date=yesterday

The query arguments vary. But it is always rooted in index.php of the Matomo installation directory.

Also, in dashboard, I always see this so I have to reload the page but at least one widget gives this, not sure if it is related.

Oops… there was a problem during the request. Maybe the server had a temporary issue, or maybe you requested a report with too much data. Please try again. If this error occurs repeatedly please contact your Matomo administrator for assistance. 

The index.php permission is set to 755. In the apcu section of phpinfo() looks like this.

APCu Support Enabled
Version 5.1.11
APCu Debugging Disabled
MMAP Support Enabled
MMAP File Mask no value
Serialization Support php
Build Date Sep 14 2018 11:24:15
Directive Local Value Master Value
apc.coredump_unmap Off Off
apc.enable_cli Off Off
apc.enabled On On
apc.entries_hint 4096 4096
apc.gc_ttl 3600 3600
apc.mmap_file_mask no value no value
apc.preload_path no value no value
apc.serializer php php
apc.shm_segments 1 1
apc.shm_size 32M 32M
apc.slam_defense On On
apc.smart 0 0
apc.ttl 0 0
apc.use_request_time On On
apc.writable /tmp /tmp

Where else should I look for the cause of the error?

I have this problem. I get this error combined with 500 code and mod_fcgid: read data timeout
Update I thought this was a proxy problem but its not. Get error via local network without proxy on http. It is in a sub folde rbut has been like that for 3-4 years without a problem. Only chnage is external ip address ?
Did it get resolved ?

Fixed this by inceasing the fastcgi timeout

1 Like