summaryrefslogtreecommitdiff
path: root/etc/rc.d/lvmlockdir
blob: 705e039c67416604e10c0325a4529b821be0e200 (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
#!/bin/sh
#
# $NetBSD: lvmlockdir,v 1.1 2021/01/26 13:31:19 martin Exp $
#

# REQUIRE: mountcritlocal
# BEFORE: CRITLOCALMOUNTED

$_rc_subr_loaded . /etc/rc.subr

name="lvmlockdir"
start_cmd="lvmlockdir_start"
stop_cmd=":"

lvmlockdir_start()
{
	#       create LVM locking directory, it needs to be owned by operator
	#	group and has parmissions to allow lock file creation.
	#
	mkdir -p /var/run/lvm
	chown root:operator /var/run/lvm
	chmod 770 /var/run/lvm
	return 0
}

load_rc_config $name
run_rc_command "$1"