I have a course which the teacher has been looking to get logs from. It has about 30,000 log entries.
When he goes to download logs for all days into a CSV, XLS, etc. he gets a blank page. It turns out that this is because the script is exceeding the PHP memory limit. The memory limit is set at 96MB which is pretty large. More than 27700 records causes this report to fail. If I up the PHP memory limit to 128MB I can get the full list.
While I don't get a log report, I can look at htop, sorted by memory and see a transient apache process go up to above 1% of memory which seems to be it, 1% of memory is about 80MB.
What's odd is that when you get the full report, it's only 2.3MB on disk. I can appreciate that the objects could be somewhat larger in RAM, but there surely must be something wrong if it's exceeding 96MB.
Is the object being copied around the place ad nauseum. Might a bit of pass by reference help here?