1 |
dev-zero 08/04/19 20:37:13 |
2 |
|
3 |
Modified: postgresql-8.3-server.patch postgresql.init-8.0 |
4 |
postgresql.init-8.1 postgresql.init-8.2 |
5 |
postgresql.init-8.3 postgresql.init-7.4 |
6 |
postgresql.init-7.3 |
7 |
Log: |
8 |
Updated patch for 8.3 (accidentally disabled tsearch2, thanks to Elvis Pranskevichus). Corrected a bug in init.d scripts. |
9 |
(Portage version: 2.1.5_rc4) |
10 |
|
11 |
Revision Changes Path |
12 |
1.2 dev-db/postgresql-server/files/postgresql-8.3-server.patch |
13 |
|
14 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql-8.3-server.patch?rev=1.2&view=markup |
15 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql-8.3-server.patch?rev=1.2&content-type=text/plain |
16 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql-8.3-server.patch?r1=1.1&r2=1.2 |
17 |
|
18 |
Index: postgresql-8.3-server.patch |
19 |
=================================================================== |
20 |
RCS file: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql-8.3-server.patch,v |
21 |
retrieving revision 1.1 |
22 |
retrieving revision 1.2 |
23 |
diff -u -r1.1 -r1.2 |
24 |
--- postgresql-8.3-server.patch 15 Apr 2008 09:29:54 -0000 1.1 |
25 |
+++ postgresql-8.3-server.patch 19 Apr 2008 20:37:13 -0000 1.2 |
26 |
@@ -26,7 +26,7 @@ |
27 |
================================================================== |
28 |
--- contrib/Makefile (revision 12) |
29 |
+++ contrib/Makefile (local) |
30 |
-@@ -20,22 +20,18 @@ |
31 |
+@@ -20,22 +20,19 @@ |
32 |
isn \ |
33 |
lo \ |
34 |
ltree \ |
35 |
@@ -44,7 +44,7 @@ |
36 |
spi \ |
37 |
tablefunc \ |
38 |
- test_parser \ |
39 |
-- tsearch2 \ |
40 |
+ tsearch2 \ |
41 |
- vacuumlo |
42 |
+ test_parser |
43 |
|
44 |
|
45 |
|
46 |
|
47 |
1.2 dev-db/postgresql-server/files/postgresql.init-8.0 |
48 |
|
49 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.0?rev=1.2&view=markup |
50 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.0?rev=1.2&content-type=text/plain |
51 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.0?r1=1.1&r2=1.2 |
52 |
|
53 |
Index: postgresql.init-8.0 |
54 |
=================================================================== |
55 |
RCS file: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.0,v |
56 |
retrieving revision 1.1 |
57 |
retrieving revision 1.2 |
58 |
diff -u -r1.1 -r1.2 |
59 |
--- postgresql.init-8.0 15 Apr 2008 09:29:55 -0000 1.1 |
60 |
+++ postgresql.init-8.0 19 Apr 2008 20:37:13 -0000 1.2 |
61 |
@@ -1,7 +1,7 @@ |
62 |
#!/sbin/runscript |
63 |
# Copyright 1999-2008 Gentoo Foundation |
64 |
# Distributed under the terms of the GNU General Public License v2 |
65 |
-# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.0,v 1.1 2008/04/15 09:29:55 dev-zero Exp $ |
66 |
+# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.0,v 1.2 2008/04/19 20:37:13 dev-zero Exp $ |
67 |
|
68 |
opts="${opts} reload" |
69 |
|
70 |
@@ -40,20 +40,25 @@ |
71 |
stop() { |
72 |
ebegin "Stopping PostgreSQL (this can take up to $(( ${WAIT_FOR_DISCONNECT} + ${WAIT_FOR_CLEANUP} )) seconds)" |
73 |
|
74 |
+ local retval |
75 |
+ |
76 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
77 |
--retry -TERM/${WAIT_FOR_DISCONNECT} |
78 |
- [ $? -eq 0 ] && eend $? && exit |
79 |
+ retval=$? |
80 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
81 |
|
82 |
ewarn "Some clients did not disconnect within ${WAIT_FOR_DISCONNECT} seconds." |
83 |
ewarn "Going to shutdown the server anyway." |
84 |
|
85 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
86 |
--retry -INT/${WAIT_FOR_CLEANUP} |
87 |
- [ $? -eq 0 ] && eend $? && exit |
88 |
+ retval=$? |
89 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
90 |
|
91 |
if [ ${WAIT_FOR_QUIT} -eq 0 ] ; then |
92 |
eerror "Server did not shut down and sending the SIGQUIT has been disabled." |
93 |
- eend $? |
94 |
+ eend $retval |
95 |
+ return $retval |
96 |
fi |
97 |
|
98 |
ewarn "Shutting down the server gracefully failed." |
99 |
@@ -61,8 +66,8 @@ |
100 |
|
101 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
102 |
--retry -QUIT/${WAIT_FOR_QUIT} |
103 |
- |
104 |
- [ $? -eq 0 ] && eend $? && exit |
105 |
+ retval=$? |
106 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
107 |
|
108 |
eerror "Forced shutdown failed!!! Something is wrong with your system, please take care of it manually." |
109 |
eend $? |
110 |
|
111 |
|
112 |
|
113 |
1.2 dev-db/postgresql-server/files/postgresql.init-8.1 |
114 |
|
115 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.1?rev=1.2&view=markup |
116 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.1?rev=1.2&content-type=text/plain |
117 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.1?r1=1.1&r2=1.2 |
118 |
|
119 |
Index: postgresql.init-8.1 |
120 |
=================================================================== |
121 |
RCS file: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.1,v |
122 |
retrieving revision 1.1 |
123 |
retrieving revision 1.2 |
124 |
diff -u -r1.1 -r1.2 |
125 |
--- postgresql.init-8.1 15 Apr 2008 09:29:55 -0000 1.1 |
126 |
+++ postgresql.init-8.1 19 Apr 2008 20:37:13 -0000 1.2 |
127 |
@@ -1,7 +1,7 @@ |
128 |
#!/sbin/runscript |
129 |
# Copyright 1999-2008 Gentoo Foundation |
130 |
# Distributed under the terms of the GNU General Public License v2 |
131 |
-# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.1,v 1.1 2008/04/15 09:29:55 dev-zero Exp $ |
132 |
+# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.1,v 1.2 2008/04/19 20:37:13 dev-zero Exp $ |
133 |
|
134 |
opts="${opts} reload" |
135 |
|
136 |
@@ -40,20 +40,25 @@ |
137 |
stop() { |
138 |
ebegin "Stopping PostgreSQL (this can take up to $(( ${WAIT_FOR_DISCONNECT} + ${WAIT_FOR_CLEANUP} )) seconds)" |
139 |
|
140 |
+ local retval |
141 |
+ |
142 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
143 |
--retry -TERM/${WAIT_FOR_DISCONNECT} |
144 |
- [ $? -eq 0 ] && eend $? && exit |
145 |
+ retval=$? |
146 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
147 |
|
148 |
ewarn "Some clients did not disconnect within ${WAIT_FOR_DISCONNECT} seconds." |
149 |
ewarn "Going to shutdown the server anyway." |
150 |
|
151 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
152 |
--retry -INT/${WAIT_FOR_CLEANUP} |
153 |
- [ $? -eq 0 ] && eend $? && exit |
154 |
+ retval=$? |
155 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
156 |
|
157 |
if [ ${WAIT_FOR_QUIT} -eq 0 ] ; then |
158 |
eerror "Server did not shut down and sending the SIGQUIT has been disabled." |
159 |
- eend $? |
160 |
+ eend $retval |
161 |
+ return $retval |
162 |
fi |
163 |
|
164 |
ewarn "Shutting down the server gracefully failed." |
165 |
@@ -61,8 +66,8 @@ |
166 |
|
167 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
168 |
--retry -QUIT/${WAIT_FOR_QUIT} |
169 |
- |
170 |
- [ $? -eq 0 ] && eend $? && exit |
171 |
+ retval=$? |
172 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
173 |
|
174 |
eerror "Forced shutdown failed!!! Something is wrong with your system, please take care of it manually." |
175 |
eend $? |
176 |
|
177 |
|
178 |
|
179 |
1.2 dev-db/postgresql-server/files/postgresql.init-8.2 |
180 |
|
181 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.2?rev=1.2&view=markup |
182 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.2?rev=1.2&content-type=text/plain |
183 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.2?r1=1.1&r2=1.2 |
184 |
|
185 |
Index: postgresql.init-8.2 |
186 |
=================================================================== |
187 |
RCS file: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.2,v |
188 |
retrieving revision 1.1 |
189 |
retrieving revision 1.2 |
190 |
diff -u -r1.1 -r1.2 |
191 |
--- postgresql.init-8.2 15 Apr 2008 09:29:55 -0000 1.1 |
192 |
+++ postgresql.init-8.2 19 Apr 2008 20:37:13 -0000 1.2 |
193 |
@@ -1,7 +1,7 @@ |
194 |
#!/sbin/runscript |
195 |
# Copyright 1999-2008 Gentoo Foundation |
196 |
# Distributed under the terms of the GNU General Public License v2 |
197 |
-# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.2,v 1.1 2008/04/15 09:29:55 dev-zero Exp $ |
198 |
+# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.2,v 1.2 2008/04/19 20:37:13 dev-zero Exp $ |
199 |
|
200 |
opts="${opts} reload" |
201 |
|
202 |
@@ -40,20 +40,25 @@ |
203 |
stop() { |
204 |
ebegin "Stopping PostgreSQL (this can take up to $(( ${WAIT_FOR_DISCONNECT} + ${WAIT_FOR_CLEANUP} )) seconds)" |
205 |
|
206 |
+ local retval |
207 |
+ |
208 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
209 |
--retry -TERM/${WAIT_FOR_DISCONNECT} |
210 |
- [ $? -eq 0 ] && eend $? && exit |
211 |
+ retval=$? |
212 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
213 |
|
214 |
ewarn "Some clients did not disconnect within ${WAIT_FOR_DISCONNECT} seconds." |
215 |
ewarn "Going to shutdown the server anyway." |
216 |
|
217 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
218 |
--retry -INT/${WAIT_FOR_CLEANUP} |
219 |
- [ $? -eq 0 ] && eend $? && exit |
220 |
+ retval=$? |
221 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
222 |
|
223 |
if [ ${WAIT_FOR_QUIT} -eq 0 ] ; then |
224 |
eerror "Server did not shut down and sending the SIGQUIT has been disabled." |
225 |
- eend $? |
226 |
+ eend $retval |
227 |
+ return $retval |
228 |
fi |
229 |
|
230 |
ewarn "Shutting down the server gracefully failed." |
231 |
@@ -61,8 +66,8 @@ |
232 |
|
233 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
234 |
--retry -QUIT/${WAIT_FOR_QUIT} |
235 |
- |
236 |
- [ $? -eq 0 ] && eend $? && exit |
237 |
+ retval=$? |
238 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
239 |
|
240 |
eerror "Forced shutdown failed!!! Something is wrong with your system, please take care of it manually." |
241 |
eend $? |
242 |
|
243 |
|
244 |
|
245 |
1.2 dev-db/postgresql-server/files/postgresql.init-8.3 |
246 |
|
247 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.3?rev=1.2&view=markup |
248 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.3?rev=1.2&content-type=text/plain |
249 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.3?r1=1.1&r2=1.2 |
250 |
|
251 |
Index: postgresql.init-8.3 |
252 |
=================================================================== |
253 |
RCS file: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.3,v |
254 |
retrieving revision 1.1 |
255 |
retrieving revision 1.2 |
256 |
diff -u -r1.1 -r1.2 |
257 |
--- postgresql.init-8.3 15 Apr 2008 09:29:55 -0000 1.1 |
258 |
+++ postgresql.init-8.3 19 Apr 2008 20:37:13 -0000 1.2 |
259 |
@@ -1,7 +1,7 @@ |
260 |
#!/sbin/runscript |
261 |
# Copyright 1999-2008 Gentoo Foundation |
262 |
# Distributed under the terms of the GNU General Public License v2 |
263 |
-# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.3,v 1.1 2008/04/15 09:29:55 dev-zero Exp $ |
264 |
+# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-8.3,v 1.2 2008/04/19 20:37:13 dev-zero Exp $ |
265 |
|
266 |
opts="${opts} reload" |
267 |
|
268 |
@@ -40,20 +40,25 @@ |
269 |
stop() { |
270 |
ebegin "Stopping PostgreSQL (this can take up to $(( ${WAIT_FOR_DISCONNECT} + ${WAIT_FOR_CLEANUP} )) seconds)" |
271 |
|
272 |
+ local retval |
273 |
+ |
274 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
275 |
--retry -TERM/${WAIT_FOR_DISCONNECT} |
276 |
- [ $? -eq 0 ] && eend $? && exit |
277 |
+ retval=$? |
278 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
279 |
|
280 |
ewarn "Some clients did not disconnect within ${WAIT_FOR_DISCONNECT} seconds." |
281 |
ewarn "Going to shutdown the server anyway." |
282 |
|
283 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
284 |
--retry -INT/${WAIT_FOR_CLEANUP} |
285 |
- [ $? -eq 0 ] && eend $? && exit |
286 |
+ retval=$? |
287 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
288 |
|
289 |
if [ ${WAIT_FOR_QUIT} -eq 0 ] ; then |
290 |
eerror "Server did not shut down and sending the SIGQUIT has been disabled." |
291 |
- eend $? |
292 |
+ eend $retval |
293 |
+ return $retval |
294 |
fi |
295 |
|
296 |
ewarn "Shutting down the server gracefully failed." |
297 |
@@ -61,8 +66,8 @@ |
298 |
|
299 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
300 |
--retry -QUIT/${WAIT_FOR_QUIT} |
301 |
- |
302 |
- [ $? -eq 0 ] && eend $? && exit |
303 |
+ retval=$? |
304 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
305 |
|
306 |
eerror "Forced shutdown failed!!! Something is wrong with your system, please take care of it manually." |
307 |
eend $? |
308 |
|
309 |
|
310 |
|
311 |
1.2 dev-db/postgresql-server/files/postgresql.init-7.4 |
312 |
|
313 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-7.4?rev=1.2&view=markup |
314 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-7.4?rev=1.2&content-type=text/plain |
315 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-7.4?r1=1.1&r2=1.2 |
316 |
|
317 |
Index: postgresql.init-7.4 |
318 |
=================================================================== |
319 |
RCS file: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-7.4,v |
320 |
retrieving revision 1.1 |
321 |
retrieving revision 1.2 |
322 |
diff -u -r1.1 -r1.2 |
323 |
--- postgresql.init-7.4 15 Apr 2008 09:29:55 -0000 1.1 |
324 |
+++ postgresql.init-7.4 19 Apr 2008 20:37:13 -0000 1.2 |
325 |
@@ -1,7 +1,7 @@ |
326 |
#!/sbin/runscript |
327 |
# Copyright 1999-2008 Gentoo Foundation |
328 |
# Distributed under the terms of the GNU General Public License v2 |
329 |
-# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-7.4,v 1.1 2008/04/15 09:29:55 dev-zero Exp $ |
330 |
+# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-7.4,v 1.2 2008/04/19 20:37:13 dev-zero Exp $ |
331 |
|
332 |
opts="${opts} reload" |
333 |
|
334 |
@@ -25,6 +25,8 @@ |
335 |
start() { |
336 |
checkconfig || return 1 |
337 |
|
338 |
+ local retval |
339 |
+ |
340 |
ebegin "Starting PostgreSQL" |
341 |
|
342 |
if [ -f "$PGDATA/postmaster.pid" ] ; then |
343 |
@@ -33,27 +35,33 @@ |
344 |
|
345 |
su -l ${PGUSER} \ |
346 |
-c "env PGDATA=\"${PGDATA}\" /usr/lib/postgresql-7.4/bin/pg_ctl start -w -o '--silent-mode=true ${PGOPTS}'" |
347 |
- |
348 |
- eend $? |
349 |
+ retval=$? |
350 |
+ echo $retval |
351 |
+ eend $retval |
352 |
} |
353 |
|
354 |
stop() { |
355 |
ebegin "Stopping PostgreSQL (this can take up to $(( ${WAIT_FOR_DISCONNECT} + ${WAIT_FOR_CLEANUP} )) seconds)" |
356 |
|
357 |
+ local retval |
358 |
+ |
359 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
360 |
--retry -TERM/${WAIT_FOR_DISCONNECT} |
361 |
- [ $? -eq 0 ] && eend $? && exit |
362 |
+ retval=$? |
363 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
364 |
|
365 |
ewarn "Some clients did not disconnect within ${WAIT_FOR_DISCONNECT} seconds." |
366 |
ewarn "Going to shutdown the server anyway." |
367 |
|
368 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
369 |
--retry -INT/${WAIT_FOR_CLEANUP} |
370 |
- [ $? -eq 0 ] && eend $? && exit |
371 |
+ retval=$? |
372 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
373 |
|
374 |
if [ ${WAIT_FOR_QUIT} -eq 0 ] ; then |
375 |
eerror "Server did not shut down and sending the SIGQUIT has been disabled." |
376 |
- eend $? |
377 |
+ eend $retval |
378 |
+ return $retval |
379 |
fi |
380 |
|
381 |
ewarn "Shutting down the server gracefully failed." |
382 |
@@ -61,8 +69,8 @@ |
383 |
|
384 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
385 |
--retry -QUIT/${WAIT_FOR_QUIT} |
386 |
- |
387 |
- [ $? -eq 0 ] && eend $? && exit |
388 |
+ retval=$? |
389 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
390 |
|
391 |
eerror "Forced shutdown failed!!! Something is wrong with your system, please take care of it manually." |
392 |
eend $? |
393 |
|
394 |
|
395 |
|
396 |
1.2 dev-db/postgresql-server/files/postgresql.init-7.3 |
397 |
|
398 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-7.3?rev=1.2&view=markup |
399 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-7.3?rev=1.2&content-type=text/plain |
400 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-7.3?r1=1.1&r2=1.2 |
401 |
|
402 |
Index: postgresql.init-7.3 |
403 |
=================================================================== |
404 |
RCS file: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-7.3,v |
405 |
retrieving revision 1.1 |
406 |
retrieving revision 1.2 |
407 |
diff -u -r1.1 -r1.2 |
408 |
--- postgresql.init-7.3 15 Apr 2008 09:29:55 -0000 1.1 |
409 |
+++ postgresql.init-7.3 19 Apr 2008 20:37:13 -0000 1.2 |
410 |
@@ -1,7 +1,7 @@ |
411 |
#!/sbin/runscript |
412 |
# Copyright 1999-2008 Gentoo Foundation |
413 |
# Distributed under the terms of the GNU General Public License v2 |
414 |
-# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-7.3,v 1.1 2008/04/15 09:29:55 dev-zero Exp $ |
415 |
+# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/files/postgresql.init-7.3,v 1.2 2008/04/19 20:37:13 dev-zero Exp $ |
416 |
|
417 |
opts="${opts} reload" |
418 |
|
419 |
@@ -40,20 +40,25 @@ |
420 |
stop() { |
421 |
ebegin "Stopping PostgreSQL (this can take up to $(( ${WAIT_FOR_DISCONNECT} + ${WAIT_FOR_CLEANUP} )) seconds)" |
422 |
|
423 |
+ local retval |
424 |
+ |
425 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
426 |
--retry -TERM/${WAIT_FOR_DISCONNECT} |
427 |
- [ $? -eq 0 ] && eend $? && exit |
428 |
+ retval=$? |
429 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
430 |
|
431 |
ewarn "Some clients did not disconnect within ${WAIT_FOR_DISCONNECT} seconds." |
432 |
ewarn "Going to shutdown the server anyway." |
433 |
|
434 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
435 |
--retry -INT/${WAIT_FOR_CLEANUP} |
436 |
- [ $? -eq 0 ] && eend $? && exit |
437 |
+ retval=$? |
438 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
439 |
|
440 |
if [ ${WAIT_FOR_QUIT} -eq 0 ] ; then |
441 |
eerror "Server did not shut down and sending the SIGQUIT has been disabled." |
442 |
- eend $? |
443 |
+ eend $retval |
444 |
+ return $retval |
445 |
fi |
446 |
|
447 |
ewarn "Shutting down the server gracefully failed." |
448 |
@@ -61,8 +66,8 @@ |
449 |
|
450 |
start-stop-daemon --stop --pidfile "${PGDATA}/postmaster.pid" \ |
451 |
--retry -QUIT/${WAIT_FOR_QUIT} |
452 |
- |
453 |
- [ $? -eq 0 ] && eend $? && exit |
454 |
+ retval=$? |
455 |
+ [ $retval -eq 0 ] && eend $retval && return $retval |
456 |
|
457 |
eerror "Forced shutdown failed!!! Something is wrong with your system, please take care of it manually." |
458 |
eend $? |
459 |
|
460 |
|
461 |
|
462 |
-- |
463 |
gentoo-commits@l.g.o mailing list |