Bug 1071576 - Mysql-Workbench 6.3.9-2.4 does not connect to server
Mysql-Workbench 6.3.9-2.4 does not connect to server
Status: RESOLVED FIXED
Classification: openSUSE
Product: openSUSE Tumbleweed
Classification: openSUSE
Component: Other
Current
x86-64 Other
: P5 - None : Critical with 5 votes (vote)
: ---
Assigned To: Martin Pluskal
E-mail List
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2017-12-06 16:42 UTC by Daniele Granata
Modified: 2018-03-14 13:27 UTC (History)
6 users (show)

See Also:
Found By: ---
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Daniele Granata 2017-12-06 16:42:43 UTC
Hi
after the last tumbleweed upgrade Mysql-workbench does not connect to any db server with the following error message:
Unsupported option provided to mysql_options()

Reproducible: always

Way to reproduce:
click on a saved connection
or 
create a new connection and click on test Connection.

What will expect:
the program should connect to the server.

What happens instead:
the program pops up an error message "Unsupported option provided to mysql_options()"

Note:
connecting to the same server using my own client compiled against the qt sql library libqt5sql5 works.

Maybe related:
Kate SQL plugin does not works too, it returns "Plugin pvio_socket could not be loaded"

Cheers
Daniele
Comment 1 Martin Pluskal 2017-12-07 13:13:39 UTC
I would expect this to be related to recent switch to mariadb-connector-c
Comment 2 Kristyna Streitova 2017-12-08 15:52:15 UTC
It seems that "Unsupported option provided to mysql_options()" message comes from mysql-connector-cpp package (files driver/nativeapi/libmysql_static_proxy.cpp or driver/nativeapi/libmysql_dynamic_proxy.cpp). But I'm not sure what is wrong yet.

However, while I was checking the mysql-workbench package I noticed at least two problems as libmariadb from mariadb-connector-c doesn't define MARIADB_BASE_VERSION anymore. This causes that these two patches don't work as intended:

1) mysql-workbench-mysql_options4.patch
This patch can be removed as MariaDB provides mysql_option4 function since the version 10.0.14.

2) mariadb-no-escape-string-quote.patch
This patch needs to be adjusted.
Comment 3 Martin Pluskal 2017-12-11 08:05:25 UTC
(In reply to Kristyna Streitova from comment #2)
> It seems that "Unsupported option provided to mysql_options()" message comes
> from mysql-connector-cpp package (files
> driver/nativeapi/libmysql_static_proxy.cpp or
> driver/nativeapi/libmysql_dynamic_proxy.cpp). But I'm not sure what is wrong
> yet.
> 
> However, while I was checking the mysql-workbench package I noticed at least
> two problems as libmariadb from mariadb-connector-c doesn't define
> MARIADB_BASE_VERSION anymore. This causes that these two patches don't work
> as intended:
> 
> 1) mysql-workbench-mysql_options4.patch
> This patch can be removed as MariaDB provides mysql_option4 function since
> the version 10.0.14.
> 
> 2) mariadb-no-escape-string-quote.patch
> This patch needs to be adjusted.

Ah thanks for noticing - will look at it.
Comment 4 Martin Pluskal 2018-01-25 13:26:25 UTC
Does the issue still occur?
Comment 5 Daniele Granata 2018-01-25 18:10:12 UTC
hi
I'm on Tumbleweed 20180124-1.2
Mariadb 10.2.12-1.1
libmysqlcppconn7 1.1.9-2.2
mysql-workbench 6.3.10-1.2

and no progress were made so far, nothing changed, the bug is still here.

Hope a solution will emerge soon.
Comment 6 Christos Gourdoupis 2018-01-28 19:05:34 UTC
(In reply to Martin Pluskal from comment #4)

Yes, workbench is useless.
Comment 7 Radisa Ilic 2018-01-29 10:22:46 UTC
(In reply to Daniele Granata from comment #5)
> hi
> I'm on Tumbleweed 20180124-1.2
> Mariadb 10.2.12-1.1
> libmysqlcppconn7 1.1.9-2.2
> mysql-workbench 6.3.10-1.2
> 
> and no progress were made so far, nothing changed, the bug is still here.
> 
> Hope a solution will emerge soon.

(In reply to Martin Pluskal from comment #3)
> (In reply to Kristyna Streitova from comment #2)
> > It seems that "Unsupported option provided to mysql_options()" message comes
> > from mysql-connector-cpp package (files
> > driver/nativeapi/libmysql_static_proxy.cpp or
> > driver/nativeapi/libmysql_dynamic_proxy.cpp). But I'm not sure what is wrong
> > yet.
> > 
> > However, while I was checking the mysql-workbench package I noticed at least
> > two problems as libmariadb from mariadb-connector-c doesn't define
> > MARIADB_BASE_VERSION anymore. This causes that these two patches don't work
> > as intended:
> > 
> > 1) mysql-workbench-mysql_options4.patch
> > This patch can be removed as MariaDB provides mysql_option4 function since
> > the version 10.0.14.
> > 
> > 2) mariadb-no-escape-string-quote.patch
> > This patch needs to be adjusted.
> 
> Ah thanks for noticing - will look at it.

(In reply to Martin Pluskal from comment #4)
> Does the issue still occur?

Yes, and this problem exists since months on ALL OpenSuse distros (including Leap 42.3 as example).

Problem is triggered with installation of package libmariadb-devel which removes libmysqlclient-devel and libmysqlclient_r18 and links libmysqlclient_r to libmariadb.

On Leap 42.3 this is not big issue because we still have available libmysql and by simple blocking libmariadb-devel everything works fine, but on Thumbleweed and Leap 15.0 there are no libmysql packages at all which makes mysql-workbench totally unusable. 

The general question is how good idea is to force Oracle tools to work with MariaDB libraries
Comment 8 Martin Pluskal 2018-01-29 13:50:35 UTC
(In reply to Radisa Ilic from comment #7)
> (In reply to Daniele Granata from comment #5)
> > hi
> > I'm on Tumbleweed 20180124-1.2
> > Mariadb 10.2.12-1.1
> > libmysqlcppconn7 1.1.9-2.2
> > mysql-workbench 6.3.10-1.2
> > 
> > and no progress were made so far, nothing changed, the bug is still here.
> > 
> > Hope a solution will emerge soon.
> 
> (In reply to Martin Pluskal from comment #3)
> > (In reply to Kristyna Streitova from comment #2)
> > > It seems that "Unsupported option provided to mysql_options()" message comes
> > > from mysql-connector-cpp package (files
> > > driver/nativeapi/libmysql_static_proxy.cpp or
> > > driver/nativeapi/libmysql_dynamic_proxy.cpp). But I'm not sure what is wrong
> > > yet.
> > > 
> > > However, while I was checking the mysql-workbench package I noticed at least
> > > two problems as libmariadb from mariadb-connector-c doesn't define
> > > MARIADB_BASE_VERSION anymore. This causes that these two patches don't work
> > > as intended:
> > > 
> > > 1) mysql-workbench-mysql_options4.patch
> > > This patch can be removed as MariaDB provides mysql_option4 function since
> > > the version 10.0.14.
> > > 
> > > 2) mariadb-no-escape-string-quote.patch
> > > This patch needs to be adjusted.
> > 
> > Ah thanks for noticing - will look at it.
> 
> (In reply to Martin Pluskal from comment #4)
> > Does the issue still occur?
> 
> Yes, and this problem exists since months on ALL OpenSuse distros (including
> Leap 42.3 as example).
That is horrible. Anyways see https://lists.opensuse.org/opensuse-factory/2018-01/msg00657.html
Comment 9 Martin Szulecki 2018-02-06 01:30:06 UTC
The apperently "unsupported" option is MYSQL_OPT_SSL_MODE which is not defined for MariaDB (and it's connector):
https://github.com/MariaDB/server/blob/10.3/include/mysql.h#L172
but it is for MySQL:
https://github.com/mysql/mysql-server/blob/5.7/include/mysql.h#L146

Thus when mysql-workbench attempts to use this option it will obviously fail with MariaDB's connector.

The current fix in "service:databases", which just ignores SSL settings, makes connecting work again.

I am not sure if the option "OPT_CAN_HANDLE_EXPIRED_PASSWORDS" has to be removed, too though.
Comment 10 Daniele Granata 2018-02-07 07:36:07 UTC
Hi there,
from yesterday I'm using the connector and mysql-workbench from this repository:

https://download.opensuse.org/repositories/home:/NickLion:/java/
openSUSE_Tumbleweed/

Mysql-workbench works now.

Thank you Mykola Krachkovsky.

Kate SQL plugin still does not work, so the problem is not correlated. I will open another bug or search for an existing one.

Cheers
Comment 11 Martin Pluskal 2018-03-14 13:27:05 UTC
Issue was fixed thanks to new mainteiner