Sparse images use less disk space and can be written more efficiently with a utility like bmap-tools. I wrote a patch for wic[1] and a testcase[2] but the option the sparse conversion symbol isn't available in the version of dd shipped in Debian 7. These changes can't be merged until we no longer support Debian 7, so this bug is to ensure the changes don't get lost. 1. http://lists.openembedded.org/pipermail/openembedded-core/2015-December/114228.html 2. http://lists.openembedded.org/pipermail/openembedded-core/2015-December/114309.html
Can we use native dd? Generally I'd suggest to use native tools in wic as much as possible. This should make it less dependent of the host system. There was some work done already and adding dd to the list of already used native tools would be good.
Dropping Debian 7 is something we want to do for master anyway, as it's very old now.
Patch was submitted[1][2] and a proposal was made to drop support for Debian 7[3][4], though there hasn't been a clear resolution. 1. http://lists.openembedded.org/pipermail/openembedded-core/2015-December/114228.html 2. http://lists.openembedded.org/pipermail/openembedded-core/2015-December/114309.html 3. http://lists.openembedded.org/pipermail/openembedded-core/2016-February/117387.html 4. https://lists.yoctoproject.org/pipermail/yocto/2016-February/028500.html
There is interesting piece of work done in ostroproject that may be related to this: https://github.com/ostroproject/meta-ostro/pull/70/files This commit contains the code which we can use instead of dd: https://github.com/ostroproject/meta-ostro/pull/70/commits/ccb4f0ca6b36f365bddaa9367ac1e95e0b8c3b5b
After discussion in the triage meeting on 7th April we want to try and get my simple patches that use dd into 2.1 and Ed will work on improving the sparseness support in the 2.2 cycle. To that end I resubmitted the patches to the list: http://lists.openembedded.org/pipermail/openembedded-core/2016-April/120034.html http://lists.openembedded.org/pipermail/openembedded-core/2016-April/120035.html
Replied to list. Proposed patch might be dangerous, as dd would not handle sparse blocks correctly.
Created attachment 3111 [details] bmap-tools recipe bmap-tools recipe adopted from Ostro Project to OE
Created attachment 3112 [details] bmap image conversion type bmap image coversion type.
I'll take care of this bug as I'll be working on bmap-tools support for wic in 2.2 time frame.
Used APIs from bmap-tools and ostro projects to make wic images sparse. Agreed with Alexander to add required functionality to the bmaptool that wic can use it. The patchset has been sent for review: http://lists.openembedded.org/pipermail/openembedded-core/2016-April/120735.html
sent v2: http://lists.openembedded.org/pipermail/openembedded-core/2016-April/120747.html
The patchset has been merged to master: https://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=7669219652bcc10fe957114952861d450f825274