visit minimum number of backups for only_increment
[BackupPC.git] / init.d / src / solaris-backuppc
1 #!/bin/sh
2 #
3 # DESCRIPTION
4 #
5 #   Startup init script for BackupPC for solaris.
6 #
7 # Distributed with BackupPC version __VERSION__, released __RELEASEDATE__.
8 #
9 # Not tested...
10
11
12 start() {
13     #
14     # You can set the SMB share password here is you wish.  Otherwise
15     # you should put it in the config.pl script.
16     # If you put it here make sure this file has no read permissions
17     # for normal users!  See the documentation for more information.
18     #
19     #BPC_SMB_PASSWD=
20     #export BPC_SMB_PASSWD
21     #
22     su __BACKUPPCUSER__ -c "__INSTALLDIR__/bin/BackupPC -d"
23 }
24
25 stop() {
26     /usr/bin/pkill -f "__INSTALLDIR__/bin/BackupPC -d"
27 }
28
29 restart() {
30     stop
31     start
32 }       
33
34 reload() {
35     /usr/bin/pkill -1 -f "__INSTALLDIR__/bin/BackupPC -d"
36 }
37
38 case "$1" in
39   start)
40         start
41         ;;
42   stop)
43         stop
44         ;;
45   restart)
46         restart
47         ;;
48   reload)
49         reload
50         ;;
51   *)
52         echo "Usage: $0 {start|stop|restart|reload}"
53         exit 1
54 esac
55
56 exit $?