samba-tng-alpha-2.2.tar.gz

Michael Glauche mg at plum.de
Tue Apr 11 11:06:06 GMT 2000


hi,
  here is a small update for the "samba" startup script, as the daemons
now are in {$PREFIX}/sbin ...

Regards,
    Michael
-------------- next part --------------
#!/bin/sh
#
# samba
#
# This is from a Solaris box.  Proper links need to be made to it from the
# rcX.d directories.  For Linux, it goes into /etc/rc.d/init.d
# 
# Lonnie

SAMBA=/opt/samba-tng

case "$1" in
'start')
        echo "SMB Service starting."
        PATH="/usr/bin:/sbin:/usr/sbin"
        export PATH
        ${SAMBA}/sbin/smbd -D
        ${SAMBA}/sbin/nmbd -D
        ${SAMBA}/sbin/browserd -D
        ${SAMBA}/sbin/lsarpcd -D
        ${SAMBA}/sbin/netlogond -D
        ${SAMBA}/sbin/samrd -D
        ${SAMBA}/sbin/spoolssd -D
        ${SAMBA}/sbin/srvsvcd -D
        ${SAMBA}/sbin/svcctld -D
        ${SAMBA}/sbin/winregd -D
        ${SAMBA}/sbin/wkssvcd -D
        ;;
'restart')
        $0 stop
        $0 start
        ;;
'stop')
        echo "SMB Service stopping."
        for file in ${SAMBA}/var/locks/*.pid
        do
                if [ -r $file ]
                then
                        kill `cat $file`
                        rm $file
                fi
        done
        ;;
*)
        echo "Usage: /etc/init.d/samba { start | stop | restart }"
        ;;
esac
exit 0


More information about the samba-technical mailing list