{"action":"created","issue":{"url":"https://api.github.com/repos/docker/docker/issues/21626","repository_url":"https://api.github.com/repos/docker/docker","labels_url":"https://api.github.com/repos/docker/docker/issues/21626/labels{/name}","comments_url":"https://api.github.com/repos/docker/docker/issues/21626/comments","events_url":"https://api.github.com/repos/docker/docker/issues/21626/events","html_url":"https://github.com/docker/docker/issues/21626","id":144360983,"number":21626,"title":"Need better handling/error path from tar/untar failures (especially in userns)","user":{"login":"estesp","id":1397980,"avatar_url":"https://avatars.githubusercontent.com/u/1397980?v=3","gravatar_id":"","url":"https://api.github.com/users/estesp","html_url":"https://github.com/estesp","followers_url":"https://api.github.com/users/estesp/followers","following_url":"https://api.github.com/users/estesp/following{/other_user}","gists_url":"https://api.github.com/users/estesp/gists{/gist_id}","starred_url":"https://api.github.com/users/estesp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/estesp/subscriptions","organizations_url":"https://api.github.com/users/estesp/orgs","repos_url":"https://api.github.com/users/estesp/repos","events_url":"https://api.github.com/users/estesp/events{/privacy}","received_events_url":"https://api.github.com/users/estesp/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-03-29T19:16:47Z","updated_at":"2016-03-29T19:16:47Z","closed_at":null,"body":"When using user namespaces, it is more easy to have tar/untar failures due to permissions or ownership issues that affect the remapping code.  Most of these errors are easy to spot in daemon logs, but usually lead to confusing errors on the client-side.\r\n\r\nFor example, if a layer is created which has an ID owner or group outside the remapping range specified for the daemon, the remapping code won't be able to handle what uid/gid to use when writing that file to local cache.  An example of this from a daemon log:\r\n```\r\nERRO[0006] Handler for POST /v1.24/images/load returned error: Untar re-exec error: exit status 1: output: Container ID 208203 cannot be mapped to a host ID\r\n```\r\n\r\nOn the client side, this ends up causing an error in interpreting this error output string as a JSON object and getting something like this:\r\n```\r\n5e868bdcb028: Loading layer [==================================================>] 16.27 MB/16.27 MB\r\n3c35e36d8df2: Loading layer [==================================================>] 23.04 MB/23.04 MB\r\ninvalid character 'U' looking for beginning of value\r\n```\r\n\r\nThese errors need to be correctly brought all the way back to the user so appropriate action can be taken.\r\n\r\n**NOTE**: *The mapping ID out of range issue is only an example and could be seen as a separate issue, which can be temporarily corrected by providing the remapping user a larger range that includes all possible uid/gid values for container images being loaded or pulled from a registry. Some guidance should also be provided to image creators on the default range for an ID space, especially when using distro defaults for `/etc/subuid` and `/etcsubgid` which are always 64K today.*"},"comment":{"url":"https://api.github.com/repos/docker/docker/issues/comments/203059994","html_url":"https://github.com/docker/docker/issues/21626#issuecomment-203059994","issue_url":"https://api.github.com/repos/docker/docker/issues/21626","id":203059994,"user":{"login":"GordonTheTurtle","id":10620046,"avatar_url":"https://avatars.githubusercontent.com/u/10620046?v=3","gravatar_id":"","url":"https://api.github.com/users/GordonTheTurtle","html_url":"https://github.com/GordonTheTurtle","followers_url":"https://api.github.com/users/GordonTheTurtle/followers","following_url":"https://api.github.com/users/GordonTheTurtle/following{/other_user}","gists_url":"https://api.github.com/users/GordonTheTurtle/gists{/gist_id}","starred_url":"https://api.github.com/users/GordonTheTurtle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GordonTheTurtle/subscriptions","organizations_url":"https://api.github.com/users/GordonTheTurtle/orgs","repos_url":"https://api.github.com/users/GordonTheTurtle/repos","events_url":"https://api.github.com/users/GordonTheTurtle/events{/privacy}","received_events_url":"https://api.github.com/users/GordonTheTurtle/received_events","type":"User","site_admin":false},"created_at":"2016-03-29T19:16:47Z","updated_at":"2016-03-29T19:16:47Z","body":"\nIf you are reporting a new issue, make sure that we do not have any duplicates already open. You can ensure this by searching the issue list for this repository. If there is a duplicate, please close your issue and add a comment to the existing issue instead.\n\nIf you suspect your issue is a bug, please edit your issue description to include the BUG REPORT INFORMATION shown below. If you fail to provide this information within 7 days, we cannot debug your issue and will close it. We will, however, reopen it if you later provide the information.\n\nFor more information about reporting issues, see [CONTRIBUTING.md](https://github.com/docker/docker/blob/master/CONTRIBUTING.md#reporting-other-issues).\n\n**You _don't_ have to include this information if this is a _feature request_**\n\n(This is an automated, informational response)\n\n-----------------------------\nBUG REPORT INFORMATION\n-----------------------------\nUse the commands below to provide key information from your environment:\n\n`docker version`:\n`docker info`:\n\nProvide additional environment details (AWS, VirtualBox, physical, etc.):\n\n\n\nList the steps to reproduce the issue:\n1.\n2.\n3.\n\n\nDescribe the results you received:\n\n\nDescribe the results you expected:\n\n\nProvide additional info you think is important:\n\n\n----------END REPORT ---------\n\n\n\n#ENEEDMOREINFO\n"}}