diff --git a/delay-fsck-cryptsetup-after-md-dmraid-lvm-are-started.patch b/delay-fsck-cryptsetup-after-md-dmraid-lvm-are-started.patch index 026de00..06b2cb6 100644 --- a/delay-fsck-cryptsetup-after-md-dmraid-lvm-are-started.patch +++ b/delay-fsck-cryptsetup-after-md-dmraid-lvm-are-started.patch @@ -1,6 +1,6 @@ From: Frederic Crozat Date: Wed, 9 Nov 2011 11:10:49 +0100 -Subject: delay fsck / cryptsetup after md / dmraid / lvm are started +Subject: delay fsck / cryptsetup after md / dmraid are started --- src/cryptsetup/cryptsetup-generator.c | 1 + @@ -13,7 +13,7 @@ Subject: delay fsck / cryptsetup after md / dmraid / lvm are started "Conflicts=umount.target\n" "DefaultDependencies=no\n" "BindsTo=dev-mapper-%i.device\n" -+ "After=md.service dmraid.service lvm.service\n" ++ "After=md.service dmraid.service\n" "After=systemd-readahead-collect.service systemd-readahead-replay.service\n", f); @@ -24,7 +24,7 @@ Subject: delay fsck / cryptsetup after md / dmraid / lvm are started DefaultDependencies=no BindsTo=%i.device -After=systemd-readahead-collect.service systemd-readahead-replay.service %i.device -+After=systemd-readahead-collect.service systemd-readahead-replay.service %i.device lvm.service md.service dmraid.service ++After=systemd-readahead-collect.service systemd-readahead-replay.service %i.device md.service dmraid.service Before=shutdown.target [Service] diff --git a/ensure-DM-and-LVM-are-started-before-local-fs-pre-target.patch b/ensure-DM-and-LVM-are-started-before-local-fs-pre-target.patch index e095da1..aca1822 100644 --- a/ensure-DM-and-LVM-are-started-before-local-fs-pre-target.patch +++ b/ensure-DM-and-LVM-are-started-before-local-fs-pre-target.patch @@ -1,8 +1,8 @@ From: Frederic Crozat Date: Thu, 9 Feb 2012 16:19:38 +0000 -Subject: ensure DM and LVM are started before local-fs-pre-target +Subject: ensure DM and dmraid are started before local-fs-pre-target -ensure md / lvm /dmraid is started before mounting partitions, +ensure md / dmraid is started before mounting partitions, if fsck was disabled for them (bnc#733283). --- units/local-fs-pre.target | 1 + @@ -14,4 +14,4 @@ if fsck was disabled for them (bnc#733283). Description=Local File Systems (Pre) Documentation=man:systemd.special(7) RefuseManualStart=yes -+After=md.service lvm.service dmraid.service ++After=md.service dmraid.service diff --git a/force-lvm-restart-after-cryptsetup-target-is-reached.patch b/force-lvm-restart-after-cryptsetup-target-is-reached.patch deleted file mode 100644 index d40fda5..0000000 --- a/force-lvm-restart-after-cryptsetup-target-is-reached.patch +++ /dev/null @@ -1,102 +0,0 @@ -From: Frederic Crozat -Date: Mon, 7 Nov 2011 18:04:20 +0100 -Subject: force lvm restart after cryptsetup target is reached - ---- - src/cryptsetup/cryptsetup-generator.c | 57 ++++++++++++++++++++++++++++++++++- - 1 file changed, 56 insertions(+), 1 deletion(-) - ---- systemd-206.orig/src/cryptsetup/cryptsetup-generator.c -+++ systemd-206/src/cryptsetup/cryptsetup-generator.c -@@ -22,6 +22,7 @@ - #include - #include - #include -+#include - - #include "log.h" - #include "util.h" -@@ -64,6 +65,54 @@ static bool has_option(const char *hayst - return false; - } - -+static int create_storage_after_cryptsetup (void) { -+ _cleanup_free_ char *to = NULL, *p = NULL; -+ _cleanup_fclose_ FILE *f = NULL; -+ -+ if (asprintf(&p, "%s/storage-after-cryptsetup.service", arg_dest) < 0) -+ return log_oom(); -+ -+ if (!(f = fopen(p, "wxe"))) { -+ log_error("Failed to create unit file: %m"); -+ return -errno; -+ } -+ -+ fprintf(f, -+ "[Unit]\n" -+ "Description=Restart storage after cryptsetup\n" -+ "DefaultDependencies=no\n" -+ "After=cryptsetup.target\n" -+ "Wants=cryptsetup.target\n" -+ "Before=local-fs.target\n" -+ "Before=shutdown.target\n"); -+ -+ fprintf(f, -+ "\n[Service]\n" -+ "RemainAfterExit=true\n" -+ "Type=oneshot\n" -+ "TimeoutSec=0\n" -+ "ExecStart=/usr/bin/systemctl restart lvm.service\n"); -+ -+ fflush(f); -+ -+ if (ferror(f)) { -+ log_error("Failed to write file: %m"); -+ return -errno; -+ } -+ -+ if (asprintf(&to, "%s/local-fs.target.wants/storage-after-cryptsetup.service", arg_dest) < 0) -+ return log_oom(); -+ -+ mkdir_parents(to, 0755); -+ -+ if (symlink("../storage-after-cryptsetup.service", to) < 0) { -+ log_error("Failed to create symlink ../storage-after-cryptsetup.service to '%s': %m", to); -+ return -errno; -+ } -+ -+ return 0; -+} -+ - static int create_disk( - const char *name, - const char *device, -@@ -334,6 +383,7 @@ int main(int argc, char *argv[]) { - _cleanup_fclose_ FILE *f = NULL; - unsigned n = 0; - int r = EXIT_SUCCESS; -+ bool no_crypttab = false; - char **i; - - if (argc > 1 && argc != 4) { -@@ -361,8 +411,10 @@ int main(int argc, char *argv[]) { - - f = fopen("/etc/crypttab", "re"); - if (!f) { -- if (errno == ENOENT) -+ if (errno == ENOENT) { -+ no_crypttab = true; - r = EXIT_SUCCESS; -+ } - else { - r = EXIT_FAILURE; - log_error("Failed to open /etc/crypttab: %m"); -@@ -464,5 +516,8 @@ next: - r = EXIT_FAILURE; - } - -+ if ((r == EXIT_SUCCESS && !no_crypttab) && (create_storage_after_cryptsetup () < 0)) -+ r = EXIT_FAILURE; -+ - return r; - } diff --git a/systemd-mini.changes b/systemd-mini.changes index a6943f5..76c0155 100644 --- a/systemd-mini.changes +++ b/systemd-mini.changes @@ -1,3 +1,12 @@ +------------------------------------------------------------------- +Fri Sep 6 15:02:08 UTC 2013 - fcrozat@suse.com + +- Remove + force-lvm-restart-after-cryptsetup-target-is-reached.patch and + remove additional dependencies on LVM in other patches: LVM has + now systemd support, no need to work around it anymore in + systemd. + ------------------------------------------------------------------- Wed Aug 21 10:42:35 UTC 2013 - idonmez@suse.com diff --git a/systemd-mini.spec b/systemd-mini.spec index deca2fd..09e188d 100644 --- a/systemd-mini.spec +++ b/systemd-mini.spec @@ -128,7 +128,6 @@ Patch6: insserv-generator.patch Patch7: service-flags-sysv-service-with-detected-pid-as-RemainAfte.patch Patch8: module-load-handle-SUSE-etc-sysconfig-kernel-module-list.patch Patch9: remain_after_exit-initscript-heuristic-and-add-new-LSB-hea.patch -Patch10: force-lvm-restart-after-cryptsetup-target-is-reached.patch Patch11: delay-fsck-cryptsetup-after-md-dmraid-lvm-are-started.patch Patch12: Fix-run-lock-directories-permissions-to-follow-openSUSE-po.patch Patch13: ensure-sysctl-are-applied-after-modules-are-loaded.patch @@ -393,7 +392,6 @@ cp %{SOURCE7} m4/ %patch7 -p1 %patch8 -p1 %patch9 -p1 -%patch10 -p1 %patch11 -p1 %patch12 -p1 %patch13 -p1 diff --git a/systemd.changes b/systemd.changes index a6943f5..76c0155 100644 --- a/systemd.changes +++ b/systemd.changes @@ -1,3 +1,12 @@ +------------------------------------------------------------------- +Fri Sep 6 15:02:08 UTC 2013 - fcrozat@suse.com + +- Remove + force-lvm-restart-after-cryptsetup-target-is-reached.patch and + remove additional dependencies on LVM in other patches: LVM has + now systemd support, no need to work around it anymore in + systemd. + ------------------------------------------------------------------- Wed Aug 21 10:42:35 UTC 2013 - idonmez@suse.com diff --git a/systemd.spec b/systemd.spec index 515f27a..ec9c1d3 100644 --- a/systemd.spec +++ b/systemd.spec @@ -123,7 +123,6 @@ Patch6: insserv-generator.patch Patch7: service-flags-sysv-service-with-detected-pid-as-RemainAfte.patch Patch8: module-load-handle-SUSE-etc-sysconfig-kernel-module-list.patch Patch9: remain_after_exit-initscript-heuristic-and-add-new-LSB-hea.patch -Patch10: force-lvm-restart-after-cryptsetup-target-is-reached.patch Patch11: delay-fsck-cryptsetup-after-md-dmraid-lvm-are-started.patch Patch12: Fix-run-lock-directories-permissions-to-follow-openSUSE-po.patch Patch13: ensure-sysctl-are-applied-after-modules-are-loaded.patch @@ -388,7 +387,6 @@ cp %{SOURCE7} m4/ %patch7 -p1 %patch8 -p1 %patch9 -p1 -%patch10 -p1 %patch11 -p1 %patch12 -p1 %patch13 -p1