summaryrefslogtreecommitdiff
path: root/units/emergency.service.in
Commit message (Collapse)AuthorAgeFilesLines
* meson: use jinja2 for unit templatesZbigniew Jędrzejewski-Szmek2021-05-191-2/+2
| | | | | | | | | We don't need two (and half) templating systems anymore, yay! I'm keeping the changes minimal, to make the diff manageable. Some enhancements due to a better templating system might be possible in the future. For handling of '## ' — see the next commit.
* license: LGPL-2.1+ -> LGPL-2.1-or-laterYu Watanabe2020-11-091-1/+1
|
* units: use correct path to refer to plymouthLennart Poettering2020-04-161-1/+1
| | | | | | | | | This doesn't really matter, since in non-/usr-merged systems plymouth needs to be in /bin and on merged ones it doesn't matter, but it is still prettier to insert the right path, and avoid /bin on merged systems, since it's just a compat symlink. Replaces: #15351
* Add SPDX license headers to unit filesZbigniew Jędrzejewski-Szmek2017-11-191-0/+2
|
* units: add missing ordering deps for Conflicts= of emergency.serviceAlan Jenkins2017-09-291-0/+1
| | | | | | | | | | | 1. If we exited emergency mode immediately, we don't want to have an irreversible stop job still running for syslog.socket. I _suspect_ that can't happen, but let's not waste effort working out exactly why it's impossible and not just very improbable. 2. Similarly, it seems undesirable to have rescue.service and emergency.service both running with an open FD of /dev/console, for however short a period.
* units: express Conflict in syslog.socket instead of emergency.serviceAlan Jenkins2017-09-291-1/+0
| | | | | | | | | | | | | | | | | | | | Note this commit only changes how the code is expressed; it does not change the existence of any dependency. The `Conflicts=` was added in 3136ec90, "Stop syslog.socket when entering emergency mode". The discussion in the issue #266 raised concerns that this might be needed for other units, but failed to point out why syslog.socket is special. The reason is that syslog.socket has DefaultDepedencies=no, so it does not get Requires=sysinit.target like other socket units do. But syslog.service does require sysinit.target, among other things. We don't have many socket, path, or timer units with DefaultDependencies=no, and I don't think any of the triggered services have such additional hard dependencies as syslog.service does. It is much less confusing if we keep this `Conflicts=` in the same file as the `DefaultDependencies=no` which made it necessary.
* sulogin-shell: switch from shell implementation to a C implementation (#6698)Felipe Sateler2017-09-081-0/+1
|
* units: simplify rescue.service and emergency.service (#5623)Michael Biebl2017-03-221-3/+1
| | | | | | | The emergency.service and rescue.service units have become rather convoluted. We spawn multiple shells and the help text spans multiple lines which makes the units hard to read. Move the logic into a single shell script and call that via ExecStart.
* units: do not throw a warning in emergency mode if plymouth is not installed ↵Daniel Molkentin2017-03-171-1/+1
| | | | | | | (#5528) Ideally, plymouth should only be referenced via dependencies, not ExecStartPre's. This at least avoids the confusing error message on minimal installations that do not carry plymouth.
* emergency.service: Don't say "Welcome" when it's an emergency (#3569)Lennart Poettering2016-06-211-1/+1
| | | | | | | | | | | Quoting @cgwalters: Just uploading this as an RFC. Now I know reading the code that systemd says `Welcome to $OS` as a generic thing, but my initial impression on seeing this was that it was almost sarcastic =) Let's say "You are in emergency mode" as a more neutral/less excited phrase. This patch is based on #3556, but makes the same change for rescue mode.
* Stop syslog.socket when entering emergency mode (#3130)Martin Pitt2016-04-271-0/+1
| | | | | | | | | | | | | | | When enabling ForwardToSyslog=yes, the syslog.socket is active when entering emergency mode. Any log message then triggers the start of rsyslog.service (or other implementation) along with its dependencies such as local-fs.target and sysinit.target. As these might fail themselves (e. g. faulty /etc/fstab), this breaks the emergency mode. This causes syslog.socket to fail with "Failed to queue service startup job: Transition is destructive". Add Conflicts=syslog.socket to emergency.service to make sure the socket is stopped when emergency.service is started. Fixes #266
* units: don't fail if /root doesn't exist for shell unitsLennart Poettering2016-01-171-1/+1
| | | | | | As discussed on the ML: http://lists.freedesktop.org/archives/systemd-devel/2016-January/035594.html
* units: emergency.service: wait for plymouth to shut downMartin Pitt2015-07-101-1/+1
| | | | | | | | | Merely calling "plymouth quit" isn't sufficient, as plymouth needs some time to shut down. This needs plymouth --wait (which is a no-op when it's not running). Fixes invisible emergency shell with plymouth running endlessly. https://launchpad.net/bugs/1471258
* Use "new" --job-mode= option in more placesZbigniew Jędrzejewski-Szmek2015-05-181-1/+1
| | | | | | --irreversible/--ignore-dependencies/--fail are deprececated since 4dc5b821ae737914499119e29811fc3346e3d97c. Also add shell completions for --jobs-mode.
* build-sys: lookup for sulogin, it might not be in /sbinCristian Rodríguez2015-01-231-1/+1
|
* units: update rescue.service and emergency.serviceZbigniew Jędrzejewski-Szmek2014-08-311-1/+1
| | | | | ^D works in emergency.service too. One needs to log in when in rescue mode too.
* units: make emergency.service conflict with rescue.serviceZbigniew Jędrzejewski-Szmek2014-08-301-0/+1
| | | | | | | | They both use StandardInput=tty-force so they cannot be run concurrently. https://bugs.freedesktop.org/show_bug.cgi?id=82778 https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=757072
* units: make ExecStopPost action part of ExecStartMichal Sekletar2014-07-091-2/+1
| | | | | | | | | | | | | | | Currently after exiting rescue shell we isolate default target. User might want to isolate to some other target than default one. However issuing systemctl isolate command to desired target would bring system to default target as a consequence of running ExecStopPost action. Having common ancestor for rescue shell and possible followup systemctl default command should fix this. If user exits rescue shell we will proceed with isolating default target, otherwise, on manual isolate, parent shell process is terminated and we don't isolate default target, but target chosen by user. Suggested-by: Michal Schmidt <mschmidt@redhat.com>
* core: optionally send SIGHUP in addition to the configured kill signalLennart Poettering2013-07-301-4/+1
| | | | This is useful to fake session ends for processes like shells.
* journal: recommend journalctl -x more oftenLennart Poettering2012-11-161-1/+1
|
* units: reword rescue mode hintsZbigniew Jędrzejewski-Szmek2012-10-281-1/+1
| | | | | | | | Do not suggest to the user that commands can be issued before logging in. sulogin prints it own message, which mentions ^D, so there's no need to repeat it here.
* units: also add journalctl suggestion to emergency.serviceLennart Poettering2012-10-231-1/+1
| | | | | More often than not we enter emergency.service due to fsck failure, so it makes sense to direct people to the journal to debug those.
* man: add Documentation= tags to all kinds of missing unitsLennart Poettering2012-06-271-0/+1
|
* units: introduce new Documentation= field and make use of it everywhereLennart Poettering2012-05-211-2/+0
| | | | | | | | | | This should help making the boot process a bit easier to explore and understand for the administrator. The simple idea is that "systemctl status" now shows a link to documentation alongside the other status and decriptionary information of a service. This patch adds the necessary fields to all our shipped units if we have proper documentation for them.
* service: introduce Type=idle and use it for gettysLennart Poettering2012-04-241-0/+1
| | | | | | | | | | | | | Type=idle is much like Type=simple, however between the fork() and the exec() in the child we wait until PID 1 informs us that no jobs are left. This is mostly a cosmetic fix to make gettys appear only after all boot output is finished and complete. Note that this does not impact the normal job logic as we do not delay the completion of any jobs. We just delay the invocation of the actual binary, and only for services that otherwise would be of Type=simple.
* relicense to LGPLv2.1 (with exceptions)Lennart Poettering2012-04-121-2/+2
| | | | | | | | | | | | | | We finally got the OK from all contributors with non-trivial commits to relicense systemd from GPL2+ to LGPL2.1+. Some udev bits continue to be GPL2+ for now, but we are looking into relicensing them too, to allow free copy/paste of all code within systemd. The bits that used to be MIT continue to be MIT. The big benefit of the relicensing is that closed source code may now link against libsystemd-login.so and friends.
* units/: use @SYSTEMCTL@ instead of hardcoded pathsDave Reisner2012-04-041-0/+31
Especially in the case of --enable-split-usr, several units will point to the wrong location for systemctl. Use @SYSTEMCTL@ which will always contain the proper path.