nginx常用的几个命令
程序员文章站
2022-03-01 17:06:08
...
nginx常用的几个命令:
#启动nginx
./nginx
#查看nginx版本
./nginx -v
#关闭nginx
./nginx -s stop
#查看nginx启动情况
ps -ef | grep nginx
#重新加载
./nginx -s reload
例子:
[[email protected] sbin]# pwd
/usr/local/nginx/sbin
[[email protected] sbin]#
[[email protected] sbin]# ./nginx -v
[[email protected] sbin]# ./nginx -s stop
[[email protected] sbin]# ps -ef | grep nginx
root 48634 8057 0 20:24 pts/1 00:00:00 grep --color=auto nginx
[[email protected] sbin]# ./nginx
[[email protected] sbin]# ps -ef | grep nginx
root 48662 1 0 20:26 ? 00:00:00 nginx: master process ./nginx
nobody 48663 48662 0 20:26 ? 00:00:00 nginx: worker process
root 48675 8057 0 20:26 pts/1 00:00:00 grep --color=auto nginx
[[email protected] sbin]#
[[email protected] sbin]# ./nginx -s reload
上一篇: '@P0'附近有语法错误
下一篇: Nginx常用的配置和配置案例