Bug 533891 - init script, parameter reload
init script, parameter reload
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: rhnsd (Show other bugs)
All Linux
high Severity high
: rc
: ---
Assigned To: Miroslav Suchý
Šimon Lukašík
Depends On:
Blocks: 533839 633349
  Show dependency treegraph
Reported: 2009-11-09 11:36 EST by Petr Sklenar
Modified: 2010-09-13 12:19 EDT (History)
5 users (show)

See Also:
Fixed In Version: rhnsd-4.9.2-2.el6
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2010-07-02 15:49:15 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Petr Sklenar 2009-11-09 11:36:56 EST
Description of three problems:
A. some strange stuff during reload
B. stop&reload - don't know this
C. force-reload

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

How reproducible:

Steps to Reproduce:
[root@xen83 ~]# /etc/init.d/rhnsd reload
[root@xen83 ~]# echo $?                                    [  OK  ]
Actual results:
It places [OK] in wrong line

Expected results:
Reloading Red Hat Network Daemon:       [OK]


stop and reload

[root@xen83 ~]# /etc/init.d/rhnsd stop
Stopping Red Hat Network Daemon:                           [  OK  ]
[root@xen83 ~]# /etc/init.d/rhnsd reload
[root@xen83 ~]# echo $?                                    [FAILED]

When service is stopped and you try reload then it writes [failed] but return code is zero. I am not sure what should be correct message and correct return code here. 

'force-reload' has to be there somehow
service rhnsd force-reload

actual result
echo $?=1, which is wrong

expected result
# if it is unimplemented then error code should be 3

Additional info:
see https://fedoraproject.org/wiki/Packaging/SysVInitScript
Comment 2 Miroslav Suchý 2010-02-10 05:41:43 EST
I could not reproduce behaviour described in A]

Correct behaviour for B] should be not write anything on output at all.

Best fix for C] would be implement force-reload.
Comment 3 Petr Sklenar 2010-02-10 06:01:55 EST
(In reply to comment #2)
> I could not reproduce behaviour described in A]

I still could see it with rhnsd-4.7.0-4.el5, is there some newer version?
[root@qa-psklenar ~]# /etc/init.d/rhnsd reload
[root@qa-psklenar ~]# #this is line after ---- >>>>>>>>    [  OK  ]
[root@qa-psklenar ~]# rpm -q rhnsd
Comment 4 Miroslav Suchý 2010-02-10 06:27:40 EST
re B] hmm some script do not write anything at all (sshd) some print [FAILURE] (httpd). I choose the second behaviour, but now it should return status code 7 which is:
7:	program is not running

Fixed in spacewalk git commits:
217731a7bcbb4c1966f00343e256a8b45359405b  (C part)
bc56ff799287f2a799a3fe4ae529e5f35ab03db4  (B part)

Not cherrypicking to rhel6 as we will be rebasing within a month.
Comment 5 Miroslav Suchý 2010-02-10 06:29:15 EST
Yes, in beta1 should go:
But yes, it is still not there. 
OK. I'm ignoring this part since rhnsd-4.8.1-2.el6.x86_64 obviously do not have this bug (A] part)
Comment 10 Šimon Lukašík 2010-04-28 07:44:16 EDT
Changing to VERIFIED

Testing procedure:
- automation on i386, x86_64
- manual run on x86_64, RHEL6.0-20100422.12

A] output on rhel6 is neat
Reloading Red Hat Network Daemon: [  OK  ]
B] 7 (program is not running) is returned
C] lsb force-reload is implemented

Verified against:
Comment 11 releng-rhel@redhat.com 2010-07-02 15:49:15 EDT
Red Hat Enterprise Linux Beta 2 is now available and should resolve
the problem described in this bug report. This report is therefore being closed
with a resolution of CURRENTRELEASE. You may reopen this bug report if the
solution does not work for you.

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