Tag Archives: purge

conffiles, newer packages and purging

Earlier this month Kumar Appaiah opened a bug against the culmus package as part of the stable -> unstable piuparts upgrade tests.

First, I’m proud in Debian to have these tests. Thanks for the people involved with running them, parsing the log files and reporting the bugs. I really feel the lake of such checks in commercial distributions I work with.

After finding the time to get to the bottom of the bug, and talking with Kumar, it seems most of the bugs found in the test are similar. I think this might indicate something wrong in a more basic level of the package handling.

The source of these bugs is how to handle files which were conffile in version x, but aren’t included in version x+1 (as a regular file). In the common situation, the conffiles are removed only during the purge process and not during upgrade or removal. But if a conffile doesn’t exist in the x+1 package, no one will “own” it after the upgrade, and no will purge it in due time.

This is why changing conffiles can result in extra files on our system, which is the problem discovered by the recent piuparts test.

One solution will be that each package maintainer will add the necessary code to the maintainer scripts to remove the file on upgrade. A second solution is to decide the wanted behavior in such a case and to have dpkg handle it for all packages.

The behavior can be to remove the old conffile during the upgrade (postinst script) or to dynamically add it to the list of files owned by the package. Although technically possible, I’m not sure if the second method is “legal” with the debian policy.

I thought it would be better to hear others’ opinions before submitting a wishlist bug about this.

Advertisements

3 Comments

Filed under Debian GNU/Linux