Package: isdnlog
Version: 1:3.25+dfsg1-3wheezy1
Severity: grave
Justification: renders package unusable

Dear Maintainer,

unfortunately, after the wheezy upgrade the entire ISDN subsystem was
broken here. 

Part of the damage was isdnlog stopped working. After a long search I
finally found /etc/isdn/isdnlog.isdnctrl0 was destroyed (overwritten
with the rate.cfg content).

The analysis of isdnlog.postinst revealed the cause:

31:        tempfile=$(mktemp -t isdnutils.XXXXXX)
(...)
35:        for cfg in isdn.conf rate.conf; do
# tempfile filled with country specific content for $cfg, then
# forwarded to ucf
59:        done
61:        if [ ! -s /etc/isdn/isdnlog.isdnctrl0 ]; then
# skipped in upgrade as /etc/isdn/isdnlog.isdnctrl0 already exists
(...)
63:            sed '/REMOVE the next line/,/REMOVE the above/d' < 
/usr/share/doc/isdnlog/examples/isdnlog.DEVICE > "$tempfile"
# tempfile filled with isdnctrol.isdnctrl* template, skipped in upgrade
(...)
67:        fi
68:        ucf --three-way --debconf-ok "$tempfile" /etc/isdn/isdnlog.isdnctrl0
# /etc/isdn/isdnlog.isdnctrl0 compared with $tempfile, which is still
# some rate.$country stuff

Then the administrator is in charge to detect something went terribly
wrong when a huge change is presented by ucf. Choosing the broken
"maintainer's" version, in the "The diff is huge, I never changed that
file manually, so it's probably OK" mood causes the breakage. 
The "A new version of configuration file /etc/isdn/isdnlog.isdnctrl0
is available, but the version installed currently has been locally
modified" message supports that behaviour.

In my case, at least reverting was easy as etckeeper(1) is installed.

How to fix:

Shouldn't be that difficult. Basically assert there's the right
content in $tempfile, so I think the following does the things
right (not tested):

        sed '/REMOVE the next line/,/REMOVE the above/d' < 
/usr/share/doc/isdnlog/examples/isdnlog.DEVICE > "$tempfile"
        if [ ! -s /etc/isdn/isdnlog.isdnctrl0 ]; then
            echo "Creating default /etc/isdn/isdnlog.isdnctrl0 ."
        fi
        ucf --three-way --debconf-ok "$tempfile" /etc/isdn/isdnlog.isdnctrl0
        ucfr isdnlog /etc/isdn/isdnlog.isdnctrl0
        if [ -x /etc/init.d/isdnutils-base ]; then
          invoke-rc.d isdnutils-base restart isdnlog
        fi

On a related note, there was other trouble but that requires more
checking on my side. At most, are you sure the ISDN-related device
nodes are still created? They are missing here here but the reason
might be, although not likely, the patched vanilla kernel I am running
on that computer. Will double-check with a stock Debian kernel on a
different box in a few days, separate bug report will follow then.

    Christoph

-- System Information:
Debian Release: wheezy/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: i386 (i686)

Kernel: Linux 3.4.23 (SMP w/4 CPU cores)
Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages isdnlog depends on:
ii  debconf       1.5.46
pn  isdnlog-data  <none>

isdnlog recommends no packages.

isdnlog suggests no packages.

Attachment: signature.asc
Description: Digital signature

Reply via email to