[systemd-commits] 7 commits - Makefile.am src/ask-password-api.c src/dbus.c src/dbus-job.c src/dbus-job.h src/dbus-manager.c src/job.c src/job.h src/logger.c src/manager.c src/systemadm.vala src/systemctl.c src/systemd-interfaces.vala src/tty-ask-password-agent.c src/unit.c src/unit.h TODO units/getty at .service.m4 units/plymouth-quit-wait.service units/serial-getty at .service.m4
Lennart Poettering
lennart at kemper.freedesktop.org
Wed Feb 23 17:47:09 PST 2011
Makefile.am | 18 +++++++---
TODO | 6 +++
src/ask-password-api.c | 2 -
src/dbus-job.c | 8 +++-
src/dbus-job.h | 4 +-
src/dbus-manager.c | 2 -
src/dbus.c | 1
src/job.c | 45 +++++++++++++++++----------
src/job.h | 19 ++++++++++-
src/logger.c | 4 +-
src/manager.c | 1
src/systemadm.vala | 2 -
src/systemctl.c | 65 ++++++++++++++++++++++++++++++---------
src/systemd-interfaces.vala | 2 -
src/tty-ask-password-agent.c | 4 +-
src/unit.c | 12 +++----
src/unit.h | 2 -
units/getty at .service.m4 | 2 -
units/plymouth-quit-wait.service | 15 +++++++++
units/serial-getty at .service.m4 | 5 ++-
20 files changed, 159 insertions(+), 60 deletions(-)
New commits:
commit 312732cfaf63b463b2062c47fddb2d639a5fe635
Author: Lennart Poettering <lennart at poettering.net>
Date: Thu Feb 24 02:41:34 2011 +0100
job: start job timeout on enqueuing not when we start to process a job
This practically reverses 23e1e0c4a3bc93fb841ac9575953ed5d0ef5282d.
This makes it easier to timeout individual jobs so that this timeout can
be relied on, since blocked dependencies will not influence the timeout.
diff --git a/src/job.c b/src/job.c
index 53c47d4..7470204 100644
--- a/src/job.c
+++ b/src/job.c
@@ -461,8 +461,6 @@ int job_run_and_invalidate(Job *j) {
j->state = JOB_WAITING;
else if (r < 0)
r = job_finish_and_invalidate(j, JOB_FAILED);
- else
- job_start_timer(j);
}
return r;
diff --git a/src/manager.c b/src/manager.c
index 6759bba..f266aaa 100644
--- a/src/manager.c
+++ b/src/manager.c
@@ -1216,6 +1216,7 @@ static int transaction_apply(Manager *m) {
job_add_to_run_queue(j);
job_add_to_dbus_queue(j);
+ job_start_timer(j);
log_debug("Installed new job %s/%s as %u", j->unit->meta.id, job_type_to_string(j->type), (unsigned) j->id);
}
commit 5f8738667f3b4a1606fd714d3da6cac5784c4053
Author: Lennart Poettering <lennart at poettering.net>
Date: Thu Feb 24 02:38:19 2011 +0100
unit: increase default timeout to 3min
diff --git a/src/unit.h b/src/unit.h
index b30f0cf..e81cffc 100644
--- a/src/unit.h
+++ b/src/unit.h
@@ -40,7 +40,7 @@ typedef enum UnitDependency UnitDependency;
#include "execute.h"
#include "condition.h"
-#define DEFAULT_TIMEOUT_USEC (60*USEC_PER_SEC)
+#define DEFAULT_TIMEOUT_USEC (3*USEC_PER_MINUTE)
#define DEFAULT_RESTART_USEC (100*USEC_PER_MSEC)
enum UnitType {
commit 84168c7740e8b370cb92548bd21defea0150c69f
Author: Lennart Poettering <lennart at poettering.net>
Date: Thu Feb 24 02:38:02 2011 +0100
logger: leave the logger longer around and allow it do handle more connections
diff --git a/src/logger.c b/src/logger.c
index 342c307..510f4e2 100644
--- a/src/logger.c
+++ b/src/logger.c
@@ -38,9 +38,9 @@
#include "sd-daemon.h"
#include "tcpwrap.h"
-#define STREAMS_MAX 256
+#define STREAMS_MAX 4096
#define SERVER_FD_MAX 16
-#define TIMEOUT ((int) (10*MSEC_PER_SEC))
+#define TIMEOUT ((int) (5*60*MSEC_PER_SEC))
typedef struct Stream Stream;
commit 5d44db4a905c62d6cf0dfabbf61df49621efec22
Author: Lennart Poettering <lennart at poettering.net>
Date: Thu Feb 24 02:36:34 2011 +0100
dbus: pass along information why a job failed when it failed (dbus api change!)
diff --git a/src/dbus-job.c b/src/dbus-job.c
index 18da72d..16aa8d0 100644
--- a/src/dbus-job.c
+++ b/src/dbus-job.c
@@ -295,10 +295,10 @@ oom:
log_error("Failed to allocate job change signal.");
}
-void bus_job_send_removed_signal(Job *j, bool success) {
+void bus_job_send_removed_signal(Job *j) {
char *p = NULL;
DBusMessage *m = NULL;
- dbus_bool_t b = success;
+ const char *r;
assert(j);
@@ -314,10 +314,12 @@ void bus_job_send_removed_signal(Job *j, bool success) {
if (!(m = dbus_message_new_signal("/org/freedesktop/systemd1", "org.freedesktop.systemd1.Manager", "JobRemoved")))
goto oom;
+ r = job_result_to_string(j->result);
+
if (!dbus_message_append_args(m,
DBUS_TYPE_UINT32, &j->id,
DBUS_TYPE_OBJECT_PATH, &p,
- DBUS_TYPE_BOOLEAN, &b,
+ DBUS_TYPE_STRING, &r,
DBUS_TYPE_INVALID))
goto oom;
diff --git a/src/dbus-job.h b/src/dbus-job.h
index 801e3e6..103c2ff 100644
--- a/src/dbus-job.h
+++ b/src/dbus-job.h
@@ -24,8 +24,10 @@
#include <dbus/dbus.h>
+#include "job.h"
+
void bus_job_send_change_signal(Job *j);
-void bus_job_send_removed_signal(Job *j, bool success);
+void bus_job_send_removed_signal(Job *j);
extern const DBusObjectPathVTable bus_job_vtable;
diff --git a/src/dbus-manager.c b/src/dbus-manager.c
index 6f98aa7..1b3bddc 100644
--- a/src/dbus-manager.c
+++ b/src/dbus-manager.c
@@ -143,7 +143,7 @@
" <signal name=\"JobRemoved\">\n" \
" <arg name=\"id\" type=\"u\"/>\n" \
" <arg name=\"job\" type=\"o\"/>\n" \
- " <arg name=\"success\" type=\"b\"/>\n" \
+ " <arg name=\"result\" type=\"s\"/>\n" \
" </signal>"
diff --git a/src/job.c b/src/job.c
index ec57144..53c47d4 100644
--- a/src/job.c
+++ b/src/job.c
@@ -60,7 +60,7 @@ void job_free(Job *j) {
/* Detach from next 'bigger' objects */
if (j->installed) {
- bus_job_send_removed_signal(j, !j->failed);
+ bus_job_send_removed_signal(j);
if (j->unit->meta.job == j) {
j->unit->meta.job = NULL;
@@ -376,7 +376,6 @@ int job_run_and_invalidate(Job *j) {
j->state = JOB_RUNNING;
job_add_to_dbus_queue(j);
- job_start_timer(j);
/* While we execute this operation the job might go away (for
* example: because it is replaced by a new, conflicting
@@ -457,17 +456,19 @@ int job_run_and_invalidate(Job *j) {
if ((j = manager_get_job(m, id))) {
if (r == -EALREADY)
- r = job_finish_and_invalidate(j, true);
+ r = job_finish_and_invalidate(j, JOB_DONE);
else if (r == -EAGAIN)
j->state = JOB_WAITING;
else if (r < 0)
- r = job_finish_and_invalidate(j, false);
+ r = job_finish_and_invalidate(j, JOB_FAILED);
+ else
+ job_start_timer(j);
}
return r;
}
-int job_finish_and_invalidate(Job *j, bool success) {
+int job_finish_and_invalidate(Job *j, JobResult result) {
Unit *u;
Unit *other;
JobType t;
@@ -479,7 +480,7 @@ int job_finish_and_invalidate(Job *j, bool success) {
job_add_to_dbus_queue(j);
/* Patch restart jobs so that they become normal start jobs */
- if (success && (j->type == JOB_RESTART || j->type == JOB_TRY_RESTART)) {
+ if (result == JOB_DONE && (j->type == JOB_RESTART || j->type == JOB_TRY_RESTART)) {
log_debug("Converting job %s/%s -> %s/%s",
j->unit->meta.id, job_type_to_string(j->type),
@@ -492,22 +493,26 @@ int job_finish_and_invalidate(Job *j, bool success) {
return 0;
}
- j->failed = !success;
+ j->result = result;
- log_debug("Job %s/%s finished, success=%s", j->unit->meta.id, job_type_to_string(j->type), yes_no(success));
+ log_debug("Job %s/%s finished, result=%s", j->unit->meta.id, job_type_to_string(j->type), job_result_to_string(result));
- if (j->failed)
+ if (result == JOB_FAILED)
j->manager->n_failed_jobs ++;
u = j->unit;
t = j->type;
job_free(j);
- if (!success && j->type == JOB_START)
+ if (result == JOB_FAILED && j->type == JOB_START)
unit_status_printf(u, "Starting %s " ANSI_HIGHLIGHT_ON "failed" ANSI_HIGHLIGHT_OFF ", see 'systemctl status %s' for details.\n", unit_description(u), u->meta.id);
+ else if (result == JOB_TIMEOUT && j->type == JOB_START)
+ unit_status_printf(u, "Starting %s " ANSI_HIGHLIGHT_ON "timed out" ANSI_HIGHLIGHT_OFF ".\n", unit_description(u), u->meta.id);
+ else if (result == JOB_TIMEOUT && j->type == JOB_STOP)
+ unit_status_printf(u, "Stopping %s " ANSI_HIGHLIGHT_ON "timed out" ANSI_HIGHLIGHT_OFF ".\n", unit_description(u), u->meta.id);
/* Fail depending jobs on failure */
- if (!success) {
+ if (result != JOB_DONE) {
if (t == JOB_START ||
t == JOB_VERIFY_ACTIVE ||
@@ -518,14 +523,14 @@ int job_finish_and_invalidate(Job *j, bool success) {
(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);
+ job_finish_and_invalidate(other->meta.job, JOB_DEPENDENCY);
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);
+ job_finish_and_invalidate(other->meta.job, JOB_DEPENDENCY);
SET_FOREACH(other, u->meta.dependencies[UNIT_REQUIRED_BY_OVERRIDABLE], i)
if (other->meta.job &&
@@ -533,7 +538,7 @@ int job_finish_and_invalidate(Job *j, bool success) {
(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);
+ job_finish_and_invalidate(other->meta.job, JOB_DEPENDENCY);
} else if (t == JOB_STOP) {
@@ -542,7 +547,7 @@ int job_finish_and_invalidate(Job *j, bool success) {
(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);
+ job_finish_and_invalidate(other->meta.job, JOB_DEPENDENCY);
}
}
@@ -648,7 +653,7 @@ void job_timer_event(Job *j, uint64_t n_elapsed, Watch *w) {
assert(w == &j->timer_watch);
log_warning("Job %s/%s timed out.", j->unit->meta.id, job_type_to_string(j->type));
- job_finish_and_invalidate(j, false);
+ job_finish_and_invalidate(j, JOB_TIMEOUT);
}
static const char* const job_state_table[_JOB_STATE_MAX] = {
@@ -678,3 +683,13 @@ static const char* const job_mode_table[_JOB_MODE_MAX] = {
};
DEFINE_STRING_TABLE_LOOKUP(job_mode, JobMode);
+
+static const char* const job_result_table[_JOB_RESULT_MAX] = {
+ [JOB_DONE] = "done",
+ [JOB_CANCELED] = "canceled",
+ [JOB_TIMEOUT] = "timeout",
+ [JOB_FAILED] = "failed",
+ [JOB_DEPENDENCY] = "dependency"
+};
+
+DEFINE_STRING_TABLE_LOOKUP(job_result, JobResult);
diff --git a/src/job.h b/src/job.h
index 2499e64..de0c1d2 100644
--- a/src/job.h
+++ b/src/job.h
@@ -30,6 +30,7 @@ typedef struct JobDependency JobDependency;
typedef enum JobType JobType;
typedef enum JobState JobState;
typedef enum JobMode JobMode;
+typedef enum JobResult JobResult;
#include "manager.h"
#include "unit.h"
@@ -71,6 +72,16 @@ enum JobMode {
_JOB_MODE_INVALID = -1
};
+enum JobResult {
+ JOB_DONE,
+ JOB_CANCELED,
+ JOB_TIMEOUT,
+ JOB_FAILED,
+ JOB_DEPENDENCY,
+ _JOB_RESULT_MAX,
+ _JOB_RESULT_INVALID = -1
+};
+
struct JobDependency {
/* Encodes that the 'subject' job needs the 'object' job in
* some way. This structure is used only while building a transaction. */
@@ -110,13 +121,14 @@ struct Job {
DBusConnection *bus;
char *bus_client;
+ JobResult result;
+
bool installed:1;
bool in_run_queue:1;
bool matters_to_anchor:1;
bool override:1;
bool in_dbus_queue:1;
bool sent_dbus_new_signal:1;
- bool failed:1;
bool ignore_deps:1;
};
@@ -146,7 +158,7 @@ int job_start_timer(Job *j);
void job_timer_event(Job *j, uint64_t n_elapsed, Watch *w);
int job_run_and_invalidate(Job *j);
-int job_finish_and_invalidate(Job *j, bool success);
+int job_finish_and_invalidate(Job *j, JobResult result);
char *job_dbus_path(Job *j);
@@ -159,4 +171,7 @@ JobState job_state_from_string(const char *s);
const char* job_mode_to_string(JobMode t);
JobMode job_mode_from_string(const char *s);
+const char* job_result_to_string(JobResult t);
+JobResult job_result_from_string(const char *s);
+
#endif
diff --git a/src/systemadm.vala b/src/systemadm.vala
index 33777b6..c262794 100644
--- a/src/systemadm.vala
+++ b/src/systemadm.vala
@@ -762,7 +762,7 @@ public class MainWindow : Window {
} while (unit_model.iter_next(ref iter));
}
- public void on_job_removed(uint32 id, ObjectPath path, bool success) {
+ public void on_job_removed(uint32 id, ObjectPath path, string res) {
TreeIter iter;
if (!(job_model.get_iter_first(out iter)))
return;
diff --git a/src/systemctl.c b/src/systemctl.c
index eacc63e..82741bc 100644
--- a/src/systemctl.c
+++ b/src/systemctl.c
@@ -1120,7 +1120,7 @@ finish:
typedef struct WaitData {
Set *set;
- bool failed;
+ char *result;
} WaitData;
static DBusHandlerResult wait_filter(DBusConnection *connection, DBusMessage *message, void *data) {
@@ -1144,26 +1144,52 @@ static DBusHandlerResult wait_filter(DBusConnection *connection, DBusMessage *me
} else if (dbus_message_is_signal(message, "org.freedesktop.systemd1.Manager", "JobRemoved")) {
uint32_t id;
- const char *path;
+ const char *path, *result;
dbus_bool_t success = true;
- if (!dbus_message_get_args(message, &error,
- DBUS_TYPE_UINT32, &id,
- DBUS_TYPE_OBJECT_PATH, &path,
- DBUS_TYPE_BOOLEAN, &success,
- DBUS_TYPE_INVALID))
- log_error("Failed to parse message: %s", bus_error_message(&error));
- else {
+ if (dbus_message_get_args(message, &error,
+ DBUS_TYPE_UINT32, &id,
+ DBUS_TYPE_OBJECT_PATH, &path,
+ DBUS_TYPE_STRING, &result,
+ DBUS_TYPE_INVALID)) {
+ char *p;
+
+ if ((p = set_remove(d->set, (char*) path)))
+ free(p);
+
+ if (*result)
+ d->result = strdup(result);
+
+ goto finish;
+ }
+#ifndef LEGACY
+ dbus_error_free(&error);
+
+ if (dbus_message_get_args(message, &error,
+ DBUS_TYPE_UINT32, &id,
+ DBUS_TYPE_OBJECT_PATH, &path,
+ DBUS_TYPE_BOOLEAN, &success,
+ DBUS_TYPE_INVALID)) {
char *p;
+ /* Compatibility with older systemd versions <
+ * 19 during upgrades. This should be dropped
+ * one day */
+
if ((p = set_remove(d->set, (char*) path)))
free(p);
if (!success)
- d->failed = true;
+ d->result = strdup("failed");
+
+ goto finish;
}
+#endif
+
+ log_error("Failed to parse message: %s", bus_error_message(&error));
}
+finish:
dbus_error_free(&error);
return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
}
@@ -1204,7 +1230,6 @@ static int wait_for_jobs(DBusConnection *bus, Set *s) {
zero(d);
d.set = s;
- d.failed = false;
if (!dbus_connection_add_filter(bus, wait_filter, &d, NULL)) {
log_error("Failed to add filter.");
@@ -1216,10 +1241,19 @@ static int wait_for_jobs(DBusConnection *bus, Set *s) {
dbus_connection_read_write_dispatch(bus, -1))
;
- if (!arg_quiet && d.failed)
- log_error("Job failed. See system logs and 'systemctl status' for details.");
+ if (!arg_quiet && d.result) {
+ if (streq(d.result, "timeout"))
+ log_error("Job timed out.");
+ else if (streq(d.result, "canceled"))
+ log_error("Job canceled.");
+ else if (streq(d.result, "dependency"))
+ log_error("A dependency job failed. See system logs for details.");
+ else
+ log_error("Job failed. See system logs and 'systemctl status' for details.");
+ }
- r = d.failed ? -EIO : 0;
+ r = d.result ? -EIO : 0;
+ free(d.result);
finish:
/* This is slightly dirty, since we don't undo the filter registration. */
@@ -2750,11 +2784,12 @@ static DBusHandlerResult monitor_filter(DBusConnection *connection, DBusMessage
} else if (dbus_message_is_signal(message, "org.freedesktop.systemd1.Manager", "JobNew") ||
dbus_message_is_signal(message, "org.freedesktop.systemd1.Manager", "JobRemoved")) {
uint32_t id;
- const char *path;
+ const char *path, *result;
if (!dbus_message_get_args(message, &error,
DBUS_TYPE_UINT32, &id,
DBUS_TYPE_OBJECT_PATH, &path,
+ DBUS_TYPE_STRING, &result,
DBUS_TYPE_INVALID))
log_error("Failed to parse message: %s", bus_error_message(&error));
else if (streq(dbus_message_get_member(message), "JobNew"))
diff --git a/src/systemd-interfaces.vala b/src/systemd-interfaces.vala
index e3b7941..a380f79 100644
--- a/src/systemd-interfaces.vala
+++ b/src/systemd-interfaces.vala
@@ -85,7 +85,7 @@ public interface Manager : DBusProxy {
public abstract signal void unit_new(string id, ObjectPath path);
public abstract signal void unit_removed(string id, ObjectPath path);
public abstract signal void job_new(uint32 id, ObjectPath path);
- public abstract signal void job_removed(uint32 id, ObjectPath path, bool success);
+ public abstract signal void job_removed(uint32 id, ObjectPath path, string res);
}
[DBus (name = "org.freedesktop.systemd1.Unit")]
diff --git a/src/unit.c b/src/unit.c
index 0d53123..1ca8e82 100644
--- a/src/unit.c
+++ b/src/unit.c
@@ -1123,12 +1123,12 @@ void unit_notify(Unit *u, UnitActiveState os, UnitActiveState ns, bool reload_su
case JOB_VERIFY_ACTIVE:
if (UNIT_IS_ACTIVE_OR_RELOADING(ns))
- job_finish_and_invalidate(u->meta.job, true);
+ job_finish_and_invalidate(u->meta.job, JOB_DONE);
else if (u->meta.job->state == JOB_RUNNING && ns != UNIT_ACTIVATING) {
unexpected = true;
if (UNIT_IS_INACTIVE_OR_FAILED(ns))
- job_finish_and_invalidate(u->meta.job, ns != UNIT_FAILED);
+ job_finish_and_invalidate(u->meta.job, ns == UNIT_FAILED ? JOB_FAILED : JOB_DONE);
}
break;
@@ -1138,12 +1138,12 @@ void unit_notify(Unit *u, UnitActiveState os, UnitActiveState ns, bool reload_su
if (u->meta.job->state == JOB_RUNNING) {
if (ns == UNIT_ACTIVE)
- job_finish_and_invalidate(u->meta.job, reload_success);
+ job_finish_and_invalidate(u->meta.job, reload_success ? JOB_DONE : JOB_FAILED);
else if (ns != UNIT_ACTIVATING && ns != UNIT_RELOADING) {
unexpected = true;
if (UNIT_IS_INACTIVE_OR_FAILED(ns))
- job_finish_and_invalidate(u->meta.job, ns != UNIT_FAILED);
+ job_finish_and_invalidate(u->meta.job, ns == UNIT_FAILED ? JOB_FAILED : JOB_DONE);
}
}
@@ -1154,10 +1154,10 @@ void unit_notify(Unit *u, UnitActiveState os, UnitActiveState ns, bool reload_su
case JOB_TRY_RESTART:
if (UNIT_IS_INACTIVE_OR_FAILED(ns))
- job_finish_and_invalidate(u->meta.job, true);
+ job_finish_and_invalidate(u->meta.job, JOB_DONE);
else if (u->meta.job->state == JOB_RUNNING && ns != UNIT_DEACTIVATING) {
unexpected = true;
- job_finish_and_invalidate(u->meta.job, false);
+ job_finish_and_invalidate(u->meta.job, JOB_FAILED);
}
break;
commit ccc80078fe47395ffe0dd48cb6c81551d991ef4b
Author: Lennart Poettering <lennart at poettering.net>
Date: Thu Feb 24 02:33:57 2011 +0100
general: unify error code we generate on timeout
diff --git a/src/ask-password-api.c b/src/ask-password-api.c
index 845517a..f43075e 100644
--- a/src/ask-password-api.c
+++ b/src/ask-password-api.c
@@ -132,7 +132,7 @@ int ask_password_tty(
r = -errno;
goto finish;
} else if (k == 0) {
- r = -ETIMEDOUT;
+ r = -ETIME;
goto finish;
}
diff --git a/src/dbus.c b/src/dbus.c
index d7b80ba..64988c7 100644
--- a/src/dbus.c
+++ b/src/dbus.c
@@ -1361,6 +1361,7 @@ static const char *error_to_dbus(int error) {
return DBUS_ERROR_FILE_EXISTS;
case -ETIMEDOUT:
+ case -ETIME:
return DBUS_ERROR_TIMEOUT;
case -EIO:
diff --git a/src/tty-ask-password-agent.c b/src/tty-ask-password-agent.c
index 14b0148..5e74524 100644
--- a/src/tty-ask-password-agent.c
+++ b/src/tty-ask-password-agent.c
@@ -128,7 +128,7 @@ static int ask_password_plymouth(
y = now(CLOCK_MONOTONIC);
if (y > until) {
- r = -ETIMEDOUT;
+ r = -ETIME;
goto finish;
}
@@ -149,7 +149,7 @@ static int ask_password_plymouth(
r = -errno;
goto finish;
} else if (j == 0) {
- r = -ETIMEDOUT;
+ r = -ETIME;
goto finish;
}
commit aa2e2115873e102b8f6701f4211ddf7bec4c5e10
Author: Lennart Poettering <lennart at poettering.net>
Date: Thu Feb 24 02:32:50 2011 +0100
units: synchronize gettys to plymouth even if plymouth is killed by gdm
diff --git a/Makefile.am b/Makefile.am
index 7e5d6d8..1841ad5 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -243,7 +243,6 @@ dist_systemunit_DATA = \
units/systemd-tmpfiles-clean.timer \
units/quotaon.service \
units/systemd-ask-password-wall.path \
- units/systemd-ask-password-plymouth.path \
units/systemd-ask-password-console.path
nodist_systemunit_DATA = \
@@ -270,7 +269,6 @@ nodist_systemunit_DATA = \
units/systemd-tmpfiles-clean.service \
units/systemd-user-sessions.service \
units/systemd-ask-password-wall.service \
- units/systemd-ask-password-plymouth.service \
units/systemd-ask-password-console.service \
units/systemd-sysctl.service \
units/syslog.target \
@@ -316,7 +314,6 @@ EXTRA_DIST = \
units/systemd-tmpfiles-clean.service.in \
units/systemd-user-sessions.service.in \
units/systemd-ask-password-wall.service.in \
- units/systemd-ask-password-plymouth.service.in \
units/systemd-ask-password-console.service.in \
units/systemd-sysctl.service.in \
units/syslog.target.in \
@@ -343,10 +340,18 @@ dist_systemunit_DATA += \
units/plymouth-start.service \
units/plymouth-read-write.service \
units/plymouth-quit.service \
+ units/plymouth-quit-wait.service \
units/plymouth-reboot.service \
units/plymouth-kexec.service \
units/plymouth-poweroff.service \
- units/plymouth-halt.service
+ units/plymouth-halt.service \
+ units/systemd-ask-password-plymouth.path
+
+nodist_systemunit_DATA += \
+ units/systemd-ask-password-plymouth.service
+
+EXTRA_DIST += \
+ units/systemd-ask-password-plymouth.service.in
endif
dist_doc_DATA = \
@@ -1302,8 +1307,9 @@ if HAVE_PLYMOUTH
$(LN_S) ../plymouth-start.service plymouth-start.service && \
$(LN_S) ../plymouth-read-write.service plymouth-read-write.service )
( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
- rm -f plymouth-quit.service && \
- $(LN_S) ../plymouth-quit.service plymouth-quit.service )
+ rm -f plymouth-quit.service plymouth-quit-wait.service && \
+ $(LN_S) ../plymouth-quit.service plymouth-quit.service && \
+ $(LN_S) ../plymouth-quit-wait.service plymouth-quit-wait.service )
( cd $(DESTDIR)$(systemunitdir)/reboot.target.wants && \
rm -f plymouth-reboot.service && \
$(LN_S) ../plymouth-reboot.service plymouth-reboot.service )
diff --git a/TODO b/TODO
index ba9650a..c7ba9fe 100644
--- a/TODO
+++ b/TODO
@@ -17,6 +17,8 @@ F15:
* NFS, networkmanager ordering issue
+* Make systemd-cryptsetup cancellable
+
Features:
* introduce simple way to do mandatory conditions
diff --git a/units/getty at .service.m4 b/units/getty at .service.m4
index 23ea979..a016ba2 100644
--- a/units/getty at .service.m4
+++ b/units/getty at .service.m4
@@ -8,7 +8,7 @@
[Unit]
Description=Getty on %I
BindTo=dev-%i.device
-After=dev-%i.device systemd-user-sessions.service plymouth-quit.service
+After=dev-%i.device systemd-user-sessions.service plymouth-quit-wait.service
m4_ifdef(`TARGET_FEDORA',
After=rc-local.service
)m4_dnl
diff --git a/units/plymouth-quit-wait.service b/units/plymouth-quit-wait.service
new file mode 100644
index 0000000..45c67bd
--- /dev/null
+++ b/units/plymouth-quit-wait.service
@@ -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.
+
+[Unit]
+Description=Wait for Plymouth Boot Screen to Quit
+After=rc-local.service plymouth-start.service
+
+[Service]
+ExecStart=-/bin/plymouth --wait
+Type=oneshot
+TimeoutSec=20
diff --git a/units/serial-getty at .service.m4 b/units/serial-getty at .service.m4
index 4b031d7..82414ea 100644
--- a/units/serial-getty at .service.m4
+++ b/units/serial-getty at .service.m4
@@ -8,13 +8,16 @@
[Unit]
Description=Serial Getty on %I
BindTo=dev-%i.device
-After=dev-%i.device systemd-user-sessions.service plymouth-quit.service
+After=dev-%i.device systemd-user-sessions.service plymouth-quit-wait.service
m4_ifdef(`TARGET_FEDORA',
After=rc-local.service
)m4_dnl
m4_ifdef(`TARGET_ARCH',
After=rc-local.service
)m4_dnl
+m4_ifdef(`TARGET_FRUGALWARE',
+After=local.service
+)m4_dnl
# If additional gettys are spawned during boot then we should make
# sure that this is synchronized before getty.target, even though
commit 2e0d98fa87a4e399763c8235abe56be4f8ac7fb8
Author: Lennart Poettering <lennart at poettering.net>
Date: Wed Feb 23 19:44:08 2011 +0100
update TODO
diff --git a/TODO b/TODO
index 64f7ad7..ba9650a 100644
--- a/TODO
+++ b/TODO
@@ -19,6 +19,10 @@ F15:
Features:
+* introduce simple way to do mandatory conditions
+
+* detect LXC environment
+
* invoke vhangup() before and after invoking getty
* skip readahead on physically r/o media
More information about the systemd-commits
mailing list