source: bootscripts-standard/bootscripts/cblfs/init.d/heimdal@ 421f21a

Last change on this file since 421f21a was e814bfe, checked in by Chris Staub <chris@…>, 10 years ago

Changed all /var/run references to /run

  • Property mode set to 100644
File size: 1.7 KB
RevLine 
[2167cfe]1#!/bin/bash
2# Begin $rc_base/init.d/heimdal
3
4# Based on sysklogd script from LFS-3.1 and earlier.
5# Rewritten by Gerard Beekmans - gerard@linuxfromscratch.org
6
7#$LastChangedBy: bdubbs $
8#$Date: 2005-08-01 14:29:19 -0500 (Mon, 01 Aug 2005) $
9
10. /etc/sysconfig/rc
11. $rc_functions
12
13case "$1" in
14 start)
15 boot_mesg -n "Starting KDC Server Daemon..."
[e814bfe]16 if test -f "/run/kdc.pid"
[2167cfe]17 then
18 boot_mesg "kdc already running!" ${WARNING}
19 echo_warning
20 else
21 /usr/sbin/kdc &
22 sleep 1
[e814bfe]23 if test -f "/run/kdc.pid"
[2167cfe]24 then
25 echo ""
26 echo_ok
27 else
28 echo ""
29 echo_failure
30 fi
31 fi
32 boot_mesg -n "Starting KDC kpasswdd Daemon..."
[e814bfe]33 if test -f "/run/kpasswdd.pid"
[2167cfe]34 then
35 boot_mesg "kpasswdd already running!" ${WARNING}
36 echo_warning
37 else
38 /usr/sbin/kpasswdd &
39 sleep 1
[e814bfe]40 if test -f "/run/kpasswdd.pid"
[2167cfe]41 then
42 echo ""
43 echo_ok
44 else
45 echo ""
46 echo_failure
47 fi
48 fi
49 boot_mesg -n "Starting KDC kadmind Daemon..."
[e814bfe]50 if test -f "/run/kadmind.pid"
[2167cfe]51 then
52 boot_mesg "kadmind already running!" ${WARNING}
53 echo_warning
54 else
55 /usr/sbin/kadmind &
56 sleep 1
[e814bfe]57 if test -f "/run/kadmind.pid"
[2167cfe]58 then
59 echo ""
60 echo_ok
61 else
62 echo ""
63 echo_failure
64 fi
65 fi
66 ;;
67
68 stop)
69 boot_mesg "Stopping KDC kadmind Daemon..."
70 killproc /usr/sbin/kadmind
71 boot_mesg "Stopping KDC kpasswdd Daemon..."
72 killproc /usr/sbin/kpasswdd
73 boot_mesg "Stopping KDC Server Daemon..."
74 killproc /usr/sbin/kdc
75 ;;
76
77 restart)
78 $0 stop
79 sleep 1
80 $0 start
81 ;;
82
83 status)
84 statusproc /usr/sbin/kdc
85 statusproc /usr/sbin/kpasswdd
86 statusproc /usr/sbin/kadmind
87 ;;
88
89 *)
90 echo "Usage: $0 {start|stop|restart|status}"
91 exit 1
92 ;;
93esac
94
95# End $rc_base/init.d/heimdal
Note: See TracBrowser for help on using the repository browser.