ZFS plugin for unRAID


steini84

826 posts in this topic Last Reply

Recommended Posts

  • 2 weeks later...
  • Replies 825
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Popular Posts

What is this? This plugin is a build of ZFS on Linux for unRAID 6   Installation of the plugin To install you copy the URL below into the install plugin page in your unRAID 6 web g

Built zfs-2.0.0-rc7 for unRAID-6.8.3 & 6.9.0-beta35   Great to see that unRAID is finally adding native ZFS so this might be one of the last builds from me   And yes, i´m alre

Figured it out. No need to mount through /etc/fstab.   What's missing are entries in /etc/mtab,  which are created if mounted from fstab. So a few echo into /etc/mtab is the solution. J

Posted Images

The update is available now.

 

Here is a rough guide on how to compile it your self:

 

First off download this awesome script from gfjardim

wget https://gist.githubusercontent.com/gfjardim/c18d782c3e9aa30837ff/raw/224264b305a56f85f08112a4ca16e3d59d45d6be/build.sh

Change this line from:
LINK="https://www.kernel.org/pub/linux/kernel/v3.x/linux-${KERNEL}.tar.xz"
to 
LINK="https://www.kernel.org/pub/linux/kernel/v4.x/linux-${KERNEL}.tar.xz

using:
nano build.sh
then make it executable
chmod +x build.sh

run it with 
./build.sh

answer 1, 2 & 3 with Y
answer 3.1, 3.2 with N
answer 3.3 with Y
answer 4 and 6 with N

then make the modules that are needed:
cd kernel
make modules

Then we need to build some dependencies

#Libuuid
wget "http://downloads.sourceforge.net/project/libuuid/libuuid-1.0.3.tar.gz?r=http%3A%2F%2Fsourceforge.net%2Fprojects%2Flibuuid%2F&ts=1453068148&use_mirror=skylink"
tar -xvf libuuid*
cd libuuid-1.0.3
./configure
make 
make install

#Zlib
wget http://zlib.net/zlib-1.2.8.tar.gz
tar -xvf zlib-1.2.8.tar.gz
cd zlib-1.2.8
./configure
make 
make install

Then we build zfs and spl

First download the latest zfs and spl from zfsonlinux.org

wget http://archive.zfsonlinux.org/downloads/zfsonlinux/spl/spl-0.6.5.4.tar.gz
tar -xvf spl-0.6.5.4.tar.gz
cd spl-0.6.5.4

./configure --prefix=/usr
make
make install DESTDIR=$(pwd)/PACKAGE
cd $(pwd)/PACKAGE
makepkg -l y -c n ../spl.tgz
installpkg ../spl.tgz

load the module

depmod
modprobe spl

Same for zfs
wget http://archive.zfsonlinux.org/downloads/zfsonlinux/zfs/zfs-0.6.5.4.tar.gz
tar -xvf zfs-0.6.5.4.tar.gz
cd zfs-0.6.5.4

./configure --prefix=/usr
make
make install DESTDIR=$(pwd)/PACKAGE
cd $(pwd)/PACKAGE
makepkg -l y -c n ../zfs.tgz
installpkg ../zfs.tgz

depmod
modprobe zfs

Link to post

something has changed in unRAID and the zpool command is not found in the path during startup and fails.  Plugin will have to be change to call zpool using a direct path instead.

 

I had to shutdown my array, and do the zpool -a manually to get it to come back up to have access to my dockers/vms.  upon restarting the array everything was working again....

 

 

Another thing I notice is the upgrade part of the script is not removing all the older packages so they are building up on the flash drive

 

Thanks

Myk

 

Link to post

something has changed in unRAID and the zpool command is not found in the path during startup and fails.  Plugin will have to be change to call zpool using a direct path instead.

 

I had to shutdown my array, and do the zpool -a manually to get it to come back up to have access to my dockers/vms.  upon restarting the array everything was working again....

 

 

Another thing I notice is the upgrade part of the script is not removing all the older packages so they are building up on the flash drive

 

Thanks

Myk

 

Please test the new version and let me know

Link to post

I have been waiting a LONG time for this combo.

 

Seeing this Plug-in with the new features of unRaid 6, I'm now ready to buy a pro key and go to town. I can actually make my storage server (which does pretty much nothing 90% of the time), move all my lower CPU Powered VMs and physical machines (Plex, pfSesnse, ect) and sell my other servers and recoup the costs while having a simpler setup.

 

unRaid6 + ZoL = Profit!

 

Why is BTRFS there but not ZoL!?

 

LimeTech... Give the customer what it wants and they will come.

Link to post
  • 3 weeks later...
  • 4 weeks later...

Updated for 6.2.0-beta18 (kernel 4.4.4)

 

I also made the plugin compatible with versions 6.1.2 - 6.2.0-beta18

 

The only downside is that you need to keep every version of the tgz files (around 50mb now).

 

If someone knows how I can make the plugin download files (using the build in plugin downloader+md5 checker) based on a kernel version a PM would be greatly appreciated :) .. if not I guess I could always do everything in bash, but do not have time for that right now

Link to post

Updated for 6.2.0-beta18 (kernel 4.4.4)

 

I also made the plugin compatible with versions 6.1.2 - 6.2.0-beta18

 

The only downside is that you need to keep every version of the tgz files (around 50mb now).

 

If someone knows how I can make the plugin download files (using the build in plugin downloader+md5 checker) based on a kernel version a PM would be greatly appreciated :) .. if not I guess I could always do everything in bash, but do not have time for that right now

 

# source unRAID version
. /etc/unraid-version

download_install() {
  local dest="&plugin;/packages/${1}"
  local src="&repo;/packages/${1}"
  local md5=$2
  if [ ! -f "${dest}" ]; then
    curl --location --silent --fail "${src}" --output "${dest}"
  fi
  file_md5=$(/usr/bin/md5sum ${dest})
  if [ "${file_md5:0:32}" != "${md5:0:32}" ]; then
    echo "Wrong '${1}' package md5 hash."
    rm "${dest}"
    exit 1
  else
    /sbin/installpkg "$dest"
  fi
}

if [ "$version" == "6.2.0-beta18" ]; then
  spl_pkg="spl-0.6.5.5-unRAID6.2.0-beta18.x86_64.tgz"
  spl_md5="6bab826e24b0c3ccc08b962e8a64058c"
  zfs_pkg="zfs-0.6.5.5-unRAID6.2.0-beta18.x86_64.tgz"
  zfs_md5="1ee9e5c1d85155ef87138aaee78aefb6"

elif [ "$version" == "6.1.9" ]; then
  spl_pkg="spl-0.6.5.4-unRAID6.1.9.x86_64.tgz"
  spl_md5="ef09a51f6fcc069ad4897b5e06088d00"
  zfs_pkg="zfs-0.6.5.4-unRAID6.1.9.x86_64.tgz"
  zfs_md5="74ee8f3698cd6f64839bcdf09abe5534"

elif [ "$version" == "6.1.8" ]; then
  spl_pkg="spl-0.6.5.4-unRAID6.1.8.x86_64.tgz"
  spl_md5="3ef7a7eb63bac07475dc7e9eee5132c5"
  zfs_pkg="zfs-0.6.5.4-unRAID6.1.8.x86_64.tgz"
  zfs_md5="ae2c5bd933f1376b52a73a07862db2bc"

elif [ "$version" == "6.1.7" ]; then
  spl_pkg="spl-0.6.5.4-unRAID6.1.7.x86_64.tgz"
  spl_md5="288b0b4c242fe947f41a2a4a1f731982"
  zfs_pkg="zfs-0.6.5.4-unRAID.1.7.x86_64.tgz"
  zfs_md5="57e386538e4726dd222c8bd682975705"

elif [ "$version" == "6.1.4" ]; then
  spl_pkg="spl-0.6.5.3-unRAID6.1.4.x86_64.tgz"
  spl_md5="41700aaec22f70d2ae257544d6f53695"
  zfs_pkg="zfs-0.6.5.3-unRAID6.1.4.x86_64.tgz"
  zfs_md5="31b8ee8c406f211a78c7dbf56ba2609e"

elif [ "$version" == "6.1.3" ]; then
  spl_pkg="spl-0.6.5.3-unRAID6.1.3.x86_64.tgz"
  spl_md5="8b0c880280b722fb1948dd9d0e3362b9"
  zfs_pkg="zfs-0.6.5.3-unRAID6.1.3.x86_64.tgz"
  zfs_md5="33401b97ae99a5f17aef4524bd5122cc"

elif [ "$version" == "6.1.2" ]; then
  spl_pkg="spl-0.6.5.1-unRAID6.1.2.x86_64.tgz"
  spl_md5="644f7c6a682b6b9d607f5a7337205d16"
  zfs_pkg="zfs-0.6.5.1-unRAID6.1.2.x86_64.tgz"
  zfs_md5="cdefbb81f0de70cdb876a4625abb4c88"
else
  exit 1
fi

download_install "${spl_pkg}" "${spl_md5}"
download_install "${zfs_pkg}" "${zfs_md5}"

 

 

Link to post
  • 3 weeks later...
  • 2 months later...
  • 1 month later...
  • 1 month later...

There are really good performance tests over at http://www.phoronix.com/ but for me it's more about stability and usability (snapshots replication etc that fits my workflow)

 

When unRaid is updated you have to wait for a plugin update. I try to update the plugin as fast as I can, but sometimes it can be a couple of days. If you accidentally update the worst thing that happens is that your Zfs pool won't be imported and the data the won't be accessible until a plugin update is pushed. In my setup that would mean all my dockers and vms.

 

I wanted to wait for 6.1 final before writing a complete how to for Zfs on unRaid, but if there was any interest I could get on that right away.

 

 

Sent from my iPhone using Tapatalk

Link to post

 

I wanted to wait for 6.1 final before writing a complete how to for Zfs on unRaid, but if there was any interest I could get on that right away.

 

 

Sent from my iPhone using Tapatalk

6.1.9 final was released many moons ago  ;)

Link to post

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.