• Resolved BigEfromDaBx

    (@bigefromdabx)


    When i click the empty cache button its hanging my site. I had to disable the plugin because it was giving me other problems as well. As soon as I did everything started working properly. Its weird because it just started today.

    below is my log file.

    [09-Jun-2022 23:30:47 UTC] PHP Fatal error: Out of memory (allocated 104857600) (tried to allocate 405504 bytes) in /bitnami/wordpress/wp-content/plugins/w3-total-cache/Cache_File.php on line 186
    [09-Jun-2022 23:30:47 UTC] PHP Fatal error: Out of memory (allocated 111149056) (tried to allocate 32768 bytes) in /bitnami/wordpress/wp-content/themes/Divi/epanel/custom_functions.php on line 1158
    [09-Jun-2022 23:30:47 UTC] PHP Fatal error: Out of memory (allocated 106954752) (tried to allocate 32768 bytes) in /bitnami/wordpress/wp-content/plugins/woocommerce/includes/wc-template-functions.php on line 3333
    [09-Jun-2022 23:30:48 UTC] PHP Fatal error: Out of memory (allocated 106954752) (tried to allocate 32768 bytes) in /bitnami/wordpress/wp-content/plugins/jetpack/jetpack_vendor/automattic/jetpack-backup/src/class-package-version.php on line 1
    [09-Jun-2022 23:30:48 UTC] PHP Fatal error: Out of memory (allocated 111149056) (tried to allocate 32768 bytes) in /bitnami/wordpress/wp-content/plugins/jetpack/jetpack_vendor/automattic/jetpack-backup/src/class-package-version.php on line 1
    [09-Jun-2022 23:41:13 UTC] PHP Warning: mysqli_real_connect(): (HY000/2002): Connection refused in /opt/bitnami/wordpress/wp-includes/wp-db.php on line 1753
    [09-Jun-2022 23:48:45 UTC] The Automattic\WooCommerce\Admin\API\Options::get_options function is deprecated since version 3.1.
    [09-Jun-2022 23:48:45 UTC] The Automattic\WooCommerce\Admin\API\Options::get_options function is deprecated since version 3.1.
    [09-Jun-2022 23:48:53 UTC] The Automattic\WooCommerce\Admin\API\Options::get_options function is deprecated since version 3.1.
    [09-Jun-2022 23:48:53 UTC] The Automattic\WooCommerce\Admin\API\Options::get_options function is deprecated since version 3.1.
    [09-Jun-2022 23:49:28 UTC] PHP Fatal error: Out of memory (allocated 46137344) (tried to allocate 32768 bytes) in /bitnami/wordpress/wp-content/plugins/updraftplus/class-updraftplus.php on line 4285
    [09-Jun-2022 23:49:28 UTC] PHP Fatal error: Out of memory (allocated 46137344) (tried to allocate 20480 bytes) in /opt/bitnami/wordpress/wp-includes/class-wp-hook.php on line 295`

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Contributor Marko Vasiljevic

    (@vmarko)

    Hello @bigefromdabx

    Thank you for reaching out and I am happy to assist you with this.
    This error means that your memory limit needs to be increased and it’s currently set to 100MB.
    You should try increasing the PHP memory limit:
    edit your php.ini and find memory_limit
    edit to

    memory_limit=256M

    Or if you want to add much more:

    memory_limit=1024M

    and restart apache :

    sudo systemctl restart httpd.service

    I hope this helps!

    Thanks!

    Thread Starter BigEfromDaBx

    (@bigefromdabx)

    Thanks for the quick response. I was able to raise it to 1024M but when I hit empty all caches it would hang and then crash my server. So I went into the wp-content folder and deleted the cache and w3tc-config and then tried emptying the cache again and it did it super fast. No hang. Thanks for your help.

    Plugin Contributor Marko Vasiljevic

    (@vmarko)

    Hello @bigefromdabx

    Thank you for the information and I am glad that the problem is resolved.
    Please make sure you are not caching everything to disk, meaning if DB cache and Object Cache are enabled, either disable those options if caching to disk or use memory-based Caching like Redis or Memcached to avoid potential problems like this.
    Thanks!

    Thread Starter BigEfromDaBx

    (@bigefromdabx)

    Im a little confused. Right now I have page cache set to disk:basic and database cache set to disk. Are you saying I should set the database cache to memchached or set page cache to memcached?

    Thanks

    Thread Starter BigEfromDaBx

    (@bigefromdabx)

    I got another error this morning even though my memory_limit=2048M

    [11-Jun-2022 11:09:57 UTC] PHP Fatal error:  Out of memory (allocated 16777216) (tried to allocate 20480 bytes) in /opt/bitnami/wordpress/wp-includes/functions.php on line 651
    [11-Jun-2022 11:09:57 UTC] PHP Fatal error:  Out of memory (allocated 16777216) (tried to allocate 20480 bytes) in /opt/bitnami/wordpress/wp-includes/class-wp-hook.php on line 300
    [11-Jun-2022 11:09:57 UTC] PHP Fatal error:  Out of memory (allocated 16777216) (tried to allocate 20480 bytes) in /bitnami/wordpress/wp-content/plugins/w3-total-cache/PgCache_ContentGrabber.php on line 1348
    Plugin Contributor Marko Vasiljevic

    (@vmarko)

    Hello @bigefromdabx

    Thank you for your feedback.
    Yes, I am referring to Database Cache and Object Cache only, it’s best to use Memory-based caching for those features,
    As for your memory limit error, have you checked with your hosting provider as this is not specifically repeated to W3TC as I can see what may be causing this?
    Can you also check the line 1348 in /wp-content/plugins/w3-total-cache/PgCache_ContentGrabber.php as this should be for a function that Returns an array of response headers
    line 1348 – if ( $headers_list ) {

    Thanks!

    Thread Starter BigEfromDaBx

    (@bigefromdabx)

    Hi Marko,

    Thanks for the quick response. As far as the memory-based caching. Is this a premium option? I think i tried enabling it and it mentioned something about not finding the server 127.0.0.1. I dont remember. Your saying it should do that for both database and page?

    My server is hosted on an amazon lightsail instance. So there is now way of me contacting my hosting provider.

    As far as the line 1348 in /wp-content/plugins/w3-total-cache/PgCache_ContentGrabber.php, click on the link below to view the code.

    https://www.dropbox.com/s/rvwktwh8c5aye5p/Screen%20Shot%202022-06-13%20at%2012.42.45%20PM.jpg?dl=0

    Thanks for all your help.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Empty Cache – Hanging my site’ is closed to new replies.