Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 85678 - LSB-style dependency frobber works as expected in source code
Summary: LSB-style dependency frobber works as expected in source code
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: chkconfig
Version: 8.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Bill Nottingham
QA Contact: Ben Levenson
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2003-03-05 22:33 UTC by Tuomo Soini
Modified: 2014-03-17 02:34 UTC (History)
2 users (show)

Fixed In Version: 1.3.11-1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2004-06-04 21:00:34 UTC


Attachments (Terms of Use)
heartbeat 1.0.1 init-script (slightly modified) (deleted)
2003-03-05 22:38 UTC, Tuomo Soini
no flags Details


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2004:332 normal SHIPPED_LIVE Updated chkconfig package 2004-08-18 04:00:00 UTC
Red Hat Product Errata RHBA-2004:333 normal SHIPPED_LIVE Updated chkconfig package 2004-09-01 04:00:00 UTC

Description Tuomo Soini 2003-03-05 22:33:10 UTC
Description of problem:
When chkconfig --add heartbeat is run, links are done with names like:
S-1heartbeat which chkconfig doesn't understand itself so it doesn't guess start
order correctly.

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

How reproducible:
always

Steps to Reproduce:
1. chkconfig --add heartbeat
2. chkconfig --list heartbeat
3. chkconfig --del heartbeat
    
Actual results:
chkconfig calculates run order number -1 while when doing links into runlevel
directories.

Expected results:
chkconfig should have calculated number like 75

Additional info:
Multiline description field parser is broken too. It barfs when description is
wirtten to different line than Description: header. Like:

# Description:
#      Here comes exellent multi
#      line
#      description

Comment 1 Tuomo Soini 2003-03-05 22:38:07 UTC
Created attachment 90484 [details]
heartbeat 1.0.1 init-script (slightly modified)

Comment 2 Tobias Burnus 2003-07-08 18:36:58 UTC
Short LSB remark:
> # Required-Start: network time syslog
> # Required-Stop: network time syslog
This should be rather:
# Required-Start: $network $time $syslog

see http://www.linuxbase.org/spec/refspecs/LSB_1.3.0/gLSB/gLSB/facilname.html

Comment 3 Orion Poplawski 2004-04-20 22:44:18 UTC
LSB comments still broken in Fedora Core 1.  End up with S-1 and K-1
links.

Comment 4 Bodo Meissner 2004-06-04 11:13:59 UTC
Red Hat Enterprise Linux ES release 3 (Taroon)
chkconfig 1.3.8

I think I found the bug which causes LSB style dependencies to be ignored:

In chkconfig.c, function addService(), the if statement

    if (s.isLSB && (s.sPriority == s.kPriority == -1))
                frobDependencies(&s);
                                                                     
          
does not work. I think it would be true only if the comparison result
(s.sPriority == s.kPriority) is -1, but the result is 1. It does not
check whether both values are -1.

This should be replaced with

    if (s.isLSB && ((s.sPriority == -1) || (s.kPriority == -1)))
                frobDependencies(&s);
                                                                     
          
to call frobDependencies() if one of the priorities is not specified
in the script, or

    if (s.isLSB && (s.sPriority == -1) && (s.kPriority == -1))
                frobDependencies(&s);
                                                                     
          
to call frobDependencies() only if both priorities are not specified.


Bodo

Comment 5 Bill Nottingham 2004-06-04 21:00:34 UTC
Fixed in CVS, thanks!

Comment 6 John Flanagan 2004-08-18 15:13:11 UTC
An errata has been issued which should help the problem 
described in this bug report. This report is therefore being 
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files, 
please follow the link below. You may reopen this bug report 
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2004-332.html


Comment 7 Jay Turner 2004-09-02 03:28:38 UTC
An errata has been issued which should help the problem 
described in this bug report. This report is therefore being 
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files, 
please follow the link below. You may reopen this bug report 
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2004-333.html



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