]> sourceware.org Git - lvm2.git/blame - udev/69-dm-lvm-metad.rules.in
man: document allocation process in lvm.8
[lvm2.git] / udev / 69-dm-lvm-metad.rules.in
CommitLineData
32c84c8f
PR
1# Copyright (C) 2012 Red Hat, Inc. All rights reserved.
2#
3# This file is part of LVM2.
4
5# Udev rules for LVM.
6#
7# Scan all block devices having a PV label for LVM metadata.
8# Store this information in LVMetaD (the LVM metadata daemon) and maintain LVM
9# metadata state for improved performance by avoiding further scans while
10# running subsequent LVM commands or while using lvm2app library.
11# Also, notify LVMetaD about any relevant block device removal.
12#
13# This rule is essential for having the information in LVMetaD up-to-date.
14# It also requires blkid to be called on block devices before so only devices
15# used as LVM PVs are processed (ID_FS_TYPE="LVM2_member" or "LVM1_member").
16
17SUBSYSTEM!="block", GOTO="lvm_end"
e6f8d864 18(LVM_EXEC_RULE)
32c84c8f
PR
19
20# Device-mapper devices are processed only on change event or on supported synthesized event.
21KERNEL=="dm-[0-9]*", ENV{DM_UDEV_RULES_VSN}!="?*", GOTO="lvm_end"
22
23# Only process devices already marked as a PV - this requires blkid to be called before.
d2df8ddd 24ENV{ID_FS_TYPE}=="LVM2_member|LVM1_member", RUN+="(LVM_EXEC)/lvm pvscan --cache --activate ay --major $major --minor $minor"
32c84c8f
PR
25
26LABEL="lvm_end"
This page took 0.026194 seconds and 5 git commands to generate.