Commit graph

101 commits

Author SHA1 Message Date
Lennart Poettering f975e971ac load-fragment: speed up parsing by using a perfect hash table with configuration settings built by gperf 2011-08-01 00:43:05 +02:00
Lennart Poettering 82e487c56d unit: introduce ConditionFileIsExecutable= and use it where we check for a binary we'll spawn 2011-07-12 04:25:02 +02:00
Lennart Poettering 8092a428d4 path,unit: support globbing in conditions and path units 2011-07-07 02:07:39 +02:00
Lennart Poettering 8fef765900 unit: support wildcards in Environment=, EnvironmentFile= 2011-07-01 01:13:47 +02:00
Lennart Poettering 1fd45a90f5 unit: do wildcard expansion in ListenStream= and friends 2011-07-01 00:55:34 +02:00
Lennart Poettering f284f69a7b execute: when parsing ConrolGroup= replace wildcards 2011-06-30 02:39:29 +02:00
Lennart Poettering 64747e2d4b exec: add ControlGroupModify= switch to allow changing access mode to cgroups fs 2011-06-30 00:11:25 +02:00
Lennart Poettering 15e11d81e7 unit: when loading symlinked template units, properly add all names on the way to the unit 2011-06-28 02:53:15 +02:00
Lennart Poettering ec6370a22d socket: expose SO_BROADCAST 2011-05-19 18:10:19 +02:00
Lennart Poettering 6b6d2deecc socket: expose IP_TRANSPARENT 2011-05-19 13:22:31 +02:00
Lennart Poettering 6ea832a207 exec: hangup/reset/deallocate VTs in gettys
Explicitly disconnect all clients from a VT when a getty starts/finishes
(requires TIOCVHANGUP, available in 2.6.29).

Explicitly deallocate getty VTs in order to flush scrollback buffer.

Explicitly reset terminals to a defined state before spawning getty.
2011-05-18 01:07:36 +02:00
Lennart Poettering 916abb21d0 socket: add POSIX mqueue support 2011-05-17 19:37:03 +02:00
Lennart Poettering 7a6000a682 unit: make ignoring in snapshots a per unit property, instead of a per unit type property 2011-05-05 10:58:55 +02:00
Lennart Poettering b0a3f2bc09 socket: support ListeSpecial= sockets 2011-04-20 05:02:23 +02:00
Lennart Poettering 49f91047af socket: guarantee order in which sockets are passed to be the one of the configuration file 2011-04-16 03:42:18 +02:00
Lennart Poettering c8f4d7642b manager: introduce IgnoreOnIsolate flag so that we can keep systemd-logger around when isolating 2011-04-16 02:03:34 +02:00
Lennart Poettering 7a22745ac3 socket: support netlink sockets 2011-04-10 03:27:00 +02:00
Lennart Poettering 0e456f9781 path: optionally, create watched directories in .path units 2011-04-10 01:30:14 +02:00
Lennart Poettering 222ae6a8d7 unit: introduce OnFailureIsolate= 2011-04-07 04:11:31 +02:00
Lennart Poettering 3d57c6ab80 exec: support unlimited resources 2011-04-04 18:15:13 +02:00
Michal Schmidt 07e833bc1d condition: add ConditionSecurity
Using ConditionSecurity a unit can depend on a security module being
enabled/disabled. For now the only recognized security module is SELinux.

I'd like to use this feature for a unit that creates /.autorelabel if
SELinux is disabled, to ensure a relabel is done automatically when the
system is later rebooted with SELinux enabled.
2011-04-03 22:16:37 +02:00
Michal Schmidt 41584525cf load-fragment: unify config_parse_condition_{kernel, virt}
They only differ in the condition type, otherwise the code is identical.
Replace them with a more generic config_parse_condition_string().
2011-04-03 22:16:23 +02:00
Lennart Poettering 7d76f31288 log: fix shifting of facilities 2011-03-31 21:22:44 +02:00
Kay Sievers 2b583ce657 use /run instead of /dev/.run
Instead of the /dev/.run trick we have currently implemented, we decided
to move the early-boot runtime dir to /run.

An existing /var/run directory is bind-mounted to /run. If /var/run is
already a symlink, no action is taken.

An existing /var/lock directory is bind-mounted to /run/lock.
If /var/lock is already a symlink, no action is taken.

To implement the directory vs. symlink logic, we have a:
  ConditionPathIsDirectory=
now, which is used in the mount units.

Skipped mount unit in case of symlink:
  $ systemctl status var-run.mount
  var-run.mount - Runtime Directory
    Loaded: loaded (/lib/systemd/system/var-run.mount)
    Active: inactive (dead)
            start condition failed at Fri, 25 Mar 2011 04:51:41 +0100; 6min ago
     Where: /var/run
      What: /run
    CGroup: name=systemd:/system/var-run.mount

The systemd rpm needs to make sure to add something like:
  %pre
  mkdir -p -m0755 /run >/dev/null 2>&1 || :
or it needs to be added to filesystem.rpm.

Udev -git already uses /run if that exists, and is writable at bootup.
Otherwise it falls back to the current /dev/.udev.

Dracut and plymouth need to be adopted to switch from /dev/.run to run
too.

Cheers,
Kay
2011-03-28 23:00:00 +02:00
Lennart Poettering 260abb780a exec: properly apply capability bounding set, add inverted bounding sets 2011-03-18 04:52:45 +01:00
Lennart Poettering 267632f0ab unit: distuingish mandatory from triggering conditions 2011-03-08 03:04:47 +01:00
Lennart Poettering 8c7be95e5a execute: load environment files at time of execution, not when we load the service configuration
https://bugzilla.redhat.com/show_bug.cgi?id=661282
2011-03-04 03:44:43 +01:00
Lennart Poettering 039655a40c unit: introduce ConditionVirtualization= 2011-02-21 22:07:55 +01:00
Lennart Poettering 3185a36b05 service: make main pid guessing optional, and reread pid file after reloads 2011-02-13 18:51:30 +01:00
Lennart Poettering b20c6be697 pam: optionally reset cgroup memberships for login sessions 2011-02-04 12:46:38 +01:00
Adrian Spinu 7115593375 load-fragment: properly parse Nice= value
Hello,

     i`ve been using systemd for a while now, and found out that when
using NICE parameter for .service files the varible is not set correctly.
     i`ve found the problem in file *load-fragment.c* function
*config_parse_nice*        variable /*c->nice_set = false;*/  should be
/*c->nice_set = true;*/
     Problem is alsom manifesting on v17 but did not upgrade yet ...
2011-02-03 21:23:32 +01:00
Lennart Poettering bd40a2d830 clang: fix some issues found with clang-analyzer 2011-01-22 02:19:16 +01:00
Lennart Poettering ba035df230 execute: make sending of SIGKILL on shutdown optional 2011-01-18 22:55:54 +01:00
Lennart Poettering 2292707df5 man: document missing KillSignal= and swap options 2011-01-18 00:40:10 +01:00
Lennart Poettering a6ff950e71 execute: drop empty assignments from env blocks on execution but keep them around otherwise to make them visible 2011-01-06 20:38:02 +01:00
Lennart Poettering afe4bfe2c1 fragment: allow prefixing of the EnvironmentFile= path with - to ignore errors 2011-01-06 01:39:08 +01:00
Lennart Poettering 5f7c426e2a fragment: properly handle quotes in assignments in EnvironmentFile= files 2011-01-05 16:06:35 +01:00
Lennart Poettering 36af55d997 unit: introduce ConditionDirectoryNotEmpty= 2010-11-15 22:13:25 +01:00
Lennart Poettering f90cf44c02 load-fragment: properly do comparison of words 2010-11-14 19:59:10 +01:00
Lennart Poettering d257ddef22 unit: add ConditionNull= condition 2010-11-10 22:39:18 +01:00
Lennart Poettering ead8e4788e unit: get rid of gnoreDependencyFailure= instead treat ConflictedBy= as weaker counterpart of Conflicts=, similar to Wants= vs. Requires= 2010-10-29 16:28:27 +02:00
Lennart Poettering b81884e746 unit: replace StopRetroactively= by BindTo= dependencies
The property StopRetroactively= needs to be per-dependency, not
per-unit, in order to properly express dependencies between .mount units
and its .device and fsck .service units. If the .device unit is
unplugged the mount should go away, but if the fsck process terminates
the .mount should stay.
2010-10-29 00:45:46 +02:00
Lennart Poettering f14e15f8af unit: replace recursive_stop by stop_retroactively to simplify things a little 2010-10-28 03:38:52 +02:00
Lennart Poettering 8a0867d6c5 systemctl: introduce systemctl kill 2010-10-22 16:11:50 +02:00
Lennart Poettering 2ba545f1a0 service: implement FsckPassNo= option 2010-10-20 14:22:23 +02:00
Lennart Poettering 52661efd21 unit: add minimal condition checker for unit startup 2010-10-13 02:15:41 +02:00
Lennart Poettering 6daf4f9001 unit: rename 'banned' load state to 'masked' 2010-10-08 18:21:52 +02:00
Lennart Poettering 169c1bda80 service: optionally, create INIT_PROCESS/DEAD_PROCESS entries for a service
This should fix accounting for pam_limits and suchlike.

https://bugzilla.redhat.com/show_bug.cgi?id=636036
2010-10-08 16:07:50 +02:00
Lennart Poettering b9c0d4415b systemctl: fix 'systemctl enable getty@.service' 2010-10-08 03:09:25 +02:00
Lennart Poettering 00dc5d769a unit: introduce 'banned' load state for units symlinked to /dev/null 2010-10-08 02:31:36 +02:00