1. yum install -y devtoolset-8-gcc devtoolset-8-gcc-c++ devtoolset-8-binutils
# 如果1安装不上
1.1 yum list installed | grep "scl"
1.2 yum remove centos-release-scl.noarch
yum remove centos-release-scl-rh.noarch
1.3 yum install -y centos-release-scl centos-release-scl-rh
1.4 yum install -y scl-utils scl-utils-build
1.5 yum -y install devtoolset-8-gcc devtoolset-8-gcc-c++ devtoolset-8-binutils
scl enable devtoolset-8 bash
echo "source /opt/rh/devtoolset-8/enable" >> /etc/profile
source /etc/profile
安装前查看最低要求
cat INSTALL | grep -E "newer|later" | grep "*"
安装前安装依赖的库
yum -y install bzip2
yum -y install bison
脚本备份
localedef -i en_US -f UTF-8 en_US.UTF-8
Error: dl failure on line 893 Error: failed /opt/jdk1.8.0_361/jre/lib/amd64/server/libjvm.so, because /lib64/libm.so.6: symbol __strtof128_nan, version GLIBC_PRIVATE not defined in file libc.so.6 with link time reference
strings /lib64/lib.so.6 | grep GLIBC strings /lib64/lib.so.6 | grep GLIBC strings /lib64/libc-2.17.so | grep GLIBC
strings /usr/lib64/libc-2.17.so
sln /usr/lib64/libc-2.17.so /usr/lib64/libc.so.6
ln -s /lib64/libc.so.6 /lib/libc.so.6
ln -s /usr/lib64/libc-2.17.so /lib/libc.so.6 ln -s /usr/lib64/libc-2.17.so /lib64/lib.so.6 ln -s /lib64/libdl-2.17.so /lib64/libdl.so.2
删除旧的 Glibc
rm -rf /lib64/libc-2.27.so /lib64/ld-2.27.so /lib64/libdl-2.27.so
亲测好用修复
rm -fv /lib64/libdl.so.2 && ln -s /lib64/libdl-2.17.so /lib64/libdl.so.2
rm -fv /lib64/libm.so.6 && ln -s /lib64/libm-2.17.so /lib64/libm.so.6
rm -fv /usr/lib64/libm.so.6 && ln -s /lib64/libm-2.17.so /usr/lib64/libm.so.6
rm -fv /lib64/libBrokenLocale.so.1 && ln -s /lib64/libBrokenLocale-2.17.so /lib64/libBrokenLocale.so.1
## 彻底解决崩溃问题
8 # 链接指回 libc-2.17 删除 glibc2.25有关的文 件
sln /usr/lib64/libc-2.17.so /lib64/libc.so.6
sln /usr/lib64/ld-2.17.so /usr/lib64/ld-linux-x86-64.so.2
sln /usr/lib64/libdl-2.17.so /usr/lib64/libdl.so.2
一体化数据平台接口:
curl -X GET -v -H "Accept: text/event-stream" -H "Connection: keep-alive"\
-H "auth: 0659c7992e268962384eb17fafe88364" -H "code: client1"\
-H "ngrok-skip-browser-warning: 1" http://10.163.88.8/yth-api/data/subscript-data
- https://www.cnblogs.com/wangjq19920210/p/15851376.html
- https://www.cnblogs.com/apanly/p/15395786.html
0615
ffmpeg -re -i 周东芬临书谱.mp4 -c copy -f rtsp -rtsp_transport tcp rtsp://10.163.189.253:8554/live/shupu
yum install zlib zlib-devel bzip2 bzip2-devel readline-devel sqlite sqlite-devel openssl openssl-devel xz xz-devel libffi-devel yum -y install ncurses-devel yum -y install python-devel yum -y install lrzsz
然后开始编译和安装:
python2.7.18
./configure --enable-optimizations make -j4 make install
sh -c 'echo "source /opt/rh/devtoolset-8/enable" >>/etc/profile'
glibc24
开始编译
../configure --prefix=/usr --disable-profile --enable-add-ons --with-headers=/usr/include --with-binutils=/usr/bin --disable-sanity-checks --disable-werror
../configure --prefix=/usr --disable-profile --enable-add-ons --with-headers=/usr/include --with-binutils=/usr/bin
make -j4 # 此处时间较长
make install
build/support/stubs /root/temp/glibc-2.28/build/crypt/stubs /root/temp/glibc-2.28/build/nptl_db/stubs /root/temp/glibc-2.28/build/inet/stubs /root/temp/glibc-2.28/build/resolv/stubs /root/temp/glibc-2.28/build/nss/stubs /root/temp/glibc-2.28/build/hesiod/stubs /root/temp/glibc-2.28/build/sunrpc/stubs /root/temp/glibc-2.28/build/nis/stubs /root/temp/glibc-2.28/build/nscd/stubs /root/temp/glibc-2.28/build/streams/stubs /root/temp/glibc-2.28/build/login/stubs /root/temp/glibc-2.28/build/elf/stubs) > /root/temp/glibc-2.28/build/stubs.h
if test -r /usr/include/gnu/stubs-64.h && cmp -s /root/temp/glibc-2.28/build/stubs.h /usr/include/gnu/stubs-64.h; \
then echo 'stubs.h unchanged'; \
else /usr/bin/install -c -m 644 /root/temp/glibc-2.28/build/stubs.h /usr/include/gnu/stubs-64.h; fi
rm -f /root/temp/glibc-2.28/build/stubs.h
/root/temp/glibc-2.28/build/elf/sln /root/temp/glibc-2.28/build/elf/symlink.list
rm -f /root/temp/glibc-2.28/build/elf/symlink.list
test ! -x /root/temp/glibc-2.28/build/elf/ldconfig || LC_ALL=C \
/root/temp/glibc-2.28/build/elf/ldconfig \
/lib64 /usr/lib64
LD_SO=ld-linux-x86-64.so.2 CC="gcc -B/usr/bin/" /usr/bin/perl scripts/test-installation.pl /root/temp/glibc-2.28/build/
/usr/bin/ld: cannot find -lnss_test2
collect2: error: ld returned 1 exit status
Execution of gcc -B/usr/bin/ failed!
The script has found some problems with your installation!
Please read the FAQ and the README file and check the following:
- Did you change the gcc specs file (necessary after upgrading from
Linux libc5)?
- Are there any symbolic links of the form libXXX.so to old libraries?
Links like libm.so -> libm.so.5 (where libm.so.5 is an old library) are wrong,
libm.so should point to the newly installed glibc file - and there should be
only one such link (check e.g. /lib and /usr/lib)
You should restart this script from your build directory after you've
fixed all problems!
Btw. the script doesn't work if you're installing GNU libc not as your
primary library!
make[1]: *** [Makefile:111: install] Error 1
mkdir -p build
编译时报一个 nss_test2 Not Found 的错误,根据教程需要修改 test-installation.pl 文件。 https://blog.csdn.net/nangonghen/article/details/132258675
vim scripts/test-installation.pl
# 128 行加
&& $name ne "nss_test2"
cd build
../configure --prefix=/usr --disable-profile --enable-add-ons --with-headers=/usr/include --with-binutils=/usr/bin --enable-obsolete-nsl
make -j 10
# 不然中文 乱码
make localedata/install-locales -j 10
make install -j 10
ll /lib64/libc.so.6* strings /lib64/libc.so.6 | grep ^GLIBC ldd --version
https://www.cnblogs.com/132818Creator/p/14211118.html
rm -fv /lib64/libdl.so.2 && ln -s /lib64/libdl-2.28.so /lib64/libdl.so.2 rm -fv /lib64/libm.so.6 && ln -s /lib64/libm-2.28.so /lib64/libm.so.6 rm -fv /usr/lib64/libm.so.6 && ln -s /lib64/libm-2.28.so /usr/lib64/libm.so.6 rm -fv /lib64/libBrokenLocale.so.1 && ln -s /lib64/libBrokenLocale-2.28.so /lib64/libBrokenLocale.so.1
rm -fv /lib64/libstdc++.so.6 && ln -s /usr/local/lib64/libstdc++.so.6.0.25 /lib64/libstdc++.so.6
StartupInfoLogger : 116 ] - InetAddress.getLocalHost().getHostName() took 20027 milliseconds to respond. Please verify your network configuration.
# 添加端口
firewall-cmd --permanent --add-port=3306/tcp
# 移除端口
firewall-cmd --permanent --remove-port=3306/tcp
# 重新加载,并应用
firewall-cmd --reload
/usr/local/mysql/bin/mysqldump -h 10.163.189.253 -P 3306 -u root -p hyd > ./hyd618.sql