Bug 1727581 - ovirt-ha-broker.service failed to start on HE deployment - NameError: global name '_use_importlib' is not defined
Summary: ovirt-ha-broker.service failed to start on HE deployment - NameError: global ...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-hosted-engine-ha
Classification: oVirt
Component: Broker
Version: 2.3.3
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ovirt-4.4.0
: 2.3.3
Assignee: Simone Tiraboschi
QA Contact: Nikolai Sednev
URL:
Whiteboard:
Depends On: 1795672
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-07-07 11:04 UTC by Evgeny Slutsky
Modified: 2020-05-20 20:01 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-05-20 20:01:16 UTC
oVirt Team: Integration
Embargoed:
sbonazzo: ovirt-4.4?


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 101572 0 None MERGED Fix a few regressions introduced with 94941 2021-01-13 13:53:33 UTC

Description Evgeny Slutsky 2019-07-07 11:04:59 UTC
Versions:
ovirt-hosted-engine-ha-2.4.0-0.0.master.20190704101347.20190704101342.gitb87bbee.el7.noarch
ovirt-ansible-engine-setup-1.1.10-0.1.master.20190613103539.el7.noarch
ovirt-hosted-engine-setup-2.4.0-0.0.master.20190703091031.git76f755f.el7.noarch



[root@hosted-engine ovirt-hosted-engine-ha]# systemctl status ovirt-ha-agent
● ovirt-ha-agent.service - oVirt Hosted Engine High Availability Monitoring Agent
   Loaded: loaded (/usr/lib/systemd/system/ovirt-ha-agent.service; disabled; vendor preset: disabled)
   Active: activating (auto-restart) (Result: exit-code) since Sun 2019-07-07 11:03:35 UTC; 1s ago
  Process: 32024 ExecStart=/usr/share/ovirt-hosted-engine-ha/ovirt-ha-agent (code=exited, status=1/FAILURE)
 Main PID: 32024 (code=exited, status=1/FAILURE)
    Tasks: 0
   CGroup: /system.slice/ovirt-ha-agent.service

Jul 07 11:03:35 hosted-engine systemd[1]: ovirt-ha-agent.service: main process exited, code=exited, status=1/FAILURE
Jul 07 11:03:35 hosted-engine systemd[1]: Unit ovirt-ha-agent.service entered failed state.
Jul 07 11:03:35 hosted-engine systemd[1]: ovirt-ha-agent.service failed.




ovirt-ha-broker service is unable to start, printing this error:

[root@hosted-engine ovirt-hosted-engine-ha]# /usr/share/ovirt-hosted-engine-ha/ovirt-ha-broker 
INFO:ovirt_hosted_engine_ha.broker.broker.Broker:ovirt-hosted-engine-ha broker 2.4.0-0.0.master.20190704101347 started
INFO:ovirt_hosted_engine_ha.broker.monitor.Monitor:Searching for submonitors in /usr/lib/python2.7/site-packages/ovirt_hosted_engine_ha/broker/submonitors
Traceback (most recent call last):
  File "/usr/share/ovirt-hosted-engine-ha/ovirt-ha-broker", line 25, in <module>
    broker.Broker().run()
  File "/usr/lib/python2.7/site-packages/ovirt_hosted_engine_ha/broker/broker.py", line 54, in run
    self._monitor_instance = self._get_monitor()
  File "/usr/lib/python2.7/site-packages/ovirt_hosted_engine_ha/broker/broker.py", line 119, in _get_monitor
    return monitor.Monitor()
  File "/usr/lib/python2.7/site-packages/ovirt_hosted_engine_ha/broker/monitor.py", line 38, in __init__
    self._discover_submonitors()
  File "/usr/lib/python2.7/site-packages/ovirt_hosted_engine_ha/broker/monitor.py", line 49, in _discover_submonitors
    if _use_importlib:
NameError: global name '_use_importlib' is not defined


this bug affecting  also ovirt-hosted-engine-setup.
[ ERROR ] fatal: [localhost]: FAILED! => {"attempts": 5, "changed": true, "cmd": ["hosted-engine", "--reinitialize-lockspace", "--force"], "delta": "0:00:01.159131", "end": "2019-07-07 09:37:49.962218", "msg": "non-zero return code", "rc": 1, "start": "2019-07-07 09:37:48.803087", "stderr": "Traceback (most recent call last):\n File \"/usr/lib64/python2.7/runpy.py\", line 162, in _run_module_as_main\n \"__main__\", fname, loader, pkg_name)\n File \"/usr/lib64/python2.7/runpy.py\", line 72, in _run_code\n exec code in run_globals\n File \"/usr/lib/python2.7/site-packages/ovirt_hosted_engine_setup/reinitialize_lockspace.py\", line 30, in <module>\n ha_cli.reset_lockspace(force)\n File \"/usr/lib/python2.7/site-packages/ovirt_hosted_engine_ha/client/client.py\", line 283, in reset_lockspace\n stats = broker.get_stats_from_storage()\n File \"/usr/lib/python2.7/site-packages/ovirt_hosted_engine_ha/lib/brokerlink.py\", line 146, in get_stats_from_storage\n result = self._proxy.get_stats()\n File \"/usr/lib64/python2.7/xmlrpclib.py\", line 1233, in __call__\n return self.__send(self.__name, args)\n File \"/usr/lib64/python2.7/xmlrpclib.py\", line 1591, in __request\n verbose=self.__verbose\n File \"/usr/lib64/python2.7/xmlrpclib.py\", line 1273, in request\n return self.single_request(host, handler, request_body, verbose)\n File \"/usr/lib64/python2.7/xmlrpclib.py\", line 1301, in single_request\n self.send_content(h, request_body)\n File \"/usr/lib64/python2.7/xmlrpclib.py\", line 1448, in send_content\n connection.endheaders(request_body)\n File \"/usr/lib64/python2.7/httplib.py\", line 1037, in endheaders\n self._send_output(message_body)\n File \"/usr/lib64/python2.7/httplib.py\", line 881, in _send_output\n self.send(msg)\n File \"/usr/lib64/python2.7/httplib.py\", line 843, in send\n self.connect()\n File \"/usr/lib/python2.7/site-packages/ovirt_hosted_engine_ha/lib/unixrpc.py\", line 63, in connect\n self.sock.connect(base64.b16decode(self.host))\n File \"/usr/lib64/python2.7/socket.py\", line 224, in meth\n return getattr(self._sock,name)(*args)\nsocket.error: [Errno 2] No such file or directory", "stderr_lines": ["Traceback (most recent call last):", " File \"/usr/lib64/python2.7/runpy.py\", line 162, in _run_module_as_main", " \"__main__\", fname, loader, pkg_name)", " File \"/usr/lib64/python2.7/runpy.py\", line 72, in _run_code", " exec code in run_globals", " File \"/usr/lib/python2.7/site-packages/ovirt_hosted_engine_setup/reinitialize_lockspace.py\", line 30, in <module>", " ha_cli.reset_lockspace(force)", " File \"/usr/lib/python2.7/site-packages/ovirt_hosted_engine_ha/client/client.py\", line 283, in reset_lockspace", " stats = broker.get_stats_from_storage()", " File \"/usr/lib/python2.7/site-packages/ovirt_hosted_engine_ha/lib/brokerlink.py\", line 146, in get_stats_from_storage", " result = self._proxy.get_stats()", " File \"/usr/lib64/python2.7/xmlrpclib.py\", line 1233, in __call__", " return self.__send(self.__name, args)", " File \"/usr/lib64/python2.7/xmlrpclib.py\", line 1591, in __request", " verbose=self.__verbose", " File \"/usr/lib64/python2.7/xmlrpclib.py\", line 1273, in request", " return self.single_request(host, handler, request_body, verbose)", " File \"/usr/lib64/python2.7/xmlrpclib.py\", line 1301, in single_request", " self.send_content(h, request_body)", " File \"/usr/lib64/python2.7/xmlrpclib.py\", line 1448, in send_content", " connection.endheaders(request_body)", " File \"/usr/lib64/python2.7/httplib.py\", line 1037, in endheaders", " self._send_output(message_body)", " File \"/usr/lib64/python2.7/httplib.py\", line 881, in _send_output", " self.send(msg)", " File \"/usr/lib64/python2.7/httplib.py\", line 843, in send", " self.connect()", " File \"/usr/lib/python2.7/site-packages/ovirt_hosted_engine_ha/lib/unixrpc.py\", line 63, in connect", " self.sock.connect(base64.b16decode(self.host))", " File \"/usr/lib64/python2.7/socket.py\", line 224, in meth", " return getattr(self._sock,name)(*args)", "socket.error: [Errno 2] No such file or directory"], "stdout": "", "stdout_lines": []}

Comment 1 Nikolai Sednev 2020-03-03 12:40:16 UTC
NFS deployment on these components:
rhvm-appliance.x86_64 2:4.4-20200123.0.el8ev rhv-4.4.0                                               
sanlock-3.8.0-2.el8.x86_64
qemu-kvm-4.2.0-12.module+el8.2.0+5858+afd073bc.x86_64
vdsm-4.40.5-1.el8ev.x86_64
libvirt-client-6.0.0-7.module+el8.2.0+5869+c23fe68b.x86_64
ovirt-hosted-engine-setup-2.4.2-2.el8ev.noarch
ovirt-hosted-engine-ha-2.4.2-1.el8ev.noarch
Linux 4.18.0-183.el8.x86_64 #1 SMP Sun Feb 23 20:50:47 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
Red Hat Enterprise Linux release 8.2 Beta (Ootpa)

Engine is software version:4.4.0-0.17.master.el7
Red Hat Enterprise Linux Server release 7.8 Beta (Maipo)
Linux 3.10.0-1123.el7.x86_64 #1 SMP Tue Jan 14 03:44:38 EST 2020 x86_64 x86_64 x86_64 GNU/Linux

Deployment went successfully and broker and ha-agent got started successfully.
Moving to verified.

Comment 2 Sandro Bonazzola 2020-05-20 20:01:16 UTC
This bugzilla is included in oVirt 4.4.0 release, published on May 20th 2020.

Since the problem described in this bug report should be
resolved in oVirt 4.4.0 release, it has been closed with a resolution of CURRENT RELEASE.

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


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