[Unit] Description = False After = systemd-udev-settle.service Before = lvm2-activation-early.service Wants = systemd-udev-settle.service [Service] Type = oneshot User = root Group = root ExecStart = /bin/bash -c "/sbin/losetup $(/sbin/losetup -f) /openstack/cinder.img" ExecStart = /sbin/pvscan ExecStop = /bin/bash -c "losetup -d $(losetup -l | awk '/cinder.img/ {print $1}')" # Give a reasonable amount of time for the server to start up/shut down TimeoutSec = 120 # This creates a specific slice which all services will operate from # The accounting options give us the ability to see resource usage through # the `systemd-cgtop` command. Slice = system.slice # Set Accounting CPUAccounting = True BlockIOAccounting = True MemoryAccounting = True TasksAccounting = True RemainAfterExit = True [Install] WantedBy = multi-user.target