2

I've read several articles about load average and all explained that the load average is the amount of processes in running/waiting to run state on CPU , so it's actually the CPU's run queue + the processes waiting for I/O . I then saw a blog post about lack of memory being a 3rd reason . Is that correct ?

Turns out that network I/O also affects loadavg

John Doe
  • 475
  • 1
  • 5
  • 12
  • I don't think the memory affected the load average, because if you don't have free memory and your process try to allocate memory, the system starts to swap out the unused memorory or invoke the oom kill, so you never have process block waiting for memory – c4f4t0r May 16 '18 at 15:46
  • You are joking, or? If the kernel is swapping out memory, then this is a LOT slower. If a process requires memory to be swapped in, it will per definition have to wait for this memory, so it will show up as blocked. Swapped out memory is SLOOOOOOOW compared to real memory. REALLY slow. Like thousands times slower. Even on SSD. – TomTom Feb 01 '19 at 09:48

1 Answers1

1

Yes, lack of memory can cause swapping which means processes will stick in the processors queue for much longer and start building up.

I've seen servers go up to hundreds of loadavg because of swapping.