TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Ask HN: What does it mean to you as DBA if DB is running at 99% CPU utilization?

4 pointsby sirkarthikover 3 years ago

3 comments

LinuxBenderover 3 years ago
If you mean a constant 99% on all cores, then I would agree with what gjvc said. There is no more processing capacity. That said, 99% CPU is not a problem if you are keeping up with the work demand. More important to me is looking at CPU load vs. Run-Queue. If I have high CPU at times, my servers are doing their job. If I have processes waiting for CPU time that is an actual problem. You can of course see this in your DB stats and slow query logs but this is also obvious in the OS.<p><pre><code> vmstat 4 40 </code></pre> Watch the first two columns. r is active processes in the run queue and b is blocked in uninterruptible sleep. r should always be higher than b and if I am a DBA concerned about performance, b should <i>nearly always</i> be 0 or very close to it. If b is higher than 0 then I need to start looking at other columns in vmstat and other commands such as iostat to start to see at a high level where my bottlenecks are. CPU queues can be deceiving because the CPU can be waiting on disk. If you provide more system stats in a pastebin-like site, it would be easier to answer your question.<p>For what it&#x27;s worth, you should also be browsing around on ServerFault [1] For your sanity sake, lurk on that site for some time before asking any questions. Make heavy use of their search and label functions. People can be a little rough if you have not made a best effort to dig into your particular issue first.<p>[1] - <a href="https:&#x2F;&#x2F;serverfault.com&#x2F;" rel="nofollow">https:&#x2F;&#x2F;serverfault.com&#x2F;</a>
gjvcover 3 years ago
you&#x27;ve got no headroom left for load spikes!<p>but this sort of question obscures the reality. are you asking this in the context of a machine which is running slowly? are the clients which are querying the DBMS acting differently? has there recently been a change to the application which might have brought this about? have the marketing department started an advertising campaign without telling you?
markus_zhangover 3 years ago
Hey boss your investment is being fully utilized! Get ready to put down more dough!<p>disclaimer not a dba