Jump to content

Recommended Posts

Posted

Hi All,

 

On an Odroid N2+ board, I have tried to install ZFS following different suggestions I found on the web.

None of them worked so far.

 

I tried:

https://forum.armbian.com/topic/19952-cant-install-kernel-headers-via-armbian-config/

https://forum.armbian.com/topic/18790-odroidhc4-with-5139-meson64-missing-zfs-modules/

https://forum.armbian.com/topic/17337-zfs-just-works-now-on-armbian-2-step-instructions-if-you-are-thick-like-me/

 

I installed both Armbian 22.05 Bullseye 5.10.110-meson64 first, and then Jammy 5.17.

 

Could someone please help me?
Thanks 🙂

Posted

Update: still not working.
 

Fresh installation of Armbian_22.05.4_Odroidn2_bullseye_current_5.10.123.img

  • sudo apt-get update
  • sudo apt-get dist-upgrade
  • sudo reboot
  • sudo armbian-config -> software -> Headers_install
  • sudo armbian-config -> software -> Source_install
  • sudo apt install zfs-dkms zfsutils-linux

 

Get error:

Setting up zfsutils-linux (2.0.3-9) ...
modprobe: FATAL: Module zfs not found in directory /lib/modules/5.10.123-meson64
zfs-import-scan.service is a disabled or a static unit, not starting it.
Job for zfs-load-module.service failed.


 

Posted
On 7/11/2022 at 11:26 PM, lucab said:

Setting up zfsutils-linux (2.0.3-9) ...

 

modprobe: FATAL: Module zfs not found in directory /lib/modules/5.10.123-meson64
zfs-import-scan.service is a disabled or a static unit, not starting it.
Job for zfs-load-module.service failed.


 

 

 

There should be another error before this for the failed `zfs-dkms` installation.

Probably something along the lines of "configure: error: Unable to build an empty module."

That happens because the kernel header package "linux-headers-current-meson64" is missing a file needed to build out-of-tree modules (dkms).

 

Check if "module.lds" exists under "/usr/src/linux-headers-5.10.123-meson64/scripts/".

If not, you have found the root of your problem.

 

The fix is somewhat simple. You can just construct your own "module.lds" and place it in the above directory.

The file contents consists of following:

 

  • The contents of the official "module.lds.S" file of the 5.10 kernel source (can be found here) without the last "#include" line
  • The contents of the  architecture specific "module.lds.h" header file. Odroid N2+ should be arm64, so the contents of "/usr/src/linux-headers-5.10.123-meson64/arch/arm64/include/asm/module.lds.h"

 

For my Odroid HC4 the module.lds looks as follows:

/*
 * Common module linker script, always used when linking a module.
 * Archs are free to supply their own linker scripts.  ld will
 * combine them automatically.
 */
SECTIONS {
        /DISCARD/ : {
                *(.discard)
                *(.discard.*)
        }

        __ksymtab               0 : { *(SORT(___ksymtab+*)) }
        __ksymtab_gpl           0 : { *(SORT(___ksymtab_gpl+*)) }
        __ksymtab_unused        0 : { *(SORT(___ksymtab_unused+*)) }
        __ksymtab_unused_gpl    0 : { *(SORT(___ksymtab_unused_gpl+*)) }
        __ksymtab_gpl_future    0 : { *(SORT(___ksymtab_gpl_future+*)) }
        __kcrctab               0 : { *(SORT(___kcrctab+*)) }
        __kcrctab_gpl           0 : { *(SORT(___kcrctab_gpl+*)) }
        __kcrctab_unused        0 : { *(SORT(___kcrctab_unused+*)) }
        __kcrctab_unused_gpl    0 : { *(SORT(___kcrctab_unused_gpl+*)) }
        __kcrctab_gpl_future    0 : { *(SORT(___kcrctab_gpl_future+*)) }

        .init_array             0 : ALIGN(8) { *(SORT(.init_array.*)) *(.init_array) }

        __jump_table            0 : ALIGN(8) { KEEP(*(__jump_table)) }
}

SECTIONS {
        .plt 0 : { BYTE(0) }
        .init.plt 0 : { BYTE(0) }
        .text.ftrace_trampoline 0 : { BYTE(0) }
}

Since you have the same kernel and also the same architecture the file contents should work as is also for you.

 

As for why this file is missing, the reason is some upstream kernel module compiling changes, which affected armbian build scripts because the Makefiles were removing the "module.lds" file on "make clean".

This SHOULD have been fixed with AR-608 / #2545. Maybe @Igor could shed some light on which kernel version will have the "module.lds" files included in the header package (If I understood it correctly, the header packages for 5.15.y kernels do not have this problem).

 

Posted

Thanks all for your suggestions and help.


I think I will wait for a stable release as I don't want to risk to do this procedure all the time a new kernel update is available.

 

Thanks,

Luca

Posted

Hi All.

I have just installed Armbian v22.08 (2022-08-30). It says it has zfs support, so I have tried running sudo apt-get install zfsutils-linux zfs-dkms. It returns an error. So I tried to follow @Greek64 suggestion, but the path /usr/src/ is empty.
I used armbian-config to install software -> header_install. The progress bar appears but it exits immediately, like nothing happened.

 

Any suggestions?

Thanks,

Luca

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines