[systemd-commits] 4 commits - man/kernel-command-line.xml man/systemctl.xml man/systemd.xml shell-completion/bash src/core src/shared src/systemctl TODO
Zbigniew JÄdrzejewski-Szmek
zbyszek at kemper.freedesktop.org
Thu May 30 17:50:03 PDT 2013
TODO | 5 -
man/kernel-command-line.xml | 12 +++
man/systemctl.xml | 31 ++++++++
man/systemd.xml | 23 ++++--
shell-completion/bash/systemctl | 6 +
src/core/dbus-manager.c | 28 +++++++
src/core/main.c | 2
src/core/manager.c | 3
src/core/org.freedesktop.systemd1.conf | 4 +
src/shared/install.c | 86 +++++++++++++++++++++++
src/shared/install.h | 2
src/shared/util.c | 8 +-
src/systemctl/systemctl.c | 119 +++++++++++++++++++++++++++++++--
13 files changed, 307 insertions(+), 22 deletions(-)
New commits:
commit 1058cbf2ad3d62d039f8f0be92d9d37777925a39
Author: Zbigniew JÄdrzejewski-Szmek <zbyszek at in.waw.pl>
Date: Thu May 30 20:28:09 2013 -0400
systemctl: suggest 'systemctl daemon-reload' without --system
--system is default anyway, and some poor user might type 9
characters without needing to.
diff --git a/src/core/manager.c b/src/core/manager.c
index a7cfe57..6b0f567 100644
--- a/src/core/manager.c
+++ b/src/core/manager.c
@@ -1037,7 +1037,8 @@ int manager_load_unit_prepare(Manager *m, const char *name, const char *path, DB
}
}
- if ((r = unit_add_name(ret, name)) < 0) {
+ r = unit_add_name(ret, name);
+ if (r < 0) {
unit_free(ret);
return r;
}
diff --git a/src/shared/util.c b/src/shared/util.c
index 673e0da..2edf9cd 100644
--- a/src/shared/util.c
+++ b/src/shared/util.c
@@ -850,18 +850,18 @@ int readlink_malloc(const char *p, char **r) {
}
int readlink_and_make_absolute(const char *p, char **r) {
- char *target, *k;
+ _cleanup_free_ char *target = NULL;
+ char *k;
int j;
assert(p);
assert(r);
- if ((j = readlink_malloc(p, &target)) < 0)
+ j = readlink_malloc(p, &target);
+ if (j < 0)
return j;
k = file_in_same_dir(p, target);
- free(target);
-
if (!k)
return -ENOMEM;
diff --git a/src/systemctl/systemctl.c b/src/systemctl/systemctl.c
index 5ccbbbc..6a4c2d6 100644
--- a/src/systemctl/systemctl.c
+++ b/src/systemctl/systemctl.c
@@ -1913,8 +1913,8 @@ static int start_unit_one(
}
if (need_daemon_reload(bus, n))
- log_warning("Warning: Unit file of %s changed on disk, 'systemctl %s daemon-reload' recommended.",
- n, arg_scope == UNIT_FILE_SYSTEM ? "--system" : "--user");
+ log_warning("Warning: Unit file of %s changed on disk, 'systemctl %sdaemon-reload' recommended.",
+ n, arg_scope == UNIT_FILE_SYSTEM ? "" : "--user ");
if (s) {
char *p;
@@ -2974,10 +2974,10 @@ static void print_status_info(UnitStatusInfo *i) {
}
if (i->need_daemon_reload)
- printf("\n%sWarning:%s Unit file changed on disk, 'systemctl %s daemon-reload' recommended.\n",
+ printf("\n%sWarning:%s Unit file changed on disk, 'systemctl %sdaemon-reload' recommended.\n",
ansi_highlight_red(true),
ansi_highlight_red(false),
- arg_scope == UNIT_FILE_SYSTEM ? "--system" : "--user");
+ arg_scope == UNIT_FILE_SYSTEM ? "" : "--user ");
}
static void show_unit_help(UnitStatusInfo *i) {
commit 76d5a71de99b6fe0ecc9bfd82ec641a5d408e191
Author: Václav PavlÃn <vpavlin at redhat.com>
Date: Wed May 29 16:08:11 2013 +0200
systemctl: add command set-log-level
Command changes current log level
diff --git a/TODO b/TODO
index 7883b7e..9ba1de0 100644
--- a/TODO
+++ b/TODO
@@ -91,8 +91,6 @@ Features:
* we need dynamic units
-* add s.th. like "systemctl set-log-level debug"
-
* cgtop: make cgtop useful in a container
* test/:
diff --git a/man/systemctl.xml b/man/systemctl.xml
index 430e16c..54573e8 100644
--- a/man/systemctl.xml
+++ b/man/systemctl.xml
@@ -546,6 +546,19 @@ kobject-uevent 1 systemd-udevd-kernel.socket systemd-udevd.service
</listitem>
</varlistentry>
+ <varlistentry>
+ <term><command>set-log-level <replaceable>LEVEL</replaceable></command></term>
+
+ <listitem>
+ <para>Change current log level of the
+ <command>systemd</command> daemon to
+ <replaceable>LEVEL</replaceable> (accepts the same values
+ as <option>--log-level=</option> described in
+ <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>).
+ </para>
+ </listitem>
+ </varlistentry>
+
<varlistentry>
<term><command>start <replaceable>NAME</replaceable>...</command></term>
diff --git a/src/systemctl/systemctl.c b/src/systemctl/systemctl.c
index 56021a6..5ccbbbc 100644
--- a/src/systemctl/systemctl.c
+++ b/src/systemctl/systemctl.c
@@ -4462,6 +4462,51 @@ finish:
return r;
}
+static int set_log_level(DBusConnection *bus, char **args) {
+ _cleanup_dbus_error_free_ DBusError error;
+ _cleanup_dbus_message_unref_ DBusMessage *m = NULL, *reply = NULL;
+ DBusMessageIter iter, sub;
+ const char* property = "LogLevel";
+ const char* interface = "org.freedesktop.systemd1.Manager";
+ const char* value;
+
+ assert(bus);
+ assert(args);
+
+ value = args[1];
+ dbus_error_init(&error);
+
+ m = dbus_message_new_method_call("org.freedesktop.systemd1",
+ "/org/freedesktop/systemd1",
+ "org.freedesktop.DBus.Properties",
+ "Set");
+ if (!m)
+ return log_oom();
+
+ dbus_message_iter_init_append(m, &iter);
+
+ if (!dbus_message_iter_append_basic(&iter, DBUS_TYPE_STRING, &interface) ||
+ !dbus_message_iter_append_basic(&iter, DBUS_TYPE_STRING, &property) ||
+ !dbus_message_iter_open_container(&iter, DBUS_TYPE_VARIANT, "s", &sub))
+ return log_oom();
+
+ if (!dbus_message_iter_append_basic(&sub, DBUS_TYPE_STRING, &value)) {
+ dbus_message_iter_abandon_container(&iter, &sub);
+ return log_oom();
+ }
+
+ if (!dbus_message_iter_close_container(&iter, &sub))
+ return log_oom();
+
+ reply = dbus_connection_send_with_reply_and_block(bus, m, -1, &error);
+ if (!reply) {
+ log_error("Failed to issue method call: %s", bus_error_message(&error));
+ return -EIO;
+ }
+
+ return 0;
+}
+
static int unit_is_enabled(DBusConnection *bus, char **args) {
_cleanup_dbus_error_free_ DBusError error;
int r;
@@ -5707,6 +5752,7 @@ static int systemctl_main(DBusConnection *bus, int argc, char *argv[], DBusError
{ "list-dependencies", LESS, 2, list_dependencies },
{ "set-default", EQUAL, 2, enable_unit },
{ "get-default", LESS, 1, get_default },
+ { "set-log-level", EQUAL, 2, set_log_level },
};
int left;
commit 99504dd4c13af7516a976fffc0f68e6f26d3faac
Author: Václav PavlÃn <vpavlin at redhat.com>
Date: Tue May 28 11:05:48 2013 +0200
systemctl: add commands set-default and get-default
systemctl set-default NAME links the default.target to the given unit,
get-default prints out the path to the currently set default target.
diff --git a/man/systemctl.xml b/man/systemctl.xml
index 0afb0cc..430e16c 100644
--- a/man/systemctl.xml
+++ b/man/systemctl.xml
@@ -998,6 +998,24 @@ kobject-uevent 1 systemd-udevd-kernel.socket systemd-udevd.service
</varlistentry>
<varlistentry>
+ <term><command>get-default</command></term>
+
+ <listitem>
+ <para>Get the default target specified
+ via <filename>default.target</filename> link.</para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
+ <term><command>set-default <replaceable>NAME</replaceable></command></term>
+
+ <listitem>
+ <para>Set the default target to boot into. Command links
+ <filename>default.target</filename> to the given unit.</para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
<term><command>load <replaceable>NAME</replaceable>...</command></term>
<listitem>
diff --git a/shell-completion/bash/systemctl b/shell-completion/bash/systemctl
index 191b8d1..a05b756 100644
--- a/shell-completion/bash/systemctl
+++ b/shell-completion/bash/systemctl
@@ -134,9 +134,10 @@ _systemctl () {
[STANDALONE]='daemon-reexec daemon-reload default dump
emergency exit halt hibernate hybrid-sleep kexec list-jobs
list-units list-unit-files poweroff reboot rescue
- show-environment suspend'
+ show-environment suspend get-default'
[NAME]='snapshot load'
[FILE]='link'
+ [TARGETS]='set-default'
)
for ((i=0; $i <= $COMP_CWORD; i++)); do
@@ -210,6 +211,9 @@ _systemctl () {
elif __contains_word "$verb" ${VERBS[FILE]}; then
comps=$( compgen -A file -- "$cur" )
compopt -o filenames
+ elif __contains_word "$verb" ${VERBS[TARGETS]}; then
+ comps=$( __systemctl $mode list-unit-files --type target --full --all \
+ | { while read -r a b; do echo " $a"; done; } )
fi
COMPREPLY=( $(compgen -W '$comps' -- "$cur") )
diff --git a/src/core/dbus-manager.c b/src/core/dbus-manager.c
index 56b02a1..f3ddfc9 100644
--- a/src/core/dbus-manager.c
+++ b/src/core/dbus-manager.c
@@ -227,6 +227,13 @@
" <arg name=\"files\" type=\"as\" direction=\"in\"/>\n" \
" <arg name=\"runtime\" type=\"b\" direction=\"in\"/>\n" \
" <arg name=\"changes\" type=\"a(sss)\" direction=\"out\"/>\n" \
+ " </method>\n" \
+ " <method name=\"SetDefaultTarget\">\n" \
+ " <arg name=\"files\" type=\"as\" direction=\"in\"/>\n" \
+ " <arg name=\"changes\" type=\"a(sss)\" direction=\"out\"/>\n" \
+ " </method>\n" \
+ " <method name=\"GetDefaultTarget\">\n" \
+ " <arg name=\"name\" type=\"s\" direction=\"out\"/>\n" \
" </method>\n"
#define BUS_MANAGER_INTERFACE_SIGNALS \
@@ -1728,7 +1735,8 @@ static DBusHandlerResult bus_manager_message_handler(DBusConnection *connection,
dbus_message_is_method_call(message, "org.freedesktop.systemd1.Manager", "ReenableUnitFiles") ||
dbus_message_is_method_call(message, "org.freedesktop.systemd1.Manager", "LinkUnitFiles") ||
dbus_message_is_method_call(message, "org.freedesktop.systemd1.Manager", "PresetUnitFiles") ||
- dbus_message_is_method_call(message, "org.freedesktop.systemd1.Manager", "MaskUnitFiles")) {
+ dbus_message_is_method_call(message, "org.freedesktop.systemd1.Manager", "MaskUnitFiles") ||
+ dbus_message_is_method_call(message, "org.freedesktop.systemd1.Manager", "SetDefaultTarget")) {
char **l = NULL;
DBusMessageIter iter;
@@ -1771,6 +1779,8 @@ static DBusHandlerResult bus_manager_message_handler(DBusConnection *connection,
carries_install_info = r;
} else if (streq(member, "MaskUnitFiles"))
r = unit_file_mask(scope, runtime, NULL, l, force, &changes, &n_changes);
+ else if (streq(member, "SetDefaultTarget"))
+ r = unit_file_set_default(scope, NULL, l[0], &changes, &n_changes);
else
assert_not_reached("Uh? Wrong method");
@@ -1838,6 +1848,22 @@ static DBusHandlerResult bus_manager_message_handler(DBusConnection *connection,
if (!reply)
goto oom;
+ } else if (dbus_message_is_method_call(message, "org.freedesktop.systemd1.Manager", "GetDefaultTarget")) {
+ UnitFileScope scope = m->running_as == SYSTEMD_SYSTEM ? UNIT_FILE_SYSTEM : UNIT_FILE_USER;
+ _cleanup_free_ char *default_target = NULL;
+
+ reply = dbus_message_new_method_return(message);
+ if (!reply)
+ goto oom;
+
+ r = unit_file_get_default(scope, NULL, &default_target);
+
+ if (r < 0)
+ return bus_send_error_reply(connection, message, NULL, r);
+
+ if (!dbus_message_append_args(reply, DBUS_TYPE_STRING, &default_target, DBUS_TYPE_INVALID)) {
+ goto oom;
+ }
} else {
const BusBoundProperties bps[] = {
{ "org.freedesktop.systemd1.Manager", bus_systemd_properties, systemd_property_string },
diff --git a/src/core/org.freedesktop.systemd1.conf b/src/core/org.freedesktop.systemd1.conf
index a07a8e1..a375dce 100644
--- a/src/core/org.freedesktop.systemd1.conf
+++ b/src/core/org.freedesktop.systemd1.conf
@@ -86,6 +86,10 @@
send_interface="org.freedesktop.systemd1.Manager"
send_member="Dump"/>
+ <allow send_destination="org.freedesktop.systemd1"
+ send_interface="org.freedesktop.systemd1.Manager"
+ send_member="GetDefaultTarget"/>
+
<allow receive_sender="org.freedesktop.systemd1"/>
</policy>
diff --git a/src/shared/install.c b/src/shared/install.c
index 8f27c6d..954dcb1 100644
--- a/src/shared/install.c
+++ b/src/shared/install.c
@@ -1570,6 +1570,92 @@ int unit_file_reenable(
return r;
}
+int unit_file_set_default(
+ UnitFileScope scope,
+ const char *root_dir,
+ char *file,
+ UnitFileChange **changes,
+ unsigned *n_changes) {
+
+ _cleanup_lookup_paths_free_ LookupPaths paths = {};
+ _cleanup_install_context_done_ InstallContext c = {};
+ _cleanup_free_ char *config_path = NULL;
+ char *path;
+ int r;
+ InstallInfo *i = NULL;
+
+ assert(scope >= 0);
+ assert(scope < _UNIT_FILE_SCOPE_MAX);
+
+ if (unit_name_to_type(file) != UNIT_TARGET)
+ return -EINVAL;
+
+ r = lookup_paths_init_from_scope(&paths, scope);
+ if (r < 0)
+ return r;
+
+ r = get_config_path(scope, false, root_dir, &config_path);
+ if (r < 0)
+ return r;
+
+ r = install_info_add_auto(&c, file);
+ if (r < 0)
+ return r;
+
+ i = (InstallInfo*)hashmap_first(c.will_install);
+
+ r = unit_file_search(&c, i, &paths, root_dir, false);
+ if (r < 0)
+ return r;
+
+ path = strappenda(config_path, "/default.target");
+ r = create_symlink(i->path, path, true, changes, n_changes);
+ if (r < 0)
+ return r;
+
+ return 0;
+}
+
+int unit_file_get_default(
+ UnitFileScope scope,
+ const char *root_dir,
+ char **name) {
+
+ _cleanup_lookup_paths_free_ LookupPaths paths = {};
+ char **p;
+ int r;
+
+ r = lookup_paths_init_from_scope(&paths, scope);
+ if (r < 0)
+ return r;
+
+ STRV_FOREACH(p, paths.unit_path) {
+ _cleanup_free_ char *path = NULL, *tmp = NULL;
+
+ if (isempty(root_dir))
+ path = strappend(*p, "/default.target");
+ else
+ path = strjoin(root_dir, "/", *p, "/default.target", NULL);
+
+ if (!path)
+ return -ENOMEM;
+
+ r = readlink_malloc(path, &tmp);
+ if (r == -ENOENT)
+ continue;
+ else if (r < 0)
+ return r;
+
+ *name = strdup(path_get_file_name(tmp));
+ if (!*name)
+ return -ENOMEM;
+
+ return 0;
+ }
+
+ return -ENOENT;
+}
+
UnitFileState unit_file_get_state(
UnitFileScope scope,
const char *root_dir,
diff --git a/src/shared/install.h b/src/shared/install.h
index 94516c9..5609d1e 100644
--- a/src/shared/install.h
+++ b/src/shared/install.h
@@ -80,6 +80,8 @@ int unit_file_link(UnitFileScope scope, bool runtime, const char *root_dir, char
int unit_file_preset(UnitFileScope scope, bool runtime, const char *root_dir, char *files[], bool force, UnitFileChange **changes, unsigned *n_changes);
int unit_file_mask(UnitFileScope scope, bool runtime, const char *root_dir, char *files[], bool force, UnitFileChange **changes, unsigned *n_changes);
int unit_file_unmask(UnitFileScope scope, bool runtime, const char *root_dir, char *files[], UnitFileChange **changes, unsigned *n_changes);
+int unit_file_set_default(UnitFileScope scope, const char *root_dir, char *file, UnitFileChange **changes, unsigned *n_changes);
+int unit_file_get_default(UnitFileScope scope, const char *root_dir, char **name);
UnitFileState unit_file_get_state(UnitFileScope scope, const char *root_dir, const char *filename);
diff --git a/src/systemctl/systemctl.c b/src/systemctl/systemctl.c
index f8573d3..56021a6 100644
--- a/src/systemctl/systemctl.c
+++ b/src/systemctl/systemctl.c
@@ -1177,6 +1177,59 @@ static int list_dependencies(DBusConnection *bus, char **args) {
return list_dependencies_one(bus, u, 0, &units, 0);
}
+static int get_default(DBusConnection *bus, char **args) {
+ char *path = NULL;
+ _cleanup_dbus_message_unref_ DBusMessage *m = NULL, *reply = NULL;
+ int r;
+ _cleanup_dbus_error_free_ DBusError error;
+
+ dbus_error_init(&error);
+
+ if (!bus || avoid_bus()) {
+ r = unit_file_get_default(arg_scope, arg_root, &path);
+
+ if (r < 0) {
+ log_error("Operation failed: %s", strerror(-r));
+ goto finish;
+ }
+
+ r = 0;
+ } else {
+ r = bus_method_call_with_reply(
+ bus,
+ "org.freedesktop.systemd1",
+ "/org/freedesktop/systemd1",
+ "org.freedesktop.systemd1.Manager",
+ "GetDefaultTarget",
+ &reply,
+ NULL,
+ DBUS_TYPE_INVALID);
+
+ if (r < 0) {
+ log_error("Operation failed: %s", strerror(-r));
+ goto finish;
+ }
+
+ if (!dbus_message_get_args(reply, &error,
+ DBUS_TYPE_STRING, &path,
+ DBUS_TYPE_INVALID)) {
+ log_error("Failed to parse reply: %s", bus_error_message(&error));
+ dbus_error_free(&error);
+ return -EIO;
+ }
+ }
+
+ if (path)
+ printf("%s\n", path);
+
+finish:
+ if ((!bus || avoid_bus()) && path)
+ free(path);
+
+ return r;
+
+}
+
struct job_info {
uint32_t id;
char *name, *type, *state;
@@ -4243,6 +4296,8 @@ static int enable_unit(DBusConnection *bus, char **args) {
r = unit_file_mask(arg_scope, arg_runtime, arg_root, mangled_names, arg_force, &changes, &n_changes);
else if (streq(verb, "unmask"))
r = unit_file_unmask(arg_scope, arg_runtime, arg_root, mangled_names, &changes, &n_changes);
+ else if (streq(verb, "set-default"))
+ r = unit_file_set_default(arg_scope, arg_root, args[1], &changes, &n_changes);
else
assert_not_reached("Unknown verb");
@@ -4286,6 +4341,8 @@ static int enable_unit(DBusConnection *bus, char **args) {
else if (streq(verb, "unmask")) {
method = "UnmaskUnitFiles";
send_force = false;
+ } else if (streq(verb, "set-default")) {
+ method = "SetDefaultTarget";
} else
assert_not_reached("Unknown verb");
@@ -4585,6 +4642,8 @@ static int systemctl_help(void) {
" unmask [NAME...] Unmask one or more units\n"
" link [PATH...] Link one or more units files into\n"
" the search path\n"
+ " get-default Get the name of the default target\n"
+ " set-default NAME Set the default target\n"
" is-enabled [NAME...] Check whether unit files are enabled\n\n"
"Job Commands:\n"
" list-jobs List jobs\n"
@@ -5646,6 +5705,8 @@ static int systemctl_main(DBusConnection *bus, int argc, char *argv[], DBusError
{ "link", MORE, 2, enable_unit },
{ "switch-root", MORE, 2, switch_root },
{ "list-dependencies", LESS, 2, list_dependencies },
+ { "set-default", EQUAL, 2, enable_unit },
+ { "get-default", LESS, 1, get_default },
};
int left;
@@ -5717,7 +5778,9 @@ static int systemctl_main(DBusConnection *bus, int argc, char *argv[], DBusError
!streq(verbs[i].verb, "preset") &&
!streq(verbs[i].verb, "mask") &&
!streq(verbs[i].verb, "unmask") &&
- !streq(verbs[i].verb, "link")) {
+ !streq(verbs[i].verb, "link") &&
+ !streq(verbs[i].verb, "set-default") &&
+ !streq(verbs[i].verb, "get-default")) {
if (running_in_chroot() > 0) {
log_info("Running in chroot, ignoring request.");
commit 9749cd77bc6121a304a7f1eb0f03f26e620dc9da
Author: Lukas Nykryn <lnykryn at redhat.com>
Date: Wed May 29 14:09:56 2013 +0200
core: read "debug" from kernel commandline and set log level
diff --git a/TODO b/TODO
index f8a1b1b..7883b7e 100644
--- a/TODO
+++ b/TODO
@@ -56,9 +56,6 @@ Features:
complain loudly if they have argv[0][0] == '@' set.
https://bugzilla.redhat.com/show_bug.cgi?id=961044
-* read the kernel's console "debug" keyword like we read "quiet" and adjust:
- systemd.log_level=debug and maybe systemd.log_target=kmsg
-
* add an option to nspawn that uses seccomp to make socket(AF_NETLINK,
SOCK_RAW, NETLINK_AUDIT) fail the the appropriate error code that
makes the audit userspace to think auditing is not available in the
diff --git a/man/kernel-command-line.xml b/man/kernel-command-line.xml
index 7ff2709..db5d38a 100644
--- a/man/kernel-command-line.xml
+++ b/man/kernel-command-line.xml
@@ -111,6 +111,18 @@
</varlistentry>
<varlistentry>
+ <term><varname>debug</varname></term>
+ <listitem>
+ <para>Parameter understood by
+ both the kernel and the system
+ and service manager to control
+ console log verbosity. For
+ details see
+ <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>.</para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
<term><varname>emergency</varname></term>
<term><varname>single</varname></term>
<term><varname>s</varname></term>
diff --git a/man/systemd.xml b/man/systemd.xml
index d009ed8..497dd2b 100644
--- a/man/systemd.xml
+++ b/man/systemd.xml
@@ -1114,15 +1114,28 @@
<varlistentry>
<term><varname>quiet</varname></term>
- <listitem><para>If passed turns off
+ <listitem><para>Turn off
status output at boot, much like
<varname>systemd.show_status=false</varname>
would. Note that this option is also
read by the kernel itself and disables
- kernel log output to the
- kernel. Passing this option hence
- turns off the usual output from both
- the system manager and the
+ kernel log output. Passing this option
+ hence turns off the usual output from
+ both the system manager and the kernel.
+ </para></listitem>
+ </varlistentry>
+
+ <varlistentry>
+ <term><varname>debug</varname></term>
+
+ <listitem><para>Turn on debugging
+ output. This is equivalent to
+ <varname>systemd.log_level=debug</varname>.
+ Note that this option is also read by
+ the kernel itself and enables kernel
+ debug output. Passing this option
+ hence turns on the debug output from
+ both the system manager and the
kernel.</para></listitem>
</varlistentry>
diff --git a/src/core/main.c b/src/core/main.c
index bf1e3e8..bb73640 100644
--- a/src/core/main.c
+++ b/src/core/main.c
@@ -410,6 +410,8 @@ static int parse_proc_cmdline_word(const char *word) {
} else if (streq(word, "quiet"))
arg_show_status = false;
+ else if (streq(word, "debug"))
+ log_set_max_level(LOG_DEBUG);
else if (!in_initrd()) {
unsigned i;
More information about the systemd-commits
mailing list