# High CPU usage (Ruby)

**URL:** <https://meta.discourse.org/t/high-cpu-usage-ruby/348913>\
**Category:** Product Support\
**Tags:** server-resources\
**Created:** [January 25, 2025, 1:50am UTC](https://meta.discourse.org/t/high-cpu-usage-ruby/348913 "2025-01-25T01:50:40Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![AstonJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/astonj/32/215041_2.png) [@AstonJ](https://meta.discourse.org/u/AstonJ)\
**Post date:** [January 25, 2025, 1:50am UTC](https://meta.discourse.org/t/high-cpu-usage-ruby/348913/1 "2025-01-25T01:50:40Z")

</div>

Pretty frequently seeing high CPU usage and it’s usually around the 85% mark:

 ![Screenshot 2025-01-25 at 00.47.46](https://global.discourse-cdn.com/meta/original/4X/5/8/4/584ab9252a383a29999c640664ea53a1761d6a1b.png)

Was previously showing up as `unicorn.conf.r`:

 ![Screenshot 2025-01-25 at 01.43.52](https://global.discourse-cdn.com/meta/original/4X/6/b/9/6b9c4ac740bd4d6df1d50c9370d324848575dc3b.png)

Could this indicate `UNICORN_WORKERS` being set too high/low?

The server has 64GB RAM (usually shows around 40GB free) and 6 cores, there are 4 Discourse instances on the server each set to `UNICORN_WORKERS: 8`

Any ideas or tips on what’s causing it or what to try? (One of the forums is in read-only mode and doesn’t get much traffic, should it be set to have fewer workers?)

---

_[View the full topic](https://meta.discourse.org/t/high-cpu-usage-ruby/348913)._
