PHP Fatal error: Allowed memory size of 536870912 bytes exhausted
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 1k
- Forks
- 348
- Avg merge
- 12h 28m
- Merged PRs (30d)
- 91
Description
Steps to reproduce
after installed lasted version of Nextcloud 25.0
https://github.com/linuxserver docker-nextcloud
Having error in log for Mail :

Expected behavior
No error in log
Actual behavior
All working but having error in log on starting nextcloud
or enabling the mail app after disabling on working nextcloud
Mail app version
lasted
Mailserver or service
Gmail
Operating system
No response
PHP engine version
PHP 8.0
Web server
No response
Database
MariaDB
Additional info
22.10.2022 8:36:17
PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 20480 bytes) in /config/www/nextcloud/apps/mail/vendor/bytestream/horde-mail/lib/Horde/Mail/Rfc822/List.php on line 430
22.10.2022 8:36:17
PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 528384 bytes) in /config/www/nextcloud/apps/mail/lib/Cache/Cache.php on line 127
22.10.2022 8:41:03
PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 20480 bytes) in /config/www/nextcloud/apps/mail/vendor/bytestream/horde-support/lib/Horde/Support/CaseInsensitiveArray.php on line 79
22.10.2022 8:41:04
PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 40960 bytes) in /config/www/nextcloud/apps/mail/vendor/bytestream/horde-imap-client/lib/Horde/Imap/Client/Fetch/Results.php on line 90
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Begin by reproducing the memory exhaustion during Nextcloud startup or Mail app enablement, then inspect the stack-trace locations in apps/mail/lib/Cache/Cache.php and the listed vendor Horde files. Check whether the failure is specific to the Gmail setup and Mail app version described. Done means the reported fatal memory errors no longer occur in the reproduced flow.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- backend, performance
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100