目录在/etc/ngnix/conf.d下
找出nginx配置文件路径和测试配置文件是否正确
# /usr/sbin/nginx -t
几种重启Nginx的方式:
service nginx restart
/etc/init.d/nginx restart
systemctl restart nginx
------------------------
[root@svr-005:~]$ /usr/sbin/nginx -t
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: configuration file /etc/nginx/nginx.conf test is successful
[root@svr-005:~]$ service nginx restart
Stoping nginx... nginx is not running.
Starting nginx... /etc/init.d/nginx: line 38: /www/server/nginx/sbin/nginx: No such file or directory
failed
本文来自博客园,作者:三哥-Noble,转载请注明原文链接:https://www.cnblogs.com/Noble-zeng/p/12837213.html