nginx报错(error while loading shared libraries: libpcre2-8.so.0)
作者:mmseoamin日期:2023-12-21

报错信息如下:

nginx: error while loading shared libraries: libpcre2-8.so.0: cannot open shared object file: No such file or directory

使用用rpm部署nginx服务在Centos7.9中,启动nginx之前试用命令nginx -t进行检查

在这里插入图片描述

处理方式1:

如果你的服务器上有配置yum源的话,可以使用yum进行安装,只需执行命令:yum install pcre2 即可

处理方式2:

使用下载相关依赖http://mirror.centos.org/centos/7/os/x86_64/Packages/pcre2-10.23-2.el7.x86_64.rpm 使用命令: rpm -ivh pcre2-10.23-2.el7.x86_64.rpm 进行安装