Title: CPU usage a bit high
Last modified: October 8, 2024

---

# CPU usage a bit high

 *  Resolved [rensm](https://wordpress.org/support/users/rensm/)
 * (@rensm)
 * [1 year, 8 months ago](https://wordpress.org/support/topic/cpu-usage-a-bit-high/)
 * Hi!
   I’ve migrated a webshop, that is having 2.3GB size of data in mysql. Added
   Redis Object cache and opcache and using this plug-in. But the CPU usage is quite
   a lot (90-100% of the 4 cores). I’ve uploaded a monitor under ID “DQT4mzYb”.Can
   someone have a look if one might see improvements on my end? buffer pool is set
   to 5GB, which uses 3GB currently. It’s a server with 4 vCPU cores and 16GB memory,
   Hosted at DigitalOcean.
    -  This topic was modified 1 year, 8 months ago by [rensm](https://wordpress.org/support/users/rensm/).
    -  This topic was modified 1 year, 8 months ago by [rensm](https://wordpress.org/support/users/rensm/).

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

 *  Plugin Author [OllieJones](https://wordpress.org/support/users/olliejones/)
 * (@olliejones)
 * [1 year, 8 months ago](https://wordpress.org/support/topic/cpu-usage-a-bit-high/#post-18064190)
 * Thanks for the upload. I took a look. I don’t see anything in particular amiss.
   As is very common in WPML sites,. that localization software is database intensive.
 * Your MySQL 8.0.39 server is **very **busy. 278 connections per second and 37K
   queries **per second** were handled in the 15 min of your monitor. (Assuming 
   that workload is legitimate and not some silly runaway reporting process or something)
   it looks to me like your CPU usage is high because you’re doing useful work with
   it.
 * Did it go up a lot after you added the high performance keys? If so, please let
   me know.
 * A quick tip for you. The ubuntu apt package for redis, as installed, puts no 
   limit on its RAM growth. I’ve had users where that default redis started hogging
   RAM and destabilizing MySQL (bad. bad.). You may want to put a couple of lines
   in /etc/redis/redis.conf . I use these settings on my 16GiB RAM development VM.
   You may want to allocate a smaller amount in maxmemory.
 *     ```wp-block-code
       maxmemory 256mb maxmemory-policy allkeys-lfu
       ```
   
 *  Thread Starter [rensm](https://wordpress.org/support/users/rensm/)
 * (@rensm)
 * [1 year, 8 months ago](https://wordpress.org/support/topic/cpu-usage-a-bit-high/#post-18064234)
 * hi! Thanks for the tip.
 * glad i’m not making any mistakes but it’s WPML… i’ve decided to switch over to
   multistore, where everything is seperated. Hopefully that will work!
 * perhaps do you know, could the connections be bots? Or a plug-in that is constant
   connecting to database?
 *  Plugin Author [OllieJones](https://wordpress.org/support/users/olliejones/)
 * (@olliejones)
 * [1 year, 8 months ago](https://wordpress.org/support/topic/cpu-usage-a-bit-high/#post-18066126)
 * I really don’t want to guess about where the connections are coming from. I have
   so little information you’d be better off with a Ouija board guess. If your site
   is busy, it’s possible all the database traffic is actual work for your audience
   and customers.
 * If I were investigating it, I would start by logging in to MySQL as “root” and
   giving this SQL command;
 *     ```wp-block-code
       https://dev.mysql.com/doc/refman/8.0/en/show-processlist.html
       ```
   
 * “Process” here means “connection”, close as makes no difference. I would eyeball
   the processes and try to figure out some kind of pattern. Let me know if I can
   help further.

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

The topic ‘CPU usage a bit high’ is closed to new replies.

 * ![](https://ps.w.org/index-wp-mysql-for-speed/assets/icon-128x128.png?rev=2652667)
 * [Index WP MySQL For Speed](https://wordpress.org/plugins/index-wp-mysql-for-speed/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/index-wp-mysql-for-speed/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/index-wp-mysql-for-speed/)
 * [Active Topics](https://wordpress.org/support/plugin/index-wp-mysql-for-speed/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/index-wp-mysql-for-speed/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/index-wp-mysql-for-speed/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [OllieJones](https://wordpress.org/support/users/olliejones/)
 * Last activity: [1 year, 8 months ago](https://wordpress.org/support/topic/cpu-usage-a-bit-high/#post-18066126)
 * Status: resolved