Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Robert Yang <liezhi.yang@windriver.com>
To: Joshua Lock <joshua.g.lock@intel.com>,
	<openembedded-core@lists.openembedded.org>
Cc: Joshua Lock <joshua.lock@collabora.co.uk>
Subject: Re: [PATCH 1/2] wic/utils/partitionedfs.py: assemble .wic images as sparse files
Date: Sun, 10 Apr 2016 22:34:27 +0800	[thread overview]
Message-ID: <570A6473.6070000@windriver.com> (raw)
In-Reply-To: <1460106859-14007-1-git-send-email-joshua.g.lock@intel.com>



On 04/08/2016 05:14 PM, Joshua Lock wrote:
> From: Joshua Lock <joshua.lock@collabora.co.uk>
>
> The individual partitions created by wic are sparse but without
> this change the assembled image is written as one (potentially
> very) large file.
>
> Preserve sparseness in the assembled image by passing the sparse
> conversion symbol.
>
> [YOCTO #9099]
>
> Signed-off-by: Joshua Lock <joshua.lock@collabora.co.uk>
> ---
>   scripts/lib/wic/utils/partitionedfs.py | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/scripts/lib/wic/utils/partitionedfs.py b/scripts/lib/wic/utils/partitionedfs.py
> index 5a103bb..3e2b420 100644
> --- a/scripts/lib/wic/utils/partitionedfs.py
> +++ b/scripts/lib/wic/utils/partitionedfs.py
> @@ -340,7 +340,7 @@ class Image(object):
>               source = part['source_file']
>               if source:
>                   # install source_file contents into a partition
> -                cmd = "dd if=%s of=%s bs=%d seek=%d count=%d conv=notrunc" % \
> +                cmd = "dd if=%s of=%s bs=%d seek=%d count=%d conv=notrunc,sparse" % \

Hi Joshua,

I got errors with this patch since my dd doesn't support conversion sparse:
dd: invalid conversion: `sparse'
Try `dd --help' for more information.

So that it would fail.

$ dd --version
dd (coreutils) 8.13
Copyright (C) 2011 Free Software Foundation, Inc.

The host is Ubuntu 12.04, it works well except this error.

// Robert

>                         (source, image_file, self.sector_size,
>                          part['start'], part['size'])
>                   exec_cmd(cmd)
>


      parent reply	other threads:[~2016-04-10 14:34 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-08  9:14 [PATCH 1/2] wic/utils/partitionedfs.py: assemble .wic images as sparse files Joshua Lock
2016-04-08  9:14 ` [PATCH 2/2] oeqa/selftest/wic: add test case for sparse images Joshua Lock
2016-04-09 10:36 ` [PATCH 1/2] wic/utils/partitionedfs.py: assemble .wic images as sparse files Alexander Kanevskiy
2016-04-09 16:41   ` Philip Balister
2016-04-11 11:52     ` Alexander Kanevskiy
2016-04-12 11:55   ` Burton, Ross
2016-04-10 14:34 ` Robert Yang [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=570A6473.6070000@windriver.com \
    --to=liezhi.yang@windriver.com \
    --cc=joshua.g.lock@intel.com \
    --cc=joshua.lock@collabora.co.uk \
    --cc=openembedded-core@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox