Can't compile ZFS from sources for Ubuntu Lunar

Mario Marietto marietto2008 at gmail.com
Mon Jun 19 08:10:02 UTC 2023


anyway :

root at Z390-AORUS-PRO-DEST:/mnt/zroot2# apt install zfsutils-linux zfs-dkms


Reading package lists... Done
Building dependency tree... Done
Reading state information... Done

The following additional packages will be installed:
 zfs-zed
Suggested packages:
 zfs-initramfs | zfs-dracut
Recommended packages:
 linux-libc-dev
The following NEW packages will be installed:
 zfs-dkms zfs-zed zfsutils-linux
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Need to get 2,917 kB of archives.
After this operation, 20.0 MB of additional disk space will be used.
Do you want to continue? [S/n] s
Get:1 http://security.ubuntu.com/ubuntu lunar-security/main amd64
zfsutils-linux amd64 2.1.9-2ubuntu
1.1 [497 kB]
Get:2 http://security.ubuntu.com/ubuntu lunar-security/main amd64 zfs-zed
amd64 2.1.9-2ubuntu1.1 [65
.3 kB]
Get:3 http://security.ubuntu.com/ubuntu lunar-security/universe amd64
zfs-dkms all 2.1.9-2ubuntu1.1
[2,355 kB]
Fetched 2,917 kB in 1s (4,531 kB/s)
Preconfiguring packages ...
Selecting previously unselected package zfsutils-linux.
dpkg: warning: files list file for package 'doc-base' missing; assuming
package has no files current
ly installed
(Reading database ... 839531 files and directories currently installed.)
Preparing to unpack .../zfsutils-linux_2.1.9-2ubuntu1.1_amd64.deb ...
Unpacking zfsutils-linux (2.1.9-2ubuntu1.1) ...
Selecting previously unselected package zfs-zed.
Preparing to unpack .../zfs-zed_2.1.9-2ubuntu1.1_amd64.deb ...
Unpacking zfs-zed (2.1.9-2ubuntu1.1) ...
Selecting previously unselected package zfs-dkms.
Preparing to unpack .../zfs-dkms_2.1.9-2ubuntu1.1_all.deb ...
Unpacking zfs-dkms (2.1.9-2ubuntu1.1) ...
Setting up zfsutils-linux (2.1.9-2ubuntu1.1) ...
modprobe: FATAL: Module zfs not found in directory
/lib/modules/6.2.0-23-generic
Setting up zfs-dkms (2.1.9-2ubuntu1.1) ...
Loading new zfs-2.1.9 DKMS
files...##############...........................]
It is likely that 6.2.0-23-generic belongs to a chroot's host
Building for 6.3.6-060306-generic
Module build for kernel 6.3.6-060306-generic was skipped since the
kernel headers for this kernel do not seem to be installed.
Setting up zfs-zed (2.1.9-2ubuntu1.1) ...
Processing triggers for man-db (2.11.2-1) ...
Processing triggers for initramfs-tools (0.142ubuntu2) ...
update-initramfs: Generating /boot/initrd.img-6.3.6-060306-generic

root at Z390-AORUS-PRO-DEST:/mnt/zroot2# apt install zfs-initramfs zfs-dracut
linux-libc-dev

Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
linux-libc-dev is already the newest version (6.2.0-23.23).
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
zfs-dracut : Depends: dracut but it is not installable
E: Unable to correct problems, you have held broken packages.
root at Z390-AORUS-PRO-DEST:/mnt/zroot2# ./monta-zroot2
The ZFS modules cannot be auto-loaded.
Try running 'modprobe zfs' as root to manually load them.

# modprobe zfs
modprobe: FATAL: Module zfs not found in directory
/lib/modules/6.2.0-23-generic

On Mon, Jun 19, 2023 at 9:47 AM Mario Marietto <marietto2008 at gmail.com>
wrote:

> The uptrace article talks about "zfs-dkms" :
>
> jonathon's PPA
>
> To install the latest ZFS version, add jonathonf's PPA:
>
> sudo add-apt-repository ppa:jonathonf/zfs
>
> And then install ZFS and zfs-dkms to update ZFS Linux kernel modules:
>
> sudo apt install zfsutils-linux zfs-dkms
>
>
> but I'm on Ubuntu Lunar,the jonathon's PPA does not support Lunar.
>
>
> On Mon, Jun 19, 2023 at 6:11 AM Jeffrey Walton <noloader at gmail.com> wrote:
>
>> On Sun, Jun 18, 2023 at 8:05 PM Mario Marietto <marietto2008 at gmail.com>
>> wrote:
>> >
>> > I tried to compile ZFS from sources for Ubuntu Lunar,but it failed.
>> This is the tutorial that I've followed :
>> >
>> > https://uptrace.dev/blog/ubuntu-install-zfs.html
>> >
>> >
>> > this is the full log:
>> >
>> >
>> > sudo apt install build-essential autoconf automake libtool
>> > gawk alien fakeroot dkms libblkid-dev uuid-dev libudev-dev
>> > libssl-dev zlib1g-dev libaio-dev libattr1-dev libelf-dev
>> > linux-headers-$(uname -r) python3 python3-dev python3-
>> > setuptools python3-cffi libffi-dev python3-packaging git
>> >
>> >
>> > Compile ZFS:
>> >
>> >
>> > git clone https://github.com/openzfs/zfs
>> > cd ./zfs
>> > git checkout master
>> >
>> >
>> > Already on 'master'. Your branch is up to date with 'origin/master'.
>> >
>> >
>> > sh autogen.sh
>> >
>> > https://pastebin.ubuntu.com/p/bpcqTg3FRV/
>> >
>> >
>> > # sudo ./configure
>> >
>> > https://pastebin.ubuntu.com/p/r5RtFvqxvN/
>> >
>> >
>> > # sudo make -s -j$(nproc)
>> >
>> > https://pastebin.ubuntu.com/p/crZyh4xcZW/
>> >
>> >
>> > Unmount existing ZFS datasets and export pools:
>> >
>> >
>> > sudo zfs unmount -a
>> >
>> >
>> > The ZFS modules cannot be auto-loaded.
>> >
>> > Try running 'modprobe zfs' as root to manually load them
>> >
>> > modprobe: FATAL: Module zfs not found in directory
>> /lib/modules/6.2.0-23-generic
>> >
>> >
>> > sudo zpool export -a
>> >
>> >
>> > The ZFS modules cannot be auto-loaded.
>> >
>> > Try running 'modprobe zfs' as root to manually load them.
>> >
>> >
>> > sudo systemctl stop zfs-send
>> >
>> >
>> > Failed to stop zfs-send.service: Unit zfs-send.service not loaded.
>> >
>> > Unload existing ZFS modules:
>> >
>> >
>> > sudo ./scripts/zfs.sh -u = OK
>> >
>> >
>> > Install newly compiled ZFS:
>> >
>> >
>> > sudo make install
>> >
>> > https://pastebin.ubuntu.com/p/ztYb89g8KQ/
>> >
>> > sudo ldconfig = OK
>> > sudo depmod
>> >
>> >
>> > depmod: ERROR: could not open directory /lib/modules/6.2.0-23-generic:
>> No such file or directory
>> >
>> > Load freshly built Linux modules:
>> >
>> >
>> > sudo ./scripts/zfs.sh = OK
>> >
>> >
>> > Failed to load /home/ziomario/Scaricati/zfs/module/zfs.ko
>> >
>> > And make sure that ZFS services are enabled:
>> >
>> >
>> > sudo systemctl enable zfs.target zfs-import.target zfs-mount.service
>> zfs-import-cache.service zfs-import-scan.service
>> >
>> >
>> > Synchronizing state of zfs-mount.service with SysV service script with
>> /lib/systemd/systemd-sysv-install.
>> >
>> > Executing: /lib/systemd/systemd-sysv-install enable zfs-mount
>> >
>> >
>> > zpool import -f -R /mnt/zroot2 zroot2
>> >
>> >
>> > The ZFS modules cannot be auto-loaded.
>> >
>> > Try running 'modprobe zfs' as root to manually load them.
>> >
>> >
>> > # sudo modprobe zfs
>> >
>> >
>> > modprobe: FATAL: Module zfs not found in directory
>> /lib/modules/6.2.0-23-generic
>> >
>> >
>> > how to fix it ? very thanks.
>>
>> This is not something I have experience with, so take it with a grain
>> of salt... I would consider the DKMS option so the kernel module gets
>> updated with each kernel update.
>>
>> Arch usually has really good documentation. Take a look at
>> https://wiki.archlinux.org/title/ZFS . It looks like you may need to
>> perform gyrations for the cache in later versions of OpenZFS. It does
>> not look like (to me) the Uptrace article talks about it.
>>
>> Jeff
>>
>> --
>> ubuntu-users mailing list
>> ubuntu-users at lists.ubuntu.com
>> Modify settings or unsubscribe at:
>> https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
>>
>
>
> --
> Mario.
>


-- 
Mario.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20230619/e0dac705/attachment.html>


More information about the ubuntu-users mailing list