Nginx启动错误:error while loading shared libraries: libpcre.so.1
1 |
# /usr/local/nginx/sbin/nginx |
2 |
/usr/local/nginx/sbin/nginx: error while loading shared libraries: libpcre.so.1: cannot open shared object file: No such file or directory |
从错误提示信息可以得知是因为缺少lib文件导致,进一步查看具体内容:
1 |
# ldd $(which /usr/local/nginx/sbin/nginx) |
2 |
libpthread.so.0 => /lib64/libpthread.so.0 (0x00000030e8400000) |
3 |
libcrypt.so.1 => /lib64/libcrypt.so.1 (0x00000030f9a00000) |
4 |
libpcre.so.1 => not found |
5 |
libcrypto.so.6 => /lib64/libcrypto.so.6 (0x00000030f2a00000) |
6 |
libz.so.1 => /lib64/libz.so.1 (0x00000030e8800000) |
7 |
libc.so.6 => /lib64/libc.so.6 (0x00000030e7800000) |
8 |
/lib64/ld-linux-x86-64.so.2 (0x00000030e7400000) |
9 |
libdl.so.2 => /lib64/libdl.so.2 (0x00000030e8000000) |
查看结果显示 : libpcre.so.1 => not found ,同时注意lib库的路径,有/lib/* 和 /lib64/* 之分。
比如上面的是 /lib64/*,这个和下面解决问题时创建的软连接有关系
解决办法:
1、首先确认已经安装好pcre 软件(nginx 依赖该软件)
2、创建软连接
对于/lib/* 32位系统来说:
1 |
#查看lib库 |
2 |
# ls /lib/ |grep pcre |
3 |
libpcre.so.0 |
4 |
libpcre.so.0.0.1 |
5 |
#添加软连接 |
6 |
# ln -s /lib/libpcre.so.0.0.1 /lib/libpcre.so.1 |
ps: 也有可能 pcre lib文件在目录:/usr/local/lib/
对于/lib64/* 64位系统来说:
1 |
#查看lib库 |
2 |
# ls /lib64/ |grep pcre |
3 |
libpcre.so.0 |
4 |
libpcre.so.0.0.1 |
5 |
#添加软连接 |
6 |
# ln -s /lib64/libpcre.so.0.0.1 /lib64/libpcre.so.1 |
ps: 也有可能 pcre lib文件在目录:/usr/local/lib64/。
Nginx启动错误:error while loading shared libraries: libpcre.so.1的更多相关文章
- Nginx启动错误:error while loading shared libraries: libpcre.so.0
今天测试的时候,启动一个其他机器预编译好的nginx到目标测试机器(OEL 7.4)启动的时候,报了下列错误: /usr/local/nginx/sbin/nginx: error while loa ...
- Nginx启动出错 error while loading shared libraries:
在centos5.7 32位上编译安照 nginx-1.1.16 出错 [root@localhost conf]# /usr/local/nginx/sbin/nginx/usr/local/ngi ...
- (转)Nginx启动出错 error while loading shared libraries
[root@localhost conf]# /usr/local/nginx/sbin/nginx/usr/local/nginx/sbin/nginx: error while loading s ...
- 解决软件启动报error while loading shared libraries: libgd.so.2: cannot open shared object错误
解决软件启动报error while loading shared libraries: libgd.so.2: cannot open shared object错误 今天安装启动nginx的时候报 ...
- nginx排错error while loading shared libraries:libpcre.so.1:cannot open shared object file:No such file or directory
启动nginx报错:error while loading shared libraries:libpcre.so.1:cannot open shared object file:No such f ...
- 启动uwsgi报错error while loading shared libraries: libpcre.so.1:
启动uwsgi时候报错: [root@ richie]# /usr/bin/uwsgi --ini /usr/local/nginx/conf/uwsgi.ini /usr/bin/uwsgi: er ...
- Ubuntu12.04安装64位系统出现编译错误error while loading shared libraries: libz.so.1: cannot open shared object file: No such file or dir
问题: Ubuntu12.04安装64位系统出现编译错误error while loading shared libraries: libz.so.1: cannot open shared obje ...
- Nginx: error while loading shared libraries: libpcre.so.1解决
Shell代码 [root@tmsapp65 conf]# /usr/local/nginx/sbin/nginx /usr/local/nginx/sbin/nginx: error while l ...
- [error]error while loading shared libraries: libpcre.so.1 解决
nginx 安装好之后,启动的时候报错 [root@localhost nginx-1.6.2]# /usr/local/nginx/sbin/nginx /usr/local/nginx/sbin ...
随机推荐
- Yahoo Programming Contest 2019 自闭记
A:签到. #include<iostream> #include<cstdio> #include<cmath> #include<cstdlib> ...
- 查询SQLSERVER中系统表结构
Declare @TableName Varchar(20); SET @TableName='B_SupplierDA'; --SELECT TE.字段名+',' --FROM ( SELECT ( ...
- LSM
1.MySQL存储引擎: B+树 https://blog.csdn.net/qq_26222859/article/details/80631121 2.HBase LSM树 核心:将对数据的修改增 ...
- python中的map函数
def f(x): return x * x """将一个全是数字的list变成平方形式""" def f2(): ls = [1, 2, ...
- MT【262】一道常见错题
若$f(x^2)$的定义域为$[-1,1]$,则函数$f(x)$的定义域为______ 设$a>0$构造$f(x)=\sqrt{x(1-x)(a+x)}$,此时$f(x^2)$的定义域为$[-1 ...
- 洛谷P4155 [SCOI2015]国旗计划(贪心,树形结构,基数排序)
洛谷题目传送门 \(O(n)\)算法来啦! 复杂度优化的思路是建立在倍增思路的基础上的,看看楼上几位巨佬的描述吧. 首先数组倍长是一样的.倍增法对于快速找到\(j\)满足\(l_j+m\le r_i\ ...
- 【BZOJ2817】[ZJOI2012]波浪(动态规划)
[BZOJ2817][ZJOI2012]波浪(动态规划) 题面 BZOJ 洛谷 题解 首先这个差值最大也就是\(n^2\)级别的. 那么这样子就可以压进状态啦. 我们把这个操作看成一个个加数的操作,按 ...
- HR_Array Manipulation
第一版有7个时间超限,优化成了第二版: 1: #!/bin/python3 import math import os import random import re import sys # Com ...
- Xposed+JustTrustMe+Android
场景介绍:APP抓包 引出的知识点:ssl-pinning. ssl-pinning: apk在开发时就将服务端证书一块打包到客户端里.这样在HTTPS建立时与服务端返回的证书比对一致性,进而识别出中 ...
- 单片机pwm控制基本原理详解
前言 PWM是Pulse Width Modulation的缩写,它的中文名字是脉冲宽度调制,一种说法是它利用微处理器的数字输出来对模拟电路进行控制的一种有效的技术,其实就是使用数字信号达到一个模拟信 ...