Skip to content
Advertisement

Estimate Core capacity required based on load?

I have quad core ubuntu system. say If I see the load average as 60 in last 15 mins during peak time. Load average goes to 150 as well. This loads happens generally only during peak time. Basically I want to know if there is any standard formula to derive the number of cores ideally required to handle the given load ?

Objective :- If consider the load as 60 then it means 60 task were in queue on an average at any point of time in last 15 mins ? Adding cpu can help me to server the request faster or save system from hang or crashing .

Advertisement

Answer

Linux load average (as printed by uptime or top) includes tasks in I/O wait, so it can have very little to do with CPU time that could potentially be used in parallel.

If all the tasks were purely CPU bound, then yes 150 sustained load average would mean that potentially 150 cores could be useful. (But if it’s not sustained, then it might just be a temporary long queue that wouldn’t get that long if you had better CPU throughput.)

If you’re getting crashes, that’s a huge problem that isn’t explainable by high loads. (Unless it’s from the out-of-memory killer kicking in.)


It might help to use vmstat or dstat to see how much CPU time is spent in user/kernel space when your load avg. is building up, or if it’s probably mostly I/O.

Or of course you probably know what tasks are running on your machine, and whether one single task is I/O bound or CPU bound on an otherwise-idle machine. I/O throughput usually scales a bit positively with queue depth, except on magnetic hard drives when that turns sequential read/write into seek-heavy workloads.

User contributions licensed under: CC BY-SA
8 People found this is helpful
Advertisement