Skip to content

--cpus limitation does not work correctly with some containers on Windows Docker #32014

@georgyturevich

Description

@georgyturevich

Hello there,

I saw in docker stats that we have containers which were consuming ~ 15-20% CPU

docker stats --no-stream
CONTAINER           CPU %               PRIV WORKING SET    NET I/O             BLOCK I/O
...
2c94b939486c        16.25%              23.63 GiB           3.15 GB / 80.1 MB   48.8 MB / 637 MB
8fc83caae394        14.62%              23.48 GiB           1.67 GB / 40.7 MB   47.5 MB / 353 MB
156d442d7f4e        17.24%              23.41 GiB           3.35 GB / 127 MB    47.9 MB / 682 MB

And all of them have CPU limitatiion "--cpus 0.3"

docker inspect --format "{{.HostConfig.NanoCpus}}" 2c94b939486c 8fc83caae394 156d442d7f4e
3e+08
3e+08
3e+08

docker info shows 64 CPUs so 15-120% is quite enormous value for the "--cpus 0.3"

All our containers are runing with this --cpus limitation and usually they are not consuming more then 2% of CPU. The main difference of that containers that they perform aggressive calculation with a lot of Memory consumption up to 100 GiB. May be it make sense.

What information I can also collect for farther investigation?

Thanks!

Output of docker version:

Client:
 Version:      1.13.0
 API version:  1.25
 Go version:   go1.7.3
 Git commit:   49bf474
 Built:        Tue Jan 17 21:19:34 2017
 OS/Arch:      windows/amd64

Server:
 Version:      1.13.1-cs1
 API version:  1.26 (minimum version 1.24)
 Go version:   go1.7.5
 Git commit:   8709b81
 Built:        Thu Feb  9 02:05:36 2017
 OS/Arch:      windows/amd64
 Experimental: false

Output of docker info:

Containers: 292
 Running: 110
 Paused: 0
 Stopped: 182
Images: 2816
Server Version: 1.13.1-cs1
Storage Driver: windowsfilter
 Windows:
Logging Driver: json-file
Plugins:
 Volume: local
 Network: l2bridge l2tunnel nat null overlay transparent
Swarm: inactive
Default Isolation: process
Kernel Version: 10.0 14393 (14393.693.amd64fre.rs1_release.161220-1747)
Operating System: Windows Server 2016 Datacenter
OSType: windows
Architecture: x86_64
CPUs: 64
Total Memory: 1.906 TiB
Name: ... skiped ...
ID: ... skiped ...
Docker Root Dir: E:\docker_storage_1_13
Debug Mode (client): false
Debug Mode (server): true
 File Descriptors: -1
 Goroutines: 963
 System Time: 2017-03-22T14:06:35.2023919Z
 EventsListeners: 1
Registry: https://index.docker.io/v1/
Experimental: false
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false

Additional environment details (AWS, VirtualBox, physical, etc.):
It is x1.x32large EC2 instance on Dedicated host.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions