[BACK]Return to runbt.sh CVS log [TXT][DIR] Up to [local] / openbsd / OpenBSDTorrents

Annotation of openbsd/OpenBSDTorrents/runbt.sh, Revision 1.10

1.2       andrew      1: #!/bin/sh
1.10    ! andrew      2: #$Id: runbt.sh,v 1.9 2005/04/29 20:16:31 andrew Exp andrew $
1.2       andrew      3:
1.10    ! andrew      4: . /etc/OpenBSDTorrents.conf
        !             5: LOGFILE=/home/torrentseeder/runbt.log
1.6       andrew      6:
1.10    ! andrew      7: cd ${OBT_DIR_HOME}
        !             8: PIDFILE=${OBT_DIR_HOME}/run/runbt.pid
        !             9:
        !            10: if [ -e ${PIDFILE} ]; then
        !            11:         PID=`head -1 ${PIDFILE}`
        !            12:         kill -0 ${PID} 2> /dev/null
        !            13:         if [ $? -eq 0 ]; then
        !            14:                 echo Already running
        !            15:                 exit 1
        !            16:         fi
        !            17: fi
        !            18: echo $$ > ${PIDFILE}
        !            19:
        !            20:
1.6       andrew     21: echo -n `date` >> ${LOGFILE}
1.7       andrew     22: echo ' Starting . . . ' >> ${LOGFILE}
1.6       andrew     23:
1.10    ! andrew     24: nice btlaunchmany.py \
1.3       andrew     25:     --super_seeder 1 \
1.10    ! andrew     26:     --check_hashes 0 \
        !            27:     --display_interval 60 \
        !            28:     --minport 6881 --maxport 6989 \
1.9       andrew     29:     --max_files_open 75 \
1.1       andrew     30:     --saveas /home/ftp/pub/ --saveas_style 2 \
1.9       andrew     31:     /home/torrentsync/torrents/ >> ${LOGFILE}
1.6       andrew     32:
                     33: echo -n `date` >> ${LOGFILE}
1.7       andrew     34: echo ' Died . . . ' >> ${LOGFILE}

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>