summaryrefslogtreecommitdiff
path: root/debian/patches/0700-init.patch
blob: be24a2a7bb9d5286597a55123835c5ca4027abb8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
Description: include lsb/init-functions
Author: Jörg Frings-Fürst <debian@jff-webhosting.net>
Last-Update: 2014-08-09
---
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
Index: trunk/scripts/ipmi_port.sh
===================================================================
--- trunk.orig/scripts/ipmi_port.sh
+++ trunk/scripts/ipmi_port.sh
@@ -14,8 +14,8 @@
 # Provides: ipmi_port
 # Required-Start: $local_fs $network $remote_fs
 # Required-Stop:  $local_fs $network $remote_fs
-# Default-Start: 3 4 5 3 4 5  
-# Default-Stop:  0 1 2 6  0 1 2 6   
+# Default-Start: 2 3 4 5
+# Default-Stop: 0 1 6
 # Short-Description: ipmi_port reserves the RMCP port from portmap
 # Description: ipmi_port is used to reserve the RMCP port from portmap
 ### END INIT INFO
@@ -29,7 +29,7 @@ name=ipmi_port
 progdir=/usr/sbin
 prog="$progdir/$name"
 lockfile=/var/lock/subsys/$name
-portmap=/etc/init.d/portmap
+portmap=/etc/init.d/rpcbind
 shardir=/usr/share
 mibdir=$shardir/snmp/mibs
 datadir=$shardir/ipmiutil
@@ -40,6 +40,8 @@ threshout=${vardir}/thresh_out.txt
 # This threshold script could be created by ipmiutil sensor -p ...
 thresh="${vardir}/thresholds.sh"
 
+. /lib/lsb/init-functions
+
 getpid () {
     # This is messy if the parent script is same name as $1
     p=`ps -ef |grep "$1" |grep -v grep |awk '{print $2}'`
@@ -184,4 +186,3 @@ case "$1" in
 esac
 
 exit $?
-
Index: trunk/scripts/ipmiutil_asy
===================================================================
--- trunk.orig/scripts/ipmiutil_asy
+++ trunk/scripts/ipmiutil_asy
@@ -13,8 +13,8 @@
 # Provides: ipmiutil_asy
 # Required-Start: $local_fs $remote_fs $syslog
 # Required-Stop: $local_fs $remote_fs $syslog
-# Default-Start: 3 4 5 3 4 5 
-# Default-Stop:  0 1 2 6  0 1 2 6 
+# Default-Start: 2 3 4 5
+# Default-Stop: 0 1 6
 # Short-Description: ipmiutil async bridge agent init script
 # Description: Init script starts ipmiutil async bridge agent for remote reset
 ### END INIT INFO
@@ -37,6 +37,8 @@ getpid () {
     echo $p
 }
 
+. /lib/lsb/init-functions
+
 start()
 {
 	echo -n "Starting $dname: "
@@ -152,4 +154,3 @@ case "$1" in
         exit 2
 esac
 exit $?
-
Index: trunk/scripts/ipmiutil_wdt
===================================================================
--- trunk.orig/scripts/ipmiutil_wdt
+++ trunk/scripts/ipmiutil_wdt
@@ -14,8 +14,8 @@
 # Provides: ipmiutil_wdt
 # Required-Start: $local_fs $remote_fs $syslog
 # Required-Stop: $local_fs $remote_fs $syslog
-# Default-Start: 3 4 5 3 4 5
-# Default-Stop:  0 1 2 6  0 1 2 6
+# Default-Start: 2 3 4 5
+# Default-Stop:  0 1 6
 # Short-Description: ipmiutil watchdog timer init script
 # Description: Init script to enable and reset ipmiutil watchdog timer via cron
 ### END INIT INFO
@@ -28,6 +28,8 @@ LOCKFILE=/var/lock/subsys/$name
 wdtlog=/var/log/$name
 wdtsec=150  # default 150 seconds for watchdog timeout (2*60 + 30)
 
+. /lib/lsb/init-functions
+
 start() {
 	echo -n "Starting $prog: "
 	echo
@@ -123,10 +125,13 @@ case "$1" in
   restart)
   	restart
 	;;
+  force-reload)
+	restart
+        ;;
   reload)
   	restart
 	;;
   *)
-	echo "Usage: $0 {start|stop|status|restart|reload}"
+	echo "Usage: $0 {start|stop|status|restart|force-reload|reload}"
 	exit 1
 esac
Index: trunk/scripts/ipmiutil_evt
===================================================================
--- trunk.orig/scripts/ipmiutil_evt
+++ trunk/scripts/ipmiutil_evt
@@ -15,8 +15,8 @@
 # Provides: ipmiutil_evt
 # Required-Start: $local_fs $remote_fs $syslog
 # Required-Stop: $local_fs $remote_fs $syslog
-# Default-Start: 3 4 5 3 4 5 
-# Default-Stop:  0 1 2 6  0 1 2 6 
+# Default-Start: 2 3 4 5
+# Default-Stop:  0 1 6
 # Short-Description: ipmiutil event monitoring init script
 # Description: Init script starts ipmiutil event monitoring service
 ### END INIT INFO
@@ -40,6 +40,8 @@ getpid () {
     echo $p
 }
 
+. /lib/lsb/init-functions
+
 start()
 {
 	echo -n "Starting $name: "
@@ -155,4 +157,3 @@ case "$1" in
         exit 2
 esac
 exit $?
-
Index: trunk/scripts/ipmi_info
===================================================================
--- trunk.orig/scripts/ipmi_info
+++ trunk/scripts/ipmi_info
@@ -11,8 +11,8 @@
 # Provides: ipmi_info
 # Required-Start: $local_fs $network $remote_fs
 # Required-Stop:  $local_fs $network $remote_fs
-# Default-Start:  
-# Default-Stop:   
+# Default-Start: 2 3 4 5
+# Default-Stop: 0 1 6
 # Short-Description: ipmi_info saves OS info to the IPMI system info
 # Description: ipmi_info saves OS info to the IPMI system info
 ### END INIT INFO
@@ -21,6 +21,8 @@ name=ipmi_info
 iuprog=/usr/bin/ipmiutil
 tmp=/tmp/ipmi_info.tmp
 
+. /lib/lsb/init-functions
+
 getosver() {
    if [ -f /etc/os-release ]; then
       . /etc/os-release
@@ -121,4 +123,3 @@ case "$1" in
 esac
 
 exit $?
-
Index: trunk/scripts/ipmiutil_asy.service
===================================================================
--- trunk.orig/scripts/ipmiutil_asy.service
+++ trunk/scripts/ipmiutil_asy.service
@@ -11,4 +11,3 @@ ExecStart=/usr/bin/ipmiutil getevt -a -b
 
 [Install]
 WantedBy=multi-user.target
-
Index: trunk/scripts/ipmiutil_evt.service
===================================================================
--- trunk.orig/scripts/ipmiutil_evt.service
+++ trunk/scripts/ipmiutil_evt.service
@@ -11,5 +11,3 @@ ExecStart=/usr/bin/ipmiutil getevt $IPMI
 
 [Install]
 WantedBy=multi-user.target
-
-
Index: trunk/scripts/ipmiutil_wdt.service
===================================================================
--- trunk.orig/scripts/ipmiutil_wdt.service
+++ trunk/scripts/ipmiutil_wdt.service
@@ -10,5 +10,3 @@ RemainAfterExit=1
 
 [Install]
 WantedBy=multi-user.target
-
-
Index: trunk/scripts/ipmi_port.service
===================================================================
--- trunk.orig/scripts/ipmi_port.service
+++ trunk/scripts/ipmi_port.service
@@ -11,5 +11,3 @@ ExecStart=-/usr/sbin/ipmi_port -b
 
 [Install]
 WantedBy=multi-user.target
-
-
Index: trunk/configure.ac
===================================================================
--- trunk.orig/configure.ac
+++ trunk/configure.ac
@@ -399,11 +399,11 @@ else
 		MD2_CFLAGS="-DSKIP_MD2"
 		init0=/etc/rc.d/init.d
         fi
-	if test $isredhat -eq 0 ; then
+#	if test $isredhat -eq 0 ; then
 	   # set default start/stop for init scripts
-           sed -i 's/# Default-Start:/# Default-Start: 3 4 5/' $init_scripts
-	   sed -i 's/# Default-Stop:/# Default-Stop:  0 1 2 6/' $init_scripts
-	fi
+#           sed -i 's/# Default-Start:/# Default-Start: 3 4 5/' $init_scripts
+#	   sed -i 's/# Default-Stop:/# Default-Stop:  0 1 2 6/' $init_scripts
+#	fi
     # The openssl rpm might not be installed
     which rpm >/dev/null 2>&1
 	if test $? -eq 0 ; then