[Pkg-samba-maint] [samba] 03/04: Don't fail in postinst when removing old alternatives fails
Ivo De Decker
ivo.dedecker at ugent.be
Mon Dec 9 18:56:58 UTC 2013
On Mon, Dec 09, 2013 at 10:23:34AM -0800, Steve Langasek wrote:
> On Mon, Dec 09, 2013 at 06:06:41PM +0000, Ivo De Decker wrote:
> > Don't fail in postinst when removing old alternatives fails
> What is the rationale for this? Ignoring failures from commands like
> update-alternatives is a good way to leave cruft behind on the system that
> will never be cleaned up. Why would these commands fail, and how can we
> better handle the specific failure case?
I got one specific failure case in my tests:
When installing samba from jessie (2:4.0.12+dfsg-1), and upgrading to the new
version (2:4.0.13+dfsg-1), the alternatives aren't there, so removing them
fails. This makes the entire upgrade fail.
When installing samba from wheezy (2:3.6.6-6+deb7u1) and then upgrading to
jessie (2:4.0.12+dfsg-1), the alternatives are not correctly removed (this is
the bug we are trying to fix). When upgrading from this version to
2:4.0.13+dfsg-1, they should be removed.
It seems update-alternatives has no convenient way to remove alternatives only
when they are there.
More information about the Pkg-samba-maint