Deleted Added
full compact
gbde (132356) gbde (136193)
1#!/bin/sh
2#
3# This file, originally written by Garrett A. Wollman, is in the public
4# domain.
5#
1#!/bin/sh
2#
3# This file, originally written by Garrett A. Wollman, is in the public
4# domain.
5#
6# $FreeBSD: head/etc/rc.d/gbde 132356 2004-07-18 18:01:48Z simon $
6# $FreeBSD: head/etc/rc.d/gbde 136193 2004-10-06 14:42:35Z pjd $
7#
8
9# PROVIDE: disks
10# KEYWORD: FreeBSD nojail
11
12. /etc/rc.subr
13
14name="gbde"

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

77}
78
79gbde_start()
80{
81 for device in $gbde_devices; do
82 parentdev=${device%.bde}
83 parent=${parentdev#/dev/}
84 eval "lock=\${gbde_lock_${parent}-\"${gbde_lockdir}/${parent}.lock\"}"
7#
8
9# PROVIDE: disks
10# KEYWORD: FreeBSD nojail
11
12. /etc/rc.subr
13
14name="gbde"

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

77}
78
79gbde_start()
80{
81 for device in $gbde_devices; do
82 parentdev=${device%.bde}
83 parent=${parentdev#/dev/}
84 eval "lock=\${gbde_lock_${parent}-\"${gbde_lockdir}/${parent}.lock\"}"
85 if [ -e "${lock}" -a ! -e "${device}" ]; then
85 if [ ! -e "${device}" ]; then
86 echo "Configuring Disk Encryption for ${device}."
87
88 count=1
89 while [ ${count} -le ${gbde_attach_attempts} ]; do
86 echo "Configuring Disk Encryption for ${device}."
87
88 count=1
89 while [ ${count} -le ${gbde_attach_attempts} ]; do
90 gbde attach ${parentdev} -l ${lock}
90 if [ -e "${lock}" ]; then
91 gbde attach ${parentdev} -l ${lock}
92 else
93 gbde attach ${parentdev}
94 fi
91 if [ -e ${device} ]; then
92 break
93 fi
94 echo "Attach failed; attempt ${count} of ${gbde_attach_attempts}."
95 count=$((${count} + 1))
96 done
97
98 fi

--- 13 unchanged lines hidden ---
95 if [ -e ${device} ]; then
96 break
97 fi
98 echo "Attach failed; attempt ${count} of ${gbde_attach_attempts}."
99 count=$((${count} + 1))
100 done
101
102 fi

--- 13 unchanged lines hidden ---