已解答
发布

service nginx start|stop|restart   等等, 启动会这个错。

Job for nginx.service failed because a configured resource limit was exceeded. See "systemctl status nginx.service" and "journalctl -xe" for details.
[FAIL
[root@localhost showdoc]# systemctl status nginx.service
● nginx.service - SYSV: Nginx is an HTTP(S) server, HTTP(S) reverse proxy and IMAP/POP3 proxy server
Loaded: loaded (/etc/rc.d/init.d/nginx)
Active: failed (Result: resources) since Wed 2016-11-23 11:04:24 CST; 19min ago
Docs: man:systemd-sysv-generator(8)
Process: 6852 ExecStart=/etc/rc.d/init.d/nginx start (code=exited, status=0/SUCCESS)

Nov 23 11:04:24 localhost.localdomain systemd[1]: Starting SYSV: Nginx is an HTTP(S) server, HTTP(S) reverse proxy and IMAP/POP3 proxy server...
Nov 23 11:04:24 localhost.localdomain systemd[1]: PID file /var/run/nginx.pid not readable (yet?) after start.
Nov 23 11:04:24 localhost.localdomain systemd[1]: Failed to start SYSV: Nginx is an HTTP(S) server, HTTP(S) reverse proxy and IMAP/POP3 proxy server.
Nov 23 11:04:24 localhost.localdomain systemd[1]: Unit nginx.service entered failed state.
Nov 23 11:04:24 localhost.localdomain systemd[1]: nginx.service failed

nginx的配置是没问题的。

Nov 23 11:04:24 localhost.localdomain systemd[1]: nginx.service failed.
[root@localhost showdoc]# /usr/local/nginx/sbin/nginx -t
nginx: the configuration file /usr/local/nginx/conf/nginx.conf syntax is ok
nginx: configuration file /usr/local/nginx/conf/nginx.conf test is successful

详细看 systemctl status nginx.service  的问题。 检查了都没问题。 至今无解。   

6 答案

发布
管理员 2016-11-24

killall nginx
/usr/local/nginx/sbin/nginx -c /usr/local/nginx/conf/nginx.conf #这样启动是否有问题?

#1
发布

@oneinstack      那种是没问题的。装的时候 用service不行, 我就是一直 用 原始方法启动跟重启的。

#2
发布

@oneinstack  我只是想知道 service的方法为何会那样

#3
发布
管理员 2016-11-24

操作系统具体版本多少?

#4
发布

@oneinstack 

[root@localhost ~]# cat /etc/redhat-release
CentOS Linux release 7.2.1511 (Core)
#5
发布

我和你遇到了一样的问题,而且我的也是centos7,,是不是oneinstack有BUG?

#6

请登录或者 注册 来提交答案