Mailinglist Archive: opensuse-bugs (5774 mails)
| < Previous | Next > |
[Bug 627480] New: patch for /sbin/insserv: --recursive switch breaks backwards compatibility
- From: bugzilla_noreply@xxxxxxxxxx
- Date: Mon, 2 Aug 2010 14:34:24 +0000
- Message-id: <bug-627480-21960@xxxxxxxxxxxxxxxxxxxxxxxx/>
http://bugzilla.novell.com/show_bug.cgi?id=627480
http://bugzilla.novell.com/show_bug.cgi?id=627480#c0
Summary: patch for /sbin/insserv: --recursive switch breaks
backwards compatibility
Classification: openSUSE
Product: openSUSE 11.3
Version: Final
Platform: All
OS/Version: openSUSE 11.3
Status: NEW
Severity: Major
Priority: P5 - None
Component: Basesystem
AssignedTo: bnc-team-screening@xxxxxxxxxxxxxxxxxxxxxx
ReportedBy: stefan.wiese@xxxxxxxxxxxx
QAContact: qa@xxxxxxx
Found By: ---
Blocker: ---
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.2.7)
Gecko/20100713 Firefox/3.6.7 ( .NET CLR 3.5.30729)
using insserv-1.14.0-9.1.i586
feature
-e, --recursive Expand and enable all required services
does not work correct for all runlevels
assume xx1 requires xx2
Test is conducted in runlevel 3.
There are thre issues:
1st Issue: The created runlevel links are incomplete when resolving
dependencies.
This means not all links are created in all runlevels (see example below)
2nd Issue: -r, --remove Remove the listed scripts from all runlevels.
This is not working as documented. It is expected that if a services is removed
recursivly then all depending services are also disabled. This is not the case.
3rd Issue: man page of insserv is not uptodate (--recursive is used within
OpenSuse 11.3 but not documented in the man page)
There are two solution to this issue:
1. Fix --remove and --recursive if used together
2. disallow the usage of --recursive with --remove. Document this
incompatibility in the help() and man-page and issue an error message
(currently it fails silently!).
Reproducible: Always
Steps to Reproduce:
assume 1st /etc/init.d/xx1 requires xx2
assume 2nd /etc/init.d/xx2 provides xx2
# insserv -v -e xx1 <-- this is expected to enable xx1 with all dependencies
(xx2)
# insserv -v -r -e xx2 <-- this is expected to remove xx2 with all dependencies
(xx1)
Actual Results:
/etc/init.d # insserv -v -e xx1
insserv: enable service ../xx1 -> /etc/init.d/rc3.d/S02xx1
insserv: enable service ../xx1 -> /etc/init.d/rc3.d/K01xx1
insserv: enable service ../xx2 -> /etc/init.d/rc3.d/S01xx2
insserv: enable service ../xx2 -> /etc/init.d/rc3.d/K02xx2
insserv: enable service ../xx1 -> /etc/init.d/rc5.d/S02xx1
insserv: enable service ../xx1 -> /etc/init.d/rc5.d/K01xx1
insserv: creating .depend.boot
insserv: creating .depend.start
insserv: creating .depend.halt
insserv: creating .depend.stop
and
/etc/init.d # insserv -v -r -e xx2
insserv: FATAL: service xx2 has to be enabled to use service xx1
insserv: exiting now!
Expected Results:
1.
/etc/init.d # insserv -v -e xx1
insserv: enable service ../xx1 -> /etc/init.d/rc3.d/S02xx1
insserv: enable service ../xx1 -> /etc/init.d/rc3.d/K01xx1
insserv: enable service ../xx2 -> /etc/init.d/rc3.d/S01xx2
insserv: enable service ../xx2 -> /etc/init.d/rc3.d/K02xx2
insserv: enable service ../xx1 -> /etc/init.d/rc5.d/S02xx1
insserv: enable service ../xx1 -> /etc/init.d/rc5.d/K01xx1
insserv: enable service ../xx2 -> /etc/init.d/rc5.d/S02xx2
insserv: enable service ../xx2 -> /etc/init.d/rc5.d/K01xx2
insserv: creating .depend.boot
insserv: creating .depend.start
insserv: creating .depend.halt
insserv: creating .depend.stop
2.
/etc/init.d # insserv -v -r -e xx2
insserv: remove service /etc/init.d/rc3.d/S02xx1
insserv: remove service /etc/init.d/rc3.d/K01xx1
insserv: remove service /etc/init.d/rc3.d/S02xx2
insserv: remove service /etc/init.d/rc3.d/K01xx2
insserv: remove service /etc/init.d/rc5.d/S02xx1
insserv: remove service /etc/init.d/rc5.d/K01xx1
insserv: remove service /etc/init.d/rc5.d/S02xx2
insserv: remove service /etc/init.d/rc5.d/K01xx2
insserv: creating .depend.boot
insserv: creating .depend.start
insserv: creating .depend.halt
insserv: creating .depend.stop
3.
Man page fully documents the new feature --recursive.
4.
--recursive works for both adding and removing services
5.
--recursive works correctly for all runlevels (e.g. runlevel 3 and 5)
6.
The modification is integrated upstream.
The change as documented in
http://lists.opensuse.org/archive/opensuse-commit/2010-05/msg00029.html does
not only implement the new feature --recursive incompletly but breaks backwards
compatibility with other tools.
E.g. Kiwi implements its own recursion algorithm based on the text output from
insserv. The above modification to insserv modifies an existing string.
- warn("Service %s has to be enabled to start service %s\n",
+ warn("FATAL: service %s has to be enabled to use service %s\n",
This breaks other tools e.g. our beloved kiwi!
Note: Adding features to existing aaa_base tools shall always be backwards
compatible because numerous other tools are depending on it.
--
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=627480#c0
Summary: patch for /sbin/insserv: --recursive switch breaks
backwards compatibility
Classification: openSUSE
Product: openSUSE 11.3
Version: Final
Platform: All
OS/Version: openSUSE 11.3
Status: NEW
Severity: Major
Priority: P5 - None
Component: Basesystem
AssignedTo: bnc-team-screening@xxxxxxxxxxxxxxxxxxxxxx
ReportedBy: stefan.wiese@xxxxxxxxxxxx
QAContact: qa@xxxxxxx
Found By: ---
Blocker: ---
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.2.7)
Gecko/20100713 Firefox/3.6.7 ( .NET CLR 3.5.30729)
using insserv-1.14.0-9.1.i586
feature
-e, --recursive Expand and enable all required services
does not work correct for all runlevels
assume xx1 requires xx2
Test is conducted in runlevel 3.
There are thre issues:
1st Issue: The created runlevel links are incomplete when resolving
dependencies.
This means not all links are created in all runlevels (see example below)
2nd Issue: -r, --remove Remove the listed scripts from all runlevels.
This is not working as documented. It is expected that if a services is removed
recursivly then all depending services are also disabled. This is not the case.
3rd Issue: man page of insserv is not uptodate (--recursive is used within
OpenSuse 11.3 but not documented in the man page)
There are two solution to this issue:
1. Fix --remove and --recursive if used together
2. disallow the usage of --recursive with --remove. Document this
incompatibility in the help() and man-page and issue an error message
(currently it fails silently!).
Reproducible: Always
Steps to Reproduce:
assume 1st /etc/init.d/xx1 requires xx2
assume 2nd /etc/init.d/xx2 provides xx2
# insserv -v -e xx1 <-- this is expected to enable xx1 with all dependencies
(xx2)
# insserv -v -r -e xx2 <-- this is expected to remove xx2 with all dependencies
(xx1)
Actual Results:
/etc/init.d # insserv -v -e xx1
insserv: enable service ../xx1 -> /etc/init.d/rc3.d/S02xx1
insserv: enable service ../xx1 -> /etc/init.d/rc3.d/K01xx1
insserv: enable service ../xx2 -> /etc/init.d/rc3.d/S01xx2
insserv: enable service ../xx2 -> /etc/init.d/rc3.d/K02xx2
insserv: enable service ../xx1 -> /etc/init.d/rc5.d/S02xx1
insserv: enable service ../xx1 -> /etc/init.d/rc5.d/K01xx1
insserv: creating .depend.boot
insserv: creating .depend.start
insserv: creating .depend.halt
insserv: creating .depend.stop
and
/etc/init.d # insserv -v -r -e xx2
insserv: FATAL: service xx2 has to be enabled to use service xx1
insserv: exiting now!
Expected Results:
1.
/etc/init.d # insserv -v -e xx1
insserv: enable service ../xx1 -> /etc/init.d/rc3.d/S02xx1
insserv: enable service ../xx1 -> /etc/init.d/rc3.d/K01xx1
insserv: enable service ../xx2 -> /etc/init.d/rc3.d/S01xx2
insserv: enable service ../xx2 -> /etc/init.d/rc3.d/K02xx2
insserv: enable service ../xx1 -> /etc/init.d/rc5.d/S02xx1
insserv: enable service ../xx1 -> /etc/init.d/rc5.d/K01xx1
insserv: enable service ../xx2 -> /etc/init.d/rc5.d/S02xx2
insserv: enable service ../xx2 -> /etc/init.d/rc5.d/K01xx2
insserv: creating .depend.boot
insserv: creating .depend.start
insserv: creating .depend.halt
insserv: creating .depend.stop
2.
/etc/init.d # insserv -v -r -e xx2
insserv: remove service /etc/init.d/rc3.d/S02xx1
insserv: remove service /etc/init.d/rc3.d/K01xx1
insserv: remove service /etc/init.d/rc3.d/S02xx2
insserv: remove service /etc/init.d/rc3.d/K01xx2
insserv: remove service /etc/init.d/rc5.d/S02xx1
insserv: remove service /etc/init.d/rc5.d/K01xx1
insserv: remove service /etc/init.d/rc5.d/S02xx2
insserv: remove service /etc/init.d/rc5.d/K01xx2
insserv: creating .depend.boot
insserv: creating .depend.start
insserv: creating .depend.halt
insserv: creating .depend.stop
3.
Man page fully documents the new feature --recursive.
4.
--recursive works for both adding and removing services
5.
--recursive works correctly for all runlevels (e.g. runlevel 3 and 5)
6.
The modification is integrated upstream.
The change as documented in
http://lists.opensuse.org/archive/opensuse-commit/2010-05/msg00029.html does
not only implement the new feature --recursive incompletly but breaks backwards
compatibility with other tools.
E.g. Kiwi implements its own recursion algorithm based on the text output from
insserv. The above modification to insserv modifies an existing string.
- warn("Service %s has to be enabled to start service %s\n",
+ warn("FATAL: service %s has to be enabled to use service %s\n",
This breaks other tools e.g. our beloved kiwi!
Note: Adding features to existing aaa_base tools shall always be backwards
compatible because numerous other tools are depending on it.
--
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
| < Previous | Next > |