#化鲲为鹏,我有话说#弹性云上的mysql安装(requires:glibc2.17)
弹性云服务器规格:1vCPUs|1G|CentOS 6.10bit
打开服务器,点击远程登录:
yum -y install mysql-community-libs-5.7.28-1.el7.x86_64
显示如下错误:
Requires:libc.so.6(GLIBC_2.17)(64bit)
执行如下命令:
strings /lib64/libc.so.6 | grep GLIBC
输出如下,发现没有2.17版本
在网上搜了搜解决方法,找到一个可以解决问题的:
执行如下命令一次下载对应的rpm包:
wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-utils-2.17-55.el6.x86_64.rpm & wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-static-2.17-55.el6.x86_64.rpm & wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-2.17-55.el6.x86_64.rpm & wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-common-2.17-55.el6.x86_64.rpm & wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-devel-2.17-55.el6.x86_64.rpm & wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-headers-2.17-55.el6.x86_64.rpm & wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/nscd-2.17-55.el6.x86_64.rpm &
下载完成后执行ls -ll -h可以查看安装包
:
之后执行安装rpm:
sudo rpm -Uvh *-2.17-55.el6.x86_64.rpm --force --nodeps
输出如上图,之后执行strings /lib64/libc.so.6 | grep GLIBC命令行可以查看已安装完毕。输出如上图。
之后开始执行安装数据库:
yum -y install mysql-community-libs-5.7.28-1.el7.x86_64
可以看到安装成功了!值得高兴!
在解决上面的问题时,我还试过GLIBC 2.14的安装,执行如下命令行:
wget http://ftp.gnu.org/gnu/glibc/glibc-2.14.tar.gz
tar xf glibc-2.14.tar.gz
cd glibc-2.14
mkdir build
cd build
../configure --prefix=/opt/glibc-2.14 --disable-profile --enable-add-ons --with-headers=/usr/include --with-binutils=/usr/bin
make
make install
然后再查看一下GLIBC版本:
strings /lib64/libc.so.6 | grep GLIBC
输出还是不变,所以这种方式估计是过期了。还有下载速度,我发现在网上用服务器下载时,下载比较快,但还是不建议大家经常熬夜哦
- 点赞
- 收藏
- 关注作者
评论(0)