openzfs-docs
openzfs-docs copied to clipboard
zfs-dkms installation fails on Arch
Installation/build of the zfs-dkms package in the live iso fails with iso 2021.12.01,2022.01.01 and 2022.02.01. Tried zfs-dkms-git also on all isos.
[root@archiso ~]# pacman -Sy --needed --noconfirm zfs-dkms-git glibc
:: Synchronizing package databases...
core is up to date
extra is up to date
community is up to date
archzfs is up to date
resolving dependencies...
looking for conflicting packages...
Packages (13) dkms-3.0.3-1 gc-8.2.0-2 gcc-11.2.0-4 gcc-libs-11.2.0-4 guile-2.2.7-2 libisl-0.24-4 libmpc-1.2.1-2 lsb-release-2.0.r48.3cf5103-1 make-4.3-3 patch-2.7.6-8
zfs-utils-git-2022.03.02.r7534.g29a0ffe795-1 glibc-2.35-2 zfs-dkms-git-2022.03.02.r7534.g29a0ffe795-1
Total Download Size: 142.19 MiB
Total Installed Size: 469.63 MiB
Net Upgrade Size: 301.27 MiB
:: Proceed with installation? [Y/n]
:: Retrieving packages...
gcc-11.2.0-4-x86_64 33.2 MiB 19.7 MiB/s 00:02 [############################################################################] 100%
gcc-libs-11.2.0-4-x86_64 30.6 MiB 77.7 MiB/s 00:00 [############################################################################] 100%
zfs-dkms-git-2022.03.02.r7534.g29a0ffe795-1-x86_64 30.3 MiB 18.7 MiB/s 00:02 [############################################################################] 100%
zfs-utils-git-2022.03.02.r7534.g29a0ffe795-1-x86_64 29.5 MiB 21.1 MiB/s 00:01 [############################################################################] 100%
glibc-2.35-2-x86_64 9.9 MiB 35.5 MiB/s 00:00 [############################################################################] 100%
guile-2.2.7-2-x86_64 6.3 MiB 63.2 MiB/s 00:00 [############################################################################] 100%
libisl-0.24-4-x86_64 1510.9 KiB 36.9 MiB/s 00:00 [############################################################################] 100%
make-4.3-3-x86_64 481.6 KiB 15.7 MiB/s 00:00 [############################################################################] 100%
gc-8.2.0-2-x86_64 233.0 KiB 8.43 MiB/s 00:00 [############################################################################] 100%
patch-2.7.6-8-x86_64 92.5 KiB 4.52 MiB/s 00:00 [############################################################################] 100%
libmpc-1.2.1-2-x86_64 69.3 KiB 2.82 MiB/s 00:00 [############################################################################] 100%
dkms-3.0.3-1-any 36.2 KiB 1342 KiB/s 00:00 [############################################################################] 100%
lsb-release-2.0.r48.3cf5103-1-any 8.8 KiB 324 KiB/s 00:00 [############################################################################] 100%
Total (13/13) 142.2 MiB 23.5 MiB/s 00:06 [############################################################################] 100%
(13/13) checking keys in keyring [############################################################################] 100%
(13/13) checking package integrity [############################################################################] 100%
(13/13) loading package files [############################################################################] 100%
(13/13) checking for file conflicts [############################################################################] 100%
(13/13) checking available disk space [############################################################################] 100%
:: Processing package changes...
( 1/13) installing zfs-utils-git [############################################################################] 100%
Optional dependencies for zfs-utils-git
python: pyzfs and extra utilities, [installed]
python-cffi: pyzfs [installed]
( 2/13) upgrading glibc [############################################################################] 100%
warning: /etc/locale.gen installed as /etc/locale.gen.pacnew
Generating locales...
en_US.UTF-8... done
Generation complete.
( 3/13) upgrading gcc-libs [############################################################################] 100%
( 4/13) installing lsb-release [############################################################################] 100%
( 5/13) installing libmpc [############################################################################] 100%
( 6/13) installing libisl [############################################################################] 100%
( 7/13) installing gcc [############################################################################] 100%
Optional dependencies for gcc
lib32-gcc-libs: for generating code for 32-bit ABI
( 8/13) installing gc [############################################################################] 100%
( 9/13) installing guile [############################################################################] 100%
(10/13) installing make [############################################################################] 100%
(11/13) installing patch [############################################################################] 100%
Optional dependencies for patch
ed: for patch -e functionality
(12/13) installing dkms [############################################################################] 100%
Optional dependencies for dkms
linux-headers: build modules against the Arch kernel [installed]
linux-lts-headers: build modules against the LTS kernel
linux-zen-headers: build modules against the ZEN kernel
linux-hardened-headers: build modules against the HARDENED kernel
(13/13) installing zfs-dkms-git [############################################################################] 100%
:: Running post-transaction hooks...
(1/7) Reloading system manager configuration...
(2/7) Creating temporary files...
(3/7) Reloading device manager configuration...
(4/7) Arming ConditionNeedsUpdate...
(5/7) Install DKMS modules
==> dkms install --no-depmod zfs/git -k 5.16.4-arch1-1
<string>:1: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives
<string>:1: DeprecationWarning: The distutils.sysconfig module is deprecated, use sysconfig instead
<string>:1: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives
<string>:1: DeprecationWarning: The distutils.sysconfig module is deprecated, use sysconfig instead
<stdin>:4: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives
<stdin>:4: DeprecationWarning: The distutils.sysconfig module is deprecated, use sysconfig instead
<stdin>:3: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives
<stdin>:3: DeprecationWarning: The distutils.sysconfig module is deprecated, use sysconfig instead
<stdin>:2: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives
<stdin>:2: DeprecationWarning: The distutils.sysconfig module is deprecated, use sysconfig instead
<string>:1: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives
<string>:1: DeprecationWarning: The distutils.sysconfig module is deprecated, use sysconfig instead
<string>:1: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives
<string>:1: DeprecationWarning: The distutils.sysconfig module is deprecated, use sysconfig instead
<string>:1: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives
<string>:1: DeprecationWarning: The distutils.sysconfig module is deprecated, use sysconfig instead
configure: error:
*** Unable to build an empty module.
Error! Bad return status for module build on kernel: 5.16.4-arch1-1 (x86_64)
Consult /var/lib/dkms/zfs/git/build/make.log for more information.
==> WARNING: `dkms install --no-depmod zfs/git -k 5.16.4-arch1-1' exited 10
(6/7) Updating linux initcpios...
==> Building image from preset: /etc/mkinitcpio.d/linux.preset: 'archiso'
-> -k /boot/vmlinuz-linux -c /etc/mkinitcpio.conf -g /boot/initramfs-linux.img
==> ERROR: specified kernel image does not exist: `/boot/vmlinuz-linux'
error: command failed to execute correctly
(7/7) Updating the info directory file...
Thanks for reporting this issue. I can confirm this build failure:
checking kernel source version... 5.16.11-arch1-1
checking kernel file name for module symbols... Module.symvers
checking whether modules can be built... no
configure: error:
*** Unable to build an empty module.
Building module:
cleaning build area...(bad exit status: 2)
make -j1 KERNELRELEASE=5.16.11-arch1-1...(bad exit status: 2)
Error! Bad return status for module build on kernel: 5.16.11-arch1-1 (x86_64)
For now the workaround seems to be manually selecting a prebuilt package and install it in live environment. The following applies to 2022.03.01 version:
#after adding repo
pacman -S zfs-utils
pacman -U https://mirror.sum7.eu/archlinux/archzfs/archive_archzfs/zfs-linux-2.1.2_5.16.11.arch1.1-1-x86_64.pkg.tar.zst
This is indeed an rather frustrating experience, I admit.
If you are interested, I suggest you give NixOS a try, which has the best out-of-box ZFS experience. Ubuntu-like, I'd say.
Thank you for your fast response. I found a fix on archlinux.de! They utilize an elaborate script to load ZFS into the liveISO. After that they load a different repository for Arch.
[archzfs]
Server = http://archzfs.com/$repo/x86_64
SigLevel = Optional TrustAll
It is currently unclear to me what the status of OpenZFS is currently. The Github page looks like it is not further maintained while the archzfs.com repository works. Can you maybe elaborate your opinion on my solution of using the other repository. Otherwise I could follow the guide for ZFS on root from the OpenZFS wiki to finish the installation. Only the repository needed adjusting.
They utilize an elaborate script to load ZFS into the liveISO.
I frankly hate this. This requires the user to already have an installed arch system. Sourcing a non-optional 3rd party script is also messy and untrustworthy.
We must start with official, vanilla disk image in any case.
load a different repository for Arch.
I have to remind you that we are using the exact same repo in the guide. Plus a few mirrors. See here https://git.io/Jsfw2
SigLevel = Optional TrustAll
This is just sloppy security practice. Why disable signature checking which the repo clearly supports? To inject malicious code?
what the status of OpenZFS is currently. The Github page looks like it is not further maintained
I do not know which page you were looking at. OpenZFS is alive and well, and is seeing new commits everyday.
while the archzfs.com repository works
It is still OpenZFS. OpenZFS provides the source, archzfs acts as an intermediate and packages the source in a arch-friendly container.
my solution of using the other repository
It's the same repo all along.
Only the repository needed adjusting.
Well, the repo works for you now? That would be quite interesting indeed.
It seems I got some things confused there, sorry. In a nutshell though, building the DKMS module failed with the 3 currently available version of the ArchISO, while executing the script I linked worked and gave me ZFS in the ArchISO. Apart from that I followed the Guide and was able to set everything up.
Pre-built packages instead of DKMS is now used in the guide. @gmelikov This issue can be closed.