[File-rc-users] Bug#688140: file-rc: File-rc doesn't restore rcX.d dirs at remove, breaks sysv-rc installation.

Roger Leigh rleigh at codelibre.net
Wed Feb 6 00:40:37 UTC 2013


On Wed, Feb 06, 2013 at 12:49:02AM +0100, Michael Stapelberg wrote:
> On Tue, 6 Nov 2012 20:46:25 +0100
> Andreas Beckmann <debian at abeckmann.de> wrote:
> > On Wednesday, 19. September 2012 21:05:03 Piotr Borkowski wrote:
> > > File-rc doesn't restore rcX.d dirs at remove. This breaks sysv-rc
> > > legacy_bootordering postinst function. After sysv-rc installation
> > > this leads to empty rcX.d dirs and broken system. Maybe file-rc
> > > should call
> > 
> > I can reproduce this problem in piuparts distupgrade tests, e.g.
> >   setup squeeze (or wheezy) chroot
> >   switch to file-rc
> >   distupgrade to wheezy (or sid)
> >   switch back to sysv-rc
> > 
> > but not within a distro:
> >   setup a squeeze (or wheezy or sid) chroot
> >   switch to file-rc
> >   switch back to sysv-rc
> > 
> > curiously it also happens after a wheezy->sid distuprade, even if the
> > versions of sysv-rc and file-rc are the same in both sid and wheezy
> I haven’t tried to reproduce this issue yet, but I have figured out
> that in file-rc 0.8.13, the call to rcfile2link.sh was removed from
> debian/prerm:
> 
> --- file-rc-0.8.12/debian/prerm	2010-04-07 21:30:54.000000000 +0200
> +++ file-rc-0.8.13/debian/prerm	2012-07-30 07:49:08.000000000 +0200
> @@ -19,7 +19,6 @@
>  
>  case "$1" in
>      remove)
> -	/usr/share/file-rc/rcfile2link.sh
>          ;;
>      upgrade|deconfigure)
>  	;;
> 
> 
> The changelog mentions:
> 
>    * Removed long obsolete logic (prior to oldstable) from maintainer
>      scripts, which is no longer useful for upgrades.
> 
> Roger: Your name was above the changes in the changelog of file-rc
> 0.8.13. Was this change intentional? If so, could you explain how the
> conversion from file to links is supposed to work in the current
> version so that we can debug further?

Hi Michael,

I'm afraid I can't remember the specifics off the top of my head;
I'd have to review this work again to refresh my memory of the
details.

The reason for this change is that with file-rc now using insserv
to maintain the links in part, it is not really meaningful to
"restore" the links.  Both file-rc and sysv-rc use insserv, and so
when we switch between them, the state should remain identical.  That
is to say, that the changes effected by insserv (wrapped by
update-rc.d/file-rc) are the state which should be preserved,
which in practice means not doing anything at all.  However... my
memory may be bad here--I can't recall the extent to which we use
insserv in file-rc for handling the links.

I think the question to ask here is, why does the pattern of links
make legacy_bootordering true, and why does activate_insserv fail?
Is this at the point of running convert_rc_s_to_k or when running
insserv?  A little more detail about exactly what is failing here
would be helpful.


Regards,
Roger

-- 
  .''`.  Roger Leigh
 : :' :  Debian GNU/Linux    http://people.debian.org/~rleigh/
 `. `'   schroot and sbuild  http://alioth.debian.org/projects/buildd-tools
   `-    GPG Public Key      F33D 281D 470A B443 6756 147C 07B3 C8BC 4083 E800



More information about the File-rc-users mailing list