Bug 523434 - initscript collected problems LSB-compilant ldap
Summary: initscript collected problems LSB-compilant ldap
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: openldap
Version: rawhide
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Jan Zeleny
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: 523431 (view as bug list)
Depends On:
Blocks: InitScriptsProject
TreeView+ depends on / blocked
 
Reported: 2009-09-15 13:50 UTC by Jan Ščotka
Modified: 2009-10-07 13:54 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-10-07 13:54:12 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Jan Ščotka 2009-09-15 13:50:43 UTC
There are some problems with LSB-compilants of initscript against
https://fedoraproject.org/wiki/Packaging/SysVInitScript definition.

service: ldap

I've created some test and there is output of run (PASS menas that it started correctly, FAIL, that there is some problem with returncode, explanaition in brackets):

:: [   LOG    ] :: >>>>>>>>> service start
:: [   PASS   ] ::  Service must start without problem
:: [   PASS   ] ::  Then Status command 
:: [   PASS   ] ::  Already started service 
:: [   PASS   ] ::  Again status command 
:: [   LOG    ] :: >>>>>>>>> service restart
:: [   PASS   ] ::  Restarting of service
:: [   PASS   ] ::  Status command 
:: [   LOG    ] :: >>>>>>>>> service stop
:: [   PASS   ] ::  Stopping service 
:: [   PASS   ] ::  Status of stopped service 
:: [   PASS   ] ::  Stopping service again 
:: [   PASS   ] ::  Status of stopped service 
:: [   LOG    ] :: >>>>>>>>> pid file
:: [   FAIL   ] :: File /var/run/ldap.pid should exist 
:: [   PASS   ] :: Running 'echo 666666 > /var/run/ldap.pid'
:: [   FAIL   ] ::  Existing pid file, but service not started  (Expected 1, got 3)
:: [   LOG    ] :: >>>>>>>>> lock file
:: [   PASS   ] :: File /var/lock/subsys/ldap should exist
:: [   PASS   ] :: Running 'touch /var/lock/subsys/ldap'
:: [   FAIL   ] ::  Existing lock file, but service not started  (Expected 2, got 3)
:: [   LOG    ] :: >>>>>>>>> insufficient rights
:: [   PASS   ] ::  Starting service for restarting under nonpriv user 
:: [   FAIL   ] :: Insufficient rights, restarting resrvice under nonprivileged user must fail (Expected 4, got 6)
:: [   LOG    ] :: >>>>>>>>> operations
:: [   PASS   ] ::  Service have to implement start function 
:: [   PASS   ] ::  Service have to implement restart function 
:: [   PASS   ] ::  Service have to implement status function 
:: [   FAIL   ] ::  Service have to implement usage function  (Expected 0, got 2)
:: [   PASS   ] ::  Service have to implement condrestart function 
:: [   PASS   ] ::  Service have to implement try-restart function 
:: [   FAIL   ] ::  Service have to implement reload function  (Expected 0, got 2)
:: [   PASS   ] ::  Service have to implement force-reload function 
:: [   LOG    ] :: >>>>>>>>> nonexist operations
:: [   PASS   ] ::  Testing proper return code when nonexisting function
:: [   LOG    ] :: >>>>>>>>> invalid arguments
:: [   PASS   ] ::  When no arguments added to service, it must fail with proper return code 


There are some problems:
* when pid file exist and service is not run, it must have returncode 1, pid file in LSB path doesnt exist
* lock file exist, but when service is stopped and lock file exist , there should be returncode 2
* working under unprevileged user must return 4
* it should implement usage, reload functions, or return code when it isnt implemented (3)

Comment 1 Jan Zeleny 2009-09-15 15:06:28 UTC
*** Bug 523431 has been marked as a duplicate of this bug. ***

Comment 2 Jan Zeleny 2009-09-24 14:21:50 UTC
Fixes should be in rawhide (version 2.4.18-3), could you please check it out, if it's ok?

Comment 3 Jan Zeleny 2009-10-07 13:54:12 UTC
I checked it manually according to listed issues. Everything ok, closing the bug.


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