Bug 853892 - Can't start the hypervkvpd service with "service hypervkvpd start" on the hyper-v guest
Can't start the hypervkvpd service with "service hypervkvpd start" on the hyp...
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: hypervkvpd (Show other bugs)
5.9
Unspecified Unspecified
high Severity high
: rc
: ---
Assigned To: Tomáš Hozza
Virtualization Bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-09-03 05:16 EDT by Shengnan Wang
Modified: 2013-01-08 02:49 EST (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Cause: The rh_status() function in initscript, which is called when starting the daemon allways returned "true". Consequence: The daemon was not started by commands "service hypervkvpd start" or "/etc/init.d/hypervkvpd start". Fix: Changed rh_status() function in initscript, so that it explicitly returns the daemon status. Result: The daemon can now be started by commands "service hypervkvpd start" or "/etc/init.d/hypervkvpd start".
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-01-08 02:49:08 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Shengnan Wang 2012-09-03 05:16:15 EDT
Description of problem:
The hypervkvpd service in the RHEL5.9 guest can't be started by the commands "service hypervkvpd start" and "/etc/init.d/hypervkvpd start". Details:

[root@localhost ~]# service hypervkvpd status
hv_kvp_daemon is stopped
[root@localhost ~]# service hypervkvpd start
[root@localhost ~]# service hypervkvpd status
hv_kvp_daemon is stopped
[root@localhost ~]# /etc/init.d/hypervkvpd start
[root@localhost ~]# service hypervkvpd status
hv_kvp_daemon is stopped

Got the result as below when run with "-x":
...
+ HV_KVP_BIN=/usr/sbin/hv_kvp_daemon
+ lockfile=/var/lock/subsys/hypervkvpd
+ test -x /usr/sbin/hv_kvp_daemon
+ case "$1" in
+ rh_status_q
+ rh_status
+ exit 0
...

There is an redundant line in the rh_status function, which makes the status of rh_status_q always true.
Below update make the problem fixed:

 rh_status() {
         # run checks to determine if the service is running or use generic status
         status $HV_KVP_BIN
-        RETVAL=$?
+        #RETVAL=$?
 }

Version-Release number of selected component (if applicable):
Host: Windows 2008 R2 Hyper-V 
Hyper-V Version: 6.1.7600.16385
Guest: Both RHEL5.9 i386 & RHEL5.9 x86_64 (2.6.18-339.el5)
Hypervkvpd package Name: hypervkvpd-0-0.5.el5
Pv drivers: 
[root@localhost ~]# lsmod |grep hv_*
hv_netvsc              25665  0 
hid_base_hv            68177  1 hid_hyperv
hv_utils               12001  0 
hv_storvsc             17601  2 
hv_vmbus               30265  4 hv_netvsc,hid_hyperv,hv_utils,hv_storvsc


How reproducible:
100%

Steps to Reproduce:

1.Install hypervkvpd-0-0.5.el5 in the 2.6.18-339.el5 guest on Hyper-V host.
[root@localhost ~]# rpm -q hypervkvpd
hypervkvpd-0-0.5.el5

2.Start the service via "service hypervkvpd start".
3.Check the status of the service hypervkvpd and Start the service via  "/etc/init.d/hypervkvpd start"
4.Check the status of the service hypervkvpd.


Actual results:

At step 3 and the step 4, the service hypervkvpd is stopped. Details:
[root@localhost ~]# service hypervkvpd status
hv_kvp_daemon is stopped

Expected results:
At step 3 and the step 4, the service hypervkvpd is running. 

Additional info:
1. The commands "/etc/init.d/hypervkvpd restart" and "service hypervkvpd restart" are useful to start the service hypervkvpd.
Comment 1 RHEL Product and Program Management 2012-09-03 05:28:50 EDT
This request was evaluated by Red Hat Product Management for inclusion
in a Red Hat Enterprise Linux release.  Product Management has
requested further review of this request by Red Hat Engineering, for
potential inclusion in a Red Hat Enterprise Linux release for currently
deployed products.  This request is not yet committed for inclusion in
a release.
Comment 3 Tomáš Hozza 2012-09-03 07:16:39 EDT
I fixed the initscript so that rh_status() function explicitly returns the RETVAL value. Can you please test this scratch build?

https://brewweb.devel.redhat.com/taskinfo?taskID=4823691

Thanks.
Comment 4 Tomáš Hozza 2012-09-03 07:19:40 EDT
(In reply to comment #3)
> https://brewweb.devel.redhat.com/taskinfo?taskID=4823691

Sorry, wrong link. The right one is:
https://brewweb.devel.redhat.com/taskinfo?taskID=4823687
Comment 5 Shengnan Wang 2012-09-03 23:04:26 EDT
(In reply to comment #4)
> (In reply to comment #3)
> > https://brewweb.devel.redhat.com/taskinfo?taskID=4823691
> 
> Sorry, wrong link. The right one is:
> https://brewweb.devel.redhat.com/taskinfo?taskID=4823687

Test it on both i386 guest and x86_64 guest with the new package (hypervkvpd-0-0.6.el5). The commands "service hypervkvpd start" and "/etc/init.d/hypervkvpd start" work well.




Thanks!
Comment 7 Shengnan Wang 2012-09-06 01:47:42 EDT
(In reply to comment #5)
> (In reply to comment #4)
> > (In reply to comment #3)
> > > https://brewweb.devel.redhat.com/taskinfo?taskID=4823691
> > 
> > Sorry, wrong link. The right one is:
> > https://brewweb.devel.redhat.com/taskinfo?taskID=4823687
> 
> Test it on both i386 guest and x86_64 guest with the new package
> (hypervkvpd-0-0.6.el5). The commands "service hypervkvpd start" and
> "/etc/init.d/hypervkvpd start" work well.
> 
> 
> 
> 
> Thanks!

So change the status to verified.
Comment 9 errata-xmlrpc 2013-01-08 02:49:08 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHEA-2013-0111.html

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