Bug 670106 - krb5 initscripts regression
Summary: krb5 initscripts regression
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: krb5
Version: 6.1
Hardware: Unspecified
OS: Unspecified
low
medium
Target Milestone: rc
: ---
Assignee: Nalin Dahyabhai
QA Contact: BaseOS QE Security Team
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-01-17 08:26 UTC by Zbysek MRAZ
Modified: 2013-11-04 10:58 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-01-18 15:15:16 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description Zbysek MRAZ 2011-01-17 08:26:40 UTC
Description of problem:
there is change in status codes for krb5kdc and kadmin
Results from 6.0
:: [   LOG    ] :: Lock file
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

:: [   PASS   ] :: Running 'kill -n 9 25399'
:: [   PASS   ] :: Running 'service kadmin status'
:: [   PASS   ] :: Running 'service kadmin stop'
:: [   LOG    ] :: Duration: 1s
:: [   LOG    ] :: Assertions: 3 good, 0 bad
:: [   PASS   ] :: RESULT: Lock file


And from 6.1 (krb5 1.9-1):

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [   LOG    ] :: Lock file
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

:: [   PASS   ] :: Running 'kill -n 9 6413'
:: [   FAIL   ] :: Running 'service krb5kdc status' (Expected 2, got 1)
:: [   PASS   ] :: Running 'service krb5kdc stop'
:: [   LOG    ] :: Duration: 3s
:: [   LOG    ] :: Assertions: 2 good, 1 bad
:: [   FAIL   ] :: RESULT: Lock file


Version-Release number of selected component (if applicable):
krb5-server-1.9-1.el6

How reproducible:
always

Steps to Reproduce:
1. kill -n 9 $(pidof ${SERVICE})
2. service ${SERVICE} status

  
Actual results:
service krb5kdc status; echo $?
krb5kdc dead but pid file exists
1

Expected results:
service krb5kdc status; echo $?
krb5kdc dead but pid file exists
2

Comment 1 Nalin Dahyabhai 2011-01-17 16:41:26 UTC
The two runs appear to have tested different things.  What happened with the krb5kdc init script on 6.0?

Comment 2 Nalin Dahyabhai 2011-01-17 20:27:28 UTC
(In reply to comment #0)
> Description of problem:
> there is change in status codes for krb5kdc and kadmin
> Results from 6.0
> :: [   LOG    ] :: Lock file
> ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
> 
> :: [   PASS   ] :: Running 'kill -n 9 25399'
> :: [   PASS   ] :: Running 'service kadmin status'
> :: [   PASS   ] :: Running 'service kadmin stop'
> :: [   LOG    ] :: Duration: 1s
> :: [   LOG    ] :: Assertions: 3 good, 0 bad
> :: [   PASS   ] :: RESULT: Lock file
> 
> 
> And from 6.1 (krb5 1.9-1):
> 
> ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
> :: [   LOG    ] :: Lock file
> ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
> 
> :: [   PASS   ] :: Running 'kill -n 9 6413'
> :: [   FAIL   ] :: Running 'service krb5kdc status' (Expected 2, got 1)
> :: [   PASS   ] :: Running 'service krb5kdc stop'
> :: [   LOG    ] :: Duration: 3s
> :: [   LOG    ] :: Assertions: 2 good, 1 bad
> :: [   FAIL   ] :: RESULT: Lock file
> 
> 
> Version-Release number of selected component (if applicable):
> krb5-server-1.9-1.el6
> 
> How reproducible:
> always
> 
> Steps to Reproduce:
> 1. kill -n 9 $(pidof ${SERVICE})
> 2. service ${SERVICE} status
> 
> 
> Actual results:
> service krb5kdc status; echo $?
> krb5kdc dead but pid file exists
> 1
> 
> Expected results:
> service krb5kdc status; echo $?
> krb5kdc dead but pid file exists
> 2

Can you double-check that the expected error message is about the pid file, and not about the subsys being locked?

When I try this manually with 1.8.2-3.el6_0.3, I get exit status 2 with a "process dead but subsys locked" error message.  In 1.9, where we start being able to tell krb5kdc and kadmind to create pid files, I do get an exit status of 1 and a "process dead but pid file exists error", which I guess is normal, because when there's a dead process, the status function checks for the existence of the pid file first.

Comment 3 Zbysek MRAZ 2011-01-18 15:15:16 UTC
You have right. My test was counting with nonexistence of pid files. The kadmin and krb5kdc scripts are behaving correctly. Even better now, when there is the pid file with the number of correct process.


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