Bug 2465 - [Anolis23][Preview][x86_64/aarch64] 生态软件测试,使用测试repo时,yum安装mysql-server失败,报大量文件冲突
Summary: [Anolis23][Preview][x86_64/aarch64] 生态软件测试,使用测试repo时,yum安装mysql-server失败,报大量文件冲突
Status: CLOSED FIXED
Alias: None
Product: Anolis OS 23
Classification: Anolis OS
Component: BaseOS Packages (show other bugs) BaseOS Packages
Version: 23.0
Hardware: All Linux
: P2-High S2-major
Target Milestone: ---
Assignee: xuchunmei
QA Contact: bolong_tbl
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-10-20 17:15 UTC by Janos
Modified: 2022-11-02 14:49 UTC (History)
10 users (show)

See Also:


Attachments
yum安装mysql日志 (23.80 KB, text/plain)
2022-10-20 17:15 UTC, Janos
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Janos alibaba_cloud_group 2022-10-20 17:15:18 UTC
Created attachment 426 [details]
yum安装mysql日志

[缺陷描述]:
  生态软件测试,使用测试repo时,yum安装mysql-server失败,报大量文件冲突,冲突中的两个包 percona-xtradb-cluster-client 和 mysql 都是 yum安装时自动安装的包


[重现环境]:
环境信息:线上ecs
OS:Anolis 23 x86_64/aarch64
# cat /etc/os-release
NAME="Anolis OS"
VERSION="23"
ID="anolis"
VERSION_ID="23"
PLATFORM_ID="platform:an23"
PRETTY_NAME="Anolis OS 23"
ANSI_COLOR="0;31"
HOME_URL="https://openanolis.cn/"
BUG_REPORT_URL="https://bugzilla.openanolis.cn/"

KERNEL:
# uname -r
5.10.134-12.1.an23.x86_64
5.10.134-12.1.an23.aarch64

[重现步骤]:
yum install -y mysql-server


[期望结果]:
mysql可以正常安装

[实际结果]:
mysql可以安装失败,提示大量文件冲突,部分冲突日志如下,完整日志见附件:

The downloaded packages were saved in cache until the next successful transaction.
You can remove cached packages by executing 'yum clean packages'.
Error: Transaction test error:
  file /usr/bin/mysql conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/bin/mysql_config_editor conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/bin/mysqladmin conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/bin/mysqlbinlog conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/bin/mysqlcheck conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/bin/mysqldump conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/bin/mysqlimport conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/bin/mysqlpump conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/bin/mysqlshow conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/bin/mysqlslap conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/share/man/man1/mysql.1.gz conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/share/man/man1/mysql_config_editor.1.gz conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/share/man/man1/mysqladmin.1.gz conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/share/man/man1/mysqlbinlog.1.gz conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/share/man/man1/mysqlcheck.1.gz conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/share/man/man1/mysqldump.1.gz conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/share/man/man1/mysqlimport.1.gz conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
  file /usr/share/man/man1/mysqlpump.1.gz conflicts between attempted installs of mysql-8.0.28-1.an23.x86_64 and percona-xtradb-cluster-client-8.0.28-1.an23.x86_64
Comment 1 xuchunmei alibaba_cloud_group 2022-10-20 17:19:39 UTC
ercona-xtradb-cluster-client 这个本身也是个数据库集群组件,冲突正常。
Comment 2 Janos alibaba_cloud_group 2022-10-20 17:24:32 UTC
(In reply to xuchunmei from comment #1)
> ercona-xtradb-cluster-client 这个本身也是个数据库集群组件,冲突正常。

但是问题在于环境上这两个包都没有安装,yum install 时也报冲突,感觉是在 yum install时安装的就有问题
# rpm -qa | egrep "mysql|percona"
# ls /usr/bin/mysql
ls: cannot access '/usr/bin/mysql': No such file or directory
Comment 3 xuchunmei alibaba_cloud_group 2022-10-20 17:32:23 UTC
刚刚没走到正式的安装流程,查看了下应该是percona-xtradb-cluster provides了mysql-server导致了依赖解析错误。我具体分析下。
Comment 4 xuchunmei alibaba_cloud_group 2022-10-20 17:32:54 UTC
刚刚没走到正式的安装流程,查看了下应该是percona-xtradb-cluster provides了mysql-server导致了依赖解析错误。我具体分析下。
Comment 5 xuchunmei alibaba_cloud_group 2022-10-20 19:37:17 UTC
问题原因:
percona-xtradb-cluster构建时未使用系统提供的libfido2和protobuf-lite,导致percona-xtradb-cluster provides这两个库:
# rpm -qp percona-xtradb-cluster-server-8.0.28-1.an23.x86_64.rpm --provides | grep libfi
libfido2.so.1()(64bit)

# rpm -qp percona-xtradb-cluster-server-8.0.28-1.an23.x86_64.rpm --provides | grep libprotobuf
libprotobuf-lite.so.3.11.4()(64bit)
libprotobuf-lite.so.3.11.4(MYSQL_HIDE_STD)(64bit)
libprotobuf.so.3.11.4()(64bit)
libprotobuf.so.3.11.4(MYSQL_HIDE_STD)(64bit)

dnf在解析mysql-server的依赖时,libfido2和protobuf的版本都不如percona-xtradb-cluster-server版本号高,所以优先安装percona-xtradb-cluster-server,而percona-xtradb-cluster-server中的文件与mysql-server冲突,导致安装失败。
Comment 6 xuchunmei alibaba_cloud_group 2022-10-25 11:13:04 UTC
percona-xtradb-cluster-8.0.28-3.an23版本已修复percona-xtradb-cluster与mysql/mariadb的兼容共存问题。
Comment 7 Janos alibaba_cloud_group 2022-11-02 14:49:09 UTC
使用最新repo源安装mysql-server测试通过,本bug可以关闭
# rpm -qa | grep mysql
mysql-common-8.0.28-1.an23.x86_64
mysql-8.0.28-1.an23.x86_64
mysql-errmsg-8.0.28-1.an23.x86_64
mysql-selinux-1.0.5-1.an23.noarch
mysql-server-8.0.28-1.an23.x86_64