{"action":"created","issue":{"url":"https://api.github.com/repos/docker/docker/issues/10091","labels_url":"https://api.github.com/repos/docker/docker/issues/10091/labels{/name}","comments_url":"https://api.github.com/repos/docker/docker/issues/10091/comments","events_url":"https://api.github.com/repos/docker/docker/issues/10091/events","html_url":"https://github.com/docker/docker/issues/10091","id":54328352,"number":10091,"title":"docker commit slow on btrfs storage driver","user":{"login":"umatomba","id":1991518,"avatar_url":"https://avatars.githubusercontent.com/u/1991518?v=3","gravatar_id":"","url":"https://api.github.com/users/umatomba","html_url":"https://github.com/umatomba","followers_url":"https://api.github.com/users/umatomba/followers","following_url":"https://api.github.com/users/umatomba/following{/other_user}","gists_url":"https://api.github.com/users/umatomba/gists{/gist_id}","starred_url":"https://api.github.com/users/umatomba/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/umatomba/subscriptions","organizations_url":"https://api.github.com/users/umatomba/orgs","repos_url":"https://api.github.com/users/umatomba/repos","events_url":"https://api.github.com/users/umatomba/events{/privacy}","received_events_url":"https://api.github.com/users/umatomba/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-01-14T14:34:09Z","updated_at":"2015-01-14T14:37:04Z","closed_at":null,"body":"**Description of problem:**\r\nI am using btrfs as a storage driver, because my containers can contain up to 60GB of new data. I thought btrfs, being a copy on write file system, should be able to handle 60GB easy and fast.\r\nIn reality docker needs up to 40 minutes to commit a container with 60GB of new data.\r\n\r\nIn log we see that committing a container with btrfs storage is actually doing some 'Start untar layer' process:\r\n\r\n```\r\n    [debug] server.go:999 Calling POST /commit\r\n    2015/01/13 09:06:39 POST /v1.12/commit?author=&comment=&container=b7b6d2056c71&repo=day13_log&tag=\r\n    [0ace70fe] +job commit(b7b6d2056c71)\r\n    [debug] image.go:90 Start untar layer\r\n    [debug] archive.go:75 [tar autodetect] n: [111 117 116 0 0 0 0 0 0 0]\r\n    [debug] image.go:94 Untar time: 2400.110357412s\r\n    [0ace70fe] -job commit(b7b6d2056c71) = OK (0)\r\n```\r\n\r\n\r\nBut all modifications during container-lifetime happen in the btrfs subvolume already, hence the commit should be as fast as a btrfs snapshot is.\r\n\r\n**How reproducible:**\r\n1. docker run -itd ubuntu:14.04 /bin/bash\r\n2. make big changes on the container\r\n3. docker commit CONTAINER IMAGE_NAME\r\n\r\n`docker version`:\r\nClient version: 1.4.1\r\nClient API version: 1.16\r\nGo version (client): go1.3.3\r\nGit commit (client): 5bc2ff8\r\nOS/Arch (client): linux/amd64\r\nServer version: 1.4.1\r\nServer API version: 1.16\r\nGo version (server): go1.3.3\r\nGit commit (server): 5bc2ff8\r\n\r\n`docker info`:\r\nContainers: 477\r\nImages: 649\r\nStorage Driver: btrfs\r\nExecution Driver: native-0.2\r\nKernel Version: 3.13.0-43-generic\r\nOperating System: Ubuntu 14.04.1 LTS\r\nCPUs: 8\r\nTotal Memory: 31.1 GiB\r\nID: \r\nDebug mode (server): true\r\nDebug mode (client): false\r\nFds: 24\r\nGoroutines: 30\r\nEventsListeners: 0\r\nInit Path: /usr/bin/docker\r\nDocker Root Dir: /docker\r\nWARNING: No swap limit support\r\n\r\n`uname -a`:\r\nLinux lx119-tpo 3.13.0-43-generic #72-Ubuntu SMP Mon Dec 8 19:35:06 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux\r\n\r\n`lsb_release -a`:\r\nNo LSB modules are available.\r\nDistributor ID: Ubuntu\r\nDescription:    Ubuntu 14.04.1 LTS\r\nRelease:        14.04\r\nCodename:       trusty"},"comment":{"url":"https://api.github.com/repos/docker/docker/issues/comments/69924429","html_url":"https://github.com/docker/docker/issues/10091#issuecomment-69924429","issue_url":"https://api.github.com/repos/docker/docker/issues/10091","id":69924429,"user":{"login":"LK4D4","id":101445,"avatar_url":"https://avatars.githubusercontent.com/u/101445?v=3","gravatar_id":"","url":"https://api.github.com/users/LK4D4","html_url":"https://github.com/LK4D4","followers_url":"https://api.github.com/users/LK4D4/followers","following_url":"https://api.github.com/users/LK4D4/following{/other_user}","gists_url":"https://api.github.com/users/LK4D4/gists{/gist_id}","starred_url":"https://api.github.com/users/LK4D4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LK4D4/subscriptions","organizations_url":"https://api.github.com/users/LK4D4/orgs","repos_url":"https://api.github.com/users/LK4D4/repos","events_url":"https://api.github.com/users/LK4D4/events{/privacy}","received_events_url":"https://api.github.com/users/LK4D4/received_events","type":"User","site_admin":false},"created_at":"2015-01-14T14:37:04Z","updated_at":"2015-01-14T14:37:04Z","body":"@umatomba Hello, this probably was fixed in #9720 \r\nPlease try master when you can and report results. Thanks!"}}