Bug #78317 Error when configuring Enterprise Backup: 'utf8' codec can't decode byte 0xea
Submitted: 3 Sep 2015 19:24 Modified: 24 Nov 2016 21:49
Reporter: Nicolas De Rico Email Updates:
Status: No Feedback Impact on me:
None 
Category:MySQL Workbench: Administration Severity:S2 (Serious)
Version:6.3.4 OS:MacOS (10.10.5)
Assigned to: CPU Architecture:Any
Tags: Backup, utf8, workbench

[3 Sep 2015 19:24] Nicolas De Rico
Description:
11:30:59 [ERR][wb_admin_main.py:tab_changed:198]: Unhandled exception in Admin for <wba_meb.wb_admin_meb.WbAdminEnterpriseBackup; proxy of <Swig Object of type 'mforms::Box *' at 0x11d9f5450> >: Traceback (most recent call last):
  File "/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wb_admin_main.py", line 195, in tab_changed
    panel.page_activated()
  File "/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wba_meb/wb_admin_meb.py", line 74, in page_activated
    self.create_ui()
  File "/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wba_meb/wb_admin_meb.py", line 35, in create_ui
    if super(WbAdminEnterpriseBackup, self).create_ui():
  File "/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wba_meb/wb_admin_meb_common.py", line 2358, in create_ui
    self.context.init_config()
  File "/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wba_meb/wb_admin_meb_common.py", line 139, in init_config
    self.helper_handler = WBMEBHelperHandlerLinux(self)
  File "/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wba_meb/wb_admin_meb_common.py", line 323, in __init__
    super(WBMEBHelperHandlerLinux, self).__init__(context)
  File "/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wba_meb/wb_admin_meb_common.py", line 207, in __init__
    self._detect()
  File "/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wba_meb/wb_admin_meb_common.py", line 252, in _detect
    self.found_helper_version = self.get_helper_version()
  File "/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wba_meb/wb_admin_meb_common.py", line 352, in get_helper_version
    ret_code = self._context.ctrl_be.server_helper.execute_command(version_command, as_user = self._context.mysql_user, user_password = self._context.ctrl_be.password_handler.get_password_for("file"), output_handler = output.write)
  File "/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wb_server_management.py", line 1981, in execute_command
    return self.shell.exec_cmd(command, as_user, user_password, output_handler, options)
  File "/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wb_server_management.py", line 564, in exec_cmd
    output_handler=handler, options=options)
  File "/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wb_server_management.py", line 151, in exec_cmd
    options = options)
  File "/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wb_admin_ssh.py", line 871, in exec_cmd
    log_debug3("%s.exec_cmd(cmd=%s, output=%s. Retcode = %s)\n" % (self.__class__.__name__.encode('utf8'), cmd.encode('utf8'), out.decode('utf8'), ret_code) )
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/encodings/utf_8.py", line 16, in decode
    return codecs.utf_8_decode(input, errors, True)
UnicodeDecodeError: 'utf8' codec can't decode byte 0xea in position 2: invalid continuation byte

How to repeat:
MySQL Enterprise Workbench is running on a Mac.  MySQL server 5.6.26 and enterprise backup 3.12.1 are running remotely on a Linux machine.

Workbench has been upgraded many times before and it seems to use Python 2.7. On the other hand, the Linux machine is brand new and this is a fresh install of MySQL and Enterprise Backup as well.

In MySQL Enterprise Workbench, I created a new connection to the MySQL server and attempted to configure the remote Enterprise backup management.  The workbench UI successfully created the backup directory and the backup mysql user.  Upon pressing OK to save the settings, the aforementioned error appeared.

Suggested fix:
In the Workbench installation folder, I changed line 873 of mysqlwbmeb.py (function MEBHelperVersion):

          self.write_output(md5.digest())
To:
          self.write_output(md5.hexdigest())

That seems to have fixed the issue.

PS: I had to delete/rename mysqlwbmeb.pyc to cause the change to take effect in Workbench.
[24 Oct 2016 21:49] MySQL Verification Team
Please try version 6.3.8. Thanks.
[25 Nov 2016 1:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".