zpool (90802d88a57c6c86b4d48bbee8d14ed2fc80c107) zpool (f30f11f878fe2aa535cd286810d31c92793a3d95)
1#!/bin/sh
2#
3# $FreeBSD$
4#
5
6# PROVIDE: zpool
7# REQUIRE: hostid disks
8# BEFORE: mountcritlocal

--- 8 unchanged lines hidden (view full) ---

17required_modules="zfs"
18
19zpool_start()
20{
21 local cachefile
22
23 for cachefile in /etc/zfs/zpool.cache /boot/zfs/zpool.cache; do
24 if [ -r $cachefile ]; then
1#!/bin/sh
2#
3# $FreeBSD$
4#
5
6# PROVIDE: zpool
7# REQUIRE: hostid disks
8# BEFORE: mountcritlocal

--- 8 unchanged lines hidden (view full) ---

17required_modules="zfs"
18
19zpool_start()
20{
21 local cachefile
22
23 for cachefile in /etc/zfs/zpool.cache /boot/zfs/zpool.cache; do
24 if [ -r $cachefile ]; then
25 zpool import -c $cachefile -a -N && break
25 zpool import -c $cachefile -a -N
26 if [ $? -ne 0 ]; then
27 echo "Import of zpool cache ${cachefile} failed," \
28 "will retry after root mount hold release"
29 root_hold_wait
30 zpool import -c $cachefile -a -N
31 fi
32 break
26 fi
27 done
28}
29
30load_rc_config $name
31run_rc_command "$1"
33 fi
34 done
35}
36
37load_rc_config $name
38run_rc_command "$1"