2

CPU usage on our metrics box is at 100% intermittently causing:
'Internal server error' when rendering Grafana dashboards

The only application running on our machine is Docker with 3 subcontainers

  • cadvisor
  • graphite

  • grafana

Machine spec
OS Version Ubuntu 16.04 LTS
Release 16.04 (xenial)
Kernel Version 4.4.0-103-generic
Docker Version 17.09.0-ce
CPU 4 cores
Memory 4096 MB
Memory reservation is unlimited
Network adapter mgnt

Storage
Driver overlay2
Backing Filesystem extfs
Supports d_type true
Native Overlay Diff true

Memory swap limit is 2.00GB

Here is a snippet from cAdvisor:

enter image description here

The kworker and ksoftirqd processes change status constently from 'D' to 'R' to 'S'

Are the machine specs correct for this setup?
How can I get the CPU usage to 'normal' levels?

mohan08p
  • 5,002
  • 1
  • 28
  • 36
gpullen
  • 1,093
  • 2
  • 14
  • 28
  • 1
    Questions on professional server- or networking-related infrastructure administration are off-topic for Stack Overflow. SO is for programming-related topics. You may be able to get help on Server Fault. – tambre Feb 02 '18 at 11:38

1 Answers1

0

By default, a Docker container (just like any process on host) has access to all memory and cpu resources of the machine.

Docker provides options to limit the container resource consumption. You check the following doc dedicated to Limiting a container's resources.

yamenk
  • 46,736
  • 10
  • 93
  • 87