Skip to content

feat(collector-zfs): add arm64 support for scrutiny collector zfs#422

Merged
Starosdev merged 1 commit intoStarosdev:masterfrom
kvanzuijlen:zfs-collector-on-arm64
Apr 4, 2026
Merged

feat(collector-zfs): add arm64 support for scrutiny collector zfs#422
Starosdev merged 1 commit intoStarosdev:masterfrom
kvanzuijlen:zfs-collector-on-arm64

Conversation

@kvanzuijlen
Copy link
Copy Markdown

@kvanzuijlen kvanzuijlen commented Apr 3, 2026

Summary

This PR adds native linux/arm64 cross-compilation support to the collector-zfs Docker image and solves the 45+ minute QEMU emulation bottleneck.

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update
  • Refactoring (no functional changes)
  • CI/CD or infrastructure change

Related Issues

Closes #90

Changes Made

  • Re-enabled linux/arm64 in the collector-zfs build target within .github/workflows/docker-build.yaml.
  • Integrated Docker Buildx --platform=$BUILDPLATFORM into Dockerfile.collector-zfs, enabling Go to natively cross-compile the binary to ARM64 before moving to final QEMU image assembly.
  • Implemented the --no-install-recommends flag for apt-get install zfsutils-linux to reduce the total build time (see additional notes).

Testing

  • I have tested this locally
  • I have added/updated tests that prove my fix/feature works
  • All existing tests pass

I have also pushed this to a temp package repository to test it on my Raspberry Pi, resulting in my ZFS pool showing up in Scrutiny.

Checklist

  • My code follows the project's code style
  • I have performed a self-review of my code
  • I have commented my code where necessary (particularly complex areas)
  • I have updated the documentation if needed
  • My changes generate no new warnings
  • No console.log, debug statements, or commented-out code

Screenshots (if applicable)

Additional Notes

Because Docker containers share their underlying kernel with the host, generating arbitrary ZFS kernel modules via zfs-dkms natively inside the container during build time was unnecessarily taxing the QEMU pipeline. By using --no-install-recommends, it skips the installation of zfs-dkms and only the necessary zpool libraries are downloaded.

Effects of `--no-install-recommends`With --no-install-recommends:
Installing:
zfsutils-linux

Installing dependencies:
libcom-err2 libnvpair3linux libzpool6linux
libexpat1 libpython3-stdlib media-types
libffi8 libpython3.13-minimal netbase
libgssapi-krb5-2 libpython3.13-stdlib python3
libk5crypto3 libreadline8t64 python3-minimal
libkeyutils1 libtirpc-common python3.13
libkrb5-3 libtirpc3t64 python3.13-minimal
libkrb5support0 libuutil3linux readline-common
libncursesw6 libzfs6linux

Without --no-install-recommends:
Installing:
zfsutils-linux

Installing dependencies:
binutils libexpat1 librtmp1
binutils-aarch64-linux-gnu libfakeroot libsasl2-2
binutils-common libffi8 libsasl2-modules
build-essential libfile-fcntllock-perl libsasl2-modules-db
bzip2 libgcc-14-dev libsframe1
ca-certificates libgdbm-compat4t64 libssh2-1t64
cpp libgdbm6t64 libstdc++-14-dev
cpp-14 libgnutls30t64 libtasn1-6
cpp-14-aarch64-linux-gnu libgomp1 libtirpc-common
cpp-aarch64-linux-gnu libgpm2 libtirpc3t64
dkms libgprofng0 libtsan2
dpkg-dev libgssapi-krb5-2 libubsan1
fakeroot libhwasan0 libunistring5
file libidn2-0 libuutil3linux
g++ libisl23 libzfs6linux
g++-14 libitm1 libzpool6linux
g++-14-aarch64-linux-gnu libjansson4 linux-libc-dev
g++-aarch64-linux-gnu libk5crypto3 lsb-release
gcc libkeyutils1 make
gcc-14 libkmod2 manpages
gcc-14-aarch64-linux-gnu libkrb5-3 manpages-dev
gcc-aarch64-linux-gnu libkrb5support0 media-types
kmod libldap-common netbase
krb5-locales libldap2 openssl
libalgorithm-diff-perl liblocale-gettext-perl patch
libalgorithm-diff-xs-perl liblsan0 perl
libalgorithm-merge-perl libmagic-mgc perl-modules-5.40
libapparmor1 libmagic1t64 publicsuffix
libasan8 libmpc3 python3
libatomic1 libmpfr6 python3-minimal
libbinutils libncursesw6 python3.13
libbrotli1 libnghttp2-14 python3.13-minimal
libc-dev-bin libnghttp3-9 readline-common
libc6-dev libnvpair3linux rpcsvc-proto
libcc1-0 libp11-kit0 sq
libcom-err2 libperl5.40 sudo
libcrypt-dev libpsl5t64 xz-utils
libctf-nobfd0 libpython3-stdlib zfs-dkms
libctf0 libpython3.13-minimal zfs-zed
libcurl4t64 libpython3.13-stdlib
libdpkg-perl libreadline8t64

@kvanzuijlen kvanzuijlen requested a review from Starosdev as a code owner April 3, 2026 12:14
@kvanzuijlen kvanzuijlen changed the title feat: add arm64 support for scrutiny collector zfs feat(collector-zfs): add arm64 support for scrutiny collector zfs Apr 3, 2026
@Starosdev Starosdev merged commit 9290987 into Starosdev:master Apr 4, 2026
15 checks passed
@kvanzuijlen kvanzuijlen deleted the zfs-collector-on-arm64 branch April 4, 2026 21:31
Starosdev pushed a commit that referenced this pull request Apr 4, 2026
## [1.49.0](v1.48.0...v1.49.0) (2026-04-04)

### Features

* **collector-zfs:** add arm64 support for scrutiny collector zfs ([#422](#422)) ([9290987](9290987)), closes [#90](#90)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add arm64 support for ZFS collector Docker image

2 participants