nginx报错

nginx在安装完成之后启动报错

sbin/nginx: error while loading shared libraries: libcrypto.so.6: cannot open shared object file: No such file or directory

由错误提示可以看出缺少libcrypto.so.6

查看nginx需要哪些依赖库

ldd $(which /app/nginx/sbin/nginx) 

通过yum install openssl* 安装

报错could not open error log file: open() "/opt/modules/nginx/logs/error.log" failed

可以通过启动参数指定nginx的安装目录

sbin/nginx -p /app/nginx/ -c /app/nginx/conf/nginx.conf

猜你喜欢

转载自zhaocuifang-bf.iteye.com/blog/2260933