From 25c1c5ad91f3d523c471dc8adb4bef29faf2c2d9 Mon Sep 17 00:00:00 2001 From: Michal Schmidt Date: Sep 29 2011 19:41:16 +0000 Subject: Undo the workaround. Kay says it does not belong in systemd. Unresolves: #741655 --- diff --git a/fedora-crypto-lvm-hack b/fedora-crypto-lvm-hack deleted file mode 100755 index c7c4313..0000000 --- a/fedora-crypto-lvm-hack +++ /dev/null @@ -1,12 +0,0 @@ -#!/bin/sh -# -# Test if the given device is an LVM PV. If yes, activate its VG. -# -# Suggested by Milan Brož in -# https://bugzilla.redhat.com/show_bug.cgi?id=741655#c19 - -device="$1" -[ -b "$device" ] || exit 1 - -blkid -t TYPE=LVM2_member "$device" > /dev/null && \ - vgchange -a y $(pvs --noheadings -o vg_name "$device") diff --git a/fedora-crypto-lvm-hack.patch b/fedora-crypto-lvm-hack.patch deleted file mode 100644 index 30789cf..0000000 --- a/fedora-crypto-lvm-hack.patch +++ /dev/null @@ -1,23 +0,0 @@ -Fedora workaround for bz741655 - -After unlocking a crypto device, give LVM a chance to assemble a VG from it. -Needed to make the crypto-on-lvm-on-crypto disk layout work. - -Non-upstream patch. Will be obsoleted as soon as LVM gets the planned -'policy daemon which will activate LV according to some system policy'. - -Index: systemd-36/src/cryptsetup-generator.c -=================================================================== ---- systemd-36.orig/src/cryptsetup-generator.c -+++ systemd-36/src/cryptsetup-generator.c -@@ -132,8 +132,10 @@ static int create_disk( - "RemainAfterExit=yes\n" - "TimeoutSec=0\n" /* the binary handles timeouts anyway */ - "ExecStart=" SYSTEMD_CRYPTSETUP_PATH " attach '%s' '%s' '%s' '%s'\n" -+ "ExecStartPost=/lib/systemd/fedora-crypto-lvm-hack '/dev/mapper/%s'\n" - "ExecStop=" SYSTEMD_CRYPTSETUP_PATH " detach '%s'\n", - name, u, strempty(password), strempty(options), -+ name, - name); - - if (has_option(options, "tmp")) diff --git a/systemd.spec b/systemd.spec index 3375e0a..e84dd77 100644 --- a/systemd.spec +++ b/systemd.spec @@ -2,7 +2,7 @@ Name: systemd Url: http://www.freedesktop.org/wiki/Software/systemd BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Version: 36 -Release: 4%{?dist} +Release: 5%{?dist} License: GPLv2+ Group: System Environment/Base Summary: A System and Service Manager @@ -44,12 +44,8 @@ Source1: macros.systemd Source2: systemd-sysv-convert # Stop-gap, just to ensure things work out-of-the-box for this driver. Source3: udlfb.conf -# Workaround https://bugzilla.redhat.com/show_bug.cgi?id=741655 -Source4: fedora-crypto-lvm-hack # We revert this one for https://bugzilla.redhat.com/show_bug.cgi?id=741078 Patch0: 0001-unit-fix-complementing-of-requirement-deps-with-Afte.patch -# Workaround https://bugzilla.redhat.com/show_bug.cgi?id=741655 -Patch100: fedora-crypto-lvm-hack.patch # For sysvinit tools Obsoletes: SysVinit < 2.86-24, sysvinit < 2.86-24 @@ -113,7 +109,6 @@ SysV compatibility tools for systemd %prep %setup -q %patch0 -p1 -R -%patch100 -p1 %build %configure --with-rootdir= --with-distro=fedora --with-rootlibdir=/%{_lib} @@ -172,9 +167,6 @@ install -m 0755 %{SOURCE2} %{buildroot}%{_bindir}/ mkdir -p %{buildroot}%{_sysconfdir}/modprobe.d/ install -m 0644 %{SOURCE3} %{buildroot}%{_sysconfdir}/modprobe.d/ -# install the Fedora crypto-LVM hack -install -m 0755 %{SOURCE4} %{buildroot}/lib/systemd/ - %clean rm -rf $RPM_BUILD_ROOT @@ -268,7 +260,6 @@ fi /usr/bin/systemd-stdio-bridge /usr/bin/systemd-analyze /lib/systemd/systemd-* -/lib/systemd/fedora-crypto-lvm-hack /lib/udev/rules.d/*.rules /lib/systemd/system-generators/systemd-cryptsetup-generator /lib/systemd/system-generators/systemd-getty-generator @@ -362,6 +353,10 @@ fi %{_bindir}/systemd-sysv-convert %changelog +* Thu Sep 29 2011 Michal Schmidt - 36-5 +- Undo the workaround. Kay says it does not belong in systemd. +- Unresolves: #741655 + * Thu Sep 29 2011 Michal Schmidt - 36-4 - Workaround for the crypto-on-lvm-on-crypto disk layout - Resolves: #741655