Title: Memory exhausted when processing huge databases
Last modified: November 6, 2020

---

# Memory exhausted when processing huge databases

 *  Resolved [David Marín Carreño](https://wordpress.org/support/users/davefx/)
 * (@davefx)
 * [5 years, 6 months ago](https://wordpress.org/support/topic/memory-exhausted-when-processing-huge-databases/)
 * Hi!
 * We are using your plugin to add 2FA to a few sites with thousands of users. I’ve
   discovered that in the one with the biggest user base, the method currently used
   to carry out batch actions causes memory problems in the server.
 * Also, the options inserted in the wp_options are huge, as the actions are exploded
   into user actions, instead of just using the roles to save them.
 * Could you consider adding the feature of carrying out these batch actions as 
   role-based, instead of user-based? They would take much less time if they are
   executed through database queries (updates/inserts), which is critical in sites
   with lots of users.

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Contributor [robertabela](https://wordpress.org/support/users/robert681/)
 * (@robert681)
 * [5 years, 6 months ago](https://wordpress.org/support/topic/memory-exhausted-when-processing-huge-databases/#post-13638630)
 * Hello [@davefx](https://wordpress.org/support/users/davefx/)
 * Thank you very much for using our plugin and for your detailed feedback.
 * We’ll definitely look into your recommendations and explore alternatives to improve
   the plugin. Can you please [send me an email](https://wordpress.org/support/topic/memory-exhausted-when-processing-huge-databases/robert@wpwhitesecurity.com?output_format=md)
   so we can exchange more details?
 * We already test our plugins on sites with thousands of users. However, until 
   now we didn’t have too many opportunities to discuss and explore live websites
   with so many users.
 * Looking forward to hearing from you.
 *  Plugin Contributor [robertabela](https://wordpress.org/support/users/robert681/)
 * (@robert681)
 * [5 years, 5 months ago](https://wordpress.org/support/topic/memory-exhausted-when-processing-huge-databases/#post-13758884)
 * Hello [@davefx](https://wordpress.org/support/users/davefx/)
 * We have just released update 1.5.0 which addresses the issues you reported. We
   also have some more performance related updates in the pipeline and they will
   be available in future updates.
 * However, 1.5.0 is already way better than any of the previous versions.
 * Thanks a lot for your valuable feedback.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Memory exhausted when processing huge databases’ is closed to new replies.

 * ![](https://ps.w.org/wp-2fa/assets/icon-256x256.png?rev=2961533)
 * [WP 2FA - Two-factor authentication for WordPress](https://wordpress.org/plugins/wp-2fa/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-2fa/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-2fa/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-2fa/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-2fa/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-2fa/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [robertabela](https://wordpress.org/support/users/robert681/)
 * Last activity: [5 years, 5 months ago](https://wordpress.org/support/topic/memory-exhausted-when-processing-huge-databases/#post-13758884)
 * Status: resolved