{"action":"created","issue":{"url":"https://api.github.com/repos/resin-io/resin-preload-image-script/issues/54","repository_url":"https://api.github.com/repos/resin-io/resin-preload-image-script","labels_url":"https://api.github.com/repos/resin-io/resin-preload-image-script/issues/54/labels{/name}","comments_url":"https://api.github.com/repos/resin-io/resin-preload-image-script/issues/54/comments","events_url":"https://api.github.com/repos/resin-io/resin-preload-image-script/issues/54/events","html_url":"https://github.com/resin-io/resin-preload-image-script/issues/54","id":238196277,"number":54,"title":"Running out of space on image during preload","user":{"login":"BrianAdams","id":1471826,"avatar_url":"https://avatars1.githubusercontent.com/u/1471826?v=3","gravatar_id":"","url":"https://api.github.com/users/BrianAdams","html_url":"https://github.com/BrianAdams","followers_url":"https://api.github.com/users/BrianAdams/followers","following_url":"https://api.github.com/users/BrianAdams/following{/other_user}","gists_url":"https://api.github.com/users/BrianAdams/gists{/gist_id}","starred_url":"https://api.github.com/users/BrianAdams/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BrianAdams/subscriptions","organizations_url":"https://api.github.com/users/BrianAdams/orgs","repos_url":"https://api.github.com/users/BrianAdams/repos","events_url":"https://api.github.com/users/BrianAdams/events{/privacy}","received_events_url":"https://api.github.com/users/BrianAdams/received_events","type":"User","site_admin":false},"labels":[{"id":269016683,"url":"https://api.github.com/repos/resin-io/resin-preload-image-script/labels/bug","name":"bug","color":"b60205","default":true}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":24,"created_at":"2017-06-23T16:46:33Z","updated_at":"2017-06-29T19:37:38Z","closed_at":null,"body":"When I download the docker image to my desktop to check the size I see that is it *1.91GB*, yet when doing the resin-preload, the script calculates the size as *798MB*.  I am assuming that is why it is running out of space when downloading the image:\r\n\r\n```\r\ndocker images\r\nREPOSITORY                                                                     TAG                 IMAGE ID            CREATED             SIZE\r\nregistry2.resin.io/...project.../86a155bc9b33e6f1d9710063638e26dc22921f42   latest              0cc797f6ebff        2 days ago          1.91GB\r\n```\r\n\r\n```\r\nresin os download raspberrypi3 -o resin.img --version default\r\ndocker run --rm -e API_KEY=..key.. -e APP_ID=..appid.. -v /tmp/resin.img:/img/resin.img --privileged resin/resin-preload\r\n```\r\n\r\n```\r\nFetching application data\r\nUsing API host https://api.resin.io\r\nUsing Registry host registry2.resin.io\r\nUsing API_KEY\r\n  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current\r\n                                 Dload  Upload   Total   Spent    Left  Speed\r\n100   840  100   840    0     0    874      0 --:--:-- --:--:-- --:--:--  1746\r\n...\r\nContainer size: 798 MB\r\nMapping /img/resin.img 46137344:327155712 to /dev/loop0\r\n\r\nMounting rootfs from /dev/loop0 to /mnt/202699-rootfs\r\n\r\nSourcing release info from /mnt/202699-rootfs/etc/os-release\r\nDetected Resin OS 2.0.6+rev3\r\n\r\nid: resin-os\r\nname: Resin OS\r\nversion: 2.0.6+rev3\r\nversion_id: 2.0.6\r\npretty_name: Resin OS 2.0.6+rev3\r\nresin_board_rev: 5f3fbb3\r\nmeta_resin_rev: c653cc2\r\nslug: raspberrypi3\r\nmachine: raspberrypi3\r\n\r\n\r\nUnmounting rootfs from /mnt/202699-rootfs\r\numount: /mnt/202699-rootfs unmounted\r\nUnmapping /dev/loop0\r\nModel:  (file)\r\nDisk /img/resin.img: 1804MB\r\nSector size (logical/physical): 512B/512B\r\nPartition Table: msdos\r\nDisk Flags:\r\n\r\nNumber  Start   End     Size    Type      File system  Flags\r\n 1      4.19MB  46.1MB  41.9MB  primary   fat16        boot, lba\r\n 2      46.1MB  373MB   327MB   primary   ext4\r\n 3      373MB   700MB   327MB   primary\r\n 4      700MB   1804MB  1103MB  extended               lba\r\n 5      705MB   726MB   21.0MB  logical   ext4\r\n 6      730MB   1804MB  1074MB  logical   ext4\r\n\r\nExpanding image by 877 MB\r\n877+0 records in\r\n877+0 records out\r\nExpanding extended partition 4 by 877 MB\r\nExpanding logical partition 6 by 877 MB\r\nModel:  (file)\r\nDisk /img/resin.img: 2723MB\r\nSector size (logical/physical): 512B/512B\r\nPartition Table: msdos\r\nDisk Flags:\r\n\r\nNumber  Start   End     Size    Type      File system  Flags\r\n 1      4.19MB  46.1MB  41.9MB  primary   fat16        boot, lba\r\n 2      46.1MB  373MB   327MB   primary   ext4\r\n 3      373MB   700MB   327MB   primary\r\n 4      700MB   2681MB  1981MB  extended               lba\r\n 5      705MB   726MB   21.0MB  logical   ext4\r\n 6      730MB   2681MB  1951MB  logical   ext4\r\n\r\nCreating mountpoint /mnt/202699\r\nExpanding filesystem\r\nUsing EXTFS\r\nMapping /img/resin.img 729808896:1951191552 to /dev/loop0\r\nUsing /dev/loop0\r\nResizing filesystem\r\ne2fsck 1.43 (17-May-2016)\r\ne2fsck: need terminal for interactive repairs\r\nRemoving /mnt/202699/rce\r\nWaiting for Docker to start...\r\ntime=\"2017-06-23T16:28:49.186529914Z\" level=info msg=\"Graph migration to content-addressability took 0.00 seconds\"\r\ntime=\"2017-06-23T16:28:49.189610610Z\" level=warning msg=\"Running modprobe bridge br_netfilter failed with message: modprobe: can't change directory to '/lib/modules': No such file or directory\\n, error: exit status 1\"\r\ntime=\"2017-06-23T16:28:49.191319399Z\" level=warning msg=\"Running modprobe nf_nat failed with message: `modprobe: can't change directory to '/lib/modules': No such file or directory`, error: exit status 1\"\r\ntime=\"2017-06-23T16:28:49.259926136Z\" level=info msg=\"Default bridge (docker0) is assigned with an IP address 172.18.0.0/16. Daemon option --bip can be used to set a preferred IP address\"\r\ntime=\"2017-06-23T16:28:49.321050917Z\" level=info msg=\"Loading containers: start.\"\r\n\r\ntime=\"2017-06-23T16:28:49.321929276Z\" level=info msg=\"Loading containers: done.\"\r\ntime=\"2017-06-23T16:28:49.322046467Z\" level=info msg=\"Daemon has completed initialization\"\r\ntime=\"2017-06-23T16:28:49.322337814Z\" level=info msg=\"Docker daemon\" commit=20f81dd execdriver=native-0.2 graphdriver=aufs version=1.10.3\r\ntime=\"2017-06-23T16:28:49.338344333Z\" level=info msg=\"API listen on /tmp/docker-202699/docker.sock\"\r\nDocker started\r\nPulling image...\r\n...\r\n\r\na1f1e8c37f14: Verifying Checksum\r\na1f1e8c37f14: Download complete\r\ntime=\"2017-06-23T16:30:14.848362139Z\" level=error msg=\"Download failed: write /mnt/202699/docker/tmp/GetImageBlob199650751: no space left on device\"\r\na1f1e8c37f14: Download complete\r\n\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/resin-io/resin-preload-image-script/issues/comments/312079396","html_url":"https://github.com/resin-io/resin-preload-image-script/issues/54#issuecomment-312079396","issue_url":"https://api.github.com/repos/resin-io/resin-preload-image-script/issues/54","id":312079396,"user":{"login":"BrianAdams","id":1471826,"avatar_url":"https://avatars1.githubusercontent.com/u/1471826?v=3","gravatar_id":"","url":"https://api.github.com/users/BrianAdams","html_url":"https://github.com/BrianAdams","followers_url":"https://api.github.com/users/BrianAdams/followers","following_url":"https://api.github.com/users/BrianAdams/following{/other_user}","gists_url":"https://api.github.com/users/BrianAdams/gists{/gist_id}","starred_url":"https://api.github.com/users/BrianAdams/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BrianAdams/subscriptions","organizations_url":"https://api.github.com/users/BrianAdams/orgs","repos_url":"https://api.github.com/users/BrianAdams/repos","events_url":"https://api.github.com/users/BrianAdams/events{/privacy}","received_events_url":"https://api.github.com/users/BrianAdams/received_events","type":"User","site_admin":false},"created_at":"2017-06-29T19:37:38Z","updated_at":"2017-06-29T19:37:38Z","body":"I thought your approach to pull the uncompressed size using a http range query was clever. Does that not end up possible in the end?"}}
{"actor":{"display_login":"BrianAdams"}}