Package: amavisd-new Version: 1:2.13.0-2 Severity: serious User: jo...@debian.org Usertags: adduserpurge
Hi, the packages passwd and adduser are not part of the Essential:yes set. According to policy §7.2 maintainer scripts cannot assume them being installed when purging a package. If one tries to remove this package without adduser (which depends on passwd) installed, one gets: --%<------------------------------------------------------------------------- Purging configuration files for amavisd-new (1:2.13.0-2) ... /var/lib/dpkg/info/amavisd-new.postrm: 36: userdel: not found dpkg: error processing package amavisd-new (--purge): installed amavisd-new package post-removal script subprocess returned error exit status 127 Errors were encountered while processing: amavisd-new -->%------------------------------------------------------------------------- There is ongoing discussion how to handle system users on package removal, see https://bugs.debian.org/621833 For a discussion about use of adduser during purge, see #1035654. To work around this problem, at least 125 source packages [codesearch] simply ignore failures of calling the passwd or adduser tools during purge. The following patch should fix this package by doing the same: --%<------------------------------------------------------------------------- diff -Nru amavisd-new-2.13.0/debian/amavisd-new.postrm amavisd-new-2.13.0/debian/amavisd-new.postrm --- amavisd-new-2.13.0/debian/amavisd-new.postrm 2023-02-23 05:59:36.000000000 +0100 +++ amavisd-new-2.13.0/debian/amavisd-new.postrm 2023-05-10 06:33:15.000000000 +0200 @@ -33,7 +33,7 @@ dpkg-statoverride --remove $i || true done - userdel amavis + userdel amavis || true echo "Removing amavis files and directories..." [ -d /var/lib/amavis ] && rm -fr /var/lib/amavis -->%------------------------------------------------------------------------- If you prefer I can fix this via an NMU. Thanks! cheers, josch [codesearch] https://codesearch.debian.net/search?q=del%28user%7Cgroup%29.*%5C%7C%5C%7C+true+path%3Adebian%2F.*%5C.%28pre%7Cpost%29rm%24&literal=0