mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-15 14:26:33 +01:00
cd1023c50d
* Added sis support for xserver. svn path=/nixos/trunk/; revision=8924
30 lines
551 B
Nix
30 lines
551 B
Nix
{modprobe, lvm2, devicemapper}:
|
|
|
|
{
|
|
name = "lvm";
|
|
|
|
job = "
|
|
start on udev
|
|
#start on new-devices
|
|
|
|
script
|
|
|
|
# Load the device mapper.
|
|
${modprobe}/sbin/modprobe dm_mod || true
|
|
|
|
${devicemapper}/sbin/dmsetup mknodes
|
|
# Scan for block devices that might contain LVM physical volumes
|
|
# and volume groups.
|
|
${lvm2}/sbin/vgscan --mknodes
|
|
|
|
# Make all logical volumes on all volume groups available, i.e.,
|
|
# make them appear in /dev.
|
|
${lvm2}/sbin/vgchange --available y
|
|
|
|
initctl emit new-devices
|
|
|
|
end script
|
|
|
|
";
|
|
|
|
}
|