Samx Here
n1udSecurity


Server : Apache
System : Linux ks5.tuic.fr 6.1.0-18-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.76-1 (2024-02-01) x86_64
User : pragmatice ( 1003)
PHP Version : 8.2.24
Disable Function : NONE
Directory :  /etc/rc1.d/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //etc/rc1.d/K01backuppc
#!/bin/sh
### BEGIN INIT INFO
# Provides:          backuppc
# Required-Start:    $syslog $network $remote_fs
# Required-Stop:     $syslog $network $remote_fs
# Should-Start:      $local_fs autofs
# Should-Stop:       $local_fs autofs
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: Launch backuppc server
# Description:       Launch backuppc server, a high-performance,
#                    enterprise-grade system for backing up PCs.
### END INIT INFO

set -e

# Do not change the values below! Performance related settings can be
# changed in /etc/default/backuppc. See /usr/share/doc/backuppc/README.Debian.
BINDIR=/usr/share/backuppc/bin
DATADIR=/var/lib/backuppc
RUNDIR=/run/backuppc
USER=backuppc
GROUP=backuppc
NICE=0
IONICE=best-effort

test -f /etc/default/backuppc && . /etc/default/backuppc

#
NAME=backuppc
DAEMON=BackupPC

test -x $BINDIR/$DAEMON || exit 0
. /lib/lsb/init-functions
[ -r /etc/default/rcS ] && . /etc/default/rcS

if [ ! -d $RUNDIR ]; then
    mkdir -p $RUNDIR
    chown ${USER}:${GROUP} $RUNDIR
    chmod 0755 $RUNDIR
fi

case "$1" in
  start)
    log_begin_msg "Starting $NAME..."
    start-stop-daemon --start --pidfile $RUNDIR/BackupPC.pid \
			    --nicelevel $NICE --iosched $IONICE -c $USER --exec $BINDIR/$DAEMON -- -d
    log_end_msg $?
    ;;
  stop)
    log_begin_msg "Stopping $NAME..."
    start-stop-daemon --stop --pidfile $RUNDIR/BackupPC.pid -u $USER \
			    --oknodo --retry 30
    log_end_msg $?
      ;;
  restart)
    log_begin_msg "Restarting $NAME..."
    start-stop-daemon --stop --pidfile $RUNDIR/BackupPC.pid -u $USER \
			    --oknodo --retry 30
    start-stop-daemon --start --pidfile $RUNDIR/BackupPC.pid \
			    --nicelevel $NICE --iosched $IONICE -c $USER --exec $BINDIR/$DAEMON -- -d
    log_end_msg $?
    ;;
  reload|force-reload)
    log_begin_msg "Reloading $NAME configuration files..."
    start-stop-daemon --stop --pidfile $RUNDIR/BackupPC.pid -u $USER \
			    --signal 1
    log_end_msg $?
    ;;
  status)
    status_of_proc "$BINDIR/$DAEMON" "$NAME" && exit 0 || exit $?
    ;;
  *)
    log_success_msg "Usage: /etc/init.d/$NAME {start|stop|restart|reload|status}"
    exit 1
    ;;
esac

exit 0

SAMX