[debian-mysql] mysql-server-5.5.postrm [was: Re: Resyncing with Ubuntu]

Robie Basak robie.basak at ubuntu.com
Mon Feb 10 15:24:00 UTC 2014


This post is about mysql-server-5.5.postrm.

Currently, it disables the standard #DEBHELPER# token. I presume this
causes an issue in Ubuntu with upstart, and so Ubuntu re-enables it
currently.

I note that in Debian, the removed token is replaced with
hand-crafted/copied code of what the token would have caused to be
included; Ubuntu doesn't remove this, so there is some duplication
there. I haven't investigated to see if there's a bug here or not.

As far as I can determine, the reason for this being in Debian is:

# - Do NOT purge logs or data if another mysql-sever* package is installed (#307473)

I've looked at that bug, and it seems to be that it is no longer
relevant in jessie, since other packages no longer exist, and this is
specifically a mysql-server-5.5 postrm.

But, we'll have mysql-server-5.6 soon, so we probably want to get this
right.

AIUI:

mysql-server-5.5 owns /var/lib/mysql, and conflicts with
mysql-server-5.6 (say), which also owns /var/lib/mysql, and they
conflict. What's the expected behaviour on package purge? Should
/var/lib/mysql, which contains the relevant database itself, be purged?
Currently, there's some really ugly code in this area.

There's a debconf option to say what should happen, but also code to try
and not do the purge if a different mysql-server-* is installed, since
otherwise it would destroy the wrong data.

The whole arrangement seems wrong to me, but I'm not sure of the correct
solution.

Can this be fixed by restoring the #DEBHELPER# token, and dropping the
custom code? I don't see any bug that would be caused by this. But this
is a tricky area and I'm not entirely sure. In the meantime, the
existing code seems quite ugly and difficult to maintain, and blocks me
from adding upstart support cleanly both in Debian and in Ubuntu.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-mysql-maint/attachments/20140210/6f3398f2/attachment.sig>


More information about the pkg-mysql-maint mailing list