Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Slow File I/O on Container VS Host (Docker 1.24, Docker for Mac) #696

Closed
flyandi opened this issue Sep 23, 2016 · 4 comments
Closed

Slow File I/O on Container VS Host (Docker 1.24, Docker for Mac) #696

flyandi opened this issue Sep 23, 2016 · 4 comments

Comments

@flyandi
Copy link

flyandi commented Sep 23, 2016

Description

There seems to be another issue when running docker-compose on Docker for Mac and having a large file base mounted to the container.

Running a large PHP project inside a multi container docker-compose project (Nginx, MySQL, Redis, PHP-FPM - all separate containers running at the same time and connecting via internal backplane).

Running the boot script on the host:

real    0m0.089s
user    0m0.065s
sys 0m0.017s

Running the boot script in the container:

real    0m1.167s
user    0m0.070s
sys 0m0.130s

Describe the results you received:

Container is about 10x slower than host for all File I/O requests.

Describe the results you expected:

Container should the same or almost equal to host file i/o

Output of docker version:

Client:
 Version:      1.12.1
 API version:  1.24
 Go version:   go1.7.1
 Git commit:   6f9534c
 Built:        Thu Sep  8 10:31:18 2016
 OS/Arch:      darwin/amd64

Server:
 Version:      1.12.1
 API version:  1.24
 Go version:   go1.6.3
 Git commit:   23cf638
 Built:        Thu Aug 18 17:52:38 2016
 OS/Arch:      linux/amd64

Output of docker info:

Containers: 5
 Running: 0
 Paused: 0
 Stopped: 5
Images: 70
Server Version: 1.12.1
Storage Driver: aufs
 Root Dir: /var/lib/docker/aufs
 Backing Filesystem: extfs
 Dirs: 96
 Dirperm1 Supported: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge null host overlay
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Security Options: seccomp
Kernel Version: 4.4.20-moby
Operating System: Alpine Linux v3.4
OSType: linux
Architecture: x86_64
CPUs: 5
Total Memory: 3.855 GiB
Name: moby
ID: OORF:UFGL:YOMG:HY4G:SX7M:PCW5:GPDN:XBV7:CVWE:VBNH:4DTH:VKI7
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): true
 File Descriptors: 18
 Goroutines: 30
 System Time: 2016-09-23T17:43:38.899804591Z
 EventsListeners: 1
Registry: https://index.docker.io/v1/
Insecure Registries:
 127.0.0.0/8

Additional environment details (AWS, VirtualBox, physical, etc.):

Using latest Docker For Mac

@geerlingguy
Copy link

I think this is a duplicate of #77 (I'm presuming it's I/O, if the PHP project has any significant number of files (e.g. something like a CMS or a framework like Symfony).

@flyandi
Copy link
Author

flyandi commented Sep 24, 2016

Yeah it's a Lumen project with Doctrine - so lots of lots of files.

@dsheets
Copy link
Contributor

dsheets commented Sep 24, 2016

If this is using bind mounts or compose volumes with host file system paths, this is a duplicate of #77 and I will close this in order to track it over there. If that isn't the issue, please feel free to re-open.

@dsheets dsheets closed this as completed Sep 24, 2016
@docker-robott
Copy link
Collaborator

Closed issues are locked after 30 days of inactivity.
This helps our team focus on active issues.

If you have found a problem that seems similar to this, please open a new issue.

Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows.
/lifecycle locked

@docker docker locked and limited conversation to collaborators Jun 20, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants