美文网首页
Centos6.5安装mysql relocation erro

Centos6.5安装mysql relocation erro

作者: DecKen | 来源:发表于2017-12-30 21:14 被阅读85次

    安装各组件

    sudo yum -y install mysql mysql-server
    

    启动

    sudo service mysqld start
    

    Initializing MySQL database:  Installing MySQL system tables...
    171230 20:51:38 [ERROR] Can't find messagefile '/usr/share/mysql/english/errmsg.sys'
    171230 20:51:38 [ERROR] Aborting
    
    171230 20:51:38 [Note]
    
    Installation of system tables failed!  Examine the logs in
    /var/lib/mysql for more information.
    
    You can try to start the mysqld daemon with:
    
        shell> /usr/libexec/mysqld --skip-grant &
    
    and use the command line tool /usr/bin/mysql
    to connect to the mysql database and look at the grant tables:
    
        shell> /usr/bin/mysql -u root mysql
        mysql> show tables
    
    Try 'mysqld --help' if you have problems with paths.  Using --log
    gives you a log in /var/lib/mysql that may be helpful.
    
    Please consult the MySQL manual section
    'Problems running mysql_install_db', and the manual section that
    describes problems on your OS.  Another information source are the
    MySQL email archives available at http://lists.mysql.com/.
    
    Please check all of the above before mailing us!  And remember, if
    you do mail us, you MUST use the /usr/bin/mysqlbug script!
    

    启动客户端 看看

    mysql
    

    mysql: relocation error: mysql: symbol strmov, version libmysqlclient_16 not defined in file libmysqlclient.so.16 with link time reference
    

    解决办法

    思路:和安装的Percona 有冲突

    1. 查看是否有安装Percona
      rpm -qa | grep Percona

    2. 如果有的话, 将其卸载
      rpm -e Percona-Server-shared-51-5.1.73 --nodeps

    3. 安装mysql-libs
      sudo yum install mysql-libs

    如果看到依旧是Percona-Server, 那么就不安装, 这个可以看到Repository是base,那我们去把base的Repository关掉

    ================================================================================================================================================================
     Package                                        Arch                         Version                                           Repository                  Size
    ================================================================================================================================================================
    Installing:
     Percona-Server-shared-51                       x86_64                       5.1.73-rel14.11.603.rhel6                         base                       2.1 M
         replacing  mysql-libs.x86_64 5.1.73-3.el6_5
    
    Transaction Summary
    ================================================================================================================================================================
    
    1. 进入/etc/yum.repos.d/找到base的的配置, 将其配置注释掉, 然后再安装mysql-libs
      ,这时可以看到mysql-libs是从updates安装了, 这样就可以安装了.
    ================================================================================================================================================================
     Package                                Arch                               Version                                    Repository                           Size
    ================================================================================================================================================================
    Installing:
     mysql-libs                             x86_64                             5.1.73-3.el6_5                             updates                             1.2 M
    
    Transaction Summary
    ================================================================================================================================================================
    

    安装完之后重新输入 mysql, 可以正常使用, 问题解决.

    1. 记得将第4部注释的base源修改回去, 免得影响其他软件的安装

    相关文章

      网友评论

          本文标题:Centos6.5安装mysql relocation erro

          本文链接:https://www.haomeiwen.com/subject/kgmngxtx.html