遇到一堆问题:直接从mysql官下载,都不行。下列是失败的:
mysql80-community-release-el8-1.noarch.rpm
mysql-8.0.34-1.el8.x86_64.rpm-bundle.tar
mysql-8.1.0-1.el9.x86_64.rpm-bundle.tar
后来想从openeuler下载应该靠谱:https://repo.huaweicloud.com/openeuler/openEuler-23.03/everything/x86_64/Packages/
就安装了这里面所有的mysql:
rpm -ivh --replacefiles --force --nodeps https://repo.huaweicloud.com/openeuler/openEuler-23.03/everything/x86_64/Packages/mysql-common-8.0.30-2.oe2303.x86_64.rpm
rpm -ivh --replacefiles --force --nodeps https://repo.huaweicloud.com/openeuler/openEuler-23.03/everything/x86_64/Packages/mysql-config-8.0.30-2.oe2303.x86_64.rpm
rpm -ivh --replacefiles --force --nodeps https://repo.huaweicloud.com/openeuler/openEuler-23.03/everything/x86_64/Packages/mysql-connector-java-8.0.16-1.oe2303.noarch.rpm
rpm -ivh --replacefiles --force --nodeps https://repo.huaweicloud.com/openeuler/openEuler-23.03/everything/x86_64/Packages/mysql-devel-8.0.30-2.oe2303.x86_64.rpm
rpm -ivh --replacefiles --force --nodeps https://repo.huaweicloud.com/openeuler/openEuler-23.03/everything/x86_64/Packages/mysql-errmsg-8.0.30-2.oe2303.x86_64.rpm
rpm -ivh --replacefiles --force --nodeps https://repo.huaweicloud.com/openeuler/openEuler-23.03/everything/x86_64/Packages/mysql-help-8.0.30-2.oe2303.x86_64.rpm
rpm -ivh --replacefiles --force --nodeps https://repo.huaweicloud.com/openeuler/openEuler-23.03/everything/x86_64/Packages/mysql-libs-8.0.30-2.oe2303.x86_64.rpm
rpm -ivh --replacefiles --force --nodeps https://repo.huaweicloud.com/openeuler/openEuler-23.03/everything/x86_64/Packages/mysql-selinux-1.0.0-2.oe2303.noarch.rpm
rpm -ivh --replacefiles --force --nodeps https://repo.huaweicloud.com/openeuler/openEuler-23.03/everything/x86_64/Packages/mysql-server-8.0.30-2.oe2303.x86_64.rpm
rpm -ivh --replacefiles --force --nodeps https://repo.huaweicloud.com/openeuler/openEuler-23.03/everything/x86_64/Packages/mysql-test-8.0.30-2.oe2303.x86_64.rpm
[root@192 download]# /usr/libexec/mysqld
出错信息:
/usr/libexec/mysqld: error while loading shared libraries: libprotobuf-lite.so.25: cannot open shared object file: No such file or directory
检查这货所有依赖:
bash
[root@192 download]# ldd /usr/libexec/mysqld
bash
linux-vdso.so.1 => linux-vdso.so.1 (0x00007ffc7b1c5000)
libicuuc.so.72 => /usr/lib64/libicuuc.so.72 (0x00007f9fbcc02000)
libicuio.so.72 => /usr/lib64/libicuio.so.72 (0x00007f9fc11a3000)
libicudata.so.72 => /usr/lib64/libicudata.so.72 (0x00007f9fbae00000)
libicui18n.so.72 => /usr/lib64/libicui18n.so.72 (0x00007f9fbaa00000)
libevent_core-2.1.so.7 => /usr/lib64/libevent_core-2.1.so.7 (0x00007f9fc116c000)
libevent_extra-2.1.so.7 => /usr/lib64/libevent_extra-2.1.so.7 (0x00007f9fc1145000)
libevent_openssl-2.1.so.7 => /usr/lib64/libevent_openssl-2.1.so.7 (0x00007f9fc113a000)
libevent_pthreads-2.1.so.7 => /usr/lib64/libevent_pthreads-2.1.so.7 (0x00007f9fc1135000)
libssl.so.3 => /usr/lib64/libssl.so.3 (0x00007f9fbad5a000)
libcrypto.so.3 => /usr/lib64/libcrypto.so.3 (0x00007f9fba400000)
libzstd.so.1 => /usr/lib64/libzstd.so.1 (0x00007f9fba919000)
libprotobuf-lite.so.25 => not found
libaio.so.1 => not found
liblz4.so.1 => /usr/lib64/liblz4.so.1 (0x00007f9fc110e000)
libnuma.so.1 => not found
libstdc++.so.6 => /usr/lib64/libstdc++.so.6 (0x00007f9fba21a000)
libm.so.6 => /usr/lib64/libm.so.6 (0x00007f9fba13a000)
libgcc_s.so.1 => /usr/lib64/libgcc_s.so.1 (0x00007f9fc10f4000)
libc.so.6 => /usr/lib64/libc.so.6 (0x00007f9fb9f5d000)
/lib64/ld-linux-x86-64.so.2 => /lib64/ld-linux-x86-64.so.2 (0x00007f9fc11c4000)
libz.so.1 => /usr/lib64/libz.so.1 (0x00007f9fc10d8000)
看来缺德东西挺多,从23.03的Packages中找到这些组件,一个个安装:
systemctl start mysqld
Active: active (running)
我去,不容易,不友好。