Power & Source of Big Ideas

NanoPi M4 How to install kernel headers?

Moderators: chensy, FATechsupport

I'm trying to install ZFS on my NanoPi M4 with the rk3399-sd-friendlycore-bionic-4.4-arm64-20180921.img Image.
It looks like i just need to install the kernel headers, but when i try apt says it couldn't find them.


Code: Select all

pi@MicroNAS:~$ sudo apt-get install linux-headers-$(uname -r)
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package linux-headers-4.4.143
E: Couldn't find any package by glob 'linux-headers-4.4.143'
E: Couldn't find any package by regex 'linux-headers-4.4.143'
pi@MicroNAS:~$


Full install and output of running modprobe zfs
https://pastebin.com/W7wyWDmK
I'm also looking to install/use zfs and have been wrestling with the same problem. Tried both the FriendlyDesktop and lubuntu images and both seem to be stuck on 4.4.143 kernel and although I can use the ubuntu kernel upgrade utility to find and "install" different kernels none of them actually "work" in that I can't figure out how to switch to them (no bootloader access that I can figure out) and the zfs module is not available with this kernel nor can I compile it without kernel headers.

Frustrating. This hardware could be so good for nas storage. Hoping someone more familiar than I can crack this but I'll keep hacking at it.
I'm also working on this. Trying to get ZFS running but without headers or an upgraded kernel/kernel module I can't get it going. Hoping someone else has had more luck though I'll keep cracking at it.
zdea wrote:
I'm also working on this. Trying to get ZFS running but without headers or an upgraded kernel/kernel module I can't get it going. Hoping someone else has had more luck though I'll keep cracking at it.


This is very simple to solve: https://www.armbian.com/download/?tx_maker=friendlyelec
igorp wrote:
zdea wrote:
I'm also working on this. Trying to get ZFS running but without headers or an upgraded kernel/kernel module I can't get it going. Hoping someone else has had more luck though I'll keep cracking at it.


This is very simple to solve: https://www.armbian.com/download/?tx_maker=friendlyelec


Thank you for the tip. The link you shared is to a different distro (armbian) which I will definitely check out, however while I download it I'm already noticing that their website indicates 2 things:

1. The armbian image is a work in progress and thus not fully supported.
2. It is based on a similarly out of date kernel.

I'm crossing my fingers and hoping that what you are saying is that when I install this the kernel can be upgraded easily ukuu or some similarly easy method. I'll report back my findings... but just in case you beat me to it... care to elaborate on why you recommend this armbian image over the FriendlyElec provided images?
zdea wrote:
1. The armbian image is a work in progress and thus not fully supported.
2. It is based on a similarly out of date kernel.
Armbian has higher standards and takes word support seriously. Since kernel features for this platform are not fully done, builds have a label "testing". In Armbian support means providing FREE help for end users (not just for hardware) which is in this changing and unfinished stage extremely expensive (that's why there is donate button) and pointless. People/users are lazy by default and before they read what works or not, they start repeating the same questions all over again: "why this is not working, how to do that, ..." Since nobody wants to spent donating their personal time for answering this, (end user) support for unfinished builds is simply not existing. Your alternative is ... not existing.

zdea wrote:
I'm crossing my fingers and hoping that what you are saying is that when I install this the kernel can be upgraded easily ukuu or some similarly easy method. I'll report back my findings... but just in case you beat me to it... care to elaborate on why you recommend this Armbian image over the FriendlyElec provided images?


Armbian provides clean, bug-fixed and performance optimised, fluid Debian/Ubuntu which is already several steps ahead. It provides build engine which is again several steps ahead. It provides modern 4.19.y (of course not finished yet) kernel, has the same legacy stock kernel at worse ...
Igorp,

Thanks for sharing your recommendation. Armbian looks like a nice project. I'll keep an eye on it. For now, it looks as if the image for this platform is not up to the point where I can use it. Hardware support (particularly gpu-side) seems to be behind the friendlydesktop image. The kernel is 4.4.162 (and curiously the headers that the armbian setup app installs are for 4.4.156) and of course ZFS (my ultimate target) can't be installed out of the box.

Couple quick things:

You said "This is very simple to solve"... did you think at the time that Armbian on M4 would support zfs out of the box or that kernel headers / building zfs would be easier on armbian or something else?

Also, you mentioned reading about what works and what does not... from what I can tell, the M4 is not really even covered in the armbian documentation and the product page on the armbian site really only lists hardware-related "support" (and not much detail even at that). I hate to be one of those "lazy users" but I feel like in this case, what I'm looking for is not there, though I'd be glad to be proven wrong.

Btw... since I'm assuming you are "the IgorP" from Armbian... thank you for all the effort you and your crew have put in.
I'd love to see and try the clean kernel of Ubuntu 4.18. And at its base to assemble your own system.
We are waiting for the release of a good version of Ubuntu Core 18.04 with kernel 4.18, because there is a lot of potential on the M4 board.
Sincerely, Pavel.
zdea wrote:
Thanks for sharing your recommendation. Armbian looks like a nice project. I'll keep an eye on it. For now, it looks as if the image for this platform is not up to the point where I can use it. Hardware support (particularly gpu-side) seems to be behind the friendlydesktop image.
Most of people behind the project are interested in the headless useage. But since there is an interest and RK3399 gpu related features will be implemented to our desktop build when possible. We are reworking build system that this will not be as complex as it is now. We need to solve for other platforms as well. We have only done this for Allwinner boards, which are among most popular ones. Rockchip 3399 is relatively new.

zdea wrote:
The kernel is 4.4.162 (and curiously the headers that the armbian setup app installs are for 4.4.156) and of course ZFS (my ultimate target) can't be installed out of the box.
Version discrepancy is simpli due to lack of human resources and protocols when making updates on the repository which is updated manually. You can switch to automated repository (beta.armbian.com instead of apt.armbian.com -> armbian-config -> system -> switch to beta repo) and there you will have right combinations.

zdea wrote:
Couple quick things:

You said "This is very simple to solve"... did you think at the time that Armbian on M4 would support zfs out of the box or that kernel headers / building zfs would be easier on armbian or something else?
Yes, because we do provide headers (virtually since day 1) and build essentials are preinstalled. Usually you just need to run "make" on the sources.

I don't think we will add ZFS to the Armbian by default since implementing doesn't look trivial and such wishes easily wait a year or more that they are implemented. Unless there is your/external help.

zdea wrote:
Also, you mentioned reading about what works and what does not... from what I can tell, the M4 is not really even covered in the armbian documentation and the product page on the armbian site really only lists hardware-related "support" (and not much detail even at that). I hate to be one of those "lazy users" but I feel like in this case, what I'm looking for is not there, though I'd be glad to be proven wrong.
When board is in the development and testing phase, nobody is updating that page. We usually write there only known problems, what we are unable to solve or if something needs a workaround. In ideal world this board would get a dedicated maintainer, someone who would extract information from https://forum.armbian.com/topic/7511-nanopi-m4/ and keep a summary here: https://www.armbian.com/nanopi-m4

zdea wrote:
Btw... since I'm assuming you are "the IgorP" from Armbian... thank you for all the effort you and your crew have put in.
Yes, thank you. The crew is unfortunately far too small for the size of the project. It expanded quickly and now we struggle with maintaining it.
pavelectric wrote:
I'd love to see and try the clean kernel of Ubuntu 4.18. And at its base to assemble your own system.
We are waiting for the release of a good version of Ubuntu Core 18.04 with kernel 4.18, because there is a lot of potential on the M4 board.
Sincerely, Pavel.


This is probably the best (and only) Ubuntu that exists with the modern kernel:
https://dl.armbian.com/nanopim4/Ubuntu_ ... nightly.7z

It's amateur based development so it goes slow. Ubuntu or Rockchip are not doing anything in this regard.
It's amateur based development so it goes slow. Ubuntu or Rockchip are not doing anything in this regard.


So is it worth waiting for a "non-amateur solution"? Stable and fast core for this chip / board.
As I understand it, the RK3399 is not bad at all, on its basis almost all manufacturers have made ready-made boards.
And the board (M4) in the Raspbery factor is generally an ingenious development, because its dimensions are identical, which means it can be embedded instead of a slow and rather expensive board (I’m talking about RP).
And in fact, the request is quite real - to assemble a normal kernel, with all the drivers. And it will be bought by a large number of developers and just enthusiasts.

Sincerely, Pavel.
pavelectric wrote:
So is it worth waiting for a "non-amateur solution"? Stable and fast core for this chip / board.
Yes.

pavelectric wrote:
As I understand it, the RK3399 is not bad at all, on its basis almost all manufacturers have made ready-made boards.
And the board (M4) in the Raspbery factor is generally an ingenious development, because its dimensions are identical, which means it can be embedded instead of a slow and rather expensive board (I’m talking about RP).
Yes, its a nice board with great potential and already quite usable.

pavelectric wrote:
And in fact, the request is quite real - to assemble a normal kernel, with all the drivers. And it will be bought by a large number of developers and just enthusiasts.
I can't tell how much it will take. But this is usually measured in years once boards are out. And in thousands of hours spent for development, maintenance and support.
zdea wrote:
I'm also looking to install/use zfs and have been wrestling with the same problem. Tried both the FriendlyDesktop and lubuntu images and both seem to be stuck on 4.4.143 kernel and although I can use the ubuntu kernel upgrade utility to find and "install" different kernels none of them actually "work" in that I can't figure out how to switch to them (no bootloader access that I can figure out) and the zfs module is not available with this kernel nor can I compile it without kernel headers.
Torrent TurboTax Gogoanime
Frustrating. This hardware could be so good for nas storage. Hoping someone more familiar than I can crack this but I'll keep hacking at it.

I'm trying to install ZFS on my NanoPi M4 with the rk3399-sd-friendlycore-bionic-4.4-arm64-20180921.img Image.
zdea wrote:
I'm also looking to install/use zfs and have been wrestling with the same problem. Tried both the FriendlyDesktop and lubuntu images and both seem to be stuck on 4.4.143 kernel and although I can use the ubuntu kernel upgrade utility to find and "install" different kernels none of them actually "work" in that I can't figure out how to switch to them (no bootloader access that I can figure out) and the zfs module is not available with this kernel nor can I compile it without kernel headers.

Frustrating. This hardware could be so good for nas storage. Hoping someone more familiar than I can crack this but I'll keep hacking at it.
JAGITA wrote:
zdea wrote:
I'm also looking to install/use zfs and have been wrestling with the same problem. Tried both the FriendlyDesktop and lubuntu images and both seem to be stuck on 4.4.143 kernel and although I can use the ubuntu kernel upgrade utility to find and "install" different kernels none of them actually "work" in that I can't figure out how to switch to them (no bootloader access that I can figure out) and the zfs module is not available with this kernel nor can I compile it without kernel headers.

Frustrating. This hardware could be so good for nas storage. Hoping someone more familiar than I can crack this but I'll keep hacking at it.
JAGITA wrote:
JAGITA wrote:
zdea wrote:
I'm also looking to install/use zfs and have been wrestling with the same problem. Tried both the FriendlyDesktop and lubuntu images and both seem to be stuck on 4.4.143 kernel and although I can use the ubuntu kernel upgrade utility to find and "install" different kernels none of them actually "work" in that I can't figure out how to switch to them (no bootloader access that I can figure out) and the zfs module is not available with this kernel nor can I compile it without kernel headers.

Frustrating. This hardware could be so good for nas storage. Hoping someone more familiar than I can crack this but I'll keep hacking at it.


Why don't you simply try already recommended and working solution?
https://forum.armbian.com/topic/9326-ne ... erboard-s/

The exact same way goes on this board.
zdea wrote:
I'm also looking to install/use zfs and have been wrestling with the same problem. Tried both the FriendlyDesktop and lubuntu images and both seem to be stuck on 4.4.143 kernel and although I can use the ubuntu kernel upgrade utility to find and "install" different kernels none of them actually "work" in that I can't figure out how to switch to them (no bootloader access that I can figure out) and the zfs module is not available with this kernel nor can I compile it without kernel headers.

Frustrating. This hardware could be so good for nas storage. Hoping someone more familiar than I can crack this but I'll keep hacking at it.

It looks like i just need to install the kernel headers, but when i try apt says it couldn't find them.

Who is online

In total there is 1 user online :: 0 registered, 0 hidden and 1 guest (based on users active over the past 5 minutes)
Most users ever online was 825 on Wed Aug 28, 2019 3:18 pm

Users browsing this forum: No registered users and 1 guest