public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
From: "'Quirin Gylstorff' via isar-users" <isar-users@googlegroups.com>
To: isar-users@googlegroups.com
Subject: Re: [PATCH 2/2] isoimage-isohybrid-isar: fix disk full if no initrd exists
Date: Thu, 27 Nov 2025 12:10:23 +0100	[thread overview]
Message-ID: <05eee0e1-bbe2-492b-b94a-2bf082259f69@siemens.com> (raw)
In-Reply-To: <20251126114431.20236-2-Quirin.Gylstorff@siemens.com>



On 11/26/25 12:43, 'Quirin Gylstorff' via isar-users wrote:
> From: Quirin Gylstorff <quirin.gylstorff@siemens.com>
> 
> If no initrd was generated during the rootfs build the wic plugin
> uses the existing rootfs as initrd. The plugin uses shutil.copytree
> to copy the rootfs to a new folder. As the rootfs contains `/dev/full`
> this will fill the disk until it is full.
> 
> To avoid this error ignore all files in `/dev/` of the rootfs.
> 
> Tested-by:    Herbert Bernecker <herbert.bernecker@siemens.com>
> Signed-off-by: Quirin Gylstorff <quirin.gylstorff@siemens.com>
> ---
/dev should be populate by mmdebstrap so another way should be
--skip=output/mknod or  --skip=output/dev  but during the initial
testing these option broke package builds.

Quirin

>   .../lib/wic/plugins/source/isoimage-isohybrid-isar.py     | 8 +++++++-
>   1 file changed, 7 insertions(+), 1 deletion(-)
> 
> diff --git a/meta/scripts/lib/wic/plugins/source/isoimage-isohybrid-isar.py b/meta/scripts/lib/wic/plugins/source/isoimage-isohybrid-isar.py
> index 690e291e..fb6c6b39 100644
> --- a/meta/scripts/lib/wic/plugins/source/isoimage-isohybrid-isar.py
> +++ b/meta/scripts/lib/wic/plugins/source/isoimage-isohybrid-isar.py
> @@ -203,8 +203,14 @@ class IsoImagePlugin(SourcePlugin):
>               # Create initrd from rootfs directory
>               initrd = "%s/initrd.cpio.gz" % cr_workdir
>               initrd_dir = "%s/INITRD" % cr_workdir
> +            def ignore_contents(src, names):
> +                if os.path.basename(src) == 'dev':
> +                    return names
> +                return []
> +
>               shutil.copytree("%s" % rootfs_dir, \
> -                            "%s" % initrd_dir, symlinks=True)
> +                            "%s" % initrd_dir, \
> +                            ignore=ignore_contents, symlinks=True)
>   
>               if os.path.isfile("%s/init" % rootfs_dir):
>                   shutil.copy2("%s/init" % rootfs_dir, "%s/init" % initrd_dir)

-- 
You received this message because you are subscribed to the Google Groups "isar-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/isar-users/05eee0e1-bbe2-492b-b94a-2bf082259f69%40siemens.com.

  reply	other threads:[~2025-11-27 11:10 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-26 11:43 [PATCH 1/2] isoimage-isohybrid-isar: fix error if source_param image_name is set 'Quirin Gylstorff' via isar-users
2025-11-26 11:43 ` [PATCH 2/2] isoimage-isohybrid-isar: fix disk full if no initrd exists 'Quirin Gylstorff' via isar-users
2025-11-27 11:10   ` 'Quirin Gylstorff' via isar-users [this message]
2025-11-28  9:02     ` Zhihang Wei
2025-11-28 16:07 ` [PATCH 1/2] isoimage-isohybrid-isar: fix error if source_param image_name is set Zhihang Wei

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=05eee0e1-bbe2-492b-b94a-2bf082259f69@siemens.com \
    --to=isar-users@googlegroups.com \
    --cc=quirin.gylstorff@siemens.com \
    /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