From: "MOESSBAUER, Felix" <felix.moessbauer@siemens.com>
To: "isar-users@googlegroups.com" <isar-users@googlegroups.com>,
"Kiszka, Jan" <jan.kiszka@siemens.com>,
"Hombourger, Cedric" <cedric.hombourger@siemens.com>
Subject: Re: [PATCH] debianize: handle .triggers and .service files
Date: Wed, 15 Nov 2023 08:43:31 +0000 [thread overview]
Message-ID: <a207db611d38bc83c42cb5b9e2cf33b325823598.camel@siemens.com> (raw)
In-Reply-To: <29444773-b058-4603-ba15-600ad787af12@siemens.com>
On Wed, 2023-11-15 at 09:36 +0100, Jan Kiszka wrote:
> On 14.11.23 21:22, 'MOESSBAUER, Felix' via isar-users wrote:
> > On Tue, 2023-11-14 at 20:54 +0100, 'Cedric Hombourger' via isar-
> > users
> > wrote:
> > > Some packages need to update/rebuild the initramfs and this is
> > > particularly
> > > slow on Debian systems (which are not using more modern
> > > technologies
> > > such
> > > as dracut or mkosi). Instead of having each package call update-
> > > initramfs,
> > > use a trigger instead to have dpkg defer that call to the very
> > > end of
> > > the
> > > transaction. Many packages also failed to rebuild the initramfs
> > > when
> > > the
> > > package gets removed. Demonstrate use with initramfs-fsck-hook-
> > > ext4.
> >
> > Hi Cedric,
> >
> > thanks for bringing this up. Especially on non x86 builds the
> > update-
> > initramfs can take really long due to the emulation.
> >
> > I also played around with disabling the initrd update during image
> > building of images with a custom initramfs (where the one from the
> > rootfs is anyways not used). However the issue is, that the config
> > change needs to be made in /etc/initramfs-tools/update-
> > initramfs.conf,
> > which is shipped by initramfs-tools (no conf.d style supported). By
> > that, we would need to add this package to the default set of
> > packages
> > which I also dislike.
> >
> > What I don't understand is how the initrd trigger should help. The
> > /usr/sbin/update-initramfs internally already detects the
> > invocation
> > via dpkg and dispatches to the trigger, so manually adding this is
> > nice
> > syntax wise, but does not make a difference in performance.
> >
> > Ideally, we don't update the initrd at all during package install,
> > but
> > just generate it at do_rootfs_postprocess.
> >
>
> There is actually an issue already in Debian itself which I started
> to
> examine during Debconf but was distracted: If you install a minimal
> rootfs with kernel, that will already run the initramfs generation
> twice, although it should do it once only. That said, anything on top
> may be related to missing proper usage of triggers.
Ok... can you provide a link to the issue?
Regarding the triggers: The triggers itself work properly, but they are
called once per apt install/remove invocation, and as we have multiple
apt calls in ISAR (within a single build), also the triggers are called
multiple times. We really need to fully disable the initramfs
generation and call it manually at the end of the rootfs install.
Felix
>
> Jan
>
next prev parent reply other threads:[~2023-11-15 8:44 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-14 19:54 Cedric Hombourger
2023-11-14 20:22 ` MOESSBAUER, Felix
2023-11-15 8:36 ` Jan Kiszka
2023-11-15 8:43 ` MOESSBAUER, Felix [this message]
2023-11-15 8:57 ` cedric.hombourger
2023-11-15 9:03 ` MOESSBAUER, Felix
2023-11-16 12:38 ` Jan Kiszka
2024-03-07 7:23 ` Uladzimir Bely
2024-03-26 20:15 ` Uladzimir Bely
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=a207db611d38bc83c42cb5b9e2cf33b325823598.camel@siemens.com \
--to=felix.moessbauer@siemens.com \
--cc=cedric.hombourger@siemens.com \
--cc=isar-users@googlegroups.com \
--cc=jan.kiszka@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