Bug 1017056

Summary: virt-who can't work in the VDSM mode
Product: Red Hat Enterprise Linux 6 Reporter: Liushihui <shihliu>
Component: virt-whoAssignee: Radek Novacek <rnovacek>
Status: CLOSED ERRATA QA Contact: John Sefler <jsefler>
Severity: urgent Docs Contact:
Priority: unspecified    
Version: 6.5CC: gxing, liliu, ovasik, qianzhan, rbalakri, sgao
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: virt-who-0.10-1.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-10-14 07:13:12 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Liushihui 2013-10-09 08:24:10 UTC
Description of problem:
During test the Rhel6.5 + Rhevm3.2(vdsm mode) against SAM1.3, after set the virt-who work under the VDSM Mode, virt-who cannot work.

Version-Release number of selected component (if applicable):
subscription-manager-1.9.7-1.el6.x86_64
python-rhsm-1.9.6-1.el6.x86_64
virt-who-0.8-9.el6.noarch
katello-headpin-1.4.3.19-1.el6sam_splice.noarch
candlepin-0.8.26-1.el6sam.noarch

How reproducible:
Always

Steps to Reproduce:
1. In the host, Set the virt-who parameters in file /etc/sysconfig/virt-who to make virt-who working in VDSM mode:
   VIRTWHO_DEBUG=1
   VIRTWHO_VDSM=1
   VIRTWHO_INTERVAL=10

2. Restart service virt-who
   # service virt-who restart
   Stopping virt-who:                                         [  OK  ]
   Starting virt-who:                                         [  OK  ]

3. Restart vdsmd service
   # service vdsmd restart
   Shutting down vdsm daemon: 
   vdsm watchdog stop                                         [  OK  ]
   vdsm stop                                                  [  OK  ]
   vdsm: libvirt already configured for vdsm                  [  OK  ]
   Starting iscsid: 
   Starting up vdsm daemon: 
   vdsm start                                                 [  OK  ]

4. check the log file:
   # tail -f /var/log/rhsm/rhsm.log

Actual results:
2013-10-09 15:43:48,010 [ERROR]  @virt-who.py:184 - Unable to recover, retry in 10 seconds.
2013-10-09 15:43:58,020 [ERROR]  @virt-who.py:181 - Unable to create connection:
Traceback (most recent call last):
  File "/usr/share/virt-who/virt-who.py", line 178, in _send
    self.checkConnections()
  File "/usr/share/virt-who/virt-who.py", line 157, in checkConnections
    self.initVirt()
  File "/usr/share/virt-who/virt-who.py", line 96, in initVirt
    self.virt = VDSM(self.logger)
  File "/usr/share/virt-who/vdsm.py", line 45, in __init__
    self._readConfig("/etc/vdsm/vdsm.conf")
  File "/usr/share/virt-who/vdsm.py", line 54, in _readConfig
    self.trust_store_path = parser.get("vars", "trust_store_path")
  File "/usr/lib64/python2.6/ConfigParser.py", line 541, in get
    raise NoOptionError(option, section)
NoOptionError: No option 'trust_store_path' in section: 'vars'

It hasn't sent the host/guest association to SAM server

Expected results:
virt-who should run normally under the VDSM mode, it should send the correct host/guest association to SAM server.

Additional info:

Comment 2 Radek Novacek 2013-10-09 10:47:50 UTC
You're missing 'trust_store_path' option in the 'vars' section of /etc/vdsm/vdsm.conf file.

Virt-who is missing the check for this exception, I'll add it - it's easy fix.

Comment 3 gaoshang 2013-10-21 09:50:35 UTC
(In reply to Radek Novacek from comment #2)
> You're missing 'trust_store_path' option in the 'vars' section of
> /etc/vdsm/vdsm.conf file.
> 
> Virt-who is missing the check for this exception, I'll add it - it's easy
> fix.

Hi Radek, I found this bug has been suggested to move to RHEL 6.6.0, but it blocked our virt-who test in vdsm mode for now, if it can not be fixed in RHEL 6.5, RHEL 6.5 will not support vdsm mode, is it as expected? 
If it's possible, I suggest to fix it in RHEL 6.5, thanks.

Comment 4 Radek Novacek 2013-10-21 10:18:18 UTC
I think it is too late for 6.5 fix. You can workaround this issue quite easily by adding 'trust_store_path' option to the 'vars' section in the /etc/vdsm/vdsm.conf file.

Comment 5 gaoshang 2013-10-22 08:35:08 UTC
(In reply to Radek Novacek from comment #4)
> I think it is too late for 6.5 fix. You can workaround this issue quite
> easily by adding 'trust_store_path' option to the 'vars' section in the
> /etc/vdsm/vdsm.conf file.

Got it, after adding "trust_store_path = /etc/pki/vdsm" to /etc/vdsm/vdsm.conf, we can test vdsm mode now, thanks.

Comment 6 Radek Novacek 2014-06-02 09:50:32 UTC
This bug is fixed upstream and will be resolved by rebase of virt-who, see bug 1002640.

Comment 7 Radek Novacek 2014-06-18 07:26:18 UTC
This bug is fixed by rebase to virt-who-0.10-1.el6.

Comment 9 Li Bin Liu 2014-08-27 14:22:17 UTC
Verification of this bug is blocked by vdsm installation issue in rhel6.6, sent mail to obasan who is the vdsm Errata 18458 owner with Radek cc'd for help, after the issue got resolved, we will verify this bug ASAP.

Comment 10 Liushihui 2014-08-29 06:32:08 UTC
Can't verify as bug 1135341

Comment 11 Liushihui 2014-09-05 06:52:39 UTC
Verified on virt-who-0.10-7.el6.noarch

Comment 12 errata-xmlrpc 2014-10-14 07:13:12 UTC
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/RHBA-2014-1513.html

Comment 13 xingge 2014-10-27 03:32:48 UTC
Though this bug is fixed in RHEL6.6, in RHEVH6.5 and this bug is still exist. And now we are testing RHEVH6.5 and this bug bothers us, What should we do to deal with this bug?