:: [devuan-dev] bug#634: marked as don…
Inizio della pagina
Delete this message
Reply to this message
Autore: Devuan bug Tracking System
Data:  
To: Mark Hindley
Oggetto: [devuan-dev] bug#634: marked as done (backuppc: Backuppc fail to start on a clean installation)
Your message dated Tue, 10 Jan 2023 16:51:40 +0000
with message-id <Y72XnF1M9I+MS7jh@???>
and subject line Fixed in Debian #992597
has caused the Devuan bug report #634,
regarding backuppc: Backuppc fail to start on a clean installation
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@???
immediately.)


--
634: https://bugs.devuan.org/cgi/bugreport.cgi?bug=634
Devuan Bug Tracking System
Contact owner@??? with problems
Package: backuppc
Version: 4.4.0-3
Severity: normal
Tags: patch
X-Debbugs-Cc: debianbugs@???

Dear Maintainer,

Backuppc, installed from the package on a new server (so no
upgrade/update from previous versions) fails with this message:

# apt install backuppc

[... omitted output...]

Creating config file /etc/backuppc/config.pl with new version
Starting backuppc...BackupPC cannot be started because important parameters are missing from config.pl.
If you just upgraded BackupPC, please update /etc/backuppc/config.pl.
invoke-rc.d: initscript backuppc, action "start" failed.
dpkg: error processing package backuppc (--configure):
installed backuppc package post-installation script subprocess returned error exit status 1


This happens because the init script for backuppc contains this check:

# Check for incompatible old config files
check_old_config()
{
    BAD=0
    CONF=/etc/backuppc/config.pl


    grep -q IncrLevel $CONF || BAD=1


    if [ "$BAD" = "1" ]; then
        echo "BackupPC cannot be started because important parameters are missing from config.pl."
        echo "If you just upgraded BackupPC, please update /etc/backuppc/config.pl."
        exit 1
    fi
}


But it seems that this check is not needed anymore in Backuppc 4, it was
something related to V2 -> V3 upgrade.

This check is called when starting/restarting backuppc. By commenting
out the call to check_old_config under start and restart, backuppc
works.

This will leave you with an unconfigured package in apt, so after
modifying the init script you'll also have to run:

rmdir /var/lib/backuppc/pc/localhost
apt install



Kind regards

Fabio Muzzi



-- System Information:
Distributor ID:    Devuan
Description:    Devuan GNU/Linux 4 (chimaera)
Release:    4
Codename:    chimaera
Architecture: x86_64


Kernel: Linux 5.10.0-9-amd64 (SMP w/2 CPU threads)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE=en_US:en
Shell: /bin/sh linked to /bin/dash
Init: sysvinit (via /sbin/init)
LSM: AppArmor: enabled

Versions of packages backuppc depends on:
ii  adduser                                    3.118
ii  apache2 [httpd]                            2.4.51-1~deb11u1
ii  apache2-utils                              2.4.51-1~deb11u1
ii  backuppc-rsync                             3.1.3.0-3
ii  bzip2                                      1.0.8-4
ii  debconf [debconf-2.0]                      1.5.77
ii  exim4-daemon-light [mail-transport-agent]  4.94.2-7
ii  init-system-helpers                        1.60+devuan1
ii  iputils-ping                               3:20210202-1
ii  libarchive-zip-perl                        1.68-1
ii  libbackuppc-xs-perl                        0.62-1+b1
ii  libc6                                      2.31-13+deb11u2
ii  libcgi-pm-perl                             4.51-1
pn  libdigest-md5-perl                         <none>
ii  libfile-listing-perl                       6.14-1
ii  libtime-parsedate-perl                     2015.103-3
ii  lsb-base                                   11.1.0
ii  perl [libio-compress-perl]                 5.32.1-4+deb11u2
ii  ucf                                        3.0043


Versions of packages backuppc recommends:
ii  libio-dirent-perl            0.05-1+b9
ii  openssh-client [ssh-client]  1:8.4p1-5
ii  rrdtool                      1.7.2-3+b7
ii  samba-common-bin             2:4.13.13+dfsg-1~deb11u2
ii  smbclient                    2:4.13.13+dfsg-1~deb11u2


Versions of packages backuppc suggests:
pn  certbot | acme-tiny | acmetool | dehydrated | lacme | lecm  <none>
pn  libscgi-perl                                                <none>
pn  par2                                                        <none>
ii  rsync                                                       3.2.3-4+deb11u1
pn  w3m | www-browser                                           <none>


-- Configuration Files:
/etc/backuppc/apache.conf changed:
Alias /backuppc /usr/share/backuppc/cgi-bin/
<Directory /usr/share/backuppc/cgi-bin/>
    AllowOverride None
        # Uncomment the line below to ensure that nobody can sniff important
        # info from network traffic during editing of the BackupPC config or
        # when browsing/restoring backups.
        # Requires that you have your webserver set up for SSL (https) access.
        #SSLRequireSSL

                    
    Options ExecCGI FollowSymlinks
    AddHandler cgi-script .cgi
    DirectoryIndex index.cgi
        AuthUserFile /etc/backuppc/htpasswd
    AuthType basic
    AuthName "BackupPC admin"
        <RequireAll>
        # Comment out this line once you have setup HTTPS and uncommented SSLRequireSSL
        # This line ensures that only authenticated users may access your backups
        Require valid-user
    </RequireAll>
</Directory>


/etc/init.d/backuppc changed:
set -e
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
check_old_config()
{
    BAD=0
    CONF=/etc/backuppc/config.pl


    grep -q IncrLevel $CONF || BAD=1


    if [ "$BAD" = "1" ]; then
    echo "BackupPC cannot be started because important parameters are missing from config.pl."
    echo "If you just upgraded BackupPC, please update /etc/backuppc/config.pl."
    exit 1
    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
    check_old_config
    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



-- debconf information:
backuppc/tmppass: (password omitted)
* backuppc/configuration-note:
* backuppc/reconfigure-webserver: apache2
backuppc/restart-webserver: true
Version: 4.4.0-4