libpcre.so.1 cannot be found
安装完Nginx之后,启动报错。
[vagrant@localhost sbin]$ sudo ./nginx
./nginx: error while loading shared libraries: libpcre.so.1: cannot open shared object file: No such file or directory
运行ldd命令,找到Nginx的依赖共享库文件。
vagrant@localhost sbin]$ ldd $(which /usr/local/nginx/sbin/nginx)
linux-vdso.so.1 => (0x00007fff1b74a000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00000032b2600000)
libcrypt.so.1 => /lib64/libcrypt.so.1 (0x00000032b3a00000)
libpcre.so.1 => not found
libcrypto.so.6 => /lib64/libcrypto.so.6 (0x00000032b4200000)
libc.so.6 => /lib64/libc.so.6 (0x00000032b1a00000)
/lib64/ld-linux-x86-64.so.2 (0x00000032b1600000)
libdl.so.2 => /lib64/libdl.so.2 (0x00000032b1e00000)
libz.so.1 => /usr/lib64/libz.so.1 (0x00000032b3200000)
原来是真的没找到libpcre.so.1文件。
进入lib64文件夹,对libpcre.so.0.0.1做软连接。
[vagrant@localhost lib64]$ cd /lib64/
[vagrant@localhost lib64]$ sudo ln -s libpcre.so.0.0.1 libpcre.so.1
再次运行ldd命令,就能够找到libpcre.so.1依赖库了。
[vagrant@localhost lib64]$ ldd $(which /usr/local/nginx/sbin/nginx)
linux-vdso.so.1 => (0x00007fffd43d5000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00000032b2600000)
libcrypt.so.1 => /lib64/libcrypt.so.1 (0x00000032b3a00000)
libpcre.so.1 => /lib64/libpcre.so.1 (0x00000032b1e00000)
libcrypto.so.6 => /lib64/libcrypto.so.6 (0x00000032b4200000)
libc.so.6 => /lib64/libc.so.6 (0x00000032b1a00000)
/lib64/ld-linux-x86-64.so.2 (0x00000032b1600000)
libdl.so.2 => /lib64/libdl.so.2 (0x00002aebb7623000)
libz.so.1 => /usr/lib64/libz.so.1 (0x00000032b3200000)
ok, 如今就能够成功启动Nginx。
[vagrant@localhost sbin]$ sudo ./nginx
[vagrant@localhost sbin]$ sudo netstat -ntlp | grep nginx
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 17529/nginx
libpcre.so.1 cannot be found的更多相关文章
- nginx无法启动: libpcre.so.1/libpcre.so.0: cannot open shared object file解决办法
NGINX启动时提示错误: /usr/local/nginx/sbin/nginx -t/usr/local/nginx/sbin/nginx: error while loading shared ...
- 关于pcre正则表达式库libpcre
gcc 4.8中已经包含了std regex的头文件 可是没有实现,所以链接是失败的 gcc 4.9完整的支持了c++ 11的regex. 在4.9以前,可以寻求boost的regex. 不过,我更熟 ...
- nginx libpcre.so.1: cannot open shared object file
linux 64位安装nginx后启动出错报以下错误 1 2 3 [root@localhost nginx-1.3.0]# /usr/local/nginx/sbin/nginx error whi ...
- [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 ...
- 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: ...
- 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: libpcre.so.1解决
Shell代码 [root@tmsapp65 conf]# /usr/local/nginx/sbin/nginx /usr/local/nginx/sbin/nginx: error while l ...
- 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 ...
- Nginx启动提示找不到libpcre.so.1解决方法
如果是32位系统 [root@lee ~]# ln -s /usr/local/lib/libpcre.so.1 /lib 如果是64位系统 [root@lee ~]# ln -s /usr/lo ...
随机推荐
- zepto源码学习-02 工具方法-详细解读
上一篇:地址 先解决上次留下的疑问,开始看到zepto.z[0]这个东西的时候,我很是不爽,看着它都不顺眼,怎么一个zepto的实例对象var test1=$('#items'); test__pr ...
- android activity在横竖屏切换的时候不重新调用onCreate方法
在安卓系统中,横竖屏切换会默认重新调用onCreate等生命周期方法,如果此时有一些临时数据没有保存下来,很有可能会导致该数据丢失. 因此我们可以进行以下设置,来避免恒切换时重新调用onCreate方 ...
- [Gauss]POJ1753 Flip Game
题意:给4×4的棋盘的初始状态,b代表黑,w代表白. 要求变成全黑或者全白 最少需要几步. 简单的做法 可以暴搜 状压bfs 不再赘述 主要学习Gauss做法 同样是01方程组 用异或解 注意全黑或全 ...
- Ci框架整合smarty模板引擎
Ci框架整合smarty模板引擎 备注:下载smarty时,最好选择2.6版本,其他测试有坑,ci可以是2.2或其他 大体思路:将smarty封装成ci框架的一个类,然后重新配置一下smarty,这样 ...
- HDU 2493 Timer 数学(二分+积分)
传送门:http://acm.hdu.edu.cn/showproblem.php?pid=2493 题意:给你一个圆锥,水平放置,圆锥中心轴与地面平行,将圆锥装满水,在圆锥某一表面开一个小洞,流出来 ...
- poj3368Frequent values(RMQ)
http://poj.org/problem?id=3368 追完韩剧 想起这题来了 想用线段树搞定来着 结果没想出来..然后想RMQ 想出来了 算是离散吧 把每个数出现的次数以及开始的位置及结束的位 ...
- JS頁面值傳遞
<script type="text/javascript"> function GetValue() { var url=location.search; var R ...
- BZOJ_3282_Tree_(LCT)
描述 http://www.lydsy.com/JudgeOnline/problem.php?id=3282 给出n个点以及权值,四种操作: 0.求x,y路径上的点权值的异或和. 1.连接x,y. ...
- Samba nsswitch/pam_winbind.c文件输入验证漏洞
漏洞名称: Samba nsswitch/pam_winbind.c文件输入验证漏洞 CNNVD编号: CNNVD-201312-047 发布时间: 2013-12-05 更新时间: 2013-12- ...
- Memcached 两款.NET客户端的郁闷事儿
不久以后就要负责一个比较大的项目,有多大?反正就是挺大的.现在处于筹备阶段,我主要负责系统框架搭建,在系统缓存这一块决定采用Http运行时缓存+memcached. memcached 以前用过几次 ...