-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Previously, loop devices for LVM volume groups backing files were not created after reboots, causing e.g. Cinder to fail with messages such as ERROR cinder.service [-] Manager for service cinder-volume devstack@lvmdriver-1 is reporting problems, not sending heartbeat. Service will appear "down". Now, we use systemd services to manage loop devices for backing files. Change-Id: I27ec027834966e44aa9a99999358f5b4debc43e0
- Loading branch information
Showing
2 changed files
with
43 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
[Unit] | ||
Description=Activate LVM backing file %BACKING_FILE% | ||
DefaultDependencies=no | ||
After=systemd-udev-settle.service | ||
Before=lvm2-activation-early.service | ||
Wants=systemd-udev-settle.service | ||
|
||
[Service] | ||
ExecStart=/sbin/losetup --find --show %DIRECTIO% %BACKING_FILE% | ||
ExecStop=/bin/sh -c '/sbin/losetup -d $$(/sbin/losetup --associated %BACKING_FILE% -O NAME -n)' | ||
RemainAfterExit=yes | ||
Type=oneshot | ||
|
||
[Install] | ||
WantedBy=local-fs.target | ||
Also=systemd-udev-settle.service |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters