make[1]: *** [server.o] Error 1 make[1]: Leaving directory `/other/redis-6.0.15/src' make: *** [all] Error 2
make[1]: Leaving directory `/other/redis-6.0.15/src’
make: *** [all] Error 2)
出现这种错误是由于gcc的版本过低
只需要升级一下gcc
yum -y install centos-release-scl
yum -y install devtoolset-9-gcc devtoolset-9-gcc-c++ devtoolset-9-binutils
scl enable devtoolset-9 bash
echo “source /opt/rh/devtoolset-9/enable” >> /etc/profile
gcc -v