|
先做个软链接方便使用:- ln -s /usr/local/nginx/sbin/nginx /bin
复制代码 参数列表:- -?,-h : this help
- -v : show version and exit
- -m : show all modules and exit
- -l : show all directives and exit
- -V : show version, modules and configure options then exit
- -t : test configuration and exit
- -d : dump configuration and exit
- -q : suppress non-error messages during configuration testing
- -s signal : send signal to a master process: stop, quit, reopen, reload
- -p prefix : set prefix path (default: /usr/local/nginx/)
- -c filename : set configuration file (default: conf/nginx.conf)
- -g directives : set global directives out of configuration file
复制代码 控制:- nginx -s stop #快速停止
- nginx -s quit #正常退出
- nginx -s reopen #重新打开日志文件
- nginx -s reload #重载配置
复制代码 |
|