From cd0b9c18b78dea8e6977330993b80baa7890b95b Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Thu, 8 Jan 2009 16:20:25 -0800 Subject: [PATCH] Update helper scripts --- scripts/Makefile.am | 3 +-- scripts/zfs.sh | 24 +++++++++++++++++------- 2 files changed, 18 insertions(+), 9 deletions(-) diff --git a/scripts/Makefile.am b/scripts/Makefile.am index daf6206542..4a58a484f0 100644 --- a/scripts/Makefile.am +++ b/scripts/Makefile.am @@ -1,5 +1,4 @@ -EXTRA_DIST = update-zfs.sh check.sh -EXTRA_DIST += load-zfs.sh unload-zfs.sh create-zpool.sh +EXTRA_DIST = update-zfs.sh check.sh zfs.sh create-zpool.sh check: ./check.sh diff --git a/scripts/zfs.sh b/scripts/zfs.sh index 80e86f8bc1..d724cad40d 100755 --- a/scripts/zfs.sh +++ b/scripts/zfs.sh @@ -1,6 +1,11 @@ #!/bin/bash +# +# A simple script to simply the loading/unloading the ZFS module +# stack. It should probably be considered a first step towards +# a full ZFS init script when that is needed. +# -prog=load-zfs.sh +prog=zfs.sh . ../.script-config KMOD=/lib/modules/${KERNELSRCVER}/kernel @@ -38,15 +43,20 @@ die() { usage() { cat << EOF -usage: $0 [hvu] [module-options] +USAGE: +$0 [hvud] [module-options] + +DESCRIPTION: + Load/unload the ZFS module stack. OPTIONS: - -h Show this message - -v Verbose - -u Unload modules - -d Save debug log on unload + -h Show this message + -v Verbose + -u Unload modules + -d Save debug log on unload -MODULE-OPTIONS: Must be of the frm module="options", for example: +MODULE-OPTIONS: + Must be of the frm module="options", for example: $0 zpool="zfs_prefetch_disable=1" $0 zpool="zfs_prefetch_disable=1 zfs_mdcomp_disable=1"