Skip to content

Instantly share code, notes, and snippets.

@overdeliver
overdeliver / zfs-dkms-fix.sh
Created April 17, 2018 23:50 — forked from dominic-p/zfs-dkms-fix.sh
A simple script to automate rebuilding ZFS related DKMS modules after a kernel upgrade. USE WITH CAUTION.
#!/bin/sh
#
# --- zfs-dkms-fix.sh ---
#
# This script automates the process of fixing ZFS after a kernel
# update. See: https://github.com/zfsonlinux/zfs/issues/3801
###################################################################
# Get the current ZFS and SPL module versions
modversion=$(dkms status | cut -d , -f 2 | tail -n 1 | xargs)