Fixed starting ipmievd under systemd

Resolves: #819234
This commit is contained in:
Jan Safranek 2012-08-27 13:14:34 +02:00
parent a79bc68acb
commit 0c0696b0d3
3 changed files with 21 additions and 2 deletions

View File

@ -7,7 +7,7 @@ After=ipmi.service
EnvironmentFile=-/etc/sysconfig/ipmievd
ExecStart=/usr/sbin/ipmievd $IPMIEVD_OPTIONS
Type=forking
PIDFile=/var/run/ipmievd.pid0
PIDFile=/var/run/ipmievd.pid
[Install]
WantedBy=multi-user.target

View File

@ -0,0 +1,14 @@
diff -up ipmitool-1.8.12/lib/helper.c.systemd ipmitool-1.8.12/lib/helper.c
--- ipmitool-1.8.12/lib/helper.c.systemd 2012-08-13 14:24:47.391037471 +0200
+++ ipmitool-1.8.12/lib/helper.c 2012-08-13 14:24:53.088016793 +0200
@@ -549,10 +549,6 @@ ipmi_start_daemon(struct ipmi_intf *intf
sigset_t sighup;
#endif
- /* if we are started from init no need to become daemon */
- if (getppid() == 1)
- return;
-
#ifdef SIGHUP
sigemptyset(&sighup);
sigaddset(&sighup, SIGHUP);

View File

@ -1,7 +1,7 @@
Name: ipmitool
Summary: Utility for IPMI control
Version: 1.8.12
Release: 1%{?dist}
Release: 2%{?dist}
License: BSD
Group: System Environment/Base
URL: http://ipmitool.sourceforge.net/
@ -20,6 +20,7 @@ Provides: OpenIPMI-tools = 2.0.14-3
Patch1: ipmitool-1.8.10-ipmievd-init.patch
Patch2: ipmitool-1.8.10-ipmievd-condrestart.patch
Patch3: ipmitool-1.8.11-remove-umask0.patch
Patch4: ipmitool-1.8.11-systemd.patch
%description
This package contains a utility for interfacing with devices that support
@ -42,6 +43,7 @@ setting LAN configuration, and chassis power control.
%patch1 -p1 -b .ipmievd-init
%patch2 -p0 -b .condrestart
%patch3 -p1 -b .umask
%patch4 -p1 -b .systemd
for f in AUTHORS ChangeLog; do
iconv -f iso-8859-1 -t utf8 < ${f} > ${f}.utf8
@ -103,6 +105,9 @@ fi
%changelog
* Mon Aug 27 2012 Jan Safranek <jsafrane@redhat.com> - 1.8.12-2
- Fixed starting ipmievd under systemd (#819234).
* Fri Aug 10 2012 Jan Safranek <jsafrane@redhat.com> - 1.8.12-1
- update to ipmitool-1.8.12