6.0.0-alpha12
6/12/25

[#12654] Infinite loop if logfile not writable
Summary Infinite loop if logfile not writable
Queue Horde Base
Queue Version 5.1.4
Type Bug
State Not A Bug
Priority 1. Low
Owners
Requester stefan (at) 404-net (dot) de
Created 09/03/2013 (4300 days ago)
Due
Updated 01/23/2014 (4158 days ago)
Assigned 09/09/2013 (4294 days ago)
Resolved 01/23/2014 (4158 days ago)
Github Issue Link
Github Pull Request
Milestone
Patch No

History
01/23/2014 06:58:03 PM Michael Rubinsky State ⇒ Not A Bug
 
09/09/2013 10:43:45 AM stefan (at) 404-net (dot) de Comment #3 Reply to this comment
The memory exhaust is triggered within seconds after login. I raised 
the php limit from
128M up to 2G and problem stays the same - couldn't think of an object 
used by Horde big enough to use that much memory. (Yes, there are huge 
mailboxes and calendars, but at the moment the error is triggered, 
there's no reasen fot them to be in use)
That's why I thought of a loop trying to write errors to the log file 
and calling the handler again when it fails. Didn't take a closer look 
to the source file yet.

With some syncing process over day the overall apache memory used by 
Horde increments up to some GB.. After fixing the permissions problem 
the exhaust errors are gone (with standard 128M limit) and the memory 
usage stays low. The horde log just shows login notes and sometimes a 
minor unauthorized-errors, no significant problems.


Sure it's caused by misconfiguration, so basically administrator's fault...
09/09/2013 09:48:43 AM Jan Schneider Comment #2
State ⇒ Feedback
Reply to this comment
What makes you think there is an infinite loop? That error can easily 
be triggered with a big backtrace including some big objects. It would 
only affect admins though.
09/03/2013 06:51:56 PM stefan (at) 404-net (dot) de Comment #1
Priority ⇒ 1. Low
Patch ⇒ No
Milestone ⇒
Queue ⇒ Horde Base
Summary ⇒ Infinite loop if logfile not writable
Type ⇒ Bug
State ⇒ Unconfirmed
Reply to this comment
If the logfile (e.g. /var/log/horde/horde.log) is not writable due to 
file permissions or open_basedir restrictions, the ErrorHandler seems 
to create an infinite loop until memory is exhausted. This leads to 
huge server load depending on apache config.

Error message in apache's error.log:
"PHP Fatal error:  Allowed memory size of ... bytes exhausted (tried 
to allocate 83107841 bytes) in /usr/share/php/Horde/ErrorHandler.php 
on line 111"


I think it's not a new issue, I just discovered it in v5.1.3 when I 
ported my installation to a different server and forgot about the 
permissions.

Saved Queries