2011-10-08 11:44:34 +02:00
|
|
|
From 6620bceb7233a830be3635a4f7a7dc75c13a9c8e Mon Sep 17 00:00:00 2001
|
|
|
|
From: Frederic Crozat <fcrozat@suse.com>
|
|
|
|
Date: Fri, 30 Sep 2011 14:12:45 +0200
|
|
|
|
Subject: [PATCH] service: Fix dependencies added when parsing insserv.conf
|
|
|
|
|
|
|
|
---
|
|
|
|
src/service.c | 16 +++++++++-------
|
|
|
|
1 files changed, 9 insertions(+), 7 deletions(-)
|
|
|
|
|
2012-02-16 16:24:03 +01:00
|
|
|
Index: systemd-41/src/service.c
|
Accepting request 101505 from Base:System
- Update to version 39:
+ New systemd-cgtop tool to show control groups by their resource
usage.
+ Linking against libacl for ACLs is optional again.
+ If a group "adm" exists, journal files are automatically owned
by them, thus allow members of this group full access to the
system journal as well as all user journals.
+ The journal now stores the SELinux context of the logging
client for all entries.
+ Add C++ inclusion guards to all public headers.
+ New output mode "cat" in the journal to print only text
messages, without any meta data like date or time.
+ Include tiny X server wrapper as a temporary stop-gap to teach
XOrg udev display enumeration (until XOrg supports udev
hotplugging for display devices).
+ Add new systemd-cat tool for executing arbitrary programs with
STDERR/STDOUT connected to the journal. Can also act as BSD
logger replacement, and does so by default.
+ Optionally store all locally generated coredumps in the journal
along with meta data.
+ systemd-tmpfiles learnt four new commands: n, L, c, b, for
writing short strings to files (for usage for /sys), and for
creating symlinks, character and block device nodes.
+ New unit file option ControlGroupPersistent= to make cgroups
persistent.
+ Support multiple local RTCs in a sane way.
+ No longer monopolize IO when replaying readahead data on
rotating disks.
+ Don't show kernel threads in systemd-cgls anymore, unless
requested with new -k switch. (forwarded request 101496 from fcrozat)
OBS-URL: https://build.opensuse.org/request/show/101505
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd?expand=0&rev=85
2012-01-26 16:00:42 +01:00
|
|
|
===================================================================
|
2012-02-16 16:24:03 +01:00
|
|
|
--- systemd-41.orig/src/service.c
|
|
|
|
+++ systemd-41/src/service.c
|
|
|
|
@@ -3210,23 +3210,30 @@ static void sysv_facility_in_insserv_con
|
2012-02-10 17:20:20 +01:00
|
|
|
Unit *u;
|
Accepting request 101505 from Base:System
- Update to version 39:
+ New systemd-cgtop tool to show control groups by their resource
usage.
+ Linking against libacl for ACLs is optional again.
+ If a group "adm" exists, journal files are automatically owned
by them, thus allow members of this group full access to the
system journal as well as all user journals.
+ The journal now stores the SELinux context of the logging
client for all entries.
+ Add C++ inclusion guards to all public headers.
+ New output mode "cat" in the journal to print only text
messages, without any meta data like date or time.
+ Include tiny X server wrapper as a temporary stop-gap to teach
XOrg udev display enumeration (until XOrg supports udev
hotplugging for display devices).
+ Add new systemd-cat tool for executing arbitrary programs with
STDERR/STDOUT connected to the journal. Can also act as BSD
logger replacement, and does so by default.
+ Optionally store all locally generated coredumps in the journal
along with meta data.
+ systemd-tmpfiles learnt four new commands: n, L, c, b, for
writing short strings to files (for usage for /sys), and for
creating symlinks, character and block device nodes.
+ New unit file option ControlGroupPersistent= to make cgroups
persistent.
+ Support multiple local RTCs in a sane way.
+ No longer monopolize IO when replaying readahead data on
rotating disks.
+ Don't show kernel threads in systemd-cgls anymore, unless
requested with new -k switch. (forwarded request 101496 from fcrozat)
OBS-URL: https://build.opensuse.org/request/show/101505
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd?expand=0&rev=85
2012-01-26 16:00:42 +01:00
|
|
|
if (sysv_translate_facility(parsed[0], NULL, &facility) < 0)
|
|
|
|
continue;
|
2012-02-10 17:20:20 +01:00
|
|
|
+ if (streq(facility, SPECIAL_REMOTE_FS_TARGET)) {
|
|
|
|
+ /* insert also a Wants dependency from remote-fs-pre on remote-fs */
|
|
|
|
+ u = manager_get_unit(mgr, SPECIAL_REMOTE_FS_TARGET);
|
2012-02-16 16:24:03 +01:00
|
|
|
+ unit_add_dependency_by_name(u, UNIT_WANTS, SPECIAL_REMOTE_FS_PRE_TARGET, NULL, true);
|
2012-02-10 17:20:20 +01:00
|
|
|
+ free (facility);
|
|
|
|
+ facility=strdup(SPECIAL_REMOTE_FS_PRE_TARGET);
|
|
|
|
+ }
|
Accepting request 101505 from Base:System
- Update to version 39:
+ New systemd-cgtop tool to show control groups by their resource
usage.
+ Linking against libacl for ACLs is optional again.
+ If a group "adm" exists, journal files are automatically owned
by them, thus allow members of this group full access to the
system journal as well as all user journals.
+ The journal now stores the SELinux context of the logging
client for all entries.
+ Add C++ inclusion guards to all public headers.
+ New output mode "cat" in the journal to print only text
messages, without any meta data like date or time.
+ Include tiny X server wrapper as a temporary stop-gap to teach
XOrg udev display enumeration (until XOrg supports udev
hotplugging for display devices).
+ Add new systemd-cat tool for executing arbitrary programs with
STDERR/STDOUT connected to the journal. Can also act as BSD
logger replacement, and does so by default.
+ Optionally store all locally generated coredumps in the journal
along with meta data.
+ systemd-tmpfiles learnt four new commands: n, L, c, b, for
writing short strings to files (for usage for /sys), and for
creating symlinks, character and block device nodes.
+ New unit file option ControlGroupPersistent= to make cgroups
persistent.
+ Support multiple local RTCs in a sane way.
+ No longer monopolize IO when replaying readahead data on
rotating disks.
+ Don't show kernel threads in systemd-cgls anymore, unless
requested with new -k switch. (forwarded request 101496 from fcrozat)
OBS-URL: https://build.opensuse.org/request/show/101505
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd?expand=0&rev=85
2012-01-26 16:00:42 +01:00
|
|
|
if ((u = manager_get_unit(mgr, facility)) && (u->type == UNIT_TARGET)) {
|
|
|
|
- UnitDependency e;
|
2011-10-08 11:44:34 +02:00
|
|
|
char *dep = NULL, *name, **j;
|
|
|
|
|
|
|
|
STRV_FOREACH (j, parsed+1) {
|
|
|
|
- if (*j[0]=='+') {
|
|
|
|
- e = UNIT_WANTS;
|
|
|
|
+ if (*j[0]=='+')
|
|
|
|
name = *j+1;
|
|
|
|
- }
|
|
|
|
- else {
|
|
|
|
- e = UNIT_REQUIRES;
|
|
|
|
+ else
|
|
|
|
name = *j;
|
|
|
|
- }
|
|
|
|
+ if (streq(name, "boot.localfs") ||
|
|
|
|
+ streq(name, "boot.crypto"))
|
|
|
|
+ continue;
|
|
|
|
if (sysv_translate_facility(name, NULL, &dep) < 0)
|
|
|
|
continue;
|
|
|
|
|
|
|
|
- r = unit_add_two_dependencies_by_name(u, UNIT_BEFORE, e, dep, NULL, true);
|
|
|
|
+ r = unit_add_dependency_by_name_inverse(u, UNIT_BEFORE, dep, NULL, true);
|
|
|
|
+ if (*j[0]!='+')
|
|
|
|
+ r = unit_add_dependency_by_name(u, UNIT_REQUIRES, dep, NULL, true);
|
|
|
|
free(dep);
|
|
|
|
}
|
|
|
|
}
|