{
  "id": 20964560,
  "title": "Why Running the yes Command Didn't Max Out CPU Usage",
  "url": "https://urgent.news/2026/11/20/why-running-the-yes-command-didnt-max-out-cpu-usage",
  "topic": "tech",
  "section": "Tech",
  "published": "2026-11-20T23:22:57.000Z",
  "source": {
    "name": "Dev.to",
    "slug": "dev-to",
    "url": "https://dev.to/kawasaki031677/why-running-the-yes-command-didnt-max-out-cpu-usage-p92"
  },
  "original_language": "en",
  "account": "The author needed to generate CPU load on a Linux server for testing purposes. They executed the yes command, which continuously outputs \"y\" infinitely, assuming it would max out CPU usage. However, the results were unexpected. When they checked with the top command, they saw that while the yes process was using 100% of one CPU core, overall CPU usage was only around 50%. This was because the yes command operates as a single-threaded process, meaning it can only run on one CPU core at a time. The overall CPU usage was split between the two cores, with one core at 100% and the other at around 50%. To load all CPU cores, multiple processes proportional to the number of CPU cores are needed. The speed of yes doesn't improve with more cores because it's single-threaded. The article emphasizes the importance of understanding the underlying processes to gain insights into how Linux and operating systems function.",
  "summary": "Introduction I needed to generate CPU load on a Linux server for testing purposes. Looking for a quick solution, I executed the yes command like this: yes > /dev/null The yes command continuously outputs \"y\" infinitely. I assumed that \"since it's an infinite loop, CPU usage should reach 100%,\" but when I checked the results, something unexpected happened. Info: The test environment I used was a…",
  "key_points": [
    "Yes command runs infinitely, not maxing CPU usage",
    "Single-threaded process limits to one CPU core",
    "Overall CPU usage split between cores, not full utilization"
  ],
  "editors_take": null,
  "illustration": null,
  "coverage": {
    "outlets": 1,
    "also_reported_by": []
  },
  "ai_generated": true,
  "disclaimer": "Summaries, key points and the editor’s take are written by software from other outlets’ reporting and may contain errors — always check the linked original."
}