Revision 1108,
775 bytes
checked in by daisuke, 14 years ago
(diff) |
import initscripts-8.90.6 from internal cvs repository
|
Line | |
---|
1 | #!/bin/sh |
---|
2 | # |
---|
3 | # lpd This shell script takes care of starting and stopping |
---|
4 | # lpd (printer daemon). |
---|
5 | # |
---|
6 | |
---|
7 | # Source function library. |
---|
8 | . /etc/init.d/functions |
---|
9 | |
---|
10 | # See how we were called. |
---|
11 | case "$1" in |
---|
12 | start) |
---|
13 | # Start daemons. |
---|
14 | echo -n $"Starting testd: " |
---|
15 | testd & |
---|
16 | echo |
---|
17 | touch /var/lock/subsys/testd |
---|
18 | ;; |
---|
19 | stop) |
---|
20 | # Stop daemons. |
---|
21 | echo -n $"Shutting down testd: " |
---|
22 | killproc testd |
---|
23 | echo |
---|
24 | rm -f /var/lock/subsys/testd |
---|
25 | ;; |
---|
26 | status) |
---|
27 | # Am I alive? |
---|
28 | status testd |
---|
29 | exit $? |
---|
30 | ;; |
---|
31 | restart) |
---|
32 | echo -n $"Shutting down testd: " |
---|
33 | killproc testd |
---|
34 | echo |
---|
35 | echo -n $"Starting testd: " |
---|
36 | testd & |
---|
37 | echo |
---|
38 | ;; |
---|
39 | *) |
---|
40 | echo $"Usage: testd {start|stop|status|restart}" |
---|
41 | exit 1 |
---|
42 | esac |
---|
43 | |
---|
44 | exit 0 |
---|
Note: See
TracBrowser
for help on using the repository browser.