summaryrefslogtreecommitdiff
path: root/source/n/krb5/conf/rc.kpropd
diff options
context:
space:
mode:
Diffstat (limited to 'source/n/krb5/conf/rc.kpropd')
-rw-r--r--source/n/krb5/conf/rc.kpropd41
1 files changed, 41 insertions, 0 deletions
diff --git a/source/n/krb5/conf/rc.kpropd b/source/n/krb5/conf/rc.kpropd
new file mode 100644
index 00000000..8dde85d8
--- /dev/null
+++ b/source/n/krb5/conf/rc.kpropd
@@ -0,0 +1,41 @@
+#!/bin/sh
+# Start the Kerberos V5 slave KDC update server. This runs on a slave
+# (secondary) KDC server. It allows the master Kerberos server to use
+# kprop(8) to propagate its database to the slave servers.
+
+# To change the default options, edit /etc/default/kpropd.
+if [ -r /etc/default/kpropd ]; then
+ . /etc/default/kpropd
+fi
+
+start_atd() {
+ if ! /usr/bin/pgrep --ns $$ --euid root -f "^/usr/sbin/kpropd" 1> /dev/null 2> /dev/null ; then
+ echo "Starting kpropd: /usr/sbin/kpropd $KPROPD_OPTIONS"
+ /usr/sbin/kpropd $KPROPD_OPTIONS
+ fi
+}
+
+stop_atd() {
+ echo "Stopping kpropd."
+ /usr/bin/pkill --ns $$ --euid root -f "^/usr/sbin/kpropd" 2> /dev/null
+}
+
+restart_atd() {
+ stop_atd
+ sleep 1
+ start_atd
+}
+
+case "$1" in
+'start')
+ start_atd
+ ;;
+'stop')
+ stop_atd
+ ;;
+'restart')
+ restart_atd
+ ;;
+*)
+ echo "usage $0 start|stop|restart"
+esac