+
+ msg_stopping "OpenSSH"
+ # we use start-stop-daemon to stop sshd, as it is unacceptable for such
+ # critical service as sshd to kill it by procname, but unfortunately
+ # rc-scripts does not provide way to kill *only* by pidfile
+ start-stop-daemon --stop --quiet --pidfile /var/run/sshd.pid && ok || fail
+ rm -f /var/lock/subsys/sshd >/dev/null 2>&1
+}
+
+reload() {
+ if [ ! -f /var/lock/subsys/sshd ]; then
+ msg_not_running "OpenSSH"
+ RETVAL=7
+ return
+ fi
+
+ checkconfig
+ msg_reloading "OpenSSH"
+ killproc sshd -HUP
+ RETVAL=$?
+}
+
+condrestart() {
+ if [ ! -f /var/lock/subsys/sshd ]; then
+ msg_not_running "OpenSSH"
+ RETVAL=$1
+ return
+ fi
+
+ checkconfig
+ stop
+ start