From: Richard Yao Date: Tue, 3 Apr 2012 04:21:22 +0000 (-0400) Subject: Make Gentoo initscript use modinfo X-Git-Url: https://git.camperquake.de/gitweb.cgi?a=commitdiff_plain;h=2ce9d0ec61706e56abd4c56fe78bfe11365ad130;p=zfs.git Make Gentoo initscript use modinfo The -l parameter to modprobe has been removed from the latest upstream code and this change has entered Gentoo. Using modinfo as a substitute addresses this. Signed-off-by: Brian Behlendorf Closes #636 --- diff --git a/etc/init.d/zfs.gentoo.in b/etc/init.d/zfs.gentoo.in index 767aba8..957be99 100644 --- a/etc/init.d/zfs.gentoo.in +++ b/etc/init.d/zfs.gentoo.in @@ -19,7 +19,7 @@ ZFS_MODULE=zfs checksystem() { if [ ! -c /dev/zfs ]; then einfo "Checking if ZFS modules present" - if [ "x$(modprobe -l $ZFS_MODULE | grep $ZFS_MODULE)" == "x" ]; then + if ! modinfo zfs > /dev/null 2>&1 ; then eerror "$ZFS_MODULE not found. Is the ZFS package installed?" return 1 fi