• Resolved johnny538

    (@johnny538)


    Like the title says. I use Flatsome theme, and when I have AO active and put the site in maintenance mode (built-in feature of Flatsome), the backend becomes superslow and AO reaches the pm.max_children setting of the PHP process.

    apache error logs:

    
    "GET /?ao_speedup_cachebuster=34542 HTTP/1.1" 503 11493 "https://domain.nl/?ao_speedup_cachebuster=34542" "WordPress/5.0.2; https://domain.nl"
    

    php-fpm logs:

    
    WARNING: [pool www] server reached pm.max_children setting (5), consider raising it
    NOTICE: [pool www] child 20097 exited with code 0 after 164.715680 seconds from start
    NOTICE: [pool www] child 20330 started
    

    ^ these appear immediately after enabling maintenance mode.

    Maintenance mode puts a splash screen on the frontend for non-admins and returns a 503 too. Some stuff gets through like popups and cookie notices. But the page content is empty aside from a maintenance notice and logo.

    I disabled the feature to serve optimized files for logged in users. So I assume AO is getting stuck in a loop when non-admin view the maintenance page. (like me when I tested maintenance mode in incognito mode)

    • This topic was modified 5 years, 11 months ago by johnny538.
Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Optimizing Matters

    (@optimizingmatters)

    this is probably because that maintenance mode is trying to purge page caches, which in turn activates AO’s cache purge which calls the cache preloading feature of AO.

    so is that page cache purging something that can be turned of in flatsome one way or another?

    frank

    Thread Starter johnny538

    (@johnny538)

    Not that I can see. It’s just a maintenance mode feature. You can switch it on and off and define a logo and message. That’s it. There’s no option to purge anything or not.

    It’s not a big deal. I can just deactivate AO while I use maintenance mode.

    BTW, have you done any tests with AO regarding server reboots ? In the past I’ve often restarted Apache & php-fpm without any issues. But today I had to reboot the server (first time in ~6 months) and I was having issues. The /wp-content/cache/autoptimize/ dir was empty, and while the AO plugin was active it was causing severe lag. When I finally found out it was AO, deactivating > reactivating the plugin fixed it again.

    On a related note, I also had to remove object-cache.php (I use Redis Object Caching), because I also was stuck in a wordpress db update loop.

    It’s all good now, but I just wanted to mention it. Maybe it’s just me but otherwise it could be worth testing.

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    thanks for the extensive feedback! object-cache.php is not part of AO though ??

    re cachebuster; I just committed (transient-based) “protection” to AO to avoid the cache-warming is done more then every 10 minutes to AO’s Github repo. I you want to you can download the beta here and install instead of 2.4.4 ??

    Thread Starter johnny538

    (@johnny538)

    Thanks for the quick fix. I finally have my site running smooth again so I’d rather not mess with the code for now. I’ll wait for the offical update and test it again.

    The object-cache.php file is from the Redis Object Cache plugin. I know it’s not part of AO. I was just saying it caused issues after rebooting the server and I had to flush the redis DB in the CLI. And there were some issue with AO too after the reboot. The /wp-content/cache/autooptimize/ dir was empty and made the CMS unstable. Disabling and re-enabling the plugin fixed it.

    I thought maybe if you have the time you could check how AO acts between reboots. It could be just me so it’s a low priority request.

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    there were some issue with AO too after the reboot. The /wp-content/cache/autooptimize/ dir was empty

    AO itself never removes files from cache, so I suppose you purged the cache or otherwise clean out the folder before rebooting?

    and made the CMS unstable.

    and were there any relevant errors in the php-errorlog?

    I thought maybe if you have the time you could check how AO acts between reboots.

    Although I have not done specific tests, I do have (obviously) gone through numerous reboots on both my production servers and my local development environments over the years without any issues. that would make sense, as ao as such doesn’t know or specifically care about reboots really; if it is active it will grab HTML from the output buffer, extract, minify, cache and re-inject CSS/ JS.

    based on the info you provided I think this was more a one-off kind of a situation which is not directly linked to AO somehow, although relevant errors from the PHP-errorlog might make me change my mind ??

    Thread Starter johnny538

    (@johnny538)

    I didn’t save the logs from that moment unfortunately. I do recall them mentioning trying to access a specific file or dir in /wp-content/cache/autoptimize/ which was empty at the time.

    I too am going to assume it was just a one-off situation. If it happens again, I’ll gather the logs and let you know.

    Thanks for the support.

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    Thanks for the support.

    you’re welcome Johnny, feel free to leave a review of the plugin and support here! ??

    have a nice weekend!
    frank

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘cachebuser flood when maintenance mode is active’ is closed to new replies.