Bug 474223 - chkconfig fails LSB init.d tests
chkconfig fails LSB init.d tests
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: chkconfig (Show other bugs)
10
All Linux
low Severity medium
: ---
: ---
Assigned To: Bill Nottingham
Fedora Extras Quality Assurance
: Reopened
: 522053 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-12-02 16:03 EST by Stew Benedict
Modified: 2014-03-16 23:16 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-03-09 16:04:46 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
re-enable initd tests 3,5, apply from /opt/lsb/test/core (888 bytes, patch)
2009-03-09 09:30 EDT, Stew Benedict
no flags Details | Diff

  None (edit)
Description Stew Benedict 2008-12-02 16:03:38 EST
Description of problem:
LSB, since 3.2, has a series of tests that check the functionality of the install_initd, remove_initd scripts. Systems based on Red Hat's chkconfig typically fail 2 of these tests, where a strict dependency on another service is involved.

Version-Release number of selected component (if applicable):
chkconfig-1.3.38-1

How reproducible:
100%

Steps to Reproduce:
1. install/run lsb-test-core: http://ftp.linuxfoundation.org/pub/lsb/repositories/yum/lsb-4.0/repo-ia32/lsb-test-core-3.97.0-1.i486.rpm
2. 
3.
  
Actual results:
/tset/initd/misc/install/general-tc 3 FAIL
/tset/initd/misc/install/general-tc 5 FAIL

Expected results:
All tests should pass

Additional info:
Some patches/mods were applied to chkconfig around 2005, when I did some work on this for Mandriva and sent it upstream. For a while Mandriva passed these tests, but they have since backed off some of the changes. A patch against 1.3.20 I used for LSB's SI build can be found here:

http://bzr.linux-foundation.org/lsb/devel/si?cmd=content;rev=stewb%40linux-foundation.org-20080428123712-jel9rr75eut4om30;pathrevid=pqm%40linux-foundation.org-20080620112025-scvq05mfzg74weym;path=build/patches/chkconfig-1.3.20-lsb-si.patch

Bug at the LSB end (with more journal detail):

http://bugs.linuxbase.org/show_bug.cgi?id=2443

Spec reference:
http://refspecs.linux-foundation.org/LSB_3.2.0/LSB-Core-generic/LSB-Core-generic/initscrcomconv.html
Comment 1 Bill Nottingham 2008-12-04 14:51:19 EST
Fixed in 1.3.39-1. You can follow the commits at http://git.fedorahosted.org/git/?p=chkconfig.git ; some of the code may be cleaned up later.

This is enabled *only* if it's called as install_initd/remove_initd; it's really bad behavior to do this in the general case.
Comment 2 Stew Benedict 2008-12-11 11:55:52 EST
Grabbed a git snapshot of 1.3.40 and built it to test on F10/x86_64, now test 3,4 fail:

/tset/initd/misc/install/general-tc 3 FAIL
/tset/initd/misc/install/general-tc 4 FAIL

ref:
http://git.fedorahosted.org/git/?p=chkconfig.git;a=snapshot;h=74ab891968c5ba0e5d43ab16c5edba578c425f62;sf=tgz
Comment 3 Bill Nottingham 2009-03-06 01:46:27 EST
Current git (as of 4ed064e287e2dd04290c7cc503b38e2f43693118) should solve both failures.

FYI - test #2 in the test suite is not really correct - an implementation could do all dependency resolution at runtime and ignore lexical sorting entirely. (Of course, I'm not sure there are any implementations that actually *do* this.)
Comment 4 Stew Benedict 2009-03-09 09:29:15 EDT
I'm still seeing issues using http://git.fedorahosted.org/git/?p=chkconfig.git;a=snapshot;h=bdef046f4feb0340e15bd02fbe45d7d1e3050405;sf=tgz

Built chkconfig on F10, x86_64 and ran just the init.d tests (I'll attach a patch to re-enable tests 3,5, which we've disabled due to this issue):

/tset/initd/misc/install/general-tc 2 FAIL
/tset/initd/misc/install/general-tc 5 FAIL

[root@fc10-64 test_sets]# /sbin/chkconfig --version
chkconfig version 1.3.42
[root@fc10-64 test_sets]# cat /etc/redhat-release 
Fedora release 10 (Cambridge)
[root@fc10-64 test_sets]# pwd
/opt/lsb/test/core/tet/test_sets
[root@fc10-64 test_sets]# cat scen.exec
all
        "total tests in LSBinitd 15"
        /tset/initd/misc/utils/utils-tc
        /tset/initd/misc/init-functions/init-functions-tc
        /tset/initd/misc/install/general-tc
Comment 5 Stew Benedict 2009-03-09 09:30:57 EDT
Created attachment 334515 [details]
re-enable initd tests 3,5, apply from /opt/lsb/test/core
Comment 6 Bill Nottingham 2009-03-09 16:04:46 EDT
Fixed. All the tests (run individually, setting up the test suite was too painful) pass for me.

http://git.fedorahosted.org/git/?p=chkconfig.git;a=commitdiff;h=fa16d756ce801b2dfbff25972f43989398ad5317
Comment 7 Stew Benedict 2009-03-10 14:04:25 EDT
Thanks, current git build also passed here.
Comment 8 Bill Nottingham 2010-03-16 15:39:11 EDT
*** Bug 522053 has been marked as a duplicate of this bug. ***

Note You need to log in before you can comment on or make changes to this bug.