[pkg-dhcp-devel] Bug#583991: Proposed solution

Vincent Danjean vdanjean.ml at free.fr
Wed Jun 16 15:41:25 UTC 2010


On 16/06/2010 13:56, Thomas Hood wrote:
> (I will open a new bug report asking for isc-dhcp-client to Conflict
> with resolvconf <= 1.45.  This dependency will force an upgrade of
> resolvconf when isc-dhcp-client is installed.)

good.

> My first thought would be to take the following actions in the
> maintainer scripts of resolvconf 1.46.

I do not understand why you want to take different actions based on
whether a package is installed or not. I think it will be very difficult
to do the right thing in all cases (installation and removing of packages
in all situations).

What I suggest:
* all packages (including resolvconf) must provide scripts in both
  /etc/dhcp3 and /etc/dhcp (or none of coarse)
  They can add logic to duplicate (with user modification if any)
  the current hook in /etc/dhcp3 into /etc/dhcp if they want (not
  required IMHO)
* isc-dhcp-client conflicts (versionned) with all package that provides
  a hook in /etc/dhcp3 but not in /etc/dhcp
* isc-dhcp-client has a NEWS.Debian explaining that home-made hooks
  and/or modifications in /etc/dhcp3 must be redone in /etc/dhcp

> 1. Move the conffile according to the instructions in
> http://wiki.debian.org/DpkgConffileHandling.  Don't use
> dpkg-maintscript-helper which isn't available in the dpkg package in
> stable.   That is, move /etc/dhcp3/dhclient-enter-hooks.d/resolvconf to
> /etc/dhcp/dhclient-enter-hooks.d/resolvconf.
> 
> 2. Symlink the old location to the new location if isc-dhcp-client is
> not yet installed.  That is, ln -s
> /etc/dhcp/dhclient-enter-hooks.d/resolvconf
> /etc/dhcp3/dhclient-enter-hooks.d/resolvconf.
>
> 3. If isc-dhcp-client is installed, delete the symlink from the old
> location to the new location (that is, from
> /etc/dhcp/dhclient-enter-hooks.d/resolvconf to
> /etc/dhcp3/dhclient-enter-hooks.d/resolvconf) if such a symlink exists.
> 
> Anyone see any problems with this?

You must always keep the /etc/dhcp3 hook in case the user remove
isc-dhcp-client and reinstall dhcp3-client

  Regards,
    Vincent

-- 
Vincent Danjean       GPG key ID 0x9D025E87         vdanjean at debian.org
GPG key fingerprint: FC95 08A6 854D DB48 4B9A  8A94 0BF7 7867 9D02 5E87
Unofficial packages: http://moais.imag.fr/membres/vincent.danjean/deb.html
APT repo:  deb http://perso.debian.org/~vdanjean/debian unstable main




More information about the pkg-dhcp-devel mailing list