Page MenuHomePhorge

Debian: error removing roundcubemail
Closed, ResolvedPublic


I'm running kolan on Debian 10, with roundcubemail on Debian 11/12 connected to the kolab imap server.

$ dpkg -l roundcubemail
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name                        Version            Architecture       Description
ii  roundcubemail               1: all          skinnable AJAX based webmail solution for IMA>

I've tried to remove the package roundcubemail from my testsystem:
[manually translated into english]

Removing roundcubemail (1: ...
/var/lib/dpkg/info/roundcubemail.prerm: 11: reload_apache: not found
dpkg: Error handling package roundcubemail (--remove):
»installed pre-removal-Script of package roundcubemail«-Subprocess returned error code 127

The prerm script in /var/lib/dpkg/info/roundcubemail.prerm contains:

if [ "$1" = "remove" ]; then
    if [ ! -f "/etc/plesk-release" ]; then
        a2dissite roundcubemail.conf > /dev/null || true
        reload_apache restart

There isn't a command reload_apache on Debian 10 and newer.
I guess that "service apache2 reload" should work fine.


Ticket Type

Event Timeline

machniak subscribed.

This can be found in preinst and postinst scripts and should be copied to prerm script.

    if apache2ctl configtest 2>/dev/null; then
        invoke-rc.d apache2 $1 || true
        echo "Your apache2 configuration is broken, so we're not restarting it for you."
machniak lowered the priority of this task from Needs Triage to Normal.Sep 27 2023, 12:27 PM
machniak added projects: Roundcube, Kolab 16.

Fix proposed in @machniak, @mollekopf, could you please take a look and push it through to Kolab:16 if it's okay?

Superseded by, which includes an additional fix for the upgrade path by adding a conflict with roundcubemail-plugins-kolab.