I’ve had things like that happen recently. Cause was a single “visitor” startig loads of sessions. Which crippled mysql If you’re on 7.4, you should be able to install ce cache (and switch to speedy once you’ve upgraded) But i don’t think it will help, since the sessions get started anyway
The images being uploaded are up to 4MB, I don’t believe they stay that big when JCOGs transforms them. Looking at one now that they uploaded that was 2MB, it’s under 100kB after JCOGs did its magic. THey’re keeping them mostly under 1MB after I advised them. Mostly.
We did recently just block the Amazon bot, it seemed to appear the most in the logs out of all the others. And also blocked one for WeChat.
Oh we did that yesterday with the “we’re under attack” mode on Cloudflare; as far as I know, that blocks all bots & challenges humans to prove they’re not a bot.
Then I blocked the two bots I mentioned, and opened it back up after like six hours. It’s been fine since but my gut feeling is this is just another lull before it happens again. I’ve been chasing this for about a month so far. We even bumped their droplet up to double the RAM just in case that would help (it didn’t).
It is deployment through Ploi, but yeah the dev & main db are on the same box.
BUT! Upgrading everything helped immensely (especially getting both dev/live updated in both respects). I suspect it was a combination of PHP7.4 and EE7.4x, because while the CPU seemed to settle slightly after the PHP bump, it wasn’t until I got EE on the latest version to where the CPU is finally very happy. On TOP when it was PHP7.4, the spikes between PHP/MySQL were frequent. Several times in a ten minute span.
Now though, MySQL’s process isn’t surpassing 30% in normal visits. The client is going to be releasing a newsletter on Wednesday, I’ll be watching to see how it handles the traffic surge as that’s another thing that had caused the site to crumple in the past.
But here’s a screenshot from the DO graph in the hour before, during and after the PHP/EE upgrades (specifically for the production site - dev was already done). The spiking in TOP was never long enough to show up on their “averaging” on the graph, but it kind of shows in the peaks on the before.
/asset/images/dovetail/14e6d4ac819183819635f502c7b43b48.png
Update post newsletter release: The site handled the traffic surge - about 4k visits immediately following the release - perfectly. Beforehand the site would’ve likely gone unreachable again. So, upgrading both PHP & EE in this case appears to have been a solid solution. I’ll of course continue to monitor things as there can always be a rush of bots that could cause issues in the future, but I feel better that I’ve done quite a bit to help mitigate issues. These upgrades also helped the site speed in general, so that’s an added bonus.
Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.