Changes

Jump to: navigation, search

Orange Pi CM4

1,677 bytes added, 14:20, 19 September 2023
How to install ZFS
=== How to install ZFS ===
{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big>'''Before installing zfs, please make sure that the Linux image used is the latest version. In addition, if zfs is already installed in the system, it needs to be installed again.'''</big>|}
Before installing zfs, you need to install the kernel header file first. For the method of installing the kernel header file, please refer to the instructions in the [[\lOrange Pi CM4#How to install kernel header files|'''section on the method of installing the kernel header file''']].
In Ubuntu20.04, Ubuntu22.04 and Debian11 systems, zfs cannot be installed directly through apt, because the default apt source zfs version is lower than 2.1.6, and there is a problem of incompatibility with rk Linux5.10 kernel. This problem is fixed in zfs version 2.1.6 and later.
</div>
After downloading the zfs deb packages of the corresponding version, please upload them to the Linux system of the development board. For the upload method, please refer to '''[[\lOrange Pi CM4#Method of uploading files to the development board Linux system|the description in the section of the method of uploading files to the Linux system of the development board]].'''
After the upload is complete, use the '''cd''' command in the command line of the development board Linux system to enter the directory of the deb package, and then use the following command to install the deb package of zfs.
{| class="wikitable" style="width:800px;"
|-
|
orangepi@orangepi:~$ '''sudo apt install ./*.deb'''
|}
After the installation is complete, use the following command to see the zfs-related kernel modules:
{| class="wikitable" style="width:800px;"
|-
|
orangepi@orangepi:~$ '''ls /lib/modules/5.10.160-rockchip-rk356x/updates/dkms/'''
'''icp.ko spl.ko zavl.ko zcommon.ko zfs.ko zlua.ko znvpair.ko zunicode.ko zzstd.ko'''
|}
Then restart the Linux system to see that the zfs kernel module will be automatically loaded:
{| class="wikitable" style="width:800px;" |-| orangepi@orangepi:~$ '''lsmod | grep &quot;"zfs&quot;"'''
zfs &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2801664 &nbsp;&nbsp;&nbsp; 0
zunicode &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs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bsp; 6 &nbsp; zfs,icp,zzstd,znvpair,zcommon,zavl|}
In Debian12, the default version of zfs is 2.1.11, so we can install zfs directly through the following command. Again, please make sure that the system has installed the deb package of the kernel header file before installation.
{| class="wikitable" style="width:800px;"
|-
|
orangepi@orangepi:~$ '''sudo apt install -y zfsutils-linux zfs-dkms'''
|}
<span id="methods-of-creating-zfs-pools"></span>
 
=== Methods of creating ZFS pools ===

Navigation menu