Bug #101464 Connector / Python 8.0.22 introduced dependency incompatible with Server 5.7
Submitted: 4 Nov 2020 22:02 Modified: 5 Nov 2020 14:01
Reporter: Rüdiger Lincke Email Updates:
Status: Closed Impact on me:
None 
Category:Connector / Python Severity:S2 (Serious)
Version:8.0.22 OS:CentOS (7.8)
Assigned to: CPU Architecture:Any

[4 Nov 2020 22:02] Rüdiger Lincke
Description:
I am using Python 2.7 to connect to a MySql 5.7 database using mysql-connector-python 8.0.21.

Since MySQL Connector / Python 8.0.22 has been released, there is a dependency to mysql-community-client-plugins 8.0.22. This dependency can only be installed if I enable the Mysql 8.0 Repo, which will lead to updating MySQL from 5.7 to 8.0.

How to repeat:
Run 'yum update' on a CentOS 7 server with MySQL 5.7 and mysql-connector-python 8.0.21 installed.

# yum update
Loaded plugins: fastestmirror, replace
Loading mirror speeds from cached hostfile
 * base: ftp.plusline.net
 * epel: ftp.plusline.net
 * extras: mirror.23media.com
 * updates: ftp.plusline.net
 * webtatic: uk.repo.webtatic.com
Resolving Dependencies
--> Running transaction check
---> Package mysql-connector-python.x86_64 0:8.0.21-1.el7 will be updated
---> Package mysql-connector-python.x86_64 0:8.0.22-1.el7 will be obsoleting
--> Processing Dependency: mysql-community-client-plugins = 8.0.22 for package: mysql-connector-python-8.0.22-1.el7.x86_64
---> Package mysql-connector-python-cext.x86_64 0:8.0.21-1.el7 will be obsoleted
--> Finished Dependency Resolution
Error: Package: mysql-connector-python-8.0.22-1.el7.x86_64 (mysql-connectors-community)
           Requires: mysql-community-client-plugins = 8.0.22
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

Suggested fix:
Remove dependency to mysql-community-client-plugins 8.0.22, or include this package in the MySQL 5.7 repo.
[4 Nov 2020 22:03] Rüdiger Lincke
I chose Severity S2, since I cannot update to MySQL 8.0.
[5 Nov 2020 3:52] MySQL Verification Team
Hello Rüdiger Lincke,

Thank you for the report and feedback.

regards,
Umesh
[5 Nov 2020 8:54] Terje Røsten
Hi!

Try this workaround (as you should be able to install the required package
without installing MySQL 8.0 *server*):

$ rpm -Uvh 
http://repo.mysql.com/yum/mysql-8.0-community/el/7/x86_64/mysql-community-client-plugins-8...

and then run 

$ yum update
[5 Nov 2020 8:56] Terje Røsten
(Use mouse over to see full link to RPM as bugs system breaks display of URL).
[5 Nov 2020 9:15] Rüdiger Lincke
Hello Terje,

thank you for the fast response.

Unfortunately, your suggestion does not seem to work. I fails with the following error:

# rpm -Uvh http://repo.mysql.com/yum/mysql-8.0-community/el/7/x86_64/mysql-community-client-plugins-8...
Retrieving http://repo.mysql.com/yum/mysql-8.0-community/el/7/x86_64/mysql-community-client-plugins-8...
error: Failed dependencies:
	mysql-community-server < 8.0.21 conflicts with mysql-community-client-plugins-8.0.22-1.el7.x86_64
	mysql-community-client < 8.0.22 conflicts with mysql-community-client-plugins-8.0.22-1.el7.x86_64

Do you have any other suggestion?

Thank you!
Rüdiger
[5 Nov 2020 9:21] Terje Røsten
Hi again,

try this instead (-Uvh will remove the 5.7 version of the package, however rpm supports install of same package in different versions, if told to):

$ rpm -ivh http://repo.mysql.com/yum/mysql-8.0-community/el/7/x86_64/mysql-community-client-plugins-8...
[5 Nov 2020 12:29] Rüdiger Lincke
Hello again,

does unfortunately still not work:

# rpm -ivh http://repo.mysql.com/yum/mysql-8.0-community/el/7/x86_64/mysql-community-client-plugins-8...
Retrieving http://repo.mysql.com/yum/mysql-8.0-community/el/7/x86_64/mysql-community-client-plugins-8...
error: Failed dependencies:
	mysql-community-server < 8.0.21 conflicts with mysql-community-client-plugins-8.0.22-1.el7.x86_64
	mysql-community-client < 8.0.22 conflicts with mysql-community-client-plugins-8.0.22-1.el7.x86_64

I also tried with --nodeps (do not verify package dependencies), but get the following:

# rpm -ivh --nodeps http://repo.mysql.com/yum/mysql-8.0-community/el/7/x86_64/mysql-community-client-plugins-8...
Retrieving http://repo.mysql.com/yum/mysql-8.0-community/el/7/x86_64/mysql-community-client-plugins-8...
Preparing...                          ################################# [100%]
	file /usr/lib64/mysql/plugin/authentication_ldap_sasl_client.so from install of mysql-community-client-plugins-8.0.22-1.el7.x86_64 conflicts with file from package mysql-community-server-5.7.32-1.el7.x86_64

Looks like the dependencies are conflicting for since the latest Connector / Python version between 8.0 and 5.7.

Any more suggestion?
(Thank you for your help so far)
[5 Nov 2020 13:05] Terje Røsten
Hi!

You are right, mixing plugins for 5.7 and 8.0 is simply not possible
at the moment.

So the only viable workaround now is to --nodeps install the connector package
itself, it will work just fine, however the feature set found in the plugin will be missing (that's new in 8.0.22 any way).
[5 Nov 2020 13:34] Rüdiger Lincke
Hello Terje,

thank you.

This was the important information to know: "... it will work just fine..."

I could update now with:

# rpm -Uvh https://dev.mysql.com/get/Downloads/Connector-Python/mysql-connector-python-8.0.22-1.el7.x... --nodeps
Retrieving https://dev.mysql.com/get/Downloads/Connector-Python/mysql-connector-python-8.0.22-1.el7.x...
Preparing...                          ################################# [100%]
Updating / installing...
   1:mysql-connector-python-8.0.22-1.e################################# [ 33%]
Cleaning up / removing...
   2:mysql-connector-python-cext-8.0.2################################# [ 67%]
   3:mysql-connector-python-8.0.21-1.e################################# [100%]

And yum update is now happy :)
(Will observe a bit on the current server, before I apply the fix to production and other servers).

Thank you very much!
[5 Nov 2020 13:57] MySQL Verification Team
https://bugs.mysql.com/bug.php?id=101478 marked as duplicate of this one.
[5 Nov 2020 14:01] Rüdiger Lincke
Closing this issue with the solution described in the previous post.
[8 Jun 2021 20:48] Philip Olson
Posted by developer:
 
This 8.0.23 release note is suggested by the documentation team:

Removed the MySQL client-plugins dependency, although it's recommended.
This plugin allows MySQL to use its newer authentication methods, thus
it's required for connecting to accounts using the new authentication
methods such as caching_sha2_password.

Additionally, the C/Py installation documentation also now mentions the client-plugins package
as required to use newer authentication methods, such as caching_sha2_password that
is the default auth method in MySQL 8.0.