public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
* [PATCH 0/2] Improving apt cache
@ 2022-12-30  4:38 Uladzimir Bely
  2022-12-30  4:38 ` [PATCH 1/2] Use hardlinks in deb-dl-dir functions Uladzimir Bely
  2022-12-30  4:38 ` [PATCH 2/2] Clean apt cache from debootstrapped rootfs dirs Uladzimir Bely
  0 siblings, 2 replies; 9+ messages in thread
From: Uladzimir Bely @ 2022-12-30  4:38 UTC (permalink / raw)
  To: isar-users

Currently, apt cache (e.g. `var/cache/apt/archives`) import and export
functions are not optimal. Multiple files are imported from global
DL_DIR to package WORKDIR, increasing disk IO and size needed.

Also, various chroots (bootstrap, buildchroot, sbuild chroot) include
their apt caches to sstate cache files.

This patchset switches to hardlinks instead of copies and removes apt
cache from bootstrapped images.

Currently (measured on qemuarm64-bullseye cross-compilation with
maximum 8 parallel tasks (e.g. 8 CPU cores)):
- build directory size reduced from 8878 to 7594 MiB
- runtime maximum disk usage reduced from 16018 to 12479 MiB

TODO:
- cleanup other rootfs's (sbuild-chroot, buildchroot)
- deal with additional copying in sbuild routines

Uladzimir Bely (2):
  Use hardlinks in deb-dl-dir functions
  Clean apt cache from debootstrapped rootfs dirs

 meta/classes/deb-dl-dir.bbclass                     | 4 ++--
 meta/recipes-core/isar-bootstrap/isar-bootstrap.inc | 6 ++++++
 2 files changed, 8 insertions(+), 2 deletions(-)

-- 
2.20.1

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2023-01-03  9:01 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-12-30  4:38 [PATCH 0/2] Improving apt cache Uladzimir Bely
2022-12-30  4:38 ` [PATCH 1/2] Use hardlinks in deb-dl-dir functions Uladzimir Bely
2022-12-30  7:29   ` Moessbauer, Felix
2022-12-30  8:29     ` Roberto A. Foglietta
2022-12-30  4:38 ` [PATCH 2/2] Clean apt cache from debootstrapped rootfs dirs Uladzimir Bely
2022-12-30  9:03   ` Roberto A. Foglietta
2023-01-02 16:27   ` Henning Schild
2023-01-02 16:33   ` Henning Schild
2023-01-03  9:01     ` Roberto A. Foglietta

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox