forked from pool/systemd
8f6010ffdf
- Change patch 0001-add-hdflush-for-reboot-or-hddown-for-poweroff.patch to skip already by the kernel managed devices - fix timeout stopping user@.service (bnc#841544) * 0001-core-introduce-new-KillMode-mixed-which-sends-SIGTER.patch * 0002-service-allow-KillMode-mixed-in-conjunction-with-PAM.patch * 0003-core-make-sure-to-always-go-through-both-SIGTERM-and.patch - Add patch 0001-upstream-systemctl-halt-reboot-error-handling.patch to be able to detect if the sysctl reboot() returns. - Add patch 0001-add-hdflush-for-reboot-or-hddown-for-poweroff.patch A check for unmaintained disk like devices is added to be able to flush and maybe shut them down. Also the missing sync() system call is added for the direct halt/reboot systemctl command. Then the system halt is used as fallback if poweroff fails for both the direct poweroff systemctl command as well as for the systemd-shutdown utility. - Make systemd-mini build - Make requires bash-completion a recommends - Add patch 1017-skip-native-unit-handling-if-sysv-already-handled.patch to avoid that enabled boot scripts will be handled as unit files by systemctl status command (bnc#818044) - Drop patch 1017-enforce-sufficient-shutdown-warnings.patch as the original code behaves exactly as the shutdown code of the old SysVinit (bnc#750845) - Rename support-powerfail-with-powerstatus.patch to OBS-URL: https://build.opensuse.org/request/show/215598 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd?expand=0&rev=173
91 lines
2.8 KiB
Diff
91 lines
2.8 KiB
Diff
--- systemd-208/units/sigpwr.target
|
|
+++ systemd-208/units/sigpwr.target 2014-01-14 15:53:32.878735762 +0000
|
|
@@ -8,3 +8,5 @@
|
|
[Unit]
|
|
Description=Power Failure
|
|
Documentation=man:systemd.special(7)
|
|
+BindsTo=powerfail.service
|
|
+DefaultDependencies=no
|
|
+RefuseManualStart=yes
|
|
--- systemd-208/units/powerfail.service
|
|
+++ systemd-208/units/powerfail.service 2014-01-14 16:11:41.802235712 +0000
|
|
@@ -0,0 +1,21 @@
|
|
+# This file is part of systemd.
|
|
+#
|
|
+# Copyright (c) 2014 SUSE LINUX Products GmbH, Germany.
|
|
+# Author: Werner Fink
|
|
+# Please send feedback to http://www.suse.de/feedback
|
|
+#
|
|
+# Description:
|
|
+#
|
|
+# Used to start the systemd-powerfail.service
|
|
+#
|
|
+
|
|
+[Unit]
|
|
+Description=powerfail handling
|
|
+BindsTo=sigpwr.target
|
|
+DefaultDependencies=no
|
|
+RefuseManualStart=yes
|
|
+
|
|
+[Service]
|
|
+Type=oneshot
|
|
+ExecStart=/usr/lib/systemd/systemd-powerfail
|
|
+RemainAfterExit=false
|
|
--- systemd-208/man/systemd-powerfail.service.8
|
|
+++ systemd-208/man/systemd-powerfail.service.8 2014-01-14 18:22:21.286735810 +0000
|
|
@@ -0,0 +1,54 @@
|
|
+'\" t
|
|
+.TH "SYSTEMD\-POWERFAIL\&.SERVICE" "8" "" "systemd 208" "systemd-powerfail.service"
|
|
+.\" -----------------------------------------------------------------
|
|
+.\" * Define some portability stuff
|
|
+.\" -----------------------------------------------------------------
|
|
+.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
+.\" http://bugs.debian.org/507673
|
|
+.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
|
|
+.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
+.ie \n(.g .ds Aq \(aq
|
|
+.el .ds Aq '
|
|
+.\" -----------------------------------------------------------------
|
|
+.\" * set default formatting
|
|
+.\" -----------------------------------------------------------------
|
|
+.\" disable hyphenation
|
|
+.nh
|
|
+.\" disable justification (adjust text to left margin only)
|
|
+.ad l
|
|
+.\" -----------------------------------------------------------------
|
|
+.\" * MAIN CONTENT STARTS HERE *
|
|
+.\" -----------------------------------------------------------------
|
|
+.SH "NAME"
|
|
+systemd-powerfail.service, systemd-powerfail \- Power Fail signal handling
|
|
+.SH "SYNOPSIS"
|
|
+.PP
|
|
+systemd\-powerfail\&.service
|
|
+.PP
|
|
+/usr/lib/systemd/systemd\-powerfail
|
|
+.SH "DESCRIPTION"
|
|
+.PP
|
|
+systemd\-powerfail
|
|
+is a system service that is used to evaulate the content of
|
|
+\fI/var/run/powerstatus\fR. Based on the content of this
|
|
+file:
|
|
+.IP F(AIL)
|
|
+Power is failing, UPS is providing the power. The
|
|
+systemd\-powerfail
|
|
+is now doing a timed shutdown.
|
|
+.IP O(K)
|
|
+The power has been restored, and pending shutdown
|
|
+will be cancled.
|
|
+.IP L(OW)
|
|
+The power is failing and the UPS has a low battery.
|
|
+The
|
|
+systemd\-powerfail
|
|
+is doing an immediate shutdown.
|
|
+.PP
|
|
+If \fI/var/run/powerstatus\fR doesn't exist or contains anything else then the letters
|
|
+F, O or L, systemd\-powerfail will behave as if it has read the letter F.
|
|
+.PP
|
|
+.SH "SEE ALSO"
|
|
+.PP
|
|
+\fBshutdown\fR(8),
|
|
+\fBpowerd\fR(8)
|