WordPress.org

Make WordPress Core

Opened 5 years ago

Last modified 18 months ago

#36470 new defect (bug)

Multisite - network sites list not very memory efficient

Reported by: Bombdogs Owned by:
Milestone: Priority: normal
Severity: normal Version: 4.3
Component: Administration Keywords:
Focuses: Cc:

Description

This recent change in 4.3 to add user counts to multisite network admin sites list can cause out of memory errors on installs with many thousands of users...

https://core.trac.wordpress.org/attachment/ticket/32434/32434.2.patch

On a vanilla WPMU install with 200,000 users (bulk generated by wp-cli) the wp-admin memory footprint for the network admin sites list page can be as low as 32Mb when running WP4.2 - simply upgrading to WP4.3 requires you to increase this to 128Mb (~4x) for this size user base. The memory requirement keeps increasing as the user base increases (unsustainable).

The problem in the code referenced in the patch above is that all users for a blog are selected out of the DB and then a count is done in PHP - this requires more memory than is ideal - selecting just the count will be quicker and more memory efficient.

Change History (0)

Note: See TracTickets for help on using tickets.