Skip to content

Docker running on high CPU and crashes in the end #21181

@michaelarnauts

Description

@michaelarnauts

Output of docker version:

Client:
 Version:      1.10.3
 API version:  1.22
 Go version:   go1.5.3
 Git commit:   20f81dd
 Built:        Thu Mar 10 15:59:07 2016
 OS/Arch:      linux/amd64

Server:
 Version:      1.10.3
 API version:  1.22
 Go version:   go1.5.3
 Git commit:   20f81dd
 Built:        Thu Mar 10 15:59:07 2016
 OS/Arch:      linux/amd64

Output of docker info:

Containers: 13
 Running: 1
 Paused: 0
 Stopped: 12
Images: 342
Server Version: 1.10.3
Storage Driver: aufs
 Root Dir: /var/lib/docker/aufs
 Backing Filesystem: extfs
 Dirs: 324
 Dirperm1 Supported: true
Execution Driver: native-0.2
Logging Driver: json-file
Plugins: 
 Volume: local
 Network: host bridge null
Kernel Version: 4.2.0-30-generic
Operating System: Ubuntu 15.10
OSType: linux
Architecture: x86_64
CPUs: 8
Total Memory: 7.705 GiB
Name: michael-OptiPlex-9020
ID: CKKO:NBNN:RDYO:QQAK:JFAX:6NA3:DLSP:HTGG:7OFX:RI5Y:U6O7:IAKU
WARNING: No swap limit support

Additional environment details (AWS, VirtualBox, physical, etc.):
Happens with a docker running on a physical machine, but also in a VirtualBox.
CPU of physical machine: Intel(R) Core(TM) i7-4770 CPU @ 3.40GHz

Steps to reproduce the issue:

  1. Build the Dockerfile below
  2. Run it
  3. Observe high CPU usage of the asterisk process, but also of the docker daemon.
  4. Docker daemon will keep on eating CPU and memory, until it crashes

Describe the results you received:

$ ps aux | grep asterisk
root     25881 99.2  0.5 3349604 42808 ?       Rsl  12:15   0:29 asterisk -c
$ ps aux | grep docker
root     25729 77.0  0.8 767488 72268 ?        Ssl  12:15   0:29 /usr/bin/docker daemon -H fd://
$ docker ps
CONTAINER ID        IMAGE               COMMAND             CREATED             STATUS              PORTS               NAMES
6cf222d88133        aa02e2b83b5c        "asterisk -c"       9 minutes ago       Up 9 minutes        80/tcp, 5060/tcp    loving_yalow
$ docker stop loving_yalow
Failed to stop container (loving_yalow): An error occurred trying to connect: Post http://%2Fvar%2Frun%2Fdocker.sock/v1.22/containers/loving_yalow/stop?t=10: net/http: transport closed before response was received

Describe the results you expected:

$ ps aux | grep asterisk
root     25881  0.2  0.5 3349604 42808 ?       Rsl  12:15   0:29 asterisk -c
$ ps aux | grep docker
root     25729  0.1  0.8 767488 72268 ?        Ssl  12:15   0:29 /usr/bin/docker daemon -H fd://

Additional information you deem important (e.g. issue happens only occasionally):

I've already tried removing all files in /var/lib/docker. Also running inside a clean Ubuntu 14.04 VirtualBox gives the same results.

Dockerfile:

FROM ubuntu:14.04
MAINTAINER Michaël Arnauts <[email protected]>

# Install packages
RUN DEBIAN_FRONTEND=noninteractive apt-get update && apt-get -y install \
    asterisk \
    && apt-get clean \
    && rm -rf /var/lib/apt/lists/*

# Expose ports
EXPOSE 5060

CMD ["asterisk", "-c"]

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/loggingkind/bugBugs are bugs. The cause may or may not be known at triage time so debugging may be needed.version/1.10

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions