VMware driver:reconnection didn't work

Bug #1495887 reported by xhzhf
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
oslo.vmware
Incomplete
Undecided
xhzhf

Bug Description

version:
Juno 2014.2.1

Detailed Process:
1. nova-compute can not connect to rabbitMQ and nova-compute does not execute any regular task because of some reason.
2. the session will expire after a few hours.
3. regular task collects nodes hardware info and fail
4. nova-compute try to judge session is active
5._is_current_session_active will get faultmsg.
6.when executing str(msg), msg is encoded by utf-8, my vCenter is chinese version. so throw UnicodeEncodeError
7.reconnection will not work. Then we have to restart nova-compute

Stack:
TRACE oslo.vmware.api Traceback (most recent call last):
TRACE oslo.vmware.api File "/usr/lib/python2.7/site-packages/oslo/vmware/api.py", line 94, in _func
TRACE oslo.vmware.api result = f(*args, **kwargs)
TRACE oslo.vmware.api File "/usr/lib/python2.7/site-packages/oslo/vmware/api.py", line 298, in _invoke_api
TRACE oslo.vmware.api if self._is_current_session_active():
TRACE oslo.vmware.api File "/usr/lib/python2.7/site-packages/oslo/vmware/api.py", line 354, in _is_current_session_active
TRACE oslo.vmware.api userName=self._session_username)
TRACE oslo.vmware.api File "/usr/lib/python2.7/site-packages/oslo/vmware/service.py", line 197, in request_handler
TRACE oslo.vmware.api excep, details)
TRACE oslo.vmware.api File "/usr/lib/python2.7/site-packages/oslo/vmware/exceptions.py", line 81, in __init__
TRACE oslo.vmware.api super(VimFaultException, self).__init__(message, cause)
TRACE oslo.vmware.api File "/usr/lib/python2.7/site-packages/oslo/vmware/exceptions.py", line 52, in __init__
TRACE oslo.vmware.api self.msg = str(message)
TRACE oslo.vmware.api UnicodeEncodeError: 'ascii' codec can't encode characters in position 0-10: ordinal not in range(128)

Suggested Solution:
when logging to vCenter, we set local to 'en'. we will not encounter encode/decode problem.

xhzhf (guoyongxhzhf)
Changed in nova:
assignee: nobody → xhzhf (guoyongxhzhf)
affects: nova → oslo.vmware
Revision history for this message
Eric Brown (ericwb) wrote :

What version of oslo.vmware are you using? I couldn't match the line numbers with any recent release.

Changed in oslo.vmware:
status: New → Incomplete
Revision history for this message
xhzhf (guoyongxhzhf) wrote :

The version is 2014.2.1

description: updated
Revision history for this message
xhzhf (guoyongxhzhf) wrote :

I read recent codes. I believe the problem still exists.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.