64aea1c5b8
Add initramfs hook and the OpenRC service, seems to work fine so far. --HG-- extra : convert_revision : bfedf452f27339d9e37ffb251800431a17dbef9b
27 lines
417 B
Text
27 lines
417 B
Text
#!/sbin/runscript
|
|
#
|
|
# OpenRC service for LVM.
|
|
|
|
name="LVM service"
|
|
|
|
depend()
|
|
{
|
|
need devfs
|
|
before checkfs fsck
|
|
}
|
|
|
|
start()
|
|
{
|
|
ebegin "Activating LVM volumes"
|
|
modprobe -q dm-mod 2>/dev/null
|
|
lvm vgscan --ignorelockingfailure --mknodes && \
|
|
lvm vgchange --ignorelockingfailure -a y >/dev/null
|
|
eend $?
|
|
}
|
|
|
|
stop()
|
|
{
|
|
ebegin "Deactivating LVM volumes"
|
|
lvm vgchange --ignorelockingfailure -an 2>&1 >/dev/null
|
|
eend $?
|
|
}
|