summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sys-infiniband/opensm/files/sldd.init.d')
-rw-r--r--sys-infiniband/opensm/files/sldd.init.d26
1 files changed, 26 insertions, 0 deletions
diff --git a/sys-infiniband/opensm/files/sldd.init.d b/sys-infiniband/opensm/files/sldd.init.d
new file mode 100644
index 000000000000..8f96af77bbd8
--- /dev/null
+++ b/sys-infiniband/opensm/files/sldd.init.d
@@ -0,0 +1,26 @@
+#!/sbin/runscript
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+depend() {
+ need opensm
+ after net # ip net seems to be needed to perform management.
+}
+
+prog=/usr/sbin/sldd.sh
+pidfile=/var/run/sldd.pid
+
+start() {
+ ebegin "Starting Semi-static LID OpenSM Distribution Manager"
+ start-stop-daemon --start --background --pidfile "${pidfile}" \
+ --make-pidfile --wait 500 --exec $prog
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping OpenSM Infiniband Subnet Manager"
+ start-stop-daemon --stop --pidfile "${pidfile}"
+ eend $?
+}
+