diff options
Diffstat (limited to 'examples/redhat/smb.init')
-rwxr-xr-x | examples/redhat/smb.init | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/examples/redhat/smb.init b/examples/redhat/smb.init new file mode 100755 index 0000000000..ab047e55b4 --- /dev/null +++ b/examples/redhat/smb.init @@ -0,0 +1,32 @@ +#!/bin/sh + +# Source function library. +. /etc/rc.d/init.d/functions + +# Source networking configuration. +. /etc/sysconfig/network + +# Check that networking is up. +[ ${NETWORKING} = "no" ] && exit 0 + +# See how we were called. +case "$1" in + start) + echo -n "Starting SMB services: " + daemon smbd -D + daemon nmbd -D + echo + touch /var/lock/subsys/smb + ;; + stop) + echo -n "Shutting down SMB services: " + killproc smbd + killproc nmbd + rm -f /var/lock/subsys/smb + echo "" + ;; + *) + echo "Usage: smb {start|stop}" + exit 1 +esac + |