blob: 3ec8d1cc285cc38225781d64e1441a578b86cd69 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
#!/sbin/runscript
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sys-fs/multipath-tools/files/init.d-multipath-0.4.8-r1,v 1.1 2009/10/30 06:50:11 robbat2 Exp $
# Existence of this file means we are on baselayout 2.
check_bl2_file='/etc/init.d/sysfs'
depend() {
if [ -e ${check_bl2_file} ]; then
# on baselayout-1 this causes
# dependency-cycles with checkroot (before *)
before checkfs fsck multipathd lvm
after modules device-mapper
fi
}
# Once we are ready to stop baselayout1 support, we can just merge the addons
# into here.
run_addon() {
local f=/lib/rcscripts/addons/$1.sh
if [ -r "$f" ]; then
( . "$f" )
fi
}
start() {
if [ ! -e ${check_bl2_file} ]; then
eerror "The $SVCNAME init-script is written for baselayout-2!"
eerror "Please do not use it with baselayout-1!".
return 1
fi
run_addon multipath-start
}
stop() {
run_addon multipath-stop
}
# vim:ts=4
|