Systemd/src/core
Lennart Poettering 6bf0f408e4 core: make the StartLimitXYZ= settings generic and apply to any kind of unit, not just services
This moves the StartLimitBurst=, StartLimitInterval=, StartLimitAction=, RebootArgument= from the [Service] section
into the [Unit] section of unit files, and thus support it in all unit types, not just in services.

This way we can enforce the start limit much earlier, in particular before testing the unit conditions, so that
repeated start-up failure due to failed conditions is also considered for the start limit logic.

For compatibility the four options may also be configured in the [Service] section still, but we only document them in
their new section [Unit].

This also renamed the socket unit failure code "service-failed-permanent" into "service-start-limit-hit" to express
more clearly what it is about, after all it's only triggered through the start limit being hit.

Finally, the code in busname_trigger_notify() and socket_trigger_notify() is altered to become more alike.

Fixes: #2467
2016-02-10 13:26:56 +01:00
..
.gitignore Move daemon-reload from package %post scripts to file triggers 2015-11-15 18:38:37 -05:00
audit-fd.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
audit-fd.h
automount.c tree-wide: expose "p"-suffix unref calls in public APIs to make gcc cleanup easy 2015-11-27 19:19:36 +01:00
automount.h Move all unit states to basic/ and extend systemctl --state=help 2015-09-28 15:09:34 -04:00
bus-endpoint.c util-lib: split out allocation calls into alloc-util.[ch] 2015-10-27 13:45:53 +01:00
bus-endpoint.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
bus-policy.c util-lib: split out allocation calls into alloc-util.[ch] 2015-10-27 13:45:53 +01:00
bus-policy.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
busname.c core: make the StartLimitXYZ= settings generic and apply to any kind of unit, not just services 2016-02-10 13:26:56 +01:00
busname.h core: make the StartLimitXYZ= settings generic and apply to any kind of unit, not just services 2016-02-10 13:26:56 +01:00
cgroup.c core: don't generate warnings when write access to the cgroup fs fails in --user due to EACCES 2015-11-17 00:52:10 +01:00
cgroup.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
dbus-automount.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
dbus-automount.h remove unused includes 2015-02-23 23:53:42 +01:00
dbus-busname.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
dbus-busname.h remove unused includes 2015-02-23 23:53:42 +01:00
dbus-cgroup.c util-lib: split out allocation calls into alloc-util.[ch] 2015-10-27 13:45:53 +01:00
dbus-cgroup.h util-lib: split our string related calls from util.[ch] into its own file string-util.[ch] 2015-10-24 23:05:02 +02:00
dbus-device.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
dbus-device.h remove unused includes 2015-02-23 23:53:42 +01:00
dbus-execute.c core: fix support for transient resource limit properties 2016-02-01 22:18:16 +01:00
dbus-execute.h util-lib: split our string related calls from util.[ch] into its own file string-util.[ch] 2015-10-24 23:05:02 +02:00
dbus-job.c tree-wide: expose "p"-suffix unref calls in public APIs to make gcc cleanup easy 2015-11-27 19:19:36 +01:00
dbus-job.h util-lib: split our string related calls from util.[ch] into its own file string-util.[ch] 2015-10-24 23:05:02 +02:00
dbus-kill.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
dbus-kill.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
dbus-manager.c core: fix memory leak on failed preset-all 2016-01-18 06:39:38 +00:00
dbus-manager.h core: emit changes for NFailedUnits property 2015-02-26 09:38:50 -05:00
dbus-mount.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
dbus-mount.h util-lib: split our string related calls from util.[ch] into its own file string-util.[ch] 2015-10-24 23:05:02 +02:00
dbus-path.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
dbus-path.h remove unused includes 2015-02-23 23:53:42 +01:00
dbus-scope.c tree-wide: expose "p"-suffix unref calls in public APIs to make gcc cleanup easy 2015-11-27 19:19:36 +01:00
dbus-scope.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
dbus-service.c core: make the StartLimitXYZ= settings generic and apply to any kind of unit, not just services 2016-02-10 13:26:56 +01:00
dbus-service.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
dbus-slice.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
dbus-slice.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
dbus-socket.c Socket: socket protocol add to dbus properties 2015-11-18 09:34:19 +05:30
dbus-socket.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
dbus-swap.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
dbus-swap.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
dbus-target.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
dbus-target.h util-lib: split our string related calls from util.[ch] into its own file string-util.[ch] 2015-10-24 23:05:02 +02:00
dbus-timer.c core: when saving timer unit time values, store them in raw µs 2016-02-01 22:18:16 +01:00
dbus-timer.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
dbus-unit.c core: make the StartLimitXYZ= settings generic and apply to any kind of unit, not just services 2016-02-10 13:26:56 +01:00
dbus-unit.h Merge pull request #1828 from fbuihuu/set-property-on-inactive-unit 2015-11-27 14:00:57 +01:00
dbus.c core: re-sync bus name list after deserializing during daemon-reload 2015-12-23 23:31:35 +01:00
dbus.h core: re-sync bus name list after deserializing during daemon-reload 2015-12-23 23:31:35 +01:00
device.c Merge pull request #2412 from fbuihuu/device-fixes 2016-01-22 17:28:05 +01:00
device.h Move all unit states to basic/ and extend systemctl --state=help 2015-09-28 15:09:34 -04:00
execute.c core: don't reset /dev/console if stdin/stdout/stderr as passed as fd in a transient service 2016-01-28 16:25:39 +01:00
execute.h core: don't reset /dev/console if stdin/stdout/stderr as passed as fd in a transient service 2016-01-28 16:25:39 +01:00
failure-action.c core: unify code that warns about jobs we fail to enqueue 2015-11-12 20:14:06 +01:00
failure-action.h core: introduce "poweroff" as new failure action types 2014-08-22 18:10:31 +02:00
hostname-setup.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
hostname-setup.h
ima-setup.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
ima-setup.h
job.c core: rework job_get_timeout() to use usec_t and handle USEC_INFINITY time events correctly 2016-02-04 00:35:43 +01:00
job.h core: rework job_get_timeout() to use usec_t and handle USEC_INFINITY time events correctly 2016-02-04 00:35:43 +01:00
kill.c util-lib: move string table stuff into its own string-table.[ch] 2015-10-27 13:25:56 +01:00
kill.h core: extend KillUnit() to return error when no unit was killed 2015-09-21 10:05:49 +02:00
killall.c shutdown: complain if process excluded from killing spree runs of the same rootfs as PID1 2016-01-26 14:13:13 +01:00
killall.h core: fix order of parameters in broadcast_signal() 2013-11-25 23:03:03 +01:00
kmod-setup.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
kmod-setup.h
load-dropin.c core: fix memory leak in transient units 2016-01-15 02:46:43 +00:00
load-dropin.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
load-fragment-gperf.gperf.m4 core: make the StartLimitXYZ= settings generic and apply to any kind of unit, not just services 2016-02-10 13:26:56 +01:00
load-fragment.c core: rework unit timeout handling, and add new setting RuntimeMaxSec= 2016-02-01 22:18:16 +01:00
load-fragment.h core: move parsing of rlimits into rlimit-util.[ch] 2016-02-01 22:18:16 +01:00
locale-setup.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
locale-setup.h
loopback-setup.c tree-wide: expose "p"-suffix unref calls in public APIs to make gcc cleanup easy 2015-11-27 19:19:36 +01:00
loopback-setup.h
machine-id-setup.c core: Add machine-id setting 2016-01-12 22:10:41 +00:00
machine-id-setup.h core: Add machine-id setting 2016-01-12 22:10:41 +00:00
macros.systemd.in rpm: fix %systemd_user_post() macro. 2015-11-22 20:38:05 +01:00
main.c resolved: apply epoch to system time from PID 1 2016-02-03 23:58:24 +01:00
Makefile
manager.c core: when determining system state, don't bother with JOB_TRY_RESTART 2016-01-28 18:49:59 +01:00
manager.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
mount-setup.c core: log about path_is_mount_point() errors 2016-02-03 23:58:53 +01:00
mount-setup.h mount-setup: remove mount_setup_late() 2014-11-14 15:18:56 +01:00
mount.c core: rework job_get_timeout() to use usec_t and handle USEC_INFINITY time events correctly 2016-02-04 00:35:43 +01:00
mount.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
namespace.c util-lib: split out allocation calls into alloc-util.[ch] 2015-10-27 13:45:53 +01:00
namespace.h core: Private*/Protect* options with RootDirectory 2015-05-18 18:47:45 +02:00
org.freedesktop.systemd1.conf systemctl: add add-wants and add-requires verbs 2014-10-08 12:44:00 +02:00
org.freedesktop.systemd1.policy.in.in core: rework policykit hookup 2015-02-18 18:56:27 +01:00
org.freedesktop.systemd1.service
path.c tree-wide: expose "p"-suffix unref calls in public APIs to make gcc cleanup easy 2015-11-27 19:19:36 +01:00
path.h Move all unit states to basic/ and extend systemctl --state=help 2015-09-28 15:09:34 -04:00
scope.c core: rework job_get_timeout() to use usec_t and handle USEC_INFINITY time events correctly 2016-02-04 00:35:43 +01:00
scope.h Move all unit states to basic/ and extend systemctl --state=help 2015-09-28 15:09:34 -04:00
selinux-access.c core: simplify selinux AVC initialization 2015-11-30 20:26:03 +01:00
selinux-access.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
selinux-setup.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
selinux-setup.h mac: add mac_ prefix to distinguish origin security apis 2014-10-28 14:31:48 +01:00
service.c core: make the StartLimitXYZ= settings generic and apply to any kind of unit, not just services 2016-02-10 13:26:56 +01:00
service.h core: make the StartLimitXYZ= settings generic and apply to any kind of unit, not just services 2016-02-10 13:26:56 +01:00
show-status.c util-lib: split out allocation calls into alloc-util.[ch] 2015-10-27 13:45:53 +01:00
show-status.h util-lib: move status printing stuff into src/core/ 2015-10-27 13:25:56 +01:00
shutdown.c util-lib: split out allocation calls into alloc-util.[ch] 2015-10-27 13:45:53 +01:00
slice.c tree-wide: sort includes 2015-11-16 22:09:36 +01:00
slice.h Move all unit states to basic/ and extend systemctl --state=help 2015-09-28 15:09:34 -04:00
smack-setup.c smack: Handling network 2016-01-11 11:12:06 +01:00
smack-setup.h mac: add mac_ prefix to distinguish origin security apis 2014-10-28 14:31:48 +01:00
socket.c core: make the StartLimitXYZ= settings generic and apply to any kind of unit, not just services 2016-02-10 13:26:56 +01:00
socket.h core: make the StartLimitXYZ= settings generic and apply to any kind of unit, not just services 2016-02-10 13:26:56 +01:00
swap.c core: rework job_get_timeout() to use usec_t and handle USEC_INFINITY time events correctly 2016-02-04 00:35:43 +01:00
swap.h util-lib: split our string related calls from util.[ch] into its own file string-util.[ch] 2015-10-24 23:05:02 +02:00
system.conf core: enable TasksMax= for all services by default, and set it to 512 2015-11-16 11:57:48 +01:00
systemd.pc.in build-sys: move systemd.pc from pkgconfiglibdir back into pkgconfigdatadir 2015-04-21 20:35:17 +02:00
target.c core: remove support for RequiresOverridable= and RequisiteOverridable= 2015-11-12 19:27:24 +01:00
target.h Move all unit states to basic/ and extend systemctl --state=help 2015-09-28 15:09:34 -04:00
timer.c tree-wide: expose "p"-suffix unref calls in public APIs to make gcc cleanup easy 2015-11-27 19:19:36 +01:00
timer.h core: add new RandomSec= setting for time units 2015-11-18 17:07:11 +01:00
transaction.c core: when propagating reload jobs, downgrade them to try-reload 2016-01-28 18:51:42 +01:00
transaction.h tree-wide: sort includes in *.h 2015-11-18 23:09:02 +01:00
triggers.systemd.in Convert file trigger scripts to lua 2015-11-23 11:32:20 -05:00
umount.c tree-wide: group include of libudev.h with sd-* 2015-11-17 07:06:08 +01:00
umount.h
unit-printf.c core: simplify handling of %u, %U, %s and %h unit file specifiers 2015-11-12 17:57:04 +01:00
unit-printf.h specifier: rework specifier calls to return proper error message 2013-09-17 10:06:50 -05:00
unit.c core: make the StartLimitXYZ= settings generic and apply to any kind of unit, not just services 2016-02-10 13:26:56 +01:00
unit.h core: make the StartLimitXYZ= settings generic and apply to any kind of unit, not just services 2016-02-10 13:26:56 +01:00
user.conf core: Support system.conf.d and user.conf.d directories in the usual search paths 2014-11-29 13:55:31 -05:00