Woocommerce: Fatal error: Allowed memory size of 1073741824 bytes exhausted (tried to allocate 20480 bytes) in /wp-includes/wp-db.php on line 2720 - Hack The Tech - Latest News related to Computer and Technology

Hack The Tech - Latest News related to Computer and Technology

Get Daily Latest News related to Computer and Technology and hack the world.

Thursday, September 15, 2022

Woocommerce: Fatal error: Allowed memory size of 1073741824 bytes exhausted (tried to allocate 20480 bytes) in /wp-includes/wp-db.php on line 2720

I am getting this error when trying to do simple tasks - like updating one product'gallery in Wooocommerce. I have increased memory limits in wp-config.php:

define( 'WP_MEMORY_LIMIT', '1024M' );
define( 'WP_MAX_MEMORY_LIMIT', '1024M' );
@ini_set( 'upload_max_size' , '1024M' );
@ini_set( 'post_max_size', '1024M');
@ini_set( 'memory_limit', '1024M' );

The host doesn't allow higher number than that, which is completely reasonable to me.

I also checked the database, It had a lot of woocommerce sessions and old logs there, and I got it from 1.7GB to 0.9GB.

The issue still remains. Any ideas what else I could do? Is something occupying memory? Because 1024MB seems more than plenty for a normal Woocommerce site.



source https://stackoverflow.com/questions/73703369/woocommerce-fatal-error-allowed-memory-size-of-1073741824-bytes-exhausted-tri

No comments:

Post a Comment