尝试升级mariadb和mariadb-lib,发现冲突
# rpm -qa | grep mariadb
mariadb-libs-5.5.41-2.el7_0.x86_64
mariadb-galera-common-5.5.40-1.el7.x86_64
mariadb-galera-server-5.5.40-1.el7.x86_64
mariadb-5.5.41-2.el7_0.x86_64
# ll
total 9704
-rw-r--r-- 1 root root 9158636 Aug 15 18:49 mariadb-5.5.56-2.el7.x86_64.rpm
-rw-r--r-- 1 root root 775548 Aug 15 18:49 mariadb-libs-5.5.56-2.el7.x86_64.rpm
# rpm -Uvh mariadb-*
warning: mariadb-5.5.56-2.el7.x86_64.rpm: Header V3 RSA/SHA256 Signature, key ID f4a80eb5: NOKEY
Preparing... ################################# [100%]
file /usr/lib64/mysql/plugin/dialog.so from install of mariadb-libs-1:5.5.56-2.el7.x86_64 conflicts with file from package mariadb-galera-server-1:5.5.40-1.el7.x86_64
file /usr/lib64/mysql/plugin/mysql_clear_password.so from install of mariadb-libs-1:5.5.56-2.el7.x86_64 conflicts with file from package mariadb-galera-server-1:5.5.40-1.el7.x86_64
#
后来发现是mariadb打包的一个bug,详见:https://bugzilla.redhat.com/show_bug.cgi?id=1138843
解决方案:
rpm安装的时候加replacefiles参数,当包中文件与其他包的文件冲突时,覆盖该文件
rpm -Uvh --replacefiles /root/mariadbrpm/*