Comment 7 for bug 1431107

Revision history for this message
Michael Marley (mamarley) wrote : Re: ordering cycles with early boot images on lvm2.service

OK, here it is:

michael@mamarley-laptop:~$ cat /etc/init.d/lvm2
#!/bin/sh
### BEGIN INIT INFO
# Provides: lvm2 lvm
# Required-Start: mountdevsubfs
# Required-Stop:
# Should-Start: udev mdadm-raid cryptdisks-early multipath-tools-boot
# Should-Stop: umountroot mdadm-raid
# X-Start-Before: checkfs mountall
# X-Stop-After: umountfs
# Default-Start: S
# Default-Stop:
### END INIT INFO

# dummy job, Ubuntu does LVM setup in udev rules, so starting udev is enough
true

michael@mamarley-laptop:~$ systemctl show lvm2 | grep Path
FragmentPath=/run/systemd/generator.late/lvm2.service
SourcePath=/etc/init.d/lvm2

michael@mamarley-laptop:~$ cat /run/systemd/generator.late/lvm2.service
# Automatically generated by systemd-sysv-generator

[Unit]
Documentation=man:systemd-sysv-generator(8)
SourcePath=/etc/init.d/lvm2
Description=(null)
Before=runlevel2.target runlevel3.target runlevel4.target runlevel5.target shutdown.target checkfs.service local-fs.target
After=mountdevsubfs.service udev.service mdadm-raid.service cryptdisks-early.service multipath-tools-boot.service
Conflicts=shutdown.target

[Service]
Type=forking
Restart=no
TimeoutSec=5min
IgnoreSIGPIPE=no
KillMode=process
GuessMainPID=no
RemainAfterExit=yes
ExecStart=/etc/init.d/lvm2 start
ExecStop=/etc/init.d/lvm2 stop