[systemd-commits] 21 commits - Makefile.am man/systemd.unit.xml src/automount.c src/fsck.c src/job.c src/load-fragment.c src/manager.c src/mount.c src/path.c src/service.c src/socket.c src/swap.c src/target.c src/timer.c src/unit.c src/unit.h TODO units/basic.target units/emergency.service units/fedora units/final.target units/.gitignore units/multi-user.target.m4 units/quotacheck.service.in units/quotaon.service units/rescue.service.m4 units/rescue.target units/shutdown.target units/sysinit.target units/sysinit.target.m4 units/umount.target
Lennart Poettering
lennart at kemper.freedesktop.org
Fri Oct 29 07:28:41 PDT 2010
Makefile.am | 78 ++++++++++++++++-----------------
TODO | 10 ----
man/systemd.unit.xml | 14 -----
src/automount.c | 5 +-
src/fsck.c | 4 -
src/job.c | 24 ++++------
src/load-fragment.c | 1
src/manager.c | 2
src/mount.c | 6 +-
src/path.c | 8 ++-
src/service.c | 4 -
src/socket.c | 8 ++-
src/swap.c | 2
src/target.c | 2
src/timer.c | 8 ++-
src/unit.c | 6 --
src/unit.h | 3 -
units/.gitignore | 2
units/basic.target | 4 -
units/emergency.service | 2
units/fedora/plymouth-halt.service | 5 --
units/fedora/plymouth-kexec.service | 19 ++++++++
units/fedora/plymouth-poweroff.service | 5 --
units/fedora/plymouth-quit.service | 5 --
units/fedora/plymouth-reboot.service | 5 --
units/fedora/plymouth-start.service | 17 +++++++
units/fedora/prefdm.service | 6 --
units/fedora/rc-local.service | 7 --
units/fedora/single.service | 31 -------------
units/fedora/sysinit.service | 21 --------
units/final.target | 1
units/multi-user.target.m4 | 4 -
units/quotacheck.service.in | 2
units/quotaon.service | 2
units/rescue.service.m4 | 33 +++++++++++++
units/rescue.target | 4 -
units/shutdown.target | 1
units/sysinit.target | 15 ++++++
units/sysinit.target.m4 | 20 --------
units/umount.target | 1
40 files changed, 185 insertions(+), 212 deletions(-)
New commits:
commit 9423fd773e093d8d1fb5fcf63f527f2b531cac02
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 16:27:58 2010 +0200
units: fix variable expansion
diff --git a/units/rescue.service.m4 b/units/rescue.service.m4
index d173beb..d31282d 100644
--- a/units/rescue.service.m4
+++ b/units/rescue.service.m4
@@ -22,7 +22,7 @@ ExecStartPre=-/bin/plymouth --hide-splash
ExecStartPre=-/bin/echo 'Welcome to rescue mode. Use "systemctl default" or ^D to activate default mode.'
m4_ifdef(`TARGET_FEDORA',
`EnvironmentFile=/etc/sysconfig/init
-ExecStart=-/bin/bash -c "exec $SINGLE"',
+ExecStart=-/bin/bash -c "exec ${SINGLE}"',
`ExecStart=-/sbin/sulogin')
ExecStopPost=/bin/systemctl default
StandardInput=tty-force
commit d91430063ed84a628890ef347571972bfd4272dd
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 06:05:02 2010 +0200
mount: don't pull in nofail mounts by default, but use them if they are around
diff --git a/src/mount.c b/src/mount.c
index 2f96625..781c7a8 100644
--- a/src/mount.c
+++ b/src/mount.c
@@ -265,7 +265,7 @@ static int mount_add_target_links(Mount *m) {
MountParameters *p;
Unit *tu;
int r;
- bool noauto, handle, automount;
+ bool noauto, nofail, handle, automount;
assert(m);
@@ -277,6 +277,7 @@ static int mount_add_target_links(Mount *m) {
return 0;
noauto = !!mount_test_option(p->options, MNTOPT_NOAUTO);
+ nofail = !!mount_test_option(p->options, "nofail");
handle = !!mount_test_option(p->options, "comment=systemd.mount") ||
m->meta.manager->mount_auto;
automount = !!mount_test_option(p->options, "comment=systemd.automount");
@@ -309,6 +310,7 @@ static int mount_add_target_links(Mount *m) {
/* Automatically add mount points that aren't natively
* configured to local-fs.target */
if (!noauto &&
+ !nofail &&
handle &&
m->from_etc_fstab &&
m->meta.manager->running_as == MANAGER_SYSTEM)
commit e6a3ff9593e88a57390534b8ad3de7a57cafbdb0
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 06:04:42 2010 +0200
job: recursively fail BoundBy dependencies
diff --git a/src/job.c b/src/job.c
index 8a74f8b..8ab12cd 100644
--- a/src/job.c
+++ b/src/job.c
@@ -506,6 +506,13 @@ int job_finish_and_invalidate(Job *j, bool success) {
other->meta.job->type == JOB_RELOAD_OR_START))
job_finish_and_invalidate(other->meta.job, false);
+ SET_FOREACH(other, u->meta.dependencies[UNIT_BOUND_BY], i)
+ if (other->meta.job &&
+ (other->meta.job->type == JOB_START ||
+ other->meta.job->type == JOB_VERIFY_ACTIVE ||
+ other->meta.job->type == JOB_RELOAD_OR_START))
+ job_finish_and_invalidate(other->meta.job, false);
+
SET_FOREACH(other, u->meta.dependencies[UNIT_REQUIRED_BY_OVERRIDABLE], i)
if (other->meta.job &&
!other->meta.job->override &&
commit 70f12d37087721089a150fad985f0dca0f8af277
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 06:04:17 2010 +0200
fsck: fix target name to check for
diff --git a/src/fsck.c b/src/fsck.c
index 96dea66..bfa35f2 100644
--- a/src/fsck.c
+++ b/src/fsck.c
@@ -39,7 +39,7 @@ static bool arg_force = false;
static void start_target(const char *target, bool isolate) {
DBusMessage *m = NULL, *reply = NULL;
DBusError error;
- const char *mode, *base_target = "base.target";
+ const char *mode, *basic_target = "basic.target";
DBusConnection *bus = NULL;
assert(target);
@@ -66,7 +66,7 @@ static void start_target(const char *target, bool isolate) {
/* Start these units only if we can replace base.target with it */
if (!dbus_message_append_args(m,
- DBUS_TYPE_STRING, &base_target,
+ DBUS_TYPE_STRING, &basic_target,
DBUS_TYPE_STRING, &target,
DBUS_TYPE_STRING, &mode,
DBUS_TYPE_INVALID)) {
commit 2a77d31df976c3934e3b38a9e61c000ec9a8acc2
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 06:04:03 2010 +0200
units: order units by default before appropriate targets in case they are pulled indirectly
diff --git a/src/automount.c b/src/automount.c
index 462f317..b45cbcf 100644
--- a/src/automount.c
+++ b/src/automount.c
@@ -154,6 +154,9 @@ static int automount_add_default_dependencies(Automount *a) {
if (a->meta.manager->running_as == MANAGER_SYSTEM) {
+ if ((r = unit_add_dependency_by_name(UNIT(a), UNIT_BEFORE, SPECIAL_BASIC_TARGET, NULL, true)) < 0)
+ return r;
+
if ((r = unit_add_two_dependencies_by_name(UNIT(a), UNIT_BEFORE, UNIT_CONFLICTS, SPECIAL_UMOUNT_TARGET, NULL, true)) < 0)
return r;
}
diff --git a/src/path.c b/src/path.c
index 1d6f98c..f62157e 100644
--- a/src/path.c
+++ b/src/path.c
@@ -106,9 +106,13 @@ static int path_add_default_dependencies(Path *p) {
assert(p);
- if (p->meta.manager->running_as == MANAGER_SYSTEM)
+ if (p->meta.manager->running_as == MANAGER_SYSTEM) {
+ if ((r = unit_add_dependency_by_name(UNIT(p), UNIT_BEFORE, SPECIAL_BASIC_TARGET, NULL, true)) < 0)
+ return r;
+
if ((r = unit_add_two_dependencies_by_name(UNIT(p), UNIT_AFTER, UNIT_REQUIRES, SPECIAL_SYSINIT_TARGET, NULL, true)) < 0)
return r;
+ }
return unit_add_two_dependencies_by_name(UNIT(p), UNIT_BEFORE, UNIT_CONFLICTS, SPECIAL_SHUTDOWN_TARGET, NULL, true);
}
diff --git a/src/socket.c b/src/socket.c
index 6d2df95..9662066 100644
--- a/src/socket.c
+++ b/src/socket.c
@@ -301,9 +301,13 @@ static int socket_add_default_dependencies(Socket *s) {
int r;
assert(s);
- if (s->meta.manager->running_as == MANAGER_SYSTEM)
+ if (s->meta.manager->running_as == MANAGER_SYSTEM) {
+ if ((r = unit_add_dependency_by_name(UNIT(s), UNIT_BEFORE, SPECIAL_SOCKETS_TARGET, NULL, true)) < 0)
+ return r;
+
if ((r = unit_add_two_dependencies_by_name(UNIT(s), UNIT_AFTER, UNIT_REQUIRES, SPECIAL_SYSINIT_TARGET, NULL, true)) < 0)
return r;
+ }
return unit_add_two_dependencies_by_name(UNIT(s), UNIT_BEFORE, UNIT_CONFLICTS, SPECIAL_SHUTDOWN_TARGET, NULL, true);
}
diff --git a/src/timer.c b/src/timer.c
index 065e9c1..6f1f02d 100644
--- a/src/timer.c
+++ b/src/timer.c
@@ -78,9 +78,13 @@ static int timer_add_default_dependencies(Timer *t) {
assert(t);
- if (t->meta.manager->running_as == MANAGER_SYSTEM)
+ if (t->meta.manager->running_as == MANAGER_SYSTEM) {
+ if ((r = unit_add_dependency_by_name(UNIT(t), UNIT_BEFORE, SPECIAL_BASIC_TARGET, NULL, true)) < 0)
+ return r;
+
if ((r = unit_add_two_dependencies_by_name(UNIT(t), UNIT_AFTER, UNIT_REQUIRES, SPECIAL_SYSINIT_TARGET, NULL, true)) < 0)
return r;
+ }
return unit_add_two_dependencies_by_name(UNIT(t), UNIT_BEFORE, UNIT_CONFLICTS, SPECIAL_SHUTDOWN_TARGET, NULL, true);
}
commit c7d78a567950eff7c2c75af9f6b97904cfa3d039
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 06:03:04 2010 +0200
fedora: enable system mounting/swapping by default
diff --git a/Makefile.am b/Makefile.am
index 2268a62..989514d 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1251,5 +1251,3 @@ git-tag:
fedora: install
rm $(DESTDIR)/lib/systemd/system/local-fs.target.wants/var-run.mount
rm $(DESTDIR)/lib/systemd/system/local-fs.target.wants/var-lock.mount
- sed -i -e 's/^#MountAuto=yes$$/MountAuto=no/' \
- -e 's/^#SwapAuto=yes$$/SwapAuto=no/' $(DESTDIR)/etc/systemd/system.conf
commit 577780ac5c0dcd81ad282df59b643b396b354cd1
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 05:18:22 2010 +0200
units: fix quota check description
diff --git a/units/quotacheck.service.in b/units/quotacheck.service.in
index 65a7055..59a0c77 100644
--- a/units/quotacheck.service.in
+++ b/units/quotacheck.service.in
@@ -6,7 +6,7 @@
# (at your option) any later version.
[Unit]
-Description=Quota Check
+Description=File System Quota Check
DefaultDependencies=no
After=systemd-readahead-collect.service systemd-readahead-replay.service
Before=local-fs.target shutdown.target
diff --git a/units/quotaon.service b/units/quotaon.service
index c527cc4..ddb5128 100644
--- a/units/quotaon.service
+++ b/units/quotaon.service
@@ -6,7 +6,7 @@
# (at your option) any later version.
[Unit]
-Description=Quota Check
+Description=Enable File System Quotas
DefaultDependencies=no
After=systemd-readahead-collect.service systemd-readahead-replay.service quotacheck.service
Before=local-fs.target shutdown.target
commit 36044f5a7096eb3a2b4b865f5a5165da592fd9c8
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 05:17:04 2010 +0200
fedora plymouthd doesn't seem to like --attach-to-session here
diff --git a/units/fedora/plymouth-start.service b/units/fedora/plymouth-start.service
index 26b04c7..e08e8d4 100644
--- a/units/fedora/plymouth-start.service
+++ b/units/fedora/plymouth-start.service
@@ -12,6 +12,6 @@ After=systemd-vconsole-setup.service
Before=systemd-ask-password-plymouth.service
[Service]
-ExecStart=/sbin/plymouthd --mode=boot --attach-to-session
+ExecStart=/sbin/plymouthd --mode=boot
ExecStartPost=-/usr/bin/plymouth --show-splash
Type=forking
commit 5d474b8848d7f6b34f5a0bc1397100ad0667ec2f
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 04:25:08 2010 +0200
units: no need to create rescue.target.wants anymore
diff --git a/Makefile.am b/Makefile.am
index 1fa4a7d..2268a62 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1176,7 +1176,6 @@ if TARGET_FEDORA
$(DESTDIR)$(systemunitdir)/kexec.target.wants \
$(DESTDIR)$(systemunitdir)/poweroff.target.wants \
$(DESTDIR)$(systemunitdir)/halt.target.wants \
- $(DESTDIR)$(systemunitdir)/rescue.target.wants \
$(DESTDIR)$(systemunitdir)/final.target.wants
( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
rm -f rc-local.service && \
commit de47ca9b50e8c05c9fc116ff37794e526bddf92e
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 04:09:36 2010 +0200
units: make fedora/single.service standard and rename it to rescue.service
diff --git a/Makefile.am b/Makefile.am
index 683376b..1fa4a7d 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -163,6 +163,7 @@ dist_tmpfiles_DATA = \
dist_systemunit_DATA = \
units/emergency.service \
units/emergency.target \
+ units/sysinit.target \
units/basic.target \
units/getty.target \
units/halt.target \
@@ -215,7 +216,6 @@ dist_systemunit_DATA = \
units/systemd-ask-password-plymouth.path
nodist_systemunit_DATA = \
- units/sysinit.target \
units/getty at .service \
units/serial-getty at .service \
units/graphical.target \
@@ -247,7 +247,8 @@ nodist_systemunit_DATA = \
units/kexec.service \
units/fsck at .service \
units/fsck-root.service \
- units/quotacheck.service
+ units/quotacheck.service \
+ units/rescue.service
dist_sessionunit_DATA = \
units/session/default.target \
@@ -258,12 +259,12 @@ nodist_sessionunit_DATA = \
units/session/exit.service
EXTRA_DIST = \
- units/sysinit.target.m4 \
units/getty at .service.m4 \
units/serial-getty at .service.m4 \
units/graphical.target.m4 \
units/multi-user.target.m4 \
units/remote-fs.target.m4 \
+ units/rescue.service.m4 \
units/systemd-initctl.service.in \
units/systemd-logger.service.in \
units/systemd-shutdownd.service.in \
@@ -299,7 +300,6 @@ dist_systemunit_DATA += \
units/fedora/prefdm.service \
units/fedora/rc-local.service \
units/fedora/halt-local.service \
- units/fedora/single.service \
units/fedora/plymouth-start.service \
units/fedora/plymouth-quit.service \
units/fedora/plymouth-reboot.service \
@@ -924,7 +924,7 @@ SED_PROCESS = \
-e 's, at PACKAGE_NAME\@,$(PACKAGE_NAME),g' \
-e 's, at PACKAGE_URL\@,$(PACKAGE_URL),g' \
-e 's, at prefix\@,$(prefix),g' \
- < $< > $@
+ < $< > $@ || rm $@
units/%: units/%.in Makefile
$(SED_PROCESS)
@@ -937,11 +937,11 @@ man/%: man/%.in Makefile
M4_PROCESS_SYSTEM = \
$(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
- $(M4) -P $(M4_DISTRO_FLAG) -DFOR_SYSTEM=1 < $< > $@
+ $(M4) -P $(M4_DISTRO_FLAG) -DFOR_SYSTEM=1 < $< > $@ || rm $@
M4_PROCESS_SESSION = \
$(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
- $(M4) -P $(M4_DISTRO_FLAG) -DFOR_SESSION=1 < $< > $@
+ $(M4) -P $(M4_DISTRO_FLAG) -DFOR_SESSION=1 < $< > $@ || rm $@
units/%: units/%.m4 Makefile
$(M4_PROCESS_SYSTEM)
@@ -1184,9 +1184,6 @@ if TARGET_FEDORA
( cd $(DESTDIR)$(systemunitdir)/final.target.wants && \
rm -f halt-local.service && \
$(LN_S) $(systemunitdir)/halt-local.service halt-local.service )
- ( cd $(DESTDIR)$(systemunitdir)/rescue.target.wants && \
- rm -f single.service && \
- $(LN_S) $(systemunitdir)/single.service single.service )
( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
rm -f plymouth-quit.service && \
$(LN_S) ../plymouth-quit.service plymouth-quit.service )
diff --git a/units/.gitignore b/units/.gitignore
index add0c6b..e90f6b3 100644
--- a/units/.gitignore
+++ b/units/.gitignore
@@ -1,3 +1,4 @@
+rescue.service
systemd-ask-password-plymouth.service
systemd-ask-password-wall.service
quotacheck.service
@@ -26,7 +27,6 @@ systemd-random-seed-save.service
systemd-initctl.service
systemd-logger.service
syslog.target
-sysinit.target
graphical.target
multi-user.target
getty at .service
diff --git a/units/basic.target b/units/basic.target
index ecd72ef..0258ca0 100644
--- a/units/basic.target
+++ b/units/basic.target
@@ -9,6 +9,6 @@
[Unit]
Description=Basic System
-Requires=sysinit.target local-fs.target swap.target sockets.target
-After=sysinit.target local-fs.target swap.target sockets.target
+Requires=sysinit.target sockets.target
+After=sysinit.target sockets.target
RefuseManualStart=yes
diff --git a/units/emergency.service b/units/emergency.service
index e056782..52f875c 100644
--- a/units/emergency.service
+++ b/units/emergency.service
@@ -10,6 +10,8 @@
[Unit]
Description=Emergency Shell
DefaultDependencies=no
+Conflicts=shutdown.target
+Before=shutdown.target
[Service]
Environment=HOME=/root
diff --git a/units/fedora/single.service b/units/fedora/single.service
deleted file mode 100644
index f36cbf3..0000000
--- a/units/fedora/single.service
+++ /dev/null
@@ -1,31 +0,0 @@
-# This file is part of systemd.
-#
-# systemd is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-
-# See systemd.special(7) for details
-
-[Unit]
-Description=Rescue Shell
-DefaultDependencies=no
-Conflicts=multi-user.target shutdown.target
-After=basic.target
-Before=multi-user.target
-
-[Service]
-Environment=HOME=/root
-Environment=TERM=vt100-nav
-EnvironmentFile=/etc/sysconfig/init
-WorkingDirectory=/root
-ExecStartPre=-/bin/plymouth --hide-splash
-ExecStartPre=-/bin/echo 'Welcome to rescue mode. Use "systemctl default" or ^D to activate default mode.'
-ExecStart=-/bin/bash -c "exec $SINGLE"
-ExecStopPost=/bin/systemctl default
-StandardInput=tty-force
-KillMode=process-group
-
-# Bash ignores SIGTERM, so we send SIGHUP instead, to ensure that bash
-# terminates cleanly.
-KillSignal=SIGHUP
diff --git a/units/multi-user.target.m4 b/units/multi-user.target.m4
index 8f8903f..8d458c7 100644
--- a/units/multi-user.target.m4
+++ b/units/multi-user.target.m4
@@ -10,8 +10,8 @@
[Unit]
Description=Multi-User
Requires=basic.target
-Conflicts=rescue.target
-After=basic.target rescue.target
+Conflicts=rescue.service rescue.target
+After=basic.target rescue.service rescue.target
m4_dnl
m4_ifdef(`TARGET_FEDORA',
m4_dnl On Fedora Runlevel 3 is multi-user
diff --git a/units/rescue.service.m4 b/units/rescue.service.m4
new file mode 100644
index 0000000..d173beb
--- /dev/null
+++ b/units/rescue.service.m4
@@ -0,0 +1,33 @@
+# This file is part of systemd.
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+
+# See systemd.special(7) for details
+
+[Unit]
+Description=Rescue Shell
+DefaultDependencies=no
+Conflicts=shutdown.target
+After=basic.target
+Before=shutdown.target
+
+[Service]
+Environment=HOME=/root
+Environment=TERM=vt100-nav
+WorkingDirectory=/root
+ExecStartPre=-/bin/plymouth --hide-splash
+ExecStartPre=-/bin/echo 'Welcome to rescue mode. Use "systemctl default" or ^D to activate default mode.'
+m4_ifdef(`TARGET_FEDORA',
+`EnvironmentFile=/etc/sysconfig/init
+ExecStart=-/bin/bash -c "exec $SINGLE"',
+`ExecStart=-/sbin/sulogin')
+ExecStopPost=/bin/systemctl default
+StandardInput=tty-force
+KillMode=process-group
+
+# Bash ignores SIGTERM, so we send SIGHUP instead, to ensure that bash
+# terminates cleanly.
+KillSignal=SIGHUP
diff --git a/units/rescue.target b/units/rescue.target
index 810fa14..ff3aef0 100644
--- a/units/rescue.target
+++ b/units/rescue.target
@@ -9,8 +9,8 @@
[Unit]
Description=Rescue Mode
-Requires=sysinit.target local-fs.target swap.target
-After=sysinit.target local-fs.target swap.target
+Requires=basic.target rescue.service
+After=basic.target rescue.service
Names=runlevel1.target
AllowIsolate=yes
diff --git a/units/sysinit.target b/units/sysinit.target
new file mode 100644
index 0000000..eb9a1c7
--- /dev/null
+++ b/units/sysinit.target
@@ -0,0 +1,15 @@
+# This file is part of systemd.
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+
+# See systemd.special(7) for details
+
+[Unit]
+Description=System Initialization
+Conflicts=emergency.service emergency.target
+Wants=local-fs.target swap.target
+After=local-fs.target swap.target emergency.service emergency.target
+RefuseManualStart=yes
diff --git a/units/sysinit.target.m4 b/units/sysinit.target.m4
deleted file mode 100644
index 6a182d4..0000000
--- a/units/sysinit.target.m4
+++ /dev/null
@@ -1,14 +0,0 @@
-# This file is part of systemd.
-#
-# systemd is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-
-# See systemd.special(7) for details
-
-[Unit]
-Description=System Initialization
-Conflicts=emergency.service emergency.target
-After=emergency.service emergency.target
-RefuseManualStart=yes
commit 42eacdadf56dfeb32c8cb0f598a47a43e6190483
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 02:42:10 2010 +0200
units: introduce plymouth-start and plymouth-kexec, and move a few things back from basic to sysinit
diff --git a/Makefile.am b/Makefile.am
index cede269..683376b 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -300,8 +300,10 @@ dist_systemunit_DATA += \
units/fedora/rc-local.service \
units/fedora/halt-local.service \
units/fedora/single.service \
+ units/fedora/plymouth-start.service \
units/fedora/plymouth-quit.service \
units/fedora/plymouth-reboot.service \
+ units/fedora/plymouth-kexec.service \
units/fedora/plymouth-poweroff.service \
units/fedora/plymouth-halt.service
endif
@@ -1035,6 +1037,7 @@ install-data-hook:
$(MKDIR_P) -m 0755 \
$(DESTDIR)$(systemunitdir) \
$(DESTDIR)$(sessionunitdir) \
+ $(DESTDIR)$(systemunitdir)/sysinit.target.wants \
$(DESTDIR)$(systemunitdir)/sockets.target.wants \
$(DESTDIR)$(systemunitdir)/basic.target.wants \
$(DESTDIR)$(systemunitdir)/shutdown.target.wants \
@@ -1047,10 +1050,9 @@ install-data-hook:
$(DESTDIR)$(systemunitdir)/multi-user.target.wants \
$(DESTDIR)$(systemunitdir)/graphical.target.wants \
$(DESTDIR)$(pkgsysconfdir)/system \
- $(DESTDIR)$(pkgsysconfdir)/system/basic.target.wants \
+ $(DESTDIR)$(pkgsysconfdir)/system/sysinit.target.wants \
$(DESTDIR)$(pkgsysconfdir)/system/local-fs.target.wants \
$(DESTDIR)$(pkgsysconfdir)/system/multi-user.target.wants \
- $(DESTDIR)$(pkgsysconfdir)/system/graphical.target.wants \
$(DESTDIR)$(pkgsysconfdir)/system/getty.target.wants \
$(DESTDIR)$(pkgsysconfdir)/session \
$(DESTDIR)$(sysconfdir)/xdg/systemd
@@ -1137,10 +1139,10 @@ install-data-hook:
( cd $(DESTDIR)$(pkgsysconfdir)/system/multi-user.target.wants && \
rm -f remote-fs.target && \
$(LN_S) $(systemunitdir)/remote-fs.target remote-fs.target )
- ( cd $(DESTDIR)$(pkgsysconfdir)/system/basic.target.wants && \
+ ( cd $(DESTDIR)$(pkgsysconfdir)/system/sysinit.target.wants && \
rm -f hwclock-load.service && \
$(LN_S) $(systemunitdir)/hwclock-load.service hwclock-load.service )
- ( cd $(DESTDIR)$(systemunitdir)/basic.target.wants && \
+ ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
rm -f dev-hugepages.automount \
dev-mqueue.automount \
proc-sys-fs-binfmt_misc.automount \
@@ -1150,8 +1152,7 @@ install-data-hook:
systemd-modules-load.service \
systemd-random-seed-load.service \
systemd-tmpfiles-setup.service \
- sysctl.service \
- systemd-tmpfiles-clean.timer && \
+ sysctl.service && \
$(LN_S) ../dev-hugepages.automount dev-hugepages.automount && \
$(LN_S) ../dev-mqueue.automount dev-mqueue.automount && \
$(LN_S) ../proc-sys-fs-binfmt_misc.automount proc-sys-fs-binfmt_misc.automount && \
@@ -1161,7 +1162,9 @@ install-data-hook:
$(LN_S) ../systemd-modules-load.service systemd-modules-load.service && \
$(LN_S) ../systemd-random-seed-load.service systemd-random-seed-load.service && \
$(LN_S) ../systemd-tmpfiles-setup.service systemd-tmpfiles-setup.service && \
- $(LN_S) ../sysctl.service sysctl.service && \
+ $(LN_S) ../sysctl.service sysctl.service )
+ ( cd $(DESTDIR)$(systemunitdir)/basic.target.wants && \
+ rm -f systemd-tmpfiles-clean.timer && \
$(LN_S) ../systemd-tmpfiles-clean.timer systemd-tmpfiles-clean.timer )
( cd $(DESTDIR)$(dbussessionservicedir) && \
rm -f org.freedesktop.systemd1.service && \
@@ -1170,10 +1173,10 @@ if TARGET_FEDORA
$(MKDIR_P) -m 0755 \
$(DESTDIR)$(SYSTEM_SYSVINIT_PATH) \
$(DESTDIR)$(systemunitdir)/reboot.target.wants \
+ $(DESTDIR)$(systemunitdir)/kexec.target.wants \
$(DESTDIR)$(systemunitdir)/poweroff.target.wants \
$(DESTDIR)$(systemunitdir)/halt.target.wants \
$(DESTDIR)$(systemunitdir)/rescue.target.wants \
- $(DESTDIR)$(systemunitdir)/multi-user.target.wants \
$(DESTDIR)$(systemunitdir)/final.target.wants
( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
rm -f rc-local.service && \
@@ -1185,12 +1188,18 @@ if TARGET_FEDORA
rm -f single.service && \
$(LN_S) $(systemunitdir)/single.service single.service )
( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
- rm -f plymouth-quit.service systemd-ask-password-plymouth.path && \
- $(LN_S) ../plymouth-quit.service plymouth-quit.service && \
+ rm -f plymouth-quit.service && \
+ $(LN_S) ../plymouth-quit.service plymouth-quit.service )
+ ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
+ rm -f plymouth-start.service systemd-ask-password-plymouth.path && \
+ $(LN_S) ../plymouth-start.service plymouth-start.service && \
$(LN_S) ../systemd-ask-password-plymouth.path systemd-ask-password-plymouth.path )
( cd $(DESTDIR)$(systemunitdir)/reboot.target.wants && \
rm -f plymouth-reboot.service && \
$(LN_S) ../plymouth-reboot.service plymouth-reboot.service )
+ ( cd $(DESTDIR)$(systemunitdir)/kexec.target.wants && \
+ rm -f plymouth-kexec.service && \
+ $(LN_S) ../plymouth-kexec.service plymouth-kexec.service )
( cd $(DESTDIR)$(systemunitdir)/poweroff.target.wants && \
rm -f plymouth-poweroff.service && \
$(LN_S) ../plymouth-poweroff.service plymouth-poweroff.service )
@@ -1205,12 +1214,12 @@ if TARGET_FEDORA
$(LN_S) $(systemunitdir)/display-manager.service display-manager.service )
endif
if TARGET_GENTOO
- ( cd $(DESTDIR)$(pkgsysconfdir)/system && \
+ ( cd $(DESTDIR)$(systemunitdir) && \
rm -f display-manager.service && \
- $(LN_S) $(systemunitdir)/xdm.service display-manager.service )
- ( cd $(DESTDIR)$(pkgsysconfdir)/system/graphical.target.wants && \
- rm -f xdm.service && \
- $(LN_S) $(systemunitdir)/xdm.service xdm.service )
+ $(LN_S) xdm.service display-manager.service )
+ ( cd $(DESTDIR)$(systemunitdir)/graphical.target.wants && \
+ rm -f display-manager.service && \
+ $(LN_S) $(systemunitdir)/display-manager.service display-manager.service )
endif
if TARGET_DEBIAN_OR_UBUNTU
$(MKDIR_P) -m 0755 \
diff --git a/units/fedora/plymouth-halt.service b/units/fedora/plymouth-halt.service
index 2a5a067..1a957f4 100644
--- a/units/fedora/plymouth-halt.service
+++ b/units/fedora/plymouth-halt.service
@@ -7,7 +7,7 @@
[Unit]
Description=Show Plymouth Halt Screen
-After=getty at tty1.service prefdm.service
+After=getty at tty1.service prefdm.service plymouth-start.service
Before=halt.service
DefaultDependencies=no
diff --git a/units/fedora/plymouth-kexec.service b/units/fedora/plymouth-kexec.service
new file mode 100644
index 0000000..b73286c
--- /dev/null
+++ b/units/fedora/plymouth-kexec.service
@@ -0,0 +1,19 @@
+# This file is part of systemd.
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+
+[Unit]
+Description=Show Plymouth Reboot with kexec Screen
+After=getty at tty1.service prefdm.service plymouth-start.service
+Before=kexec.service
+DefaultDependencies=no
+
+[Service]
+ExecStart=/sbin/plymouthd --mode=shutdown
+ExecStartPost=-/usr/bin/plymouth --sysinit
+ExecStartPost=-/usr/bin/plymouth --show-splash
+ExecStartPost=-/usr/bin/plymouth message '--text=Rebooting with kexec...'
+Type=forking
diff --git a/units/fedora/plymouth-poweroff.service b/units/fedora/plymouth-poweroff.service
index c92b663..5ff174f 100644
--- a/units/fedora/plymouth-poweroff.service
+++ b/units/fedora/plymouth-poweroff.service
@@ -7,7 +7,7 @@
[Unit]
Description=Show Plymouth Power Off Screen
-After=getty at tty1.service prefdm.service
+After=getty at tty1.service prefdm.service plymouth-start.service
Before=poweroff.service
DefaultDependencies=no
diff --git a/units/fedora/plymouth-quit.service b/units/fedora/plymouth-quit.service
index 89c146b..f4d292c 100644
--- a/units/fedora/plymouth-quit.service
+++ b/units/fedora/plymouth-quit.service
@@ -8,7 +8,7 @@
[Unit]
Description=Terminate Plymouth Boot Screen
Before=getty at tty1.service
-After=dev-tty1.device rc-local.service
+After=dev-tty1.device rc-local.service plymouth-start.service
[Service]
ExecStart=-/usr/bin/plymouth quit
diff --git a/units/fedora/plymouth-reboot.service b/units/fedora/plymouth-reboot.service
index 6641b7f..d09171a 100644
--- a/units/fedora/plymouth-reboot.service
+++ b/units/fedora/plymouth-reboot.service
@@ -7,7 +7,7 @@
[Unit]
Description=Show Plymouth Reboot Screen
-After=getty at tty1.service prefdm.service
+After=getty at tty1.service prefdm.service plymouth-start.service
Before=reboot.service
DefaultDependencies=no
diff --git a/units/fedora/plymouth-start.service b/units/fedora/plymouth-start.service
new file mode 100644
index 0000000..26b04c7
--- /dev/null
+++ b/units/fedora/plymouth-start.service
@@ -0,0 +1,17 @@
+# This file is part of systemd.
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+
+[Unit]
+Description=Show Plymouth Boot Screen
+DefaultDependencies=no
+After=systemd-vconsole-setup.service
+Before=systemd-ask-password-plymouth.service
+
+[Service]
+ExecStart=/sbin/plymouthd --mode=boot --attach-to-session
+ExecStartPost=-/usr/bin/plymouth --show-splash
+Type=forking
commit c19a87330f5a9c49a884910abc39e8cb41df8ca7
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 01:40:46 2010 +0200
fedora: get rid of sysinit.service
diff --git a/Makefile.am b/Makefile.am
index 7e6a7b1..cede269 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -299,7 +299,6 @@ dist_systemunit_DATA += \
units/fedora/prefdm.service \
units/fedora/rc-local.service \
units/fedora/halt-local.service \
- units/fedora/sysinit.service \
units/fedora/single.service \
units/fedora/plymouth-quit.service \
units/fedora/plymouth-reboot.service \
diff --git a/units/fedora/sysinit.service b/units/fedora/sysinit.service
deleted file mode 100644
index 9e83baa..0000000
--- a/units/fedora/sysinit.service
+++ /dev/null
@@ -1,21 +0,0 @@
-# This file is part of systemd.
-#
-# systemd is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-
-[Unit]
-Description=System Initialization
-DefaultDependencies=no
-Conflicts=shutdown.target
-After=systemd-readahead-collect.service systemd-readahead-replay.service
-Before=shutdown.target emergency.service emergency.target
-
-[Service]
-Environment=TERM=linux
-ExecStart=/etc/rc.d/rc.sysinit
-Type=forking
-TimeoutSec=0
-StandardInput=tty
-RemainAfterExit=yes
diff --git a/units/sysinit.target.m4 b/units/sysinit.target.m4
index 792fcaf..6a182d4 100644
--- a/units/sysinit.target.m4
+++ b/units/sysinit.target.m4
@@ -12,9 +12,3 @@ Description=System Initialization
Conflicts=emergency.service emergency.target
After=emergency.service emergency.target
RefuseManualStart=yes
-m4_dnl
-m4_ifdef(`TARGET_FEDORA',
-m4_dnl Hook in Fedora's /etc/rc.d/rc.sysinit
-Requires=sysinit.service
-After=sysinit.service
-)m4_dnl
commit 6b2a56f04c333facb06fadedccc614271849d853
Author: Bill Nottingham <notting at redhat.com>
Date: Thu Oct 28 13:27:49 2010 -0400
Fedora: Link graphical-target.wants to the virtual display-manager.service, not the specific prefdm.service.
diff --git a/Makefile.am b/Makefile.am
index 80a9207..7e6a7b1 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1176,9 +1176,6 @@ if TARGET_FEDORA
$(DESTDIR)$(systemunitdir)/rescue.target.wants \
$(DESTDIR)$(systemunitdir)/multi-user.target.wants \
$(DESTDIR)$(systemunitdir)/final.target.wants
- ( cd $(DESTDIR)$(systemunitdir)/graphical.target.wants && \
- rm -f prefdm.service && \
- $(LN_S) $(systemunitdir)/prefdm.service prefdm.service )
( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
rm -f rc-local.service && \
$(LN_S) $(systemunitdir)/rc-local.service rc-local.service )
@@ -1204,6 +1201,9 @@ if TARGET_FEDORA
( cd $(DESTDIR)$(systemunitdir) && \
rm -f display-manager.service && \
$(LN_S) prefdm.service display-manager.service )
+ ( cd $(DESTDIR)$(systemunitdir)/graphical.target.wants && \
+ rm -f display-manager.service && \
+ $(LN_S) $(systemunitdir)/display-manager.service display-manager.service )
endif
if TARGET_GENTOO
( cd $(DESTDIR)$(pkgsysconfdir)/system && \
commit c980a27940ac3932b1e2414af52ac9f6ec235ada
Author: Bill Nottingham <notting at redhat.com>
Date: Thu Oct 28 13:27:48 2010 -0400
Fedora: Make systemunitdir/graphical.target.wants on 'make install'.
diff --git a/Makefile.am b/Makefile.am
index 3c65feb..80a9207 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1046,6 +1046,7 @@ install-data-hook:
$(DESTDIR)$(systemunitdir)/runlevel4.target.wants \
$(DESTDIR)$(systemunitdir)/runlevel5.target.wants \
$(DESTDIR)$(systemunitdir)/multi-user.target.wants \
+ $(DESTDIR)$(systemunitdir)/graphical.target.wants \
$(DESTDIR)$(pkgsysconfdir)/system \
$(DESTDIR)$(pkgsysconfdir)/system/basic.target.wants \
$(DESTDIR)$(pkgsysconfdir)/system/local-fs.target.wants \
commit 90d2e58ae9cc51f65dc2edce4ce93cff8030902b
Author: Bill Nottingham <notting at redhat.com>
Date: Thu Oct 28 13:27:46 2010 -0400
Fedora: by default, run prefdm last to match prior behavior.
diff --git a/units/fedora/prefdm.service b/units/fedora/prefdm.service
index 78bf14c..45ecd7c 100644
--- a/units/fedora/prefdm.service
+++ b/units/fedora/prefdm.service
@@ -7,7 +7,7 @@
[Unit]
Description=Display Manager
-After=syslog.target livesys-late.service
+After=syslog.target livesys-late.service rc-local.service
# On Fedora gdm/X11 is on tty1. We explicitly cancel the getty here to
# avoid any races around that.
commit 8e9b7dd86b26e1fdfedcee221ec5537c18ca5d0c
Author: Bill Nottingham <notting at redhat.com>
Date: Thu Oct 28 13:27:45 2010 -0400
Fedora: don't ship [Install] sections; these are enabled in the system configuration.
diff --git a/units/fedora/plymouth-halt.service b/units/fedora/plymouth-halt.service
index e027629..2a5a067 100644
--- a/units/fedora/plymouth-halt.service
+++ b/units/fedora/plymouth-halt.service
@@ -17,6 +17,3 @@ ExecStartPost=-/usr/bin/plymouth --sysinit
ExecStartPost=-/usr/bin/plymouth --show-splash
ExecStartPost=-/usr/bin/plymouth message '--text=Halting...'
Type=forking
-
-[Install]
-WantedBy=halt.target
diff --git a/units/fedora/plymouth-poweroff.service b/units/fedora/plymouth-poweroff.service
index fb6f9ae..c92b663 100644
--- a/units/fedora/plymouth-poweroff.service
+++ b/units/fedora/plymouth-poweroff.service
@@ -17,6 +17,3 @@ ExecStartPost=-/usr/bin/plymouth --sysinit
ExecStartPost=-/usr/bin/plymouth --show-splash
ExecStartPost=-/usr/bin/plymouth message '--text=Powering Off...'
Type=forking
-
-[Install]
-WantedBy=poweroff.target
diff --git a/units/fedora/plymouth-quit.service b/units/fedora/plymouth-quit.service
index 62dbf0e..89c146b 100644
--- a/units/fedora/plymouth-quit.service
+++ b/units/fedora/plymouth-quit.service
@@ -13,6 +13,3 @@ After=dev-tty1.device rc-local.service
[Service]
ExecStart=-/usr/bin/plymouth quit
Type=oneshot
-
-[Install]
-WantedBy=multi-user.target
diff --git a/units/fedora/plymouth-reboot.service b/units/fedora/plymouth-reboot.service
index e73de40..6641b7f 100644
--- a/units/fedora/plymouth-reboot.service
+++ b/units/fedora/plymouth-reboot.service
@@ -17,6 +17,3 @@ ExecStartPost=-/usr/bin/plymouth --sysinit
ExecStartPost=-/usr/bin/plymouth --show-splash
ExecStartPost=-/usr/bin/plymouth message '--text=Rebooting...'
Type=forking
-
-[Install]
-WantedBy=reboot.target
diff --git a/units/fedora/prefdm.service b/units/fedora/prefdm.service
index 32ceb9a..78bf14c 100644
--- a/units/fedora/prefdm.service
+++ b/units/fedora/prefdm.service
@@ -18,7 +18,3 @@ After=getty at tty1.service plymouth-quit.service
ExecStart=/etc/X11/prefdm -nodaemon
Restart=always
RestartSec=0
-
-[Install]
-Alias=display-manager.service
-WantedBy=graphical.target
diff --git a/units/fedora/rc-local.service b/units/fedora/rc-local.service
index 1d5d105..88846c1 100644
--- a/units/fedora/rc-local.service
+++ b/units/fedora/rc-local.service
@@ -17,6 +17,3 @@ TimeoutSec=0
StandardOutput=tty
RemainAfterExit=yes
SysVStartPriority=99
-
-[Install]
-WantedBy=multi-user.target
commit 73d35ff8e475d17a22fc524ae003553021acaa8e
Author: Bill Nottingham <notting at redhat.com>
Date: Thu Oct 28 13:27:44 2010 -0400
Fedora: further unit tweaks
1) Just ship rc-local as-is; don't worry about the 'local' name.
2) Don't install rc-local and prefdm to /etc ; just enable them globally for the system in /lib.
diff --git a/Makefile.am b/Makefile.am
index 56bafdc..3c65feb 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1175,13 +1175,10 @@ if TARGET_FEDORA
$(DESTDIR)$(systemunitdir)/rescue.target.wants \
$(DESTDIR)$(systemunitdir)/multi-user.target.wants \
$(DESTDIR)$(systemunitdir)/final.target.wants
- ( cd $(DESTDIR)$(pkgsysconfdir)/system && \
- rm -f display-manager.service && \
- $(LN_S) $(systemunitdir)/prefdm.service display-manager.service )
- ( cd $(DESTDIR)$(pkgsysconfdir)/system/graphical.target.wants && \
+ ( cd $(DESTDIR)$(systemunitdir)/graphical.target.wants && \
rm -f prefdm.service && \
$(LN_S) $(systemunitdir)/prefdm.service prefdm.service )
- ( cd $(DESTDIR)$(pkgsysconfdir)/system/multi-user.target.wants && \
+ ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
rm -f rc-local.service && \
$(LN_S) $(systemunitdir)/rc-local.service rc-local.service )
( cd $(DESTDIR)$(systemunitdir)/final.target.wants && \
@@ -1204,8 +1201,8 @@ if TARGET_FEDORA
rm -f plymouth-halt.service && \
$(LN_S) ../plymouth-halt.service plymouth-halt.service )
( cd $(DESTDIR)$(systemunitdir) && \
- rm -f local.service && \
- $(LN_S) rc-local.service local.service )
+ rm -f display-manager.service && \
+ $(LN_S) prefdm.service display-manager.service )
endif
if TARGET_GENTOO
( cd $(DESTDIR)$(pkgsysconfdir)/system && \
diff --git a/units/fedora/rc-local.service b/units/fedora/rc-local.service
index fb27694..1d5d105 100644
--- a/units/fedora/rc-local.service
+++ b/units/fedora/rc-local.service
@@ -9,10 +9,6 @@
Description=/etc/rc.local Compatibility
ConditionPathExists=/etc/rc.local
-# The rcN.d symlink uses the name "local" while the script itself is
-# called "rc.local", hence carry both names here.
-Names=rc-local.service local.service
-
[Service]
Type=forking
Environment=TERM=linux
commit 9524600eac7c45a8e4b9f426020e24ccfc150d41
Author: Bill Nottingham <notting at redhat.com>
Date: Thu Oct 28 13:27:43 2010 -0400
Fedora: Assorted tweaks to Fedora single-user mode.
1) Start after basic.target, not the deprecated sysinit.target
2) Conflict with shutdown.
diff --git a/units/fedora/single.service b/units/fedora/single.service
index f494237..f36cbf3 100644
--- a/units/fedora/single.service
+++ b/units/fedora/single.service
@@ -10,8 +10,8 @@
[Unit]
Description=Rescue Shell
DefaultDependencies=no
-Conflicts=multi-user.target
-After=sysinit.target
+Conflicts=multi-user.target shutdown.target
+After=basic.target
Before=multi-user.target
[Service]
commit 0fbe72dc372526e8bd65bdf79587f5888f61fb94
Author: Bill Nottingham <notting at redhat.com>
Date: Thu Oct 28 13:27:42 2010 -0400
Fedora: Don't ship a init.d reboot symlink.
diff --git a/Makefile.am b/Makefile.am
index e079ac8..56bafdc 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1206,8 +1206,6 @@ if TARGET_FEDORA
( cd $(DESTDIR)$(systemunitdir) && \
rm -f local.service && \
$(LN_S) rc-local.service local.service )
- ( cd $(DESTDIR)$(SYSTEM_SYSVINIT_PATH) && \
- $(LN_S) halt reboot > /dev/null 2>&1 || true )
endif
if TARGET_GENTOO
( cd $(DESTDIR)$(pkgsysconfdir)/system && \
commit 62c9af5ecfaa7693d4b3d47d0b04669216f44f9d
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 01:22:20 2010 +0200
update fixme
diff --git a/TODO b/TODO
index 0d6ac5f..b022165 100644
--- a/TODO
+++ b/TODO
@@ -62,7 +62,7 @@
* fix plymouth socket name, when plymouth started to use a clean one
-* parse early boot time env var from dracut
+* parse early boot time env var from dracut RD_TIMEOUT, drop RD_xxx
* cryptsetup
@@ -70,7 +70,7 @@
* only add quotacheck deps to .mount units which mention grpquota/usrquota in the mount flags
-* Introduce weaker Conflicts. get rid of ignore_dependency_failure
+* make use of fsck -l
External:
@@ -78,17 +78,12 @@ External:
* patch kernel for cpu feature modalias for autoloading aes/kvm/...
-* patch fsck to support --lock
-
* place /etc/inittab with explaining blurb.
* pam_securetty should honour console=
* procps, psmisc, sysvinit-tools, hostname â util-linux-ng
-* pam: fix double sudo session cleanup:
- http://www.gratisoft.us/bugzilla/show_bug.cgi?id=421
-
https://bugzilla.redhat.com/show_bug.cgi?id=614245 -- plymouth
https://bugzilla.redhat.com/show_bug.cgi?id=612789 -- umount /cgroup on halt
https://bugzilla.redhat.com/show_bug.cgi?id=612728 -- /etc/rc.d/init.d/functions
@@ -107,7 +102,6 @@ https://bugzilla.redhat.com/show_bug.cgi?id=617327 -- gpm
https://bugzilla.redhat.com/show_bug.cgi?id=617330 -- pcsc-lite
https://bugzilla.redhat.com/show_bug.cgi?id=617321 -- audit
https://bugzilla.redhat.com/show_bug.cgi?id=617316 -- abrt
-http://sources.redhat.com/bugzilla/show_bug.cgi?id=11930 -- glibc
Regularly:
commit ead8e4788ee31bbdc38b4cd3c6e71c8a95bbc95a
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Oct 29 01:15:18 2010 +0200
unit: get rid of gnoreDependencyFailure= instead treat ConflictedBy= as weaker counterpart of Conflicts=, similar to Wants= vs. Requires=
diff --git a/man/systemd.unit.xml b/man/systemd.unit.xml
index ff1b47f..4e1d9f3 100644
--- a/man/systemd.unit.xml
+++ b/man/systemd.unit.xml
@@ -544,20 +544,6 @@
</varlistentry>
<varlistentry>
- <term><varname>IgnoreDependencyFailure=</varname></term>
-
- <listitem><para>Takes a boolean
- argument. If <option>true</option> and
- a requirement dependency of this unit
- fails to start up this unit will be
- started nonetheless, ignoring that
- failure. If <option>false</option>
- (the default) and a dependency unit
- fails the unit will immediately fail
- too and the job is removed.</para></listitem>
- </varlistentry>
-
- <varlistentry>
<term><varname>JobTimeoutSec=</varname></term>
<listitem><para>When clients are
diff --git a/src/automount.c b/src/automount.c
index da66630..462f317 100644
--- a/src/automount.c
+++ b/src/automount.c
@@ -154,7 +154,7 @@ static int automount_add_default_dependencies(Automount *a) {
if (a->meta.manager->running_as == MANAGER_SYSTEM) {
- if ((r = unit_add_two_dependencies_by_name(UNIT(a), UNIT_BEFORE, UNIT_CONFLICTED_BY, SPECIAL_UMOUNT_TARGET, NULL, true)) < 0)
+ if ((r = unit_add_two_dependencies_by_name(UNIT(a), UNIT_BEFORE, UNIT_CONFLICTS, SPECIAL_UMOUNT_TARGET, NULL, true)) < 0)
return r;
}
diff --git a/src/job.c b/src/job.c
index 0b6d321..8a74f8b 100644
--- a/src/job.c
+++ b/src/job.c
@@ -500,16 +500,14 @@ int job_finish_and_invalidate(Job *j, bool success) {
t == JOB_RELOAD_OR_START) {
SET_FOREACH(other, u->meta.dependencies[UNIT_REQUIRED_BY], i)
- if (!other->meta.ignore_dependency_failure &&
- other->meta.job &&
+ if (other->meta.job &&
(other->meta.job->type == JOB_START ||
other->meta.job->type == JOB_VERIFY_ACTIVE ||
other->meta.job->type == JOB_RELOAD_OR_START))
job_finish_and_invalidate(other->meta.job, false);
SET_FOREACH(other, u->meta.dependencies[UNIT_REQUIRED_BY_OVERRIDABLE], i)
- if (!other->meta.ignore_dependency_failure &&
- other->meta.job &&
+ if (other->meta.job &&
!other->meta.job->override &&
(other->meta.job->type == JOB_START ||
other->meta.job->type == JOB_VERIFY_ACTIVE ||
@@ -519,16 +517,7 @@ int job_finish_and_invalidate(Job *j, bool success) {
} else if (t == JOB_STOP) {
SET_FOREACH(other, u->meta.dependencies[UNIT_CONFLICTS], i)
- if (!other->meta.ignore_dependency_failure &&
- other->meta.job &&
- (other->meta.job->type == JOB_START ||
- other->meta.job->type == JOB_VERIFY_ACTIVE ||
- other->meta.job->type == JOB_RELOAD_OR_START))
- job_finish_and_invalidate(other->meta.job, false);
-
- SET_FOREACH(other, u->meta.dependencies[UNIT_CONFLICTED_BY], i)
- if (!other->meta.ignore_dependency_failure &&
- other->meta.job &&
+ if (other->meta.job &&
(other->meta.job->type == JOB_START ||
other->meta.job->type == JOB_VERIFY_ACTIVE ||
other->meta.job->type == JOB_RELOAD_OR_START))
diff --git a/src/load-fragment.c b/src/load-fragment.c
index 828b8d2..4f94c64 100644
--- a/src/load-fragment.c
+++ b/src/load-fragment.c
@@ -1775,7 +1775,6 @@ static int load_from_path(Unit *u, const char *path) {
{ "RefuseManualStop", config_parse_bool, &u->meta.refuse_manual_stop, "Unit" },
{ "AllowIsolate", config_parse_bool, &u->meta.allow_isolate, "Unit" },
{ "DefaultDependencies", config_parse_bool, &u->meta.default_dependencies, "Unit" },
- { "IgnoreDependencyFailure",config_parse_bool, &u->meta.ignore_dependency_failure, "Unit" },
{ "JobTimeoutSec", config_parse_usec, &u->meta.job_timeout, "Unit" },
{ "ConditionPathExists", config_parse_condition_path, u, "Unit" },
{ "ConditionKernelCommandLine", config_parse_condition_kernel, u, "Unit" },
diff --git a/src/manager.c b/src/manager.c
index 796d3cb..9fa4877 100644
--- a/src/manager.c
+++ b/src/manager.c
@@ -1483,7 +1483,7 @@ static int transaction_add_job_and_dependencies(
goto fail;
SET_FOREACH(dep, ret->unit->meta.dependencies[UNIT_CONFLICTED_BY], i)
- if ((r = transaction_add_job_and_dependencies(m, JOB_STOP, dep, ret, true, override, false, e, NULL)) < 0 && r != -EBADR)
+ if ((r = transaction_add_job_and_dependencies(m, JOB_STOP, dep, ret, false, override, false, e, NULL)) < 0 && r != -EBADR)
goto fail;
} else if (type == JOB_STOP || type == JOB_RESTART || type == JOB_TRY_RESTART) {
diff --git a/src/mount.c b/src/mount.c
index d62ce8f..2f96625 100644
--- a/src/mount.c
+++ b/src/mount.c
@@ -398,7 +398,7 @@ static int mount_add_default_dependencies(Mount *m) {
if ((r = unit_add_dependency_by_name(UNIT(m), UNIT_BEFORE, SPECIAL_QUOTACHECK_SERVICE, NULL, true)) < 0)
return r;
- if ((r = unit_add_two_dependencies_by_name(UNIT(m), UNIT_BEFORE, UNIT_CONFLICTED_BY, SPECIAL_UMOUNT_TARGET, NULL, true)) < 0)
+ if ((r = unit_add_two_dependencies_by_name(UNIT(m), UNIT_BEFORE, UNIT_CONFLICTS, SPECIAL_UMOUNT_TARGET, NULL, true)) < 0)
return r;
}
diff --git a/src/path.c b/src/path.c
index b3bc8a5..1d6f98c 100644
--- a/src/path.c
+++ b/src/path.c
@@ -110,7 +110,7 @@ static int path_add_default_dependencies(Path *p) {
if ((r = unit_add_two_dependencies_by_name(UNIT(p), UNIT_AFTER, UNIT_REQUIRES, SPECIAL_SYSINIT_TARGET, NULL, true)) < 0)
return r;
- return unit_add_two_dependencies_by_name(UNIT(p), UNIT_BEFORE, UNIT_CONFLICTED_BY, SPECIAL_SHUTDOWN_TARGET, NULL, true);
+ return unit_add_two_dependencies_by_name(UNIT(p), UNIT_BEFORE, UNIT_CONFLICTS, SPECIAL_SHUTDOWN_TARGET, NULL, true);
}
static int path_load(Unit *u) {
diff --git a/src/service.c b/src/service.c
index 49bdae7..d3c750e 100644
--- a/src/service.c
+++ b/src/service.c
@@ -1021,7 +1021,7 @@ static int service_add_default_dependencies(Service *s) {
}
/* Second, activate normal shutdown */
- return unit_add_two_dependencies_by_name(UNIT(s), UNIT_BEFORE, UNIT_CONFLICTED_BY, SPECIAL_SHUTDOWN_TARGET, NULL, true);
+ return unit_add_two_dependencies_by_name(UNIT(s), UNIT_BEFORE, UNIT_CONFLICTS, SPECIAL_SHUTDOWN_TARGET, NULL, true);
}
static int service_load(Unit *u) {
@@ -3017,7 +3017,7 @@ static int service_enumerate(Manager *m) {
if (service->meta.fragment_path)
continue;
- if ((r = unit_add_two_dependencies_by_name_inverse(service, UNIT_AFTER, UNIT_CONFLICTS, SPECIAL_SHUTDOWN_TARGET, NULL, true)) < 0)
+ if ((r = unit_add_two_dependencies_by_name(service, UNIT_BEFORE, UNIT_CONFLICTS, SPECIAL_SHUTDOWN_TARGET, NULL, true)) < 0)
goto finish;
}
diff --git a/src/socket.c b/src/socket.c
index e8c016c..6d2df95 100644
--- a/src/socket.c
+++ b/src/socket.c
@@ -305,7 +305,7 @@ static int socket_add_default_dependencies(Socket *s) {
if ((r = unit_add_two_dependencies_by_name(UNIT(s), UNIT_AFTER, UNIT_REQUIRES, SPECIAL_SYSINIT_TARGET, NULL, true)) < 0)
return r;
- return unit_add_two_dependencies_by_name(UNIT(s), UNIT_BEFORE, UNIT_CONFLICTED_BY, SPECIAL_SHUTDOWN_TARGET, NULL, true);
+ return unit_add_two_dependencies_by_name(UNIT(s), UNIT_BEFORE, UNIT_CONFLICTS, SPECIAL_SHUTDOWN_TARGET, NULL, true);
}
static int socket_load(Unit *u) {
diff --git a/src/swap.c b/src/swap.c
index 078ad9f..ddda9e1 100644
--- a/src/swap.c
+++ b/src/swap.c
@@ -211,7 +211,7 @@ static int swap_add_default_dependencies(Swap *s) {
if (s->meta.manager->running_as == MANAGER_SYSTEM) {
- if ((r = unit_add_two_dependencies_by_name(UNIT(s), UNIT_BEFORE, UNIT_CONFLICTED_BY, SPECIAL_UMOUNT_TARGET, NULL, true)) < 0)
+ if ((r = unit_add_two_dependencies_by_name(UNIT(s), UNIT_BEFORE, UNIT_CONFLICTS, SPECIAL_UMOUNT_TARGET, NULL, true)) < 0)
return r;
}
diff --git a/src/target.c b/src/target.c
index 3522bf1..f322ce7 100644
--- a/src/target.c
+++ b/src/target.c
@@ -77,7 +77,7 @@ static int target_add_default_dependencies(Target *t) {
return r;
/* Make sure targets are unloaded on shutdown */
- return unit_add_dependency_by_name(UNIT(t), UNIT_CONFLICTED_BY, SPECIAL_SHUTDOWN_TARGET, NULL, true);
+ return unit_add_dependency_by_name(UNIT(t), UNIT_CONFLICTS, SPECIAL_SHUTDOWN_TARGET, NULL, true);
}
static int target_add_getty_dependencies(Target *t) {
diff --git a/src/timer.c b/src/timer.c
index 627a360..065e9c1 100644
--- a/src/timer.c
+++ b/src/timer.c
@@ -82,7 +82,7 @@ static int timer_add_default_dependencies(Timer *t) {
if ((r = unit_add_two_dependencies_by_name(UNIT(t), UNIT_AFTER, UNIT_REQUIRES, SPECIAL_SYSINIT_TARGET, NULL, true)) < 0)
return r;
- return unit_add_two_dependencies_by_name(UNIT(t), UNIT_BEFORE, UNIT_CONFLICTED_BY, SPECIAL_SHUTDOWN_TARGET, NULL, true);
+ return unit_add_two_dependencies_by_name(UNIT(t), UNIT_BEFORE, UNIT_CONFLICTS, SPECIAL_SHUTDOWN_TARGET, NULL, true);
}
static int timer_load(Unit *u) {
diff --git a/src/unit.c b/src/unit.c
index fb5583b..410ff9f 100644
--- a/src/unit.c
+++ b/src/unit.c
@@ -655,13 +655,11 @@ void unit_dump(Unit *u, FILE *f, const char *prefix) {
"%s\tStopWhenUnneeded: %s\n"
"%s\tRefuseManualStart: %s\n"
"%s\tRefuseManualStop: %s\n"
- "%s\tDefaultDependencies: %s\n"
- "%s\tIgnoreDependencyFailure: %s\n",
+ "%s\tDefaultDependencies: %s\n",
prefix, yes_no(u->meta.stop_when_unneeded),
prefix, yes_no(u->meta.refuse_manual_start),
prefix, yes_no(u->meta.refuse_manual_stop),
- prefix, yes_no(u->meta.default_dependencies),
- prefix, yes_no(u->meta.ignore_dependency_failure));
+ prefix, yes_no(u->meta.default_dependencies));
LIST_FOREACH(by_unit, b, u->meta.cgroup_bondings)
fprintf(f, "%s\tControlGroup: %s:%s\n",
diff --git a/src/unit.h b/src/unit.h
index ff11511..796aee5 100644
--- a/src/unit.h
+++ b/src/unit.h
@@ -199,9 +199,6 @@ struct Meta {
/* Create default depedencies */
bool default_dependencies;
- /* Bring up this unit even if a dependency fails to start */
- bool ignore_dependency_failure;
-
/* Refuse manual starting, allow starting only indirectly via dependency. */
bool refuse_manual_start;
diff --git a/units/final.target b/units/final.target
index ba64261..9cfda19 100644
--- a/units/final.target
+++ b/units/final.target
@@ -11,5 +11,4 @@
Description=Final Step
DefaultDependencies=no
RefuseManualStart=yes
-IgnoreDependencyFailure=yes
After=shutdown.target umount.target
diff --git a/units/shutdown.target b/units/shutdown.target
index 4db9f1f..99a659e 100644
--- a/units/shutdown.target
+++ b/units/shutdown.target
@@ -11,4 +11,3 @@
Description=Shutdown
DefaultDependencies=no
RefuseManualStart=yes
-IgnoreDependencyFailure=yes
diff --git a/units/umount.target b/units/umount.target
index b5a993f..b9ecca6 100644
--- a/units/umount.target
+++ b/units/umount.target
@@ -11,4 +11,3 @@
Description=Unmount All Filesystems
DefaultDependencies=no
RefuseManualStart=yes
-IgnoreDependencyFailure=yes
More information about the systemd-commits
mailing list