Container CPU Limit Configuration
IBM 👶 Easy Docker
Beginner Mode

Start your terminal to use beginner mode.

Scenario:

You have a container named cpu_test running from the image myapp:cpu that performs CPU-intensive computations. When monitoring with docker stats, the container regularly spikes to 150-200% CPU usage, consuming multiple CPU cores and impacting other services on the host.

Task:

Update the container configuration to limit CPU usage so that docker stats shows the cpu_test container consistently using less than 60% CPU during validation; You need to assign 500m CPU for that.

Terminal requires a larger screen

Open this page on a desktop or tablet (≥ 768px) to launch the terminal and practice hands-on.

Linux Terminal Environment

Write and execute your solution in the terminal below.

Sign In

Track

Question Difficulty Company Access
Need more practice in this area? Explore more questions →