[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: transitioning config files between two packages



Steve Langasek <vorlon@debian.org> wrote:

> On Thu, Sep 14, 2006 at 01:32:43AM +0200, Javier Fernández-Sanguino Peña wrote:
>> On Tue, Sep 12, 2006 at 05:21:50PM -0700, Steve Langasek wrote:
>> > After an upgrade and answering all of the conffile prompts, does
>> > /var/lib/dpkg/info/nagios-plugins.conffiles still exist and reference these
>> > files?  Depending on what dpkg is really doing here, it may well be possible
>> > to handle the conffile transfer in maintainer scripts.  (And I thought
>> > dpkg.org once had recipes for exactly this, but unfortunately the site has
>> > been down for some time now. :/)
>
>> Are you looking for http://wiki.debian.org/DpkgConffileHandling ? 
>> (just found it googling). I guess this information (if current) should be
>> moved over to the developer's reference. 
>
> That seems to be the one.  It also doesn't seem to address changing the
> owner of a conffile.. ohwell. :)

Maybe I'm dumb, but this code doesn't seem correct to me, in the sense
that it doesn't do the right thing.  Let's consider a couple of possible
cases:

1. The conffile at the old place (or package) is the same as the one in
   the new place

   In this case the code in the wiki does the right thing.

2. At the same time as the move is done, the contents of the file do
   also change. And here "same time" doesn't necessarily mean "same
   upload", it can as well be "same run of dist-upgrade", which often
   skips intermediate versions, especially when upgrading from stable to
   new stable.

   In this case the user should get a conffile prompt during upgrade, to
   be able to consider the changes made in the package.  But that won't
   happen with the code in the wiki; instead the old, locally changed
   version will be used unconditionally.

There might be ways to do it right with dpkg only, but ucf is probably
easier. 

Regards, Frank

-- 
Frank Küster
Single Molecule Spectroscopy, Protein Folding @ Inst. f. Biochemie, Univ. Zürich
Debian Developer (teTeX/TeXLive)



Reply to: