]> TLD Linux GIT Repositories - packages/dracut.git/commitdiff
- remove systemd stuff completly, cleanup
authorMarcin Krol <hawk@tld-linux.org>
Sat, 21 Jul 2018 20:53:31 +0000 (20:53 +0000)
committerMarcin Krol <hawk@tld-linux.org>
Sat, 21 Jul 2018 20:53:31 +0000 (20:53 +0000)
dracut.spec
no_systemd.patch [new file with mode: 0644]
no_systemd_udevd.patch [deleted file]

index 1e73810ef02a5f659e06e3a21ff6fd2402ff63cc..82010e183756e287a1e5eee1715a61ca2e44b144 100644 (file)
@@ -16,7 +16,7 @@ Patch4:               compressors.patch
 Patch5:                proc_sys_remount.patch
 Patch6:                misc_fixes.patch
 Patch7:                initrd-release.patch
-Patch8:                no_systemd_udevd.patch
+Patch8:                no_systemd.patch
 Patch9:                crypttab-keyscript.patch
 URL:           https://dracut.wiki.kernel.org/
 BuildRequires: asciidoc
@@ -224,11 +224,16 @@ ln -s %{_bindir}/dracut $RPM_BUILD_ROOT/sbin/dracut
 # SuSE specific man page
 %{__rm} $RPM_BUILD_ROOT%{_mandir}/man8/mkinitrd-suse.8
 
-# remove systemd stuff
-%{__rm} -r $RPM_BUILD_ROOT%{dracutlibdir}/modules.d/{00systemd,01systemd-initrd,02systemd-networkd,98dracut-systemd}
+# remove systemd and related stuff
+%{__rm} -r $RPM_BUILD_ROOT%{dracutlibdir}/modules.d/{00systemd,01systemd-initrd,02systemd-networkd,80lvmmerge,98dracut-systemd}
 %{__rm} $RPM_BUILD_ROOT%{dracutlibdir}/modules.d/{90multipath/multipathd,90dmsquash-live/checkisomd5@,90stratis/stratisd-init}.service
 %{__rm} $RPM_BUILD_ROOT%{_mandir}/man8/dracut-*.service.8
 
+# remove other, uncesessary stuff
+%{__rm} -r $RPM_BUILD_ROOT%{dracutlibdir}/modules.d/91zipl
+%{__rm} -r $RPM_BUILD_ROOT/usr/lib/kernel/install.d/50-dracut.install
+%{__rm} -r $RPM_BUILD_ROOT/usr/lib/kernel/install.d/51-dracut-rescue.install
+
 %clean
 rm -rf $RPM_BUILD_ROOT
 
@@ -279,9 +284,6 @@ rm -rf $RPM_BUILD_ROOT
 %attr(755,root,root) %{dracutlibdir}/modules.d/50plymouth/*.sh
 %dir %{dracutlibdir}/modules.d/80cms
 %attr(755,root,root) %{dracutlibdir}/modules.d/80cms/*.sh
-%dir %{dracutlibdir}/modules.d/80lvmmerge
-%{dracutlibdir}/modules.d/80lvmmerge/README.md
-%attr(755,root,root) %{dracutlibdir}/modules.d/80lvmmerge/*.sh
 %dir %{dracutlibdir}/modules.d/81cio_ignore
 %attr(755,root,root) %{dracutlibdir}/modules.d/81cio_ignore/*.sh
 %dir %{dracutlibdir}/modules.d/90btrfs
@@ -318,8 +320,6 @@ rm -rf $RPM_BUILD_ROOT
 %attr(755,root,root) %{dracutlibdir}/modules.d/91crypt-gpg/*.sh
 %dir %{dracutlibdir}/modules.d/91crypt-loop
 %attr(755,root,root) %{dracutlibdir}/modules.d/91crypt-loop/*.sh
-%dir %{dracutlibdir}/modules.d/91zipl
-%attr(755,root,root) %{dracutlibdir}/modules.d/91zipl/*.sh
 %dir %{dracutlibdir}/modules.d/95dcssblk
 %attr(755,root,root) %{dracutlibdir}/modules.d/95dcssblk/*.sh
 %dir %{dracutlibdir}/modules.d/95debug
@@ -402,9 +402,6 @@ rm -rf $RPM_BUILD_ROOT
 %{_mandir}/man8/dracut.8*
 %{_mandir}/man8/mkinitrd.8*
 
-#/usr/lib/kernel/install.d/50-dracut.install
-#/usr/lib/kernel/install.d/51-dracut-rescue.install
-
 %files network
 %defattr(644,root,root,755)
 %dir %{dracutlibdir}/modules.d/40network
diff --git a/no_systemd.patch b/no_systemd.patch
new file mode 100644 (file)
index 0000000..3f1a4de
--- /dev/null
@@ -0,0 +1,1554 @@
+diff -urpa dracut-048.orig/dracut-logger.sh dracut-048/dracut-logger.sh
+--- dracut-048.orig/dracut-logger.sh   2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/dracut-logger.sh        2018-07-21 20:26:36.646212790 +0000
+@@ -144,16 +144,7 @@ dlog_init() {
+     fi
+     if (( $sysloglvl > 0 )); then
+-        if [[ -d /run/systemd/journal ]] \
+-            && type -P systemd-cat &>/dev/null \
+-            && systemctl --quiet is-active systemd-journald.socket &>/dev/null \
+-            && { echo "dracut-$DRACUT_VERSION" | systemd-cat -t 'dracut' &>/dev/null; } ; then
+-            readonly _systemdcatfile="$DRACUT_TMPDIR/systemd-cat"
+-            mkfifo "$_systemdcatfile"
+-            readonly _dlogfd=15
+-            systemd-cat -t 'dracut' --level-prefix=true <"$_systemdcatfile" &
+-            exec 15>"$_systemdcatfile"
+-        elif ! [ -S /dev/log -a -w /dev/log ] || ! command -v logger >/dev/null; then
++        if ! [ -S /dev/log -a -w /dev/log ] || ! command -v logger >/dev/null; then
+             # We cannot log to syslog, so turn this facility off.
+             kmsgloglvl=$sysloglvl
+             sysloglvl=0
+diff -urpa dracut-048.orig/dracut.sh dracut-048/dracut.sh
+--- dracut-048.orig/dracut.sh  2018-07-21 20:22:15.812228337 +0000
++++ dracut-048/dracut.sh       2018-07-21 20:45:51.059143982 +0000
+@@ -1077,8 +1077,7 @@ if [[ ! $print_cmdline ]]; then
+         if ! [[ -s $uefi_stub ]]; then
+             for uefi_stub in \
+-                "${systemdutildir}/boot/efi/linux${EFI_MACHINE_TYPE_NAME}.efi.stub" \
+-                    "/usr/lib/gummiboot/linux${EFI_MACHINE_TYPE_NAME}.efi.stub"; do
++                "/usr/lib/gummiboot/linux${EFI_MACHINE_TYPE_NAME}.efi.stub"; do
+                 [[ -s $uefi_stub ]] || continue
+                 break
+             done
+@@ -1319,32 +1318,6 @@ if ! [[ -d "$udevdir" ]]; then
+     [[ -e /usr/lib/udev/collect ]] && udevdir=/usr/lib/udev
+ fi
+-[[ -d $systemdutildir ]] \
+-    || systemdutildir=$(pkg-config systemd --variable=systemdutildir 2>/dev/null)
+-
+-if ! [[ -d "$systemdutildir" ]]; then
+-    [[ -e /lib/systemd/systemd-udevd ]] && systemdutildir=/lib/systemd
+-    [[ -e /usr/lib/systemd/systemd-udevd ]] && systemdutildir=/usr/lib/systemd
+-fi
+-
+-[[ -d $systemdsystemunitdir ]] \
+-    || systemdsystemunitdir=$(pkg-config systemd --variable=systemdsystemunitdir 2>/dev/null)
+-
+-[[ -d "$systemdsystemunitdir" ]] || systemdsystemunitdir=${systemdutildir}/system
+-
+-[[ -d $systemdsystemconfdir ]] \
+-    || systemdsystemconfdir=$(pkg-config systemd --variable=systemdsystemconfdir 2>/dev/null)
+-
+-[[ -d "$systemdsystemconfdir" ]] || systemdsystemconfdir=/etc/systemd/system
+-
+-[[ -d $tmpfilesdir ]] \
+-    || tmpfilesdir=$(pkg-config systemd --variable=tmpfilesdir 2>/dev/null)
+-
+-if ! [[ -d "$tmpfilesdir" ]]; then
+-    [[ -d /lib/tmpfiles.d ]] && tmpfilesdir=/lib/tmpfiles.d
+-    [[ -d /usr/lib/tmpfiles.d ]] && tmpfilesdir=/usr/lib/tmpfiles.d
+-fi
+-
+ export initdir dracutbasedir \
+     dracutmodules force_add_dracutmodules add_dracutmodules omit_dracutmodules \
+     mods_to_load \
+@@ -1354,9 +1327,7 @@ export initdir dracutbasedir \
+     stdloglvl sysloglvl fileloglvl kmsgloglvl logfile \
+     debug host_fs_types host_devs swap_devs sshkey add_fstab \
+     DRACUT_VERSION udevdir prefix filesystems drivers \
+-    systemdutildir systemdsystemunitdir systemdsystemconfdir \
+-    hostonly_cmdline loginstall \
+-    tmpfilesdir
++    hostonly_cmdline loginstall
+ mods_to_load=""
+ # check all our modules to see if they should be sourced.
+@@ -1558,17 +1529,6 @@ if [[ $kernel_only != yes ]]; then
+         cat "$f" >> "${initdir}/etc/fstab"
+     done
+-    if [[ $systemdutildir ]]; then
+-        if [ -d ${initdir}/$systemdutildir ]; then
+-            mkdir -p ${initdir}/etc/conf.d
+-            {
+-                printf "%s\n" "systemdutildir=\"$systemdutildir\""
+-                printf "%s\n" "systemdsystemunitdir=\"$systemdsystemunitdir\""
+-                printf "%s\n" "systemdsystemconfdir=\"$systemdsystemconfdir\""
+-            } > ${initdir}/etc/conf.d/systemd.conf
+-        fi
+-    fi
+-
+     if [[ $DRACUT_RESOLVE_LAZY ]] && [[ $DRACUT_INSTALL ]]; then
+         dinfo "*** Resolving executable dependencies ***"
+         find "$initdir" -type f -perm /0111 -not -path '*.ko' -print0 \
+@@ -1849,23 +1809,4 @@ fi
+ command -v restorecon &>/dev/null && restorecon -- "$outfile"
+-# We sync/fsfreeze only if we're operating on a live booted system.
+-# It's possible for e.g. `kernel` to be installed as an RPM BuildRequires or equivalent,
+-# and there's no reason to sync, and *definitely* no reason to fsfreeze.
+-# Another case where this happens is rpm-ostree, which performs its own sync/fsfreeze
+-# globally.  See e.g. https://github.com/ostreedev/ostree/commit/8642ef5ab3fec3ac8eb8f193054852f83a8bc4d0
+-if test -d /run/systemd/system; then
+-    if ! sync "$outfile" 2> /dev/null; then
+-        dinfo "dracut: sync operation on newly created initramfs $outfile failed"
+-        exit 1
+-    fi
+-
+-    # use fsfreeze only if we're not writing to /
+-    if [[ "$(stat -c %m -- "$outfile")" != "/" && "$(stat -f -c %T -- "$outfile")" != "msdos" ]]; then
+-        if ! $(fsfreeze -f $(dirname "$outfile") 2>/dev/null && fsfreeze -u $(dirname "$outfile") 2>/dev/null); then
+-            dinfo "dracut: warning: could not fsfreeze $(dirname "$outfile")"
+-        fi
+-    fi
+-fi
+-
+ exit 0
+diff -urpa dracut-048.orig/modules.d/02caps/module-setup.sh dracut-048/modules.d/02caps/module-setup.sh
+--- dracut-048.orig/modules.d/02caps/module-setup.sh   2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/02caps/module-setup.sh        2018-07-21 20:22:31.907227377 +0000
+@@ -13,13 +13,9 @@ depends() {
+ # called by dracut
+ install() {
+-    if ! dracut_module_included "systemd"; then
+-        inst_hook pre-pivot 00 "$moddir/caps.sh"
+-        inst $(type -P capsh 2>/dev/null) /usr/sbin/capsh
+-        # capsh wants bash and we need bash also
+-        inst /bin/bash
+-    else
+-        dwarning "caps: does not work with systemd in the initramfs"
+-    fi
++    inst_hook pre-pivot 00 "$moddir/caps.sh"
++    inst $(type -P capsh 2>/dev/null) /usr/sbin/capsh
++    # capsh wants bash and we need bash also
++    inst /bin/bash
+ }
+diff -urpa dracut-048.orig/modules.d/04watchdog/module-setup.sh dracut-048/modules.d/04watchdog/module-setup.sh
+--- dracut-048.orig/modules.d/04watchdog/module-setup.sh       2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/04watchdog/module-setup.sh    2018-07-21 20:22:31.907227377 +0000
+@@ -12,21 +12,17 @@ depends() {
+ # called by dracut
+ install() {
+-    # Do not add watchdog hooks if systemd module is included
+-    # In that case, systemd will manage watchdog kick
+-    if ! dracut_module_included "systemd"; then
+-        inst_hook cmdline   00 "$moddir/watchdog.sh"
+-        inst_hook cmdline   50 "$moddir/watchdog.sh"
+-        inst_hook pre-trigger 00 "$moddir/watchdog.sh"
+-        inst_hook initqueue 00 "$moddir/watchdog.sh"
+-        inst_hook mount     00 "$moddir/watchdog.sh"
+-        inst_hook mount     50 "$moddir/watchdog.sh"
+-        inst_hook mount     99 "$moddir/watchdog.sh"
+-        inst_hook pre-pivot 00 "$moddir/watchdog.sh"
+-        inst_hook pre-pivot 99 "$moddir/watchdog.sh"
+-        inst_hook cleanup   00 "$moddir/watchdog.sh"
+-        inst_hook cleanup   99 "$moddir/watchdog.sh"
+-    fi
++    inst_hook cmdline   00 "$moddir/watchdog.sh"
++    inst_hook cmdline   50 "$moddir/watchdog.sh"
++    inst_hook pre-trigger 00 "$moddir/watchdog.sh"
++    inst_hook initqueue 00 "$moddir/watchdog.sh"
++    inst_hook mount     00 "$moddir/watchdog.sh"
++    inst_hook mount     50 "$moddir/watchdog.sh"
++    inst_hook mount     99 "$moddir/watchdog.sh"
++    inst_hook pre-pivot 00 "$moddir/watchdog.sh"
++    inst_hook pre-pivot 99 "$moddir/watchdog.sh"
++    inst_hook cleanup   00 "$moddir/watchdog.sh"
++    inst_hook cleanup   99 "$moddir/watchdog.sh"
+     inst_hook emergency 02 "$moddir/watchdog-stop.sh"
+     inst_multiple -o wdctl
+ }
+diff -urpa dracut-048.orig/modules.d/10i18n/console_init.sh dracut-048/modules.d/10i18n/console_init.sh
+--- dracut-048.orig/modules.d/10i18n/console_init.sh   2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/10i18n/console_init.sh        2018-07-21 20:22:31.907227377 +0000
+@@ -1,11 +1,5 @@
+ #!/bin/sh
+-[ -n "$DRACUT_SYSTEMD" ] && exit 0
+-
+-if [ -x $systemdutildir/systemd-vconsole-setup ]; then
+-    $systemdutildir/systemd-vconsole-setup "$@"
+-fi
+-
+ [ -e /etc/vconsole.conf ] && . /etc/vconsole.conf
+ DEFAULT_FONT=LatArCyrHeb-16
+diff -urpa dracut-048.orig/modules.d/10i18n/module-setup.sh dracut-048/modules.d/10i18n/module-setup.sh
+--- dracut-048.orig/modules.d/10i18n/module-setup.sh   2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/10i18n/module-setup.sh        2018-07-21 20:22:31.908227377 +0000
+@@ -16,12 +16,6 @@ depends() {
+ # called by dracut
+ install() {
+-    if dracut_module_included "systemd"; then
+-        unset FONT
+-        unset KEYMAP
+-        [[ -f /etc/vconsole.conf ]] && . /etc/vconsole.conf
+-    fi
+-
+     KBDSUBDIRS=consolefonts,consoletrans,keymaps,unimaps
+     DEFAULT_FONT="${i18n_default_font:-LatArCyrHeb-16}"
+     I18N_CONF="/etc/locale.conf"
+@@ -99,11 +93,9 @@ install() {
+     install_base() {
+         inst_multiple setfont loadkeys kbd_mode stty
+-        if ! dracut_module_included "systemd"; then
+-            inst ${moddir}/console_init.sh /lib/udev/console_init
+-            inst_rules ${moddir}/10-console.rules
+-            inst_hook cmdline 20 "${moddir}/parse-i18n.sh"
+-        fi
++        inst ${moddir}/console_init.sh /lib/udev/console_init
++        inst_rules ${moddir}/10-console.rules
++        inst_hook cmdline 20 "${moddir}/parse-i18n.sh"
+         if [[ ${kbddir} != "/usr/share" ]]; then
+             inst_dir /usr/share
+@@ -222,19 +214,11 @@ install() {
+             inst_simple ${kbddir}/unimaps/${FONT_UNIMAP}.uni
+         fi
+-        if dracut_module_included "systemd" && [[ -f ${I18N_CONF} ]]; then
+-            inst_simple ${I18N_CONF}
+-        else
+-            mksubdirs ${initdir}${I18N_CONF}
+-            print_vars LC_ALL LANG >> ${initdir}${I18N_CONF}
+-        fi
++        mksubdirs ${initdir}${I18N_CONF}
++        print_vars LC_ALL LANG >> ${initdir}${I18N_CONF}
+-        if dracut_module_included "systemd" && [[ -f ${VCONFIG_CONF} ]]; then
+-            inst_simple ${VCONFIG_CONF}
+-        else
+-            mksubdirs ${initdir}${VCONFIG_CONF}
+-            print_vars KEYMAP EXT_KEYMAPS UNICODE FONT FONT_MAP FONT_UNIMAP >> ${initdir}${VCONFIG_CONF}
+-        fi
++        mksubdirs ${initdir}${VCONFIG_CONF}
++        print_vars KEYMAP EXT_KEYMAPS UNICODE FONT FONT_MAP FONT_UNIMAP >> ${initdir}${VCONFIG_CONF}
+         return 0
+     }
+diff -urpa dracut-048.orig/modules.d/40network/net-lib.sh dracut-048/modules.d/40network/net-lib.sh
+--- dracut-048.orig/modules.d/40network/net-lib.sh     2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/40network/net-lib.sh  2018-07-21 20:22:31.908227377 +0000
+@@ -52,7 +52,7 @@ iface_name() {
+ configured_ifaces() {
+     local IFACES="" iface_id="" rv=1
+     [ -e "/tmp/net.ifaces" ] && read IFACES < /tmp/net.ifaces
+-    if { pidof udevd || pidof systemd-udevd; } > /dev/null; then
++    if { pidof udevd; } > /dev/null; then
+         for iface_id in $IFACES; do
+             echo $(iface_name $iface_id)
+             rv=0
+diff -urpa dracut-048.orig/modules.d/50plymouth/module-setup.sh dracut-048/modules.d/50plymouth/module-setup.sh
+--- dracut-048.orig/modules.d/50plymouth/module-setup.sh       2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/50plymouth/module-setup.sh    2018-07-21 20:22:31.908227377 +0000
+@@ -41,9 +41,7 @@ install() {
+     inst_multiple readlink
+-    if ! dracut_module_included "systemd"; then
+-        inst_hook pre-trigger 10 "$moddir"/plymouth-pretrigger.sh
+-        inst_hook pre-pivot 90 "$moddir"/plymouth-newroot.sh
+-    fi
++    inst_hook pre-trigger 10 "$moddir"/plymouth-pretrigger.sh
++    inst_hook pre-pivot 90 "$moddir"/plymouth-newroot.sh
+ }
+diff -urpa dracut-048.orig/modules.d/50plymouth/plymouth-newroot.sh dracut-048/modules.d/50plymouth/plymouth-newroot.sh
+--- dracut-048.orig/modules.d/50plymouth/plymouth-newroot.sh   2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/50plymouth/plymouth-newroot.sh        2018-07-21 20:22:31.908227377 +0000
+@@ -1,5 +1,5 @@
+ #!/bin/sh
+-if type plymouth >/dev/null 2>&1 && [ -z "$DRACUT_SYSTEMD" ]; then
++if type plymouth >/dev/null 2>&1; then
+     plymouth --newroot=$NEWROOT
+ fi
+diff -urpa dracut-048.orig/modules.d/50plymouth/plymouth-pretrigger.sh dracut-048/modules.d/50plymouth/plymouth-pretrigger.sh
+--- dracut-048.orig/modules.d/50plymouth/plymouth-pretrigger.sh        2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/50plymouth/plymouth-pretrigger.sh     2018-07-21 20:22:31.908227377 +0000
+@@ -1,6 +1,6 @@
+ #!/bin/sh
+-if type plymouthd >/dev/null 2>&1 && [ -z "$DRACUT_SYSTEMD" ]; then
++if type plymouthd >/dev/null 2>&1; then
+     if getargbool 1 plymouth.enable && getargbool 1 rd.plymouth -d -n rd_NO_PLYMOUTH; then
+         # first trigger graphics subsystem
+         udevadm trigger --action=add --attr-match=class=0x030000 >/dev/null 2>&1
+diff -urpa dracut-048.orig/modules.d/90btrfs/module-setup.sh dracut-048/modules.d/90btrfs/module-setup.sh
+--- dracut-048.orig/modules.d/90btrfs/module-setup.sh  2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90btrfs/module-setup.sh       2018-07-21 20:22:31.908227377 +0000
+@@ -42,9 +42,7 @@ install() {
+         esac
+     fi
+-    if ! dracut_module_included "systemd"; then
+-        inst_hook initqueue/timeout 10 "$moddir/btrfs_timeout.sh"
+-    fi
++    inst_hook initqueue/timeout 10 "$moddir/btrfs_timeout.sh"
+     inst_multiple -o btrfsck btrfs-zero-log
+     inst $(command -v btrfs) /sbin/btrfs
+diff -urpa dracut-048.orig/modules.d/90crypt/crypt-run-generator.sh dracut-048/modules.d/90crypt/crypt-run-generator.sh
+--- dracut-048.orig/modules.d/90crypt/crypt-run-generator.sh   2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90crypt/crypt-run-generator.sh        2018-07-21 20:22:31.908227377 +0000
+@@ -24,8 +24,4 @@ fi
+ echo "$luks $dev - timeout=0,$allowdiscards" >> /etc/crypttab
+-if command -v systemctl >/dev/null; then
+-    systemctl daemon-reload
+-    systemctl start cryptsetup.target
+-fi
+ exit 0
+diff -urpa dracut-048.orig/modules.d/90crypt/module-setup.sh dracut-048/modules.d/90crypt/module-setup.sh
+--- dracut-048.orig/modules.d/90crypt/module-setup.sh  2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90crypt/module-setup.sh       2018-07-21 20:22:31.909227377 +0000
+@@ -4,7 +4,7 @@
+ check() {
+     local _rootdev
+     # if cryptsetup is not installed, then we cannot support encrypted devices.
+-    require_any_binary $systemdutildir/systemd-cryptsetup cryptsetup || return 1
++    require_any_binary cryptsetup || return 1
+     [[ $hostonly ]] || [[ $mount_needs ]] && {
+         for fs in "${host_fs_types[@]}"; do
+@@ -59,13 +59,11 @@ install() {
+     fi
+     inst_hook cmdline 30 "$moddir/parse-crypt.sh"
+-    if ! dracut_module_included "systemd"; then
+-        inst_multiple cryptsetup rmdir readlink umount
+-        inst_script "$moddir"/cryptroot-ask.sh /sbin/cryptroot-ask
+-        inst_script "$moddir"/probe-keydev.sh /sbin/probe-keydev
+-        inst_hook cmdline 10 "$moddir/parse-keydev.sh"
+-        inst_hook cleanup 30 "$moddir/crypt-cleanup.sh"
+-    fi
++    inst_multiple cryptsetup rmdir readlink umount
++    inst_script "$moddir"/cryptroot-ask.sh /sbin/cryptroot-ask
++    inst_script "$moddir"/probe-keydev.sh /sbin/probe-keydev
++    inst_hook cmdline 10 "$moddir/parse-keydev.sh"
++    inst_hook cleanup 30 "$moddir/crypt-cleanup.sh"
+     if [[ $hostonly ]] && [[ -f /etc/crypttab ]]; then
+         # filter /etc/crypttab for the devices we need
+@@ -119,17 +117,5 @@ install() {
+     inst_simple "$moddir/crypt-lib.sh" "/lib/dracut-crypt-lib.sh"
+-    if dracut_module_included "systemd"; then
+-        inst_multiple -o \
+-                      $systemdutildir/system-generators/systemd-cryptsetup-generator \
+-                      $systemdutildir/systemd-cryptsetup \
+-                      $systemdsystemunitdir/systemd-ask-password-console.path \
+-                      $systemdsystemunitdir/systemd-ask-password-console.service \
+-                      $systemdsystemunitdir/cryptsetup.target \
+-                      $systemdsystemunitdir/sysinit.target.wants/cryptsetup.target \
+-                      systemd-ask-password systemd-tty-ask-password-agent
+-        inst_script "$moddir"/crypt-run-generator.sh /sbin/crypt-run-generator
+-    fi
+-
+     dracut_need_initqueue
+ }
+diff -urpa dracut-048.orig/modules.d/90crypt/parse-crypt.sh dracut-048/modules.d/90crypt/parse-crypt.sh
+--- dracut-048.orig/modules.d/90crypt/parse-crypt.sh   2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90crypt/parse-crypt.sh        2018-07-21 20:22:31.909227377 +0000
+@@ -40,12 +40,6 @@ else
+     LUKS=$(getargs rd.luks.uuid -d rd_LUKS_UUID)
+     tout=$(getarg rd.luks.key.tout)
+-    if [ -e /etc/crypttab ]; then
+-        while read -r _ _dev _ || [ -n "$_dev" ]; do
+-            set_systemd_timeout_for_dev "$_dev"
+-        done < /etc/crypttab
+-    fi
+-
+     if [ -n "$PARTUUID" ]; then
+         for uuid in $PARTUUID; do
+@@ -56,26 +50,12 @@ else
+                 luksname="luks-$uuid"
+             fi
+-            if [ -z "$DRACUT_SYSTEMD" ]; then
+-                {
+-                    printf -- 'ENV{ID_PART_ENTRY_UUID}=="*%s*", ' "$uuid"
+-                    printf -- 'RUN+="%s --settled --unique --onetime ' "$(command -v initqueue)"
+-                    printf -- '--name cryptroot-ask-%%k %s ' "$(command -v cryptroot-ask)"
+-                    printf -- '$env{DEVNAME} %s %s"\n' "$luksname" "$tout"
+-                } >> /etc/udev/rules.d/70-luks.rules.new
+-            else
+-                luksname=$(dev_unit_name "$luksname")
+-                luksname="$(str_replace "$luksname" '\' '\\')"
+-
+-                if ! crypttab_contains "$uuid"; then
+-                    {
+-                        printf -- 'ENV{ID_PART_ENTRY_UUID}=="*%s*", ' "$uuid"
+-                        printf -- 'RUN+="%s --settled --unique --onetime ' "$(command -v initqueue)"
+-                        printf -- '--name systemd-cryptsetup-%%k %s start ' "$(command -v systemctl)"
+-                        printf -- 'systemd-cryptsetup@%s.service"\n' "$luksname"
+-                    } >> /etc/udev/rules.d/70-luks.rules.new
+-                fi
+-            fi
++            {
++                printf -- 'ENV{ID_PART_ENTRY_UUID}=="*%s*", ' "$uuid"
++                printf -- 'RUN+="%s --settled --unique --onetime ' "$(command -v initqueue)"
++                printf -- '--name cryptroot-ask-%%k %s ' "$(command -v cryptroot-ask)"
++                printf -- '$env{DEVNAME} %s %s"\n' "$luksname" "$tout"
++            } >> /etc/udev/rules.d/70-luks.rules.new
+         done
+     elif [ -n "$SERIAL" ]; then
+@@ -88,26 +68,12 @@ else
+                 luksname="luks-$serialid"
+             fi
+-            if [ -z "$DRACUT_SYSTEMD" ]; then
+-                {
+-                    printf -- 'ENV{ID_SERIAL_SHORT}=="*%s*", ' "$serialid"
+-                    printf -- 'RUN+="%s --settled --unique --onetime ' "$(command -v initqueue)"
+-                    printf -- '--name cryptroot-ask-%%k %s ' "$(command -v cryptroot-ask)"
+-                    printf -- '$env{DEVNAME} %s %s"\n' "$luksname" "$tout"
+-                } >> /etc/udev/rules.d/70-luks.rules.new
+-            else
+-                luksname=$(dev_unit_name "$luksname")
+-                luksname="$(str_replace "$luksname" '\' '\\')"
+-
+-                if ! crypttab_contains "$serialid"; then
+-                    {
+-                        printf -- 'ENV{ID_SERIAL_SHORT}=="*%s*", ' "$serialid"
+-                        printf -- 'RUN+="%s --settled --unique --onetime ' "$(command -v initqueue)"
+-                        printf -- '--name systemd-cryptsetup-%%k %s start ' "$(command -v systemctl)"
+-                        printf -- 'systemd-cryptsetup@%s.service"\n' "$luksname"
+-                    } >> /etc/udev/rules.d/70-luks.rules.new
+-                fi
+-            fi
++            {
++                printf -- 'ENV{ID_SERIAL_SHORT}=="*%s*", ' "$serialid"
++                printf -- 'RUN+="%s --settled --unique --onetime ' "$(command -v initqueue)"
++                printf -- '--name cryptroot-ask-%%k %s ' "$(command -v cryptroot-ask)"
++                printf -- '$env{DEVNAME} %s %s"\n' "$luksname" "$tout"
++            } >> /etc/udev/rules.d/70-luks.rules.new
+         done
+     elif [ -n "$LUKS" ]; then
+@@ -120,28 +86,13 @@ else
+                 luksname="luks-$luksid"
+             fi
+-            if [ -z "$DRACUT_SYSTEMD" ]; then
+-                {
+-                    printf -- 'ENV{ID_FS_TYPE}=="crypto_LUKS", '
+-                    printf -- 'ENV{ID_FS_UUID}=="*%s*", ' "$luksid"
+-                    printf -- 'RUN+="%s --settled --unique --onetime ' "$(command -v initqueue)"
+-                    printf -- '--name cryptroot-ask-%%k %s ' "$(command -v cryptroot-ask)"
+-                    printf -- '$env{DEVNAME} %s %s"\n' "$luksname" "$tout"
+-                } >> /etc/udev/rules.d/70-luks.rules.new
+-            else
+-                luksname=$(dev_unit_name "$luksname")
+-                luksname="$(str_replace "$luksname" '\' '\\')"
+-
+-                if ! crypttab_contains "$luksid"; then
+-                    {
+-                        printf -- 'ENV{ID_FS_TYPE}=="crypto_LUKS", '
+-                        printf -- 'ENV{ID_FS_UUID}=="*%s*", ' "$luksid"
+-                        printf -- 'RUN+="%s --settled --unique --onetime ' "$(command -v initqueue)"
+-                        printf -- '--name systemd-cryptsetup-%%k %s start ' "$(command -v systemctl)"
+-                        printf -- 'systemd-cryptsetup@%s.service"\n' "$luksname"
+-                    } >> /etc/udev/rules.d/70-luks.rules.new
+-                fi
+-            fi
++            {
++                printf -- 'ENV{ID_FS_TYPE}=="crypto_LUKS", '
++                printf -- 'ENV{ID_FS_UUID}=="*%s*", ' "$luksid"
++                printf -- 'RUN+="%s --settled --unique --onetime ' "$(command -v initqueue)"
++                printf -- '--name cryptroot-ask-%%k %s ' "$(command -v cryptroot-ask)"
++                printf -- '$env{DEVNAME} %s %s"\n' "$luksname" "$tout"
++            } >> /etc/udev/rules.d/70-luks.rules.new
+             uuid=$luksid
+             while [ "$uuid" != "${uuid#*-}" ]; do uuid=${uuid%%-*}${uuid#*-}; done
+@@ -154,19 +105,11 @@ else
+             } >> "$hookdir/emergency/90-crypt.sh"
+         done
+     elif getargbool 0 rd.auto; then
+-        if [ -z "$DRACUT_SYSTEMD" ]; then
+-            {
+-                printf -- 'ENV{ID_FS_TYPE}=="crypto_LUKS", RUN+="%s ' "$(command -v initqueue)"
+-                printf -- '--unique --settled --onetime --name cryptroot-ask-%%k '
+-                printf -- '%s $env{DEVNAME} luks-$env{ID_FS_UUID} %s"\n' "$(command -v cryptroot-ask)" "$tout"
+-            } >> /etc/udev/rules.d/70-luks.rules.new
+-        else
+-            {
+-                printf -- 'ENV{ID_FS_TYPE}=="crypto_LUKS", RUN+="%s ' "$(command -v initqueue)"
+-                printf -- '--unique --settled --onetime --name crypt-run-generator-%%k '
+-                printf -- '%s $env{DEVNAME} luks-$env{ID_FS_UUID}"\n' "$(command -v crypt-run-generator)"
+-            } >> /etc/udev/rules.d/70-luks.rules.new
+-        fi
++        {
++            printf -- 'ENV{ID_FS_TYPE}=="crypto_LUKS", RUN+="%s ' "$(command -v initqueue)"
++            printf -- '--unique --settled --onetime --name cryptroot-ask-%%k '
++            printf -- '%s $env{DEVNAME} luks-$env{ID_FS_UUID} %s"\n' "$(command -v cryptroot-ask)" "$tout"
++        } >> /etc/udev/rules.d/70-luks.rules.new
+     fi
+     echo 'LABEL="luks_end"' >> /etc/udev/rules.d/70-luks.rules.new
+diff -urpa dracut-048.orig/modules.d/90dmsquash-live/dmsquash-live-root.sh dracut-048/modules.d/90dmsquash-live/dmsquash-live-root.sh
+--- dracut-048.orig/modules.d/90dmsquash-live/dmsquash-live-root.sh    2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90dmsquash-live/dmsquash-live-root.sh 2018-07-21 20:51:34.330123521 +0000
+@@ -41,12 +41,7 @@ fi
+ getarg rd.live.check -d check || check=""
+ if [ -n "$check" ]; then
+     type plymouth >/dev/null 2>&1 && plymouth --hide-splash
+-    if [ -n "$DRACUT_SYSTEMD" ]; then
+-        p=$(dev_unit_name "$livedev")
+-        systemctl start checkisomd5@${p}.service
+-    else
+-        checkisomd5 --verbose $livedev
+-    fi
++    checkisomd5 --verbose $livedev
+     if [ $? -eq 1 ]; then
+         die "CD check failed!"
+         exit 1
+@@ -81,9 +76,6 @@ else
+     if [ "$(blkid -o value -s TYPE $livedev)" != "ntfs" ]; then
+         mount -n -t $fstype -o ${liverw:-ro} $livedev /run/initramfs/live
+     else
+-        # Symlinking /usr/bin/ntfs-3g as /sbin/mount.ntfs seems to boot
+-        # at the first glance, but ends with lots and lots of squashfs
+-        # errors, because systemd attempts to kill the ntfs-3g process?!
+         if [ -x "/usr/bin/ntfs-3g" ]; then
+             ( exec -a @ntfs-3g ntfs-3g -o ${liverw:-ro} $livedev /run/initramfs/live ) | vwarn
+         else
+@@ -137,7 +129,6 @@ do_live_overlay() {
+                 fi
+                 if [ -n "$overlayfs" ]; then
+                     unset -v overlayfs
+-                    [ -n "$DRACUT_SYSTEMD" ] && reloadsysrootmountunit="yes"
+                 fi
+                 setup="yes"
+             else
+@@ -148,7 +139,6 @@ do_live_overlay() {
+                     ln -s /run/initramfs/overlayfs/ovlwork /run/ovlwork$opt
+                     if [ -z "$overlayfs" ]; then
+                         overlayfs="yes"
+-                        [ -n "$DRACUT_SYSTEMD" ] && reloadsysrootmountunit="yes"
+                     fi
+                     setup="yes"
+                 fi
+@@ -159,7 +149,6 @@ do_live_overlay() {
+             ln -s /run/initramfs/overlayfs$pathspec/../ovlwork /run/ovlwork$opt
+             if [ -z "$overlayfs" ]; then
+                 overlayfs="yes"
+-                [ -n "$DRACUT_SYSTEMD" ] && reloadsysrootmountunit="yes"
+             fi
+             setup="yes"
+         fi
+@@ -169,7 +158,6 @@ do_live_overlay() {
+         if [ $? != 0 ]; then
+             m='OverlayFS is not available; using temporary Device-mapper overlay.'
+             unset -v overlayfs setup
+-            [ -n "$reloadsysrootmountunit" ] && unset -v reloadsysrootmountunit
+         fi
+     fi
+@@ -182,23 +170,8 @@ do_live_overlay() {
+             m="$m"$'\n      All root filesystem changes will be lost on shutdown.'
+             m="$m"$'\n         Press [Enter] to continue.'
+             echo -e "\n\n\n\n${m}\n\n\n" > /dev/kmsg
+-            if [ -n "$DRACUT_SYSTEMD" ]; then
+-                if type plymouth >/dev/null 2>&1 && plymouth --ping ; then
+-                    if getargbool 0 rhgb || getargbool 0 splash ; then
+-                        m='>>>'$'\n''>>>'$'\n''>>>'$'\n\n\n'"$m"
+-                        m="${m%n.*}"$'n.\n\n\n''<<<'$'\n''<<<'$'\n''<<<'
+-                        plymouth display-message --text="${m}"
+-                    else
+-                        plymouth ask-question --prompt="${m}" --command=true
+-                    fi
+-                else
+-                    m=">>>${m//.[[:space:]]/.}  <<<"
+-                    systemd-ask-password --timeout=0 "${m}"
+-                fi
+-            else
+-                type plymouth >/dev/null 2>&1 && plymouth --ping && plymouth --quit
+-                read -s -r -p $'\n\n'"${m}" -n 1 reply
+-            fi
++            type plymouth >/dev/null 2>&1 && plymouth --ping && plymouth --quit
++            read -s -r -p $'\n\n'"${m}" -n 1 reply
+         fi
+         if [ -n "$overlayfs" ]; then
+             mkdir -m 0755 /run/overlayfs
+@@ -354,11 +327,6 @@ if [ -b "$OSMIN_LOOPDEV" ]; then
+     echo "0 $sz snapshot $BASE_LOOPDEV $OSMIN_LOOPDEV P 8" | dmsetup create --readonly live-osimg-min
+ fi
+-if [ -n "$reloadsysrootmountunit" ]; then
+-    > /xor_overlayfs
+-    systemctl daemon-reload
+-fi
+-
+ ROOTFLAGS="$(getarg rootflags)"
+ if [ -n "$overlayfs" ]; then
+@@ -375,18 +343,14 @@ if [ -n "$overlayfs" ]; then
+     else
+         mount -r $FSIMG /run/rootfsbase
+     fi
+-    if [ -z "$DRACUT_SYSTEMD" ]; then
+-        #FIXME What to link to /dev/root? Is it even needed?
+-        printf 'mount -t overlay LiveOS_rootfs -o%s,%s %s\n' "$ROOTFLAGS" \
+-        'lowerdir=/run/rootfsbase,upperdir=/run/overlayfs,workdir=/run/ovlwork' \
+-        "$NEWROOT" > $hookdir/mount/01-$$-live.sh
+-    fi
++    #FIXME What to link to /dev/root? Is it even needed?
++    printf 'mount -t overlay LiveOS_rootfs -o%s,%s %s\n' "$ROOTFLAGS" \
++    'lowerdir=/run/rootfsbase,upperdir=/run/overlayfs,workdir=/run/ovlwork' \
++    "$NEWROOT" > $hookdir/mount/01-$$-live.sh
+ else
+     ln -s /dev/mapper/live-rw /dev/root
+-    if [ -z "$DRACUT_SYSTEMD" ]; then
+-        [ -n "$ROOTFLAGS" ] && ROOTFLAGS="-o $ROOTFLAGS"
+-        printf 'mount %s /dev/mapper/live-rw %s\n' "$ROOTFLAGS" "$NEWROOT" > $hookdir/mount/01-$$-live.sh
+-    fi
++    [ -n "$ROOTFLAGS" ] && ROOTFLAGS="-o $ROOTFLAGS"
++    printf 'mount %s /dev/mapper/live-rw %s\n' "$ROOTFLAGS" "$NEWROOT" > $hookdir/mount/01-$$-live.sh
+     ln -s $BASE_LOOPDEV /run/rootfsbase
+ fi
+diff -urpa dracut-048.orig/modules.d/90dmsquash-live/iso-scan.sh dracut-048/modules.d/90dmsquash-live/iso-scan.sh
+--- dracut-048.orig/modules.d/90dmsquash-live/iso-scan.sh      2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90dmsquash-live/iso-scan.sh   2018-07-21 20:50:13.809128320 +0000
+@@ -16,7 +16,7 @@ do_iso_scan() {
+     local _name
+     local dev
+     for dev in /dev/disk/by-uuid/*; do
+-        _name=$(dev_unit_name "$dev")
++        _name="$dev"
+         [ -e /tmp/isoscan-${_name} ] && continue
+         > /tmp/isoscan-${_name}
+         mount -t auto -o ro "$dev" "/run/initramfs/isoscan" || continue
+diff -urpa dracut-048.orig/modules.d/90dmsquash-live/module-setup.sh dracut-048/modules.d/90dmsquash-live/module-setup.sh
+--- dracut-048.orig/modules.d/90dmsquash-live/module-setup.sh  2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90dmsquash-live/module-setup.sh       2018-07-21 20:22:31.909227377 +0000
+@@ -31,9 +31,7 @@ install() {
+     inst_hook pre-pivot 20 "$moddir/apply-live-updates.sh"
+     inst_script "$moddir/dmsquash-live-root.sh" "/sbin/dmsquash-live-root"
+     inst_script "$moddir/iso-scan.sh" "/sbin/iso-scan"
+-    inst_script "$moddir/dmsquash-generator.sh" $systemdutildir/system-generators/dracut-dmsquash-generator
+     # should probably just be generally included
+     inst_rules 60-cdrom_id.rules
+-    inst_simple "$moddir/checkisomd5@.service" "/etc/systemd/system/checkisomd5@.service"
+     dracut_need_initqueue
+ }
+diff -urpa dracut-048.orig/modules.d/90kernel-modules/module-setup.sh dracut-048/modules.d/90kernel-modules/module-setup.sh
+--- dracut-048.orig/modules.d/90kernel-modules/module-setup.sh 2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90kernel-modules/module-setup.sh      2018-07-21 20:22:31.909227377 +0000
+@@ -92,8 +92,6 @@ installkernel() {
+ install() {
+     inst_multiple -o /lib/modprobe.d/*.conf
+     [[ $hostonly ]] && inst_multiple -H -o /etc/modprobe.d/*.conf /etc/modprobe.conf
+-    if ! dracut_module_included "systemd"; then
+-        inst_hook cmdline 01 "$moddir/parse-kernel.sh"
+-    fi
++    inst_hook cmdline 01 "$moddir/parse-kernel.sh"
+     inst_simple "$moddir/insmodpost.sh" /sbin/insmodpost.sh
+ }
+diff -urpa dracut-048.orig/modules.d/90livenet/module-setup.sh dracut-048/modules.d/90livenet/module-setup.sh
+--- dracut-048.orig/modules.d/90livenet/module-setup.sh        2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90livenet/module-setup.sh     2018-07-21 20:22:31.910227377 +0000
+@@ -17,8 +17,5 @@ install() {
+     inst_hook cmdline 29 "$moddir/parse-livenet.sh"
+     inst_hook initqueue/online 95 "$moddir/fetch-liveupdate.sh"
+     inst_script "$moddir/livenetroot.sh" "/sbin/livenetroot"
+-    if dracut_module_included "systemd-initrd"; then
+-        inst_script "$moddir/livenet-generator.sh" $systemdutildir/system-generators/dracut-livenet-generator
+-    fi
+     dracut_need_initqueue
+ }
+diff -urpa dracut-048.orig/modules.d/90lvm/module-setup.sh dracut-048/modules.d/90lvm/module-setup.sh
+--- dracut-048.orig/modules.d/90lvm/module-setup.sh    2018-07-21 20:22:15.814228337 +0000
++++ dracut-048/modules.d/90lvm/module-setup.sh 2018-07-21 20:22:31.910227377 +0000
+@@ -97,15 +97,8 @@ install() {
+     # Do not run lvmetad update via pvscan in udev rule  - lvmetad is not running yet in dracut!
+     if [[ -f ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules ]]; then
+-        if grep -q SYSTEMD_WANTS ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules; then
+-            sed -i -e 's/^ENV{SYSTEMD_ALIAS}=.*/# No LVM pvscan in dracut - lvmetad is not running yet/' \
+-                ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules
+-            sed -i -e 's/^ENV{ID_MODEL}=.*//' ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules
+-            sed -i -e 's/^ENV{SYSTEMD_WANTS}=.*//' ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules
+-        else
+-            sed -i -e 's/.*lvm pvscan.*/# No LVM pvscan for in dracut - lvmetad is not running yet/' \
+-                ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules
+-        fi
++        sed -i -e 's/.*lvm pvscan.*/# No LVM pvscan for in dracut - lvmetad is not running yet/' \
++            ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules
+     fi
+     # Gentoo ebuild for LVM2 prior to 2.02.63-r1 doesn't install above rules
+diff -urpa dracut-048.orig/modules.d/90mdraid/module-setup.sh dracut-048/modules.d/90mdraid/module-setup.sh
+--- dracut-048.orig/modules.d/90mdraid/module-setup.sh 2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90mdraid/module-setup.sh      2018-07-21 20:22:31.910227377 +0000
+@@ -126,17 +126,6 @@ install() {
+     inst_hook shutdown 30 "$moddir/md-shutdown.sh"
+     inst_script "$moddir/mdraid-cleanup.sh" /sbin/mdraid-cleanup
+     inst_script "$moddir/mdraid_start.sh" /sbin/mdraid_start
+-    if dracut_module_included "systemd"; then
+-        if [ -e $systemdsystemunitdir/mdmon@.service ]; then
+-            inst_simple $systemdsystemunitdir/mdmon@.service
+-        fi
+-        if [ -e $systemdsystemunitdir/mdadm-last-resort@.service ]; then
+-            inst_simple $systemdsystemunitdir/mdadm-last-resort@.service
+-        fi
+-        if [ -e $systemdsystemunitdir/mdadm-last-resort@.timer ]; then
+-            inst_simple $systemdsystemunitdir/mdadm-last-resort@.timer
+-        fi
+-    fi
+     inst_hook pre-shutdown 30 "$moddir/mdmon-pre-shutdown.sh"
+     dracut_need_initqueue
+ }
+diff -urpa dracut-048.orig/modules.d/90multipath/module-setup.sh dracut-048/modules.d/90multipath/module-setup.sh
+--- dracut-048.orig/modules.d/90multipath/module-setup.sh      2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90multipath/module-setup.sh   2018-07-21 20:22:31.910227377 +0000
+@@ -107,14 +107,8 @@ install() {
+         [[ $_conf ]] && echo "$_conf" >> "${initdir}/etc/cmdline.d/90multipath.conf"
+     fi
+-    if dracut_module_included "systemd"; then
+-        inst_simple "${moddir}/multipathd.service" "${systemdsystemunitdir}/multipathd.service"
+-        mkdir -p "${initdir}${systemdsystemunitdir}/sysinit.target.wants"
+-        ln -rfs "${initdir}${systemdsystemunitdir}/multipathd.service" "${initdir}${systemdsystemunitdir}/sysinit.target.wants/multipathd.service"
+-    else
+-        inst_hook pre-trigger 02 "$moddir/multipathd.sh"
+-        inst_hook cleanup   02 "$moddir/multipathd-stop.sh"
+-    fi
++    inst_hook pre-trigger 02 "$moddir/multipathd.sh"
++    inst_hook cleanup   02 "$moddir/multipathd-stop.sh"
+     inst_hook cleanup   80 "$moddir/multipathd-needshutdown.sh"
+     inst_hook shutdown  20 "$moddir/multipath-shutdown.sh"
+diff -urpa dracut-048.orig/modules.d/90qemu/module-setup.sh dracut-048/modules.d/90qemu/module-setup.sh
+--- dracut-048.orig/modules.d/90qemu/module-setup.sh   2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90qemu/module-setup.sh        2018-07-21 20:22:31.910227377 +0000
+@@ -3,14 +3,6 @@
+ # called by dracut
+ check() {
+     if [[ $hostonly ]] || [[ $mount_needs ]]; then
+-        if type -P systemd-detect-virt >/dev/null 2>&1; then
+-            vm=$(systemd-detect-virt --vm 2>/dev/null)
+-            (($? != 0)) && return 255
+-            [[ $vm = "qemu" ]] && return 0
+-            [[ $vm = "kvm" ]] && return 0
+-            [[ $vm = "bochs" ]] && return 0
+-        fi
+-
+         for i in /sys/class/dmi/id/*_vendor; do
+             [[ -f $i ]] || continue
+             read vendor < $i
+diff -urpa dracut-048.orig/modules.d/90qemu-net/module-setup.sh dracut-048/modules.d/90qemu-net/module-setup.sh
+--- dracut-048.orig/modules.d/90qemu-net/module-setup.sh       2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90qemu-net/module-setup.sh    2018-07-21 20:22:31.910227377 +0000
+@@ -3,14 +3,6 @@
+ # called by dracut
+ check() {
+     if [[ $hostonly ]] || [[ $mount_needs ]]; then
+-        if type -P systemd-detect-virt >/dev/null 2>&1; then
+-            vm=$(systemd-detect-virt --vm >/dev/null 2>&1)
+-            (($? != 0)) && return 255
+-            [[ $vm = "qemu" ]] && return 0
+-            [[ $vm = "kvm" ]] && return 0
+-            [[ $vm = "bochs" ]] && return 0
+-        fi
+-
+         for i in /sys/class/dmi/id/*_vendor; do
+             [[ -f $i ]] || continue
+             read vendor < $i
+diff -urpa dracut-048.orig/modules.d/90stratis/module-setup.sh dracut-048/modules.d/90stratis/module-setup.sh
+--- dracut-048.orig/modules.d/90stratis/module-setup.sh        2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/90stratis/module-setup.sh     2018-07-21 20:22:31.910227377 +0000
+@@ -22,13 +22,7 @@ install() {
+     inst_multiple stratisd-init thin_check thin_repair
+-    if dracut_module_included "systemd"; then
+-        inst_simple "${moddir}/stratisd-init.service" "${systemdsystemunitdir}/stratisd-init.service"
+-        mkdir -p "${initdir}${systemdsystemunitdir}/sysinit.target.wants"
+-        ln -rfs "${initdir}${systemdsystemunitdir}/stratisd-init.service" "${initdir}${systemdsystemunitdir}/sysinit.target.wants/stratisd-init.service"
+-    else
+-        inst_hook cmdline 25 "$moddir/stratisd-start.sh"
+-        inst_hook cleanup 25 "$moddir/stratisd-stop.sh"
+-    fi
++    inst_hook cmdline 25 "$moddir/stratisd-start.sh"
++    inst_hook cleanup 25 "$moddir/stratisd-stop.sh"
+ }
+diff -urpa dracut-048.orig/modules.d/95debug/module-setup.sh dracut-048/modules.d/95debug/module-setup.sh
+--- dracut-048.orig/modules.d/95debug/module-setup.sh  2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95debug/module-setup.sh       2018-07-21 20:22:31.911227377 +0000
+@@ -15,7 +15,7 @@ depends() {
+ install() {
+     inst_multiple -o cat ls ps grep more cat rm strace free showmount \
+                   ping netstat rpcinfo vi scp ping6 ssh find vi \
+-                  tcpdump cp less hostname mkdir systemd-analyze \
++                  tcpdump cp less hostname mkdir \
+                   fsck fsck.ext2 fsck.ext4 fsck.ext3 fsck.ext4dev fsck.f2fs fsck.vfat e2fsck
+     grep '^tcpdump:' /etc/passwd 2>/dev/null >> "$initdir/etc/passwd"
+diff -urpa dracut-048.orig/modules.d/95fcoe/cleanup-fcoe.sh dracut-048/modules.d/95fcoe/cleanup-fcoe.sh
+--- dracut-048.orig/modules.d/95fcoe/cleanup-fcoe.sh   2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95fcoe/cleanup-fcoe.sh        2018-07-21 20:22:31.911227377 +0000
+@@ -4,11 +4,7 @@
+ if [ -e /var/run/lldpad.pid ]; then
+     lldpad -k
+-    # with systemd version 230, this is not necessary anymore
+-    # systemd commit cacf980ed44a28e276a6cc7f8fc41f991e2ab354
+-    if [ -z "$DRACUT_SYSTEMD" ]; then
+-        mkdir -m 0755 -p /run/initramfs/state/dev/shm
+-        cp /dev/shm/lldpad.state /run/initramfs/state/dev/shm/ > /dev/null 2>&1
+-        echo "files /dev/shm/lldpad.state" >> /run/initramfs/rwtab
+-    fi
++    mkdir -m 0755 -p /run/initramfs/state/dev/shm
++    cp /dev/shm/lldpad.state /run/initramfs/state/dev/shm/ > /dev/null 2>&1
++    echo "files /dev/shm/lldpad.state" >> /run/initramfs/rwtab
+ fi
+diff -urpa dracut-048.orig/modules.d/95fstab-sys/mount-sys.sh dracut-048/modules.d/95fstab-sys/mount-sys.sh
+--- dracut-048.orig/modules.d/95fstab-sys/mount-sys.sh 2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95fstab-sys/mount-sys.sh      2018-07-21 20:22:31.911227377 +0000
+@@ -25,11 +25,7 @@ fstab_mount() {
+     return 0
+ }
+-# systemd will mount and run fsck from /etc/fstab and we don't want to
+-# run into a race condition.
+-if [ -z "$DRACUT_SYSTEMD" ]; then
+-    [ -f /etc/fstab ] && fstab_mount /etc/fstab
+-fi
++[ -f /etc/fstab ] && fstab_mount /etc/fstab
+ # prefer $NEWROOT/etc/fstab.sys over local /etc/fstab.sys
+ if [ -f $NEWROOT/etc/fstab.sys ]; then
+diff -urpa dracut-048.orig/modules.d/95iscsi/cleanup-iscsi.sh dracut-048/modules.d/95iscsi/cleanup-iscsi.sh
+--- dracut-048.orig/modules.d/95iscsi/cleanup-iscsi.sh 2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95iscsi/cleanup-iscsi.sh      2018-07-21 20:22:31.911227377 +0000
+@@ -1,4 +1,4 @@
+ #!/bin/sh
+-[ -z "${DRACUT_SYSTEMD}" ] && [ -e /sys/module/bnx2i ] && killproc iscsiuio
++[ -e /sys/module/bnx2i ] && killproc iscsiuio
+diff -urpa dracut-048.orig/modules.d/95iscsi/iscsiroot.sh dracut-048/modules.d/95iscsi/iscsiroot.sh
+--- dracut-048.orig/modules.d/95iscsi/iscsiroot.sh     2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95iscsi/iscsiroot.sh  2018-07-21 20:47:30.720138041 +0000
+@@ -36,7 +36,7 @@ iroot=${iroot#:}
+ # figured out a way how to check whether this is built-in or not
+ modprobe crc32c 2>/dev/null
+-if [ -z "${DRACUT_SYSTEMD}" ] && [ -e /sys/module/bnx2i ] && ! [ -e /tmp/iscsiuio-started ]; then
++if [ -e /sys/module/bnx2i ] && ! [ -e /tmp/iscsiuio-started ]; then
+         iscsiuio
+         > /tmp/iscsiuio-started
+ fi
+@@ -142,11 +142,6 @@ handle_netroot()
+            mkdir -p /etc/iscsi
+            ln -fs /run/initiatorname.iscsi /etc/iscsi/initiatorname.iscsi
+            > /tmp/iscsi_set_initiator
+-           if [ -n "$DRACUT_SYSTEMD" ]; then
+-               systemctl try-restart iscsid
+-               # FIXME: iscsid is not yet ready, when the service is :-/
+-               sleep 1
+-           fi
+     fi
+     if [ -z "$iscsi_initiator" ]; then
+@@ -163,11 +158,6 @@ handle_netroot()
+         mkdir -p /etc/iscsi
+         ln -fs /run/initiatorname.iscsi /etc/iscsi/initiatorname.iscsi
+         > /tmp/iscsi_set_initiator
+-        if [ -n "$DRACUT_SYSTEMD" ]; then
+-            systemctl try-restart iscsid
+-            # FIXME: iscsid is not yet ready, when the service is :-/
+-            sleep 1
+-        fi
+     fi
+@@ -188,11 +178,6 @@ handle_netroot()
+     if ! [ -e /etc/iscsi/initiatorname.iscsi ]; then
+         mkdir -p /etc/iscsi
+         ln -fs /run/initiatorname.iscsi /etc/iscsi/initiatorname.iscsi
+-        if [ -n "$DRACUT_SYSTEMD" ]; then
+-            systemctl try-restart iscsid
+-            # FIXME: iscsid is not yet ready, when the service is :-/
+-            sleep 1
+-        fi
+     fi
+ # FIXME $iscsi_protocol??
+@@ -204,12 +189,9 @@ handle_netroot()
+         wait_for_dev -n /dev/root
+         # install mount script
+-        [ -z "$DRACUT_SYSTEMD" ] && \
+-            echo "iscsi_lun=$iscsi_lun . /bin/mount-lun.sh " > $hookdir/mount/01-$$-iscsi.sh
++        echo "iscsi_lun=$iscsi_lun . /bin/mount-lun.sh " > $hookdir/mount/01-$$-iscsi.sh
+     fi
+-    ### ToDo: Upstream calls systemd-run - Shall we, do we have to port this?
+-
+     targets=$(iscsiadm -m discovery -t st -p $iscsi_target_ip:${iscsi_target_port:+$iscsi_target_port} | sed 's/^.*iqn/iqn/')
+     [ -z "$targets" ] && echo "Target discovery to $iscsi_target_ip:${iscsi_target_port:+$iscsi_target_port} failed with status $?" && exit 1
+@@ -250,14 +232,6 @@ if [ "$netif" != "timeout" ] && getargbo
+     all_ifaces_setup || exit 0
+ fi
+-if [ "$netif" = "timeout" ] && all_ifaces_setup; then
+-    # s.th. went wrong and the timeout script hits
+-    # restart
+-    systemctl restart iscsid
+-    # damn iscsid is not ready after unit says it's ready
+-    sleep 2
+-fi
+-
+ if getargbool 0 rd.iscsi.firmware -d -y iscsi_firmware ; then
+     if [ "$netif" = "timeout" ] || [ "$netif" = "online" ] || [ "$netif" = "dummy" ]; then
+         [ -f /tmp/session-retry ] || echo 1 > /tmp/session-retry
+diff -urpa dracut-048.orig/modules.d/95iscsi/module-setup.sh dracut-048/modules.d/95iscsi/module-setup.sh
+--- dracut-048.orig/modules.d/95iscsi/module-setup.sh  2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95iscsi/module-setup.sh       2018-07-21 20:22:31.911227377 +0000
+@@ -208,17 +208,6 @@ install() {
+     inst_libdir_file 'libgcc_s.so*'
+     inst_multiple umount hostname iscsi-iname iscsiadm iscsid
+-    ln -sf $systemdsystemunitdir/iscsid.socket $systemdsystemunitdir/sockets.target.wants/iscsid.socket
+-    ln -sf $systemdsystemunitdir/iscsiuio.socket $systemdsystemunitdir/sockets.target.wants/iscsiuio.socket
+-
+-    inst_multiple -o \
+-        $systemdsystemunitdir/iscsid.socket \
+-        $systemdsystemunitdir/iscsid.service \
+-        $systemdsystemunitdir/iscsiuio.service \
+-        $systemdsystemunitdir/iscsiuio.socket \
+-        $systemdsystemunitdir/sockets.target.wants/iscsid.socket \
+-        $systemdsystemunitdir/sockets.target.wants/iscsiuio.socket
+-
+     [[ -d /etc/iscsi ]] && inst_dir $(/usr/bin/find /etc/iscsi)
+     # Detect iBFT and perform mandatory steps
+@@ -230,40 +219,7 @@ install() {
+     inst_hook cmdline 90 "$moddir/parse-iscsiroot.sh"
+     inst_hook cleanup 90 "$moddir/cleanup-iscsi.sh"
+     inst "$moddir/iscsiroot.sh" "/sbin/iscsiroot"
+-    if ! dracut_module_included "systemd"; then
+-        inst "$moddir/mount-lun.sh" "/bin/mount-lun.sh"
+-    else
+-        inst_multiple -o \
+-                      $systemdsystemunitdir/iscsi.service \
+-                      $systemdsystemunitdir/iscsid.service \
+-                      $systemdsystemunitdir/iscsid.socket \
+-                      $systemdsystemunitdir/iscsiuio.service \
+-                      $systemdsystemunitdir/iscsiuio.socket \
+-                      iscsiadm iscsid
+-
+-        mkdir -p "${initdir}/$systemdsystemunitdir/sockets.target.wants"
+-        for i in \
+-                iscsiuio.socket \
+-            ; do
+-            ln_r "$systemdsystemunitdir/${i}" "$systemdsystemunitdir/sockets.target.wants/${i}"
+-        done
+-
+-        mkdir -p "${initdir}/$systemdsystemunitdir/basic.target.wants"
+-        for i in \
+-                iscsid.service \
+-                iscsiuio.service \
+-            ; do
+-            ln_r "$systemdsystemunitdir/${i}" "$systemdsystemunitdir/basic.target.wants/${i}"
+-        done
+-
+-        # Make sure iscsid is started after dracut-cmdline and ready for the initqueue
+-        mkdir -p "${initdir}/$systemdsystemunitdir/iscsid.service.d"
+-        (
+-            echo "[Unit]"
+-            echo "After=dracut-cmdline.service"
+-            echo "Before=dracut-initqueue.service"
+-        ) > "${initdir}/$systemdsystemunitdir/iscsid.service.d/dracut.conf"
+-    fi
++    inst "$moddir/mount-lun.sh" "/bin/mount-lun.sh"
+     inst_dir /var/lib/iscsi
+     dracut_need_initqueue
+ }
+diff -urpa dracut-048.orig/modules.d/95iscsi/parse-iscsiroot.sh dracut-048/modules.d/95iscsi/parse-iscsiroot.sh
+--- dracut-048.orig/modules.d/95iscsi/parse-iscsiroot.sh       2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95iscsi/parse-iscsiroot.sh    2018-07-21 20:22:31.912227377 +0000
+@@ -41,7 +41,7 @@ if [ "${root%%:*}" = "iscsi" ] ; then
+     netroot=$root
+     # if root is not specified try to mount the whole iSCSI LUN
+     printf 'ENV{DEVTYPE}!="partition", SYMLINK=="disk/by-path/*-iscsi-*-*", SYMLINK+="root"\n' >> /etc/udev/rules.d/99-iscsi-root.rules
+-    [ -n "$DRACUT_SYSTEMD" ] && systemctl is-active systemd-udevd && udevadm control --reload-rules
++    udevadm control --reload-rules
+     root=/dev/root
+     write_fs_tab /dev/root
+@@ -58,7 +58,7 @@ done
+ if [ "${root}" = "/dev/root" ] && getarg "netroot=dhcp" ; then
+     # if root is not specified try to mount the whole iSCSI LUN
+     printf 'ENV{DEVTYPE}!="partition", SYMLINK=="disk/by-path/*-iscsi-*-*", SYMLINK+="root"\n' >> /etc/udev/rules.d/99-iscsi-root.rules
+-    [ -n "$DRACUT_SYSTEMD" ] && systemctl is-active systemd-udevd && udevadm control --reload-rules
++    udevadm control --reload-rules
+ fi
+ if [ -n "$iscsiroot" ] ; then
+@@ -116,11 +116,6 @@ if arg=$(getarg rd.iscsi.initiator -d is
+     if ! [ -e /etc/iscsi/initiatorname.iscsi ]; then
+         mkdir -p /etc/iscsi
+         ln -fs /run/initiatorname.iscsi /etc/iscsi/initiatorname.iscsi
+-        if [ -n "$DRACUT_SYSTEMD" ]; then
+-            systemctl try-restart iscsid
+-            # FIXME: iscsid is not yet ready, when the service is :-/
+-            sleep 1
+-        fi
+     fi
+ fi
+@@ -133,11 +128,6 @@ if [ -z $iscsi_initiator ] && [ -f /sys/
+         mkdir -p /etc/iscsi
+         ln -fs /run/initiatorname.iscsi /etc/iscsi/initiatorname.iscsi
+         > /tmp/iscsi_set_initiator
+-        if [ -n "$DRACUT_SYSTEMD" ]; then
+-            systemctl try-restart iscsid
+-            # FIXME: iscsid is not yet ready, when the service is :-/
+-            sleep 1
+-        fi
+     fi
+ fi
+diff -urpa dracut-048.orig/modules.d/95nbd/module-setup.sh dracut-048/modules.d/95nbd/module-setup.sh
+--- dracut-048.orig/modules.d/95nbd/module-setup.sh    2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95nbd/module-setup.sh 2018-07-21 20:22:31.912227377 +0000
+@@ -34,9 +34,6 @@ install() {
+     inst nbd-client
+     inst_hook cmdline 90 "$moddir/parse-nbdroot.sh"
+     inst_script "$moddir/nbdroot.sh" "/sbin/nbdroot"
+-    if dracut_module_included "systemd-initrd"; then
+-        inst_script "$moddir/nbd-generator.sh" $systemdutildir/system-generators/dracut-nbd-generator
+-    fi
+     dracut_need_initqueue
+ }
+diff -urpa dracut-048.orig/modules.d/95nbd/nbdroot.sh dracut-048/modules.d/95nbd/nbdroot.sh
+--- dracut-048.orig/modules.d/95nbd/nbdroot.sh 2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95nbd/nbdroot.sh      2018-07-21 20:22:31.912227377 +0000
+@@ -97,37 +97,15 @@ if [ "$root" = "block:/dev/root" -o "$ro
+     write_fs_tab /dev/root "$nbdfstype" "$fsopts"
+     wait_for_dev -n /dev/root
+-    if [ -z "$DRACUT_SYSTEMD" ]; then
+-        printf '/bin/mount %s\n' \
+-             "$NEWROOT" \
+-             > $hookdir/mount/01-$$-nbd.sh
+-    fi
+-fi
+-
+-if strstr "$(nbd-client --help 2>&1)" "systemd-mark"; then
+-    preopts="--systemd-mark $preopts"
++    printf '/bin/mount %s\n' \
++         "$NEWROOT" \
++         > $hookdir/mount/01-$$-nbd.sh
+ fi
+ if [ "$nbdport" -gt 0 ] 2>/dev/null; then
+-    if [ -z "$DRACUT_SYSTEMD" ]; then
+-        nbd-client "$nbdserver" $nbdport /dev/nbd0 $preopts $opts || exit 1
+-    else
+-        systemd-run --no-block --service-type=forking --quiet \
+-                    --description="nbd nbd0" \
+-                    -p 'DefaultDependencies=no' \
+-                    -p 'KillMode=none' \
+-                    --unit="nbd0" -- nbd-client "$nbdserver" $nbdport /dev/nbd0 $preopts $opts >/dev/null 2>&1 || exit 1
+-    fi
++    nbd-client "$nbdserver" $nbdport /dev/nbd0 $preopts $opts || exit 1
+ else
+-    if [ -z "$DRACUT_SYSTEMD" ]; then
+-        nbd-client -name "$nbdport" "$nbdserver" /dev/nbd0 $preopts $opts || exit 1
+-    else
+-        systemd-run --no-block --service-type=forking --quiet \
+-                    --description="nbd nbd0" \
+-                    -p 'DefaultDependencies=no' \
+-                    -p 'KillMode=none' \
+-                    --unit="nbd0" --  nbd-client -name "$nbdport" "$nbdserver" /dev/nbd0 $preopts $opts >/dev/null 2>&1 || exit 1
+-    fi
++    nbd-client -name "$nbdport" "$nbdserver" /dev/nbd0 $preopts $opts || exit 1
+ fi
+ # NBD doesn't emit uevents when it gets connected, so kick it
+diff -urpa dracut-048.orig/modules.d/95nbd/parse-nbdroot.sh dracut-048/modules.d/95nbd/parse-nbdroot.sh
+--- dracut-048.orig/modules.d/95nbd/parse-nbdroot.sh   2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95nbd/parse-nbdroot.sh        2018-07-21 20:22:31.912227377 +0000
+@@ -46,11 +46,6 @@ fi
+ [ "${netroot%%:*}" = "nbd" ] || return
+-if [ -n "${DRACUT_SYSTEMD}" ] && [ "$root" = "dhcp" ]; then
+-    echo "root=$netroot" > /etc/cmdline.d/root.conf
+-    systemctl --no-block daemon-reload
+-fi
+-
+ # Check required arguments
+ netroot_to_var $netroot
+ [ -z "$server" ] && die "Argument server for nbdroot is missing"
+diff -urpa dracut-048.orig/modules.d/95nfs/module-setup.sh dracut-048/modules.d/95nfs/module-setup.sh
+--- dracut-048.orig/modules.d/95nfs/module-setup.sh    2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95nfs/module-setup.sh 2018-07-21 20:46:52.523140318 +0000
+@@ -73,7 +73,7 @@ install() {
+     local _i
+     local _nsslibs
+     inst_multiple -o portmap rpcbind rpc.statd mount.nfs \
+-        mount.nfs4 umount rpc.idmapd sed /etc/netconfig chmod "$tmpfilesdir/rpcbind.conf"
++        mount.nfs4 umount rpc.idmapd sed /etc/netconfig chmod
+     inst_multiple /etc/services /etc/nsswitch.conf /etc/rpc /etc/protocols /etc/idmapd.conf
+     if [[ $hostonly_cmdline == "yes" ]]; then
+diff -urpa dracut-048.orig/modules.d/95resume/module-setup.sh dracut-048/modules.d/95resume/module-setup.sh
+--- dracut-048.orig/modules.d/95resume/module-setup.sh 2018-07-21 20:22:15.810228337 +0000
++++ dracut-048/modules.d/95resume/module-setup.sh      2018-07-21 20:22:31.912227377 +0000
+@@ -33,15 +33,6 @@ install() {
+       [[ $_resumeconf ]] && printf "%s\n" "$_resumeconf" >> "${initdir}/etc/cmdline.d/95resume.conf"
+     fi
+-    # if systemd is included and has the hibernate-resume tool, use it and nothing else
+-    if dracut_module_included "systemd" && [[ -x $systemdutildir/systemd-hibernate-resume ]]; then
+-        inst_multiple -o \
+-                      $systemdutildir/system-generators/systemd-hibernate-resume-generator \
+-                      $systemdsystemunitdir/systemd-hibernate-resume@.service \
+-                      $systemdutildir/systemd-hibernate-resume
+-        return 0
+-    fi
+-
+     # Optional uswsusp support
+     for _bin in /usr/sbin/resume /usr/@lib@/suspend/resume /usr/@lib@/uswsusp/resume
+     do
+@@ -52,11 +43,7 @@ install() {
+         }
+     done
+-    if ! dracut_module_included "systemd"; then
+-        inst_hook cmdline 10 "$moddir/parse-resume.sh"
+-    else
+-        inst_script "$moddir/parse-resume.sh" /lib/dracut/parse-resume.sh
+-    fi
++    inst_hook cmdline 10 "$moddir/parse-resume.sh"
+     inst_script  "$moddir/resume.sh" /lib/dracut/resume.sh
+ }
+diff -urpa dracut-048.orig/modules.d/95rootfs-block/module-setup.sh dracut-048/modules.d/95rootfs-block/module-setup.sh
+--- dracut-048.orig/modules.d/95rootfs-block/module-setup.sh   2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95rootfs-block/module-setup.sh        2018-07-21 20:22:31.912227377 +0000
+@@ -69,11 +69,9 @@ install() {
+     inst_multiple umount
+     inst_multiple tr
+-    if ! dracut_module_included "systemd"; then
+-        inst_hook cmdline 95 "$moddir/parse-block.sh"
+-        inst_hook pre-udev 30 "$moddir/block-genrules.sh"
+-        inst_hook mount 99 "$moddir/mount-root.sh"
+-    fi
++    inst_hook cmdline 95 "$moddir/parse-block.sh"
++    inst_hook pre-udev 30 "$moddir/block-genrules.sh"
++    inst_hook mount 99 "$moddir/mount-root.sh"
+     inst_hook initqueue/timeout 99 "$moddir/rootfallback.sh"
+ }
+diff -urpa dracut-048.orig/modules.d/95udev-rules/module-setup.sh dracut-048/modules.d/95udev-rules/module-setup.sh
+--- dracut-048.orig/modules.d/95udev-rules/module-setup.sh     2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95udev-rules/module-setup.sh  2018-07-21 20:22:31.912227377 +0000
+@@ -11,20 +11,7 @@ install() {
+     inst_dir /etc/udev
+     inst_multiple -o /etc/udev/udev.conf
+-    [ -d ${initdir}/$systemdutildir ] || mkdir -p ${initdir}/$systemdutildir
+-    for _i in ${systemdutildir}/systemd-udevd ${udevdir}/udevd /sbin/udevd; do
+-        [ -x "$_i" ] || continue
+-        inst "$_i"
+-
+-        if ! [[ -f  ${initdir}${systemdutildir}/systemd-udevd ]]; then
+-            ln -fs "$_i" ${initdir}${systemdutildir}/systemd-udevd
+-        fi
+-        break
+-    done
+-    if ! [[ -e ${initdir}${systemdutildir}/systemd-udevd ]]; then
+-        derror "Cannot find [systemd-]udevd binary!"
+-        exit 1
+-    fi
++    inst /sbin/udevd;
+     inst_rules \
+         40-redhat.rules \
+@@ -56,11 +43,6 @@ install() {
+     # eudev rules
+     inst_rules 80-drivers-modprobe.rules
+-    if dracut_module_included "systemd"; then
+-        inst_multiple -o ${systemdutildir}/network/*.link
+-        [[ $hostonly ]] && inst_multiple -H -o /etc/systemd/network/*.link
+-    fi
+-
+     {
+         for i in cdrom tape dialout floppy; do
+             if ! grep -q "^$i:" "$initdir/etc/group" 2>/dev/null; then
+diff -urpa dracut-048.orig/modules.d/95virtfs/module-setup.sh dracut-048/modules.d/95virtfs/module-setup.sh
+--- dracut-048.orig/modules.d/95virtfs/module-setup.sh 2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/95virtfs/module-setup.sh      2018-07-21 20:22:31.913227377 +0000
+@@ -9,14 +9,6 @@ check() {
+         return 255
+     }
+-    if type -P systemd-detect-virt >/dev/null 2>&1; then
+-        vm=$(systemd-detect-virt --vm >/dev/null 2>&1)
+-        (($? != 0)) && return 255
+-        [[ $vm = "qemu" ]] && return 0
+-        [[ $vm = "kvm" ]] && return 0
+-        [[ $vm = "bochs" ]] && return 0
+-    fi
+-
+     for i in /sys/class/dmi/id/*_vendor; do
+         [[ -f $i ]] || continue
+         read vendor < $i
+diff -urpa dracut-048.orig/modules.d/98usrmount/module-setup.sh dracut-048/modules.d/98usrmount/module-setup.sh
+--- dracut-048.orig/modules.d/98usrmount/module-setup.sh       2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/98usrmount/module-setup.sh    2018-07-21 20:22:31.913227377 +0000
+@@ -13,9 +13,7 @@ depends() {
+ # called by dracut
+ install() {
+-    if ! dracut_module_included "systemd"; then
+-        inst_hook pre-pivot 50 "$moddir/mount-usr.sh"
+-    fi
++    inst_hook pre-pivot 50 "$moddir/mount-usr.sh"
+     :
+ }
+diff -urpa dracut-048.orig/modules.d/99base/dracut-lib.sh dracut-048/modules.d/99base/dracut-lib.sh
+--- dracut-048.orig/modules.d/99base/dracut-lib.sh     2018-07-21 20:22:15.815228337 +0000
++++ dracut-048/modules.d/99base/dracut-lib.sh  2018-07-21 20:22:31.913227377 +0000
+@@ -1,6 +1,5 @@
+ #!/bin/sh
+-export DRACUT_SYSTEMD
+ export NEWROOT
+ if [ -n "$NEWROOT" ]; then
+     [ -d $NEWROOT ] || mkdir -p -m 0755 $NEWROOT
+@@ -58,32 +57,13 @@ trim() {
+     printf "%s" "$var"
+ }
+-if [ -z "$DRACUT_SYSTEMD" ]; then
+-
+-    warn() {
+-        check_quiet
+-        echo "<28>dracut Warning: $*" > /dev/kmsg
+-        echo "dracut Warning: $*" >&2
+-    }
+-
+-    info() {
+-        check_quiet
+-        echo "<30>dracut: $*" > /dev/kmsg
+-        [ "$DRACUT_QUIET" != "yes" ] && \
+-            echo "dracut: $*" >&2
+-    }
+-
+-else
+-
+-    warn() {
+-        echo "Warning: $*" >&2
+-    }
+-
+-    info() {
+-        echo "$*"
+-    }
++warn() {
++    echo "Warning: $*" >&2
++}
+-fi
++info() {
++    echo "$*"
++}
+ vwarn() {
+     while read line || [ -n "$line" ]; do
+@@ -475,10 +455,6 @@ die() {
+         source_hook "shutdown-emergency"
+     fi
+-    if [ -n "$DRACUT_SYSTEMD" ]; then
+-        systemctl --no-block --force halt
+-    fi
+-
+     exit 1
+ }
+@@ -883,77 +859,7 @@ wait_for_mount()
+     } >> "$hookdir/emergency/90-${_name}.sh"
+ }
+-# get a systemd-compatible unit name from a path
+-# (mimicks unit_name_from_path_instance())
+-dev_unit_name()
+-{
+-    local dev="$1"
+-
+-    if command -v systemd-escape >/dev/null; then
+-        systemd-escape -p -- "$dev"
+-        return
+-    fi
+-    if [ "$dev" = "/" -o -z "$dev" ]; then
+-        printf -- "-"
+-        exit 0
+-    fi
+-
+-    dev="${1%%/}"
+-    dev="${dev##/}"
+-    dev="$(str_replace "$dev" '\' '\x5c')"
+-    dev="$(str_replace "$dev" '-' '\x2d')"
+-    if [ "${dev##.}" != "$dev" ]; then
+-        dev="\x2e${dev##.}"
+-    fi
+-    dev="$(str_replace "$dev" '/' '-')"
+-
+-    printf -- "%s" "$dev"
+-}
+-
+-# set_systemd_timeout_for_dev <dev>
+-# Set 'rd.timeout' as the systemd timeout for <dev>
+-
+-set_systemd_timeout_for_dev()
+-{
+-    local _name
+-    local _needreload
+-    local _noreload
+-    local _timeout
+-
+-    if [ "$1" = "-n" ]; then
+-        _noreload=1
+-        shift
+-    fi
+-
+-    _timeout=$(getarg rd.timeout)
+-    _timeout=${_timeout:-0}
+-
+-    if [ -n "$DRACUT_SYSTEMD" ]; then
+-        _name=$(dev_unit_name "$1")
+-        if ! [ -L ${PREFIX}/etc/systemd/system/initrd.target.wants/${_name}.device ]; then
+-            [ -d ${PREFIX}/etc/systemd/system/initrd.target.wants ] || mkdir -p ${PREFIX}/etc/systemd/system/initrd.target.wants
+-            ln -s ../${_name}.device ${PREFIX}/etc/systemd/system/initrd.target.wants/${_name}.device
+-            type mark_hostonly >/dev/null 2>&1 && mark_hostonly /etc/systemd/system/initrd.target.wants/${_name}.device
+-            _needreload=1
+-        fi
+-
+-        if ! [ -f ${PREFIX}/etc/systemd/system/${_name}.device.d/timeout.conf ]; then
+-            mkdir -p ${PREFIX}/etc/systemd/system/${_name}.device.d
+-            {
+-                echo "[Unit]"
+-                echo "JobTimeoutSec=$_timeout"
+-                echo "JobRunningTimeoutSec=$_timeout"
+-            } > ${PREFIX}/etc/systemd/system/${_name}.device.d/timeout.conf
+-            type mark_hostonly >/dev/null 2>&1 && mark_hostonly /etc/systemd/system/${_name}.device.d/timeout.conf
+-            _needreload=1
+-        fi
+-
+-        if [ -z "$PREFIX" ] && [ "$_needreload" = 1 ] && [ -z "$_noreload" ]; then
+-            /sbin/initqueue --onetime --unique --name daemon-reload systemctl daemon-reload
+-        fi
+-    fi
+-}
+ # wait_for_dev <dev>
+ #
+ # Installs a initqueue-finished script,
+@@ -981,8 +887,6 @@ wait_for_dev()
+         printf '[ -e "%s" ] || ' $1
+         printf 'warn "\"%s\" does not exist"\n' $1
+     } >> "${PREFIX}$hookdir/emergency/80-${_name}.sh"
+-
+-    set_systemd_timeout_for_dev $_noreload $1
+ }
+ cancel_wait_for_dev()
+@@ -991,12 +895,6 @@ cancel_wait_for_dev()
+     _name="$(str_replace "$1" '/' '\x2f')"
+     rm -f -- "$hookdir/initqueue/finished/devexists-${_name}.sh"
+     rm -f -- "$hookdir/emergency/80-${_name}.sh"
+-    if [ -n "$DRACUT_SYSTEMD" ]; then
+-        _name=$(dev_unit_name "$1")
+-        rm -f -- ${PREFIX}/etc/systemd/system/initrd.target.wants/${_name}.device
+-        rm -f -- ${PREFIX}/etc/systemd/system/${_name}.device.d/timeout.conf
+-        /sbin/initqueue --onetime --unique --name daemon-reload systemctl daemon-reload
+-    fi
+ }
+ killproc() {
+@@ -1081,43 +979,35 @@ fi
+ _emergency_shell()
+ {
+     local _name="$1"
+-    if [ -n "$DRACUT_SYSTEMD" ]; then
+-        > /.console_lock
+-        echo "PS1=\"$_name:\\\${PWD}# \"" >/etc/profile
+-        systemctl start dracut-emergency.service
+-        rm -f -- /etc/profile
+-        rm -f -- /.console_lock
+-    else
+-        debug_off
+-        source_hook "$hook"
+-        echo
+-        /sbin/rdsosreport
+-        echo 'You might want to save "/run/initramfs/rdsosreport.txt" to a USB stick or /boot'
+-        echo 'after mounting them and attach it to a bug report.'
+-        if ! RD_DEBUG= getargbool 0 rd.debug -d -y rdinitdebug -d -y rdnetdebug; then
+-            echo
+-            echo 'To get more debug information in the report,'
+-            echo 'reboot with "rd.debug" added to the kernel command line.'
+-        fi
+-        echo
+-        echo 'Dropping to debug shell.'
++    debug_off
++    source_hook "$hook"
++    echo
++    /sbin/rdsosreport
++    echo 'You might want to save "/run/initramfs/rdsosreport.txt" to a USB stick or /boot'
++    echo 'after mounting them and attach it to a bug report.'
++    if ! RD_DEBUG= getargbool 0 rd.debug -d -y rdinitdebug -d -y rdnetdebug; then
+         echo
+-        export PS1="$_name:\${PWD}# "
+-        [ -e /.profile ] || >/.profile
+-
+-        _ctty="$(RD_DEBUG= getarg rd.ctty=)" && _ctty="/dev/${_ctty##*/}"
+-        if [ -z "$_ctty" ]; then
+-            _ctty=console
+-            while [ -f /sys/class/tty/$_ctty/active ]; do
+-                _ctty=$(cat /sys/class/tty/$_ctty/active)
+-                _ctty=${_ctty##* } # last one in the list
+-            done
+-            _ctty=/dev/$_ctty
+-        fi
+-        [ -c "$_ctty" ] || _ctty=/dev/tty1
+-        case "$(/usr/bin/setsid --help 2>&1)" in *--ctty*) CTTY="--ctty";; esac
+-        setsid $CTTY /bin/sh -i -l 0<>$_ctty 1<>$_ctty 2<>$_ctty
++        echo 'To get more debug information in the report,'
++        echo 'reboot with "rd.debug" added to the kernel command line.'
++    fi
++    echo
++    echo 'Dropping to debug shell.'
++    echo
++    export PS1="$_name:\${PWD}# "
++    [ -e /.profile ] || >/.profile
++
++    _ctty="$(RD_DEBUG= getarg rd.ctty=)" && _ctty="/dev/${_ctty##*/}"
++    if [ -z "$_ctty" ]; then
++        _ctty=console
++        while [ -f /sys/class/tty/$_ctty/active ]; do
++            _ctty=$(cat /sys/class/tty/$_ctty/active)
++            _ctty=${_ctty##* } # last one in the list
++        done
++        _ctty=/dev/$_ctty
+     fi
++    [ -c "$_ctty" ] || _ctty=/dev/tty1
++    case "$(/usr/bin/setsid --help 2>&1)" in *--ctty*) CTTY="--ctty";; esac
++    setsid $CTTY /bin/sh -i -l 0<>$_ctty 1<>$_ctty 2<>$_ctty
+ }
+ emergency_shell()
+diff -urpa dracut-048.orig/modules.d/99base/init.sh dracut-048/modules.d/99base/init.sh
+--- dracut-048.orig/modules.d/99base/init.sh   2018-07-21 20:22:15.815228337 +0000
++++ dracut-048/modules.d/99base/init.sh        2018-07-21 20:22:31.913227377 +0000
+@@ -150,7 +150,7 @@ getargbool 0 rd.udev.info -d -y rdudevin
+ getargbool 0 rd.udev.debug -d -y rdudevdebug && UDEV_LOG=debug
+ # start up udev and trigger cold plugs
+-UDEV_LOG=$UDEV_LOG $systemdutildir/systemd-udevd --daemon --resolve-names=never
++UDEV_LOG=$UDEV_LOG /sbin/udevd --daemon --resolve-names=never
+ UDEV_QUEUE_EMPTY="udevadm settle --timeout=0"
+diff -urpa dracut-048.orig/modules.d/99base/memtrace-ko.sh dracut-048/modules.d/99base/memtrace-ko.sh
+--- dracut-048.orig/modules.d/99base/memtrace-ko.sh    2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/99base/memtrace-ko.sh 2018-07-21 20:22:31.913227377 +0000
+@@ -23,7 +23,7 @@ get_want_events() {
+ }
+ get_event_filter() {
+-    echo "comm == systemd-udevd || comm == modprobe || comm == insmod"
++    echo "comm == udevd || comm == modprobe || comm == insmod"
+ }
+ is_trace_ready() {
+@@ -63,7 +63,7 @@ prepare_trace() {
+     echo "$(get_want_events)" > $trace_base/tracing/set_event
+     # There are three kinds of known applications for module loading:
+-    # "systemd-udevd", "modprobe" and "insmod".
++    # "udevd", "modprobe" and "insmod".
+     # Set them as the global events filter.
+     # NOTE: Some kernel may not support this format of filter, anyway
+     #       the operation will fail and it doesn't matter.
+diff -urpa dracut-048.orig/modules.d/99base/module-setup.sh dracut-048/modules.d/99base/module-setup.sh
+--- dracut-048.orig/modules.d/99base/module-setup.sh   2018-07-21 20:22:15.816228337 +0000
++++ dracut-048/modules.d/99base/module-setup.sh        2018-07-21 20:22:31.914227377 +0000
+@@ -46,11 +46,8 @@ install() {
+     inst_simple "$moddir/dracut-lib.sh" "/lib/dracut-lib.sh"
+     mkdir -p "${initdir}/var"
+-    if ! dracut_module_included "systemd"; then
+-        inst_multiple switch_root || dfatal "Failed to install switch_root"
+-        inst_hook cmdline 10 "$moddir/parse-root-opts.sh"
+-        inst_multiple -o $systemdutildir/systemd-timestamp
+-    fi
++    inst_multiple switch_root || dfatal "Failed to install switch_root"
++    inst_hook cmdline 10 "$moddir/parse-root-opts.sh"
+     if [[ $realinitpath ]]; then
+         for i in $realinitpath; do
+@@ -92,11 +89,8 @@ install() {
+     ## save host_devs which we need bring up
+     if [[ $hostonly_cmdline == "yes" ]]; then
+-        if [[ -f "$initdir/lib/dracut/need-initqueue" ]] || ! dracut_module_included "systemd"; then
++        if [[ -f "$initdir/lib/dracut/need-initqueue" ]]; then
+             (
+-                if dracut_module_included "systemd"; then
+-                    DRACUT_SYSTEMD=1
+-                fi
+                 PREFIX="$initdir"
+                 . "$moddir/dracut-lib.sh"
+diff -urpa dracut-048.orig/modules.d/99fs-lib/fs-lib.sh dracut-048/modules.d/99fs-lib/fs-lib.sh
+--- dracut-048.orig/modules.d/99fs-lib/fs-lib.sh       2018-07-06 08:37:51.000000000 +0000
++++ dracut-048/modules.d/99fs-lib/fs-lib.sh    2018-07-21 20:22:31.914227377 +0000
+@@ -247,9 +247,4 @@ write_fs_tab() {
+     fi
+     echo "$_root /sysroot $_rootfstype $_rootflags $_fspassno 0" >> /etc/fstab
+-
+-    if type systemctl >/dev/null 2>/dev/null; then
+-        systemctl daemon-reload
+-        systemctl --no-block start initrd-root-fs.target
+-    fi
+ }
diff --git a/no_systemd_udevd.patch b/no_systemd_udevd.patch
deleted file mode 100644 (file)
index 65f30d7..0000000
+++ /dev/null
@@ -1,69 +0,0 @@
-diff -urpa dracut-047.orig/modules.d/40network/net-lib.sh dracut-047/modules.d/40network/net-lib.sh
---- dracut-047.orig/modules.d/40network/net-lib.sh     2018-02-19 09:00:33.000000000 +0000
-+++ dracut-047/modules.d/40network/net-lib.sh  2018-03-15 12:20:15.154971442 +0000
-@@ -52,7 +52,7 @@ iface_name() {
- configured_ifaces() {
-     local IFACES="" iface_id="" rv=1
-     [ -e "/tmp/net.ifaces" ] && read IFACES < /tmp/net.ifaces
--    if { pidof udevd || pidof systemd-udevd; } > /dev/null; then
-+    if { pidof udevd; } > /dev/null; then
-         for iface_id in $IFACES; do
-             echo $(iface_name $iface_id)
-             rv=0
-diff -urpa dracut-047.orig/modules.d/95iscsi/parse-iscsiroot.sh dracut-047/modules.d/95iscsi/parse-iscsiroot.sh
---- dracut-047.orig/modules.d/95iscsi/parse-iscsiroot.sh       2018-02-19 09:00:33.000000000 +0000
-+++ dracut-047/modules.d/95iscsi/parse-iscsiroot.sh    2018-03-15 12:20:15.155971442 +0000
-@@ -41,7 +41,7 @@ if [ "${root%%:*}" = "iscsi" ] ; then
-     netroot=$root
-     # if root is not specified try to mount the whole iSCSI LUN
-     printf 'ENV{DEVTYPE}!="partition", SYMLINK=="disk/by-path/*-iscsi-*-*", SYMLINK+="root"\n' >> /etc/udev/rules.d/99-iscsi-root.rules
--    [ -n "$DRACUT_SYSTEMD" ] && systemctl is-active systemd-udevd && udevadm control --reload-rules
-+    udevadm control --reload-rules
-     root=/dev/root
-     write_fs_tab /dev/root
-@@ -58,7 +58,7 @@ done
- if [ "${root}" = "/dev/root" ] && getarg "netroot=dhcp" ; then
-     # if root is not specified try to mount the whole iSCSI LUN
-     printf 'ENV{DEVTYPE}!="partition", SYMLINK=="disk/by-path/*-iscsi-*-*", SYMLINK+="root"\n' >> /etc/udev/rules.d/99-iscsi-root.rules
--    [ -n "$DRACUT_SYSTEMD" ] && systemctl is-active systemd-udevd && udevadm control --reload-rules
-+    udevadm control --reload-rules
- fi
- if [ -n "$iscsiroot" ] ; then
-diff -urpa dracut-047.orig/modules.d/95udev-rules/module-setup.sh dracut-047/modules.d/95udev-rules/module-setup.sh
---- dracut-047.orig/modules.d/95udev-rules/module-setup.sh     2018-02-19 09:00:33.000000000 +0000
-+++ dracut-047/modules.d/95udev-rules/module-setup.sh  2018-03-15 12:20:15.155971442 +0000
-@@ -12,19 +12,7 @@ install() {
-     inst_multiple -o /etc/udev/udev.conf
-     [ -d ${initdir}/$systemdutildir ] || mkdir -p ${initdir}/$systemdutildir
--    for _i in ${systemdutildir}/systemd-udevd ${udevdir}/udevd /sbin/udevd; do
--        [ -x "$_i" ] || continue
--        inst "$_i"
--
--        if ! [[ -f  ${initdir}${systemdutildir}/systemd-udevd ]]; then
--            ln -fs "$_i" ${initdir}${systemdutildir}/systemd-udevd
--        fi
--        break
--    done
--    if ! [[ -e ${initdir}${systemdutildir}/systemd-udevd ]]; then
--        derror "Cannot find [systemd-]udevd binary!"
--        exit 1
--    fi
-+    inst /sbin/udevd;
-     inst_rules \
-         40-redhat.rules \
-diff -urpa dracut-047.orig/modules.d/99base/init.sh dracut-047/modules.d/99base/init.sh
---- dracut-047.orig/modules.d/99base/init.sh   2018-03-15 12:17:03.000000000 +0000
-+++ dracut-047/modules.d/99base/init.sh        2018-03-15 12:20:15.155971442 +0000
-@@ -150,7 +150,7 @@ getargbool 0 rd.udev.info -d -y rdudevin
- getargbool 0 rd.udev.debug -d -y rdudevdebug && UDEV_LOG=debug
- # start up udev and trigger cold plugs
--UDEV_LOG=$UDEV_LOG $systemdutildir/systemd-udevd --daemon --resolve-names=never
-+UDEV_LOG=$UDEV_LOG /sbin/udevd --daemon --resolve-names=never
- UDEV_QUEUE_EMPTY="udevadm settle --timeout=0"