Bug 1389326

Summary: JSONRPC client should be properly configured out of the box
Product: [oVirt] vdsm Reporter: Shira Maximov <mshira>
Component: GeneralAssignee: Jenny Tokar <jtokar>
Status: CLOSED CURRENTRELEASE QA Contact: Shira Maximov <mshira>
Severity: medium Docs Contact:
Priority: high    
Version: 4.18.11CC: akrejcir, bugs, dfediuck, jtokar, mavital, mgoldboi, mshira
Target Milestone: ovirt-4.0.6Flags: rule-engine: ovirt-4.0.z+
rule-engine: ovirt-4.1+
mgoldboi: planning_ack+
rule-engine: devel_ack+
mavital: testing_ack+
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: No Doc Update
Doc Text:
undefined
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-01-18 07:29:10 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: SLA RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1373832, 1392986    

Description Shira Maximov 2016-10-27 12:59:40 UTC
Description of problem:
when Trying to change mom to work with json rpc 
( edit /etc/vdsm/mom.conf , set hypervisor-interface: vdsmjsonrpc) and restart mom service , the mom service can't start because there is incompatibility between VDSM and mom


var log messages : 
Oct 27 15:55:06 RHEL7 systemd: Failed to receive notification message: Resource temporarily unavailable
Oct 27 15:55:22 RHEL7 journal: vdsm MOM WARNING MOM not available.
Oct 27 15:55:22 RHEL7 journal: vdsm MOM WARNING MOM not available, KSM stats will be missing.
Oct 27 15:55:22 RHEL7 systemd: Failed to receive notification message: Resource temporarily unavailable
Oct 27 15:55:25 RHEL7 systemd: Failed to receive notification message: Resource temporarily unavailable


/etc/vdsm/mom.log
2016-10-27 14:59:24,242 - mom - ERROR - Failed to initialize MOM threads
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/mom/__init__.py", line 29, in run
    hypervisor_iface = self.get_hypervisor_interface()
  File "/usr/lib/python2.7/site-packages/mom/__init__.py", line 217, in get_hypervisor_interface
    return module.instance(self.config)
  File "/usr/lib/python2.7/site-packages/mom/HypervisorInterfaces/vdsmjsonrpcInterface.py", line 236, in instance
    return JsonRpcVdsmInterface()
  File "/usr/lib/python2.7/site-packages/mom/HypervisorInterfaces/vdsmjsonrpcInterface.py", line 42, in __init__
    self._vdsm_api = self.checked_call(jsonrpcvdscli.connect)\
  File "/usr/lib/python2.7/site-packages/mom/HypervisorInterfaces/vdsmjsonrpcInterface.py", line 221, in checked_call
    response = vdsm_method(*args, **kwargs)
TypeError: connect() takes at least 1 argument (0 given)


Version-Release number of selected component (if applicable):
mom-0.5.7-1.el7ev.noarch
mom-0.5.7-1.el7ev.noarch

How reproducible:
100%

Steps to Reproduce:
1. edit /etc/vdsm/mom.conf , set hypervisor-interface: vdsmjsonrpc
2. systemctl restart  mom-vdsm.service 
3.

Actual results:


Expected results:


Additional info:

Comment 1 Andrej Krejcir 2016-10-27 13:26:17 UTC
Backporting this patch should solve it:

https://gerrit.ovirt.org/#/c/62730

Comment 2 Martin Sivák 2016-10-27 13:42:27 UTC
The current implementation of jsonrpc client requires the user to pass in the stomp queue names. Those have to match the running VDSM and so the only way to do that was to parse VDSM config files. That is not really nice.. and I would expect the client to know what queues should be used (as it already does on master branch).

Comment 3 Dan Kenigsberg 2016-10-27 14:04:13 UTC
Which vdsm is used? If mom and vdsm of 4.0.5 are incompatible, it's a blocker.

Comment 4 Shira Maximov 2016-10-27 14:48:08 UTC
vdsm-4.18.15.2-1.el7ev.x86_64 

i'm not sure it's a blocker because it happens when trying to change to work with JSONRPC

Comment 5 Dan Kenigsberg 2016-10-30 07:11:24 UTC
I see that http://bob.eng.lab.tlv.redhat.com/builds/4.0/4.0.5-5/el7/noarch/ has mom-0.5.8. Does this bug reproduce with it?

Comment 6 Shira Maximov 2016-10-30 08:01:29 UTC
the bug doesn't reproduce with mom-0.5.8

Comment 7 Shira Maximov 2016-10-30 08:40:04 UTC
(In reply to Shira Maximov from comment #6)
> the bug doesn't reproduce with mom-0.5.8

ignore the last comment, i check with the wrong interface, 
the bug reproduce with mom 0.5.8 as well

Comment 8 Martin Sivák 2016-11-02 09:46:45 UTC
This is not a blocker for 4.0.5, because VDSM does not use the offending interface. But we want to use it in 4.0.6.

Comment 9 Shira Maximov 2016-11-22 12:17:37 UTC
mom-0.5.8-1.el7ev.noarch
vdsm-4.18.16-1.el7ev.x86_64

verification steps: 
2. make sure the interface is: vdsmjsonrpcbulk (/etc/vdsm/mom.conf)
3. running automation sanity test.