JHT ===> Prepared now for release of Samba-1.9.16p10 RedHat RPMS
[samba.git] / examples / redhat / smb.init
1 #!/bin/sh
2
3 # Source function library.
4 . /etc/rc.d/init.d/functions
5
6 # Source networking configuration.
7 . /etc/sysconfig/network
8
9 # Check that networking is up.
10 [ ${NETWORKING} = "no" ] && exit 0
11
12 # See how we were called.
13 case "$1" in
14   start)
15         echo -n "Starting SMB services: "
16         daemon smbd -D  
17         daemon nmbd -D 
18         echo
19         touch /var/lock/subsys/smb
20         ;;
21   stop)
22         echo -n "Shutting down SMB services: "
23         killproc smbd
24         killproc nmbd
25         rm -f /var/lock/subsys/smb
26         echo ""
27         ;;
28   *)
29         echo "Usage: smb {start|stop}"
30         exit 1
31 esac
32