#100804Sorting pages: Allowed memory size exhausted
Description
I just tried to sort about 160 pages in the backend (Page tree > context menu > sort subpages) and got a fatal error:
"Allowed memory size of 268435456 bytes exhausted (tried to allocate 20480 bytes) in /var/html/t3xxx/web/typo3/sysext/core/Classes/Utility/ArrayUtility.php on line 201"
Unfortunately there is no error stack trace, as the script just exits.
Some of the page titles are quite long (150+ characters, with URLs sometimes over 200 characters long). But apparently 256M – as recommended by TYPO3 11 – isn’t enough, or is there a possible memory leak? Sorting with a php_memory_limit of 512M works, though…
I’ve also tried to sort by the other options. Only sorting by crdate was possible (but not reversed sorting). Interestingly, sorting by tstamp was unsuccessful, even if it’s the same type as crdate.
I have attached a file containing the pages I wanted to sort by page title. Most of them are sorted already, but the editors inserted some pages at the top which should be moved further down the list.
The only other active extension I could think of that maybe has an influence on this is the sluggi extension. But even after uninstalling it the error still occurs.
TYPO3 version is 11.5.26.
Reviews 0
No change resolves or names this issue in its commit message, and no comment links one.
Files 1
History 10
-
Florian Seirer commented <span data-processor="relativetime" data-value="2023-05-04T08:04:23+00:00" > 05/04/23, 08:04 </span>
-
Oliver Hader commented <span data-processor="relativetime" data-value="2023-05-04T08:56:41+00:00" > 05/04/23, 08:56 </span>
Can you please update the CSV to include the
pidvalue? This way nesting depth could be spotted easier. Besides that, are you using workspaces? -
Florian Seirer commented <span data-processor="relativetime" data-value="2023-05-04T08:59:40+00:00" > 05/04/23, 08:59 </span>
Sure. Would an export with the impexp extension (pages table only) be even more useful?
And we don’t use workspaces.
-
Christian Kuhn commented <span data-processor="relativetime" data-value="2023-05-04T09:04:51+00:00" > 05/04/23, 09:04 </span>
General note here: We may want to compare v11 and v12 first: I had a memory optimization with #100701, this may be related. For easy and quick first measurements, extension https://github.com/lolli42/peak_memory might become handy.
-
Florian Seirer changed
pages_040523-0928.csv<span data-processor="relativetime" data-value="2023-05-04T09:13:18+00:00" > 05/04/23, 09:13 </span> -
Florian Seirer changed attached pages_040523-1112.csv <span data-processor="relativetime" data-value="2023-05-04T09:13:54+00:00" > 05/04/23, 09:13 </span>
-
Oliver Hader commented <span data-processor="relativetime" data-value="2023-05-04T09:41:00+00:00" > 05/04/23, 09:41 </span>
Since
\TYPO3\CMS\Backend\Controller\Page\SortSubPagesControlleris invokingDataHandlerfor those 160 pages, my guess is, that memory is exhausted there.
@SortSubPagesController@ reorders the pages by first sorting the collection (e.g. by title) and then re-adds it in reverse order to the top of the corresponding parent page – basically it’s a “move command to the same page”, howeverDataHandlerstill processes all fields of eachsys_pagesrecord, to determine possible reference updates and to move along all localizations.(besides workspaces, having lots of actually localized pages and content on these pages might be another indicator – I forgot to mention that earlier)
-
Riccardo De Contardi changed category <span data-processor="relativetime" data-value="2023-08-09T14:52:21+00:00" > 08/09/23, 14:52 </span>
-
Benni Mack commented and changed status
NewNeeds Feedback <span data-processor="relativetime" data-value="2025-03-23T19:21:18+00:00" > 03/23/25, 19:21 </span>Please check again with latest v13 changes. We’ve drastically reduced the DB and memory load (thanks to @lolli ) in v13.4.8, so please go ahead and report if this is still an issue.
-
Benni Mack commented and changed status
Needs FeedbackClosed <span data-processor="relativetime" data-value="2026-10-24T07:15:51+00:00" > 10/24/26, 07:15 </span>CLosing this now due to lack of feedback, I think it is a non-issue now.
Most pages have two or three subpages. Indexed_search is not installed (we use solr).