Extremely High CPU usage in idle cluster


I’m experiencing high CPU usage in an almost idle cluster, version 20.1.4:

This is one of the servers:

As you can see, they are super beefy.

And finally, there is not much going on the server:

We are running them like this, using Docker:

docker run -d -p 26257:26257 -p 8085:8080 -v /var/cockroach-data:/cockroach/cockroach-data -v /var/datomia/certs:/etc/ssl/private --name cockroach cockroachdb/cockroach:v20.1.6 start --insecure --advertise-addr= --join=,,,,,,,, --locality=region=cdmx,zone=cdmx1

Upgrading to 20.1.6 did not seem to help at all.

Hi Luis,

You could try taking a CPU profile (https://wiki.crdb.io/wiki/spaces/CRDB/pages/73203940/Profiling+CockroachDB) during one of the high CPU events, that can help figure out what is going on. Other than that, try looking at the logs and other timeseries metrics to see if you can correlate the CPU spikes with any other spikes - often that can help triangulate what is going on.



I manage to find the conflicting query, is this one:


It is weird, since it worked just fine at 2.1.4, but had to upgrade due to another issue to 2.1.6.