Chinaunix首页 | 论坛 | 博客
  • 博客访问: 88990
  • 博文数量: 69
  • 博客积分: 0
  • 博客等级: 民兵
  • 技术积分: 697
  • 用 户 组: 普通用户
  • 注册时间: 2014-05-03 23:44
文章分类

全部博文(69)

文章存档

2014年(69)

我的朋友

分类: LINUX

2014-05-16 00:04:29

service nginx does not support chkconfig 解决办法:
在启动脚本中加入:
# Startup script for the Nginx Web Server
#
# chkconfig: 2345 85 15
# description: Nginx is a World Wide Web server.
#
其中:
2345 表示LINUX需要启动的各个级别,如果一个都不想on,那就写一个横线"-",比如:chkconfig: - 85 15
85 15 表示S和K的默认排序号.
再添加成功
chkconfig --add nginx
chkconfig nginx on


85 15 表示S和K的默认排序号。启动序号(85);关闭序号(15)。
添加后:
# chkconfig --list | grep nginx
nginx           0:off 1:off 2:on 3:on 4:on 5:on 6:off
# ll /etc/rc.d/rc0.d/ | grep nginx
lrwxrwxrwx 1 root root 15 Jun 13 11:41 K15nginx -> ../init.d/nginx
# ll /etc/rc.d/rc1.d/ | grep nginx
lrwxrwxrwx 1 root root 15 Jun 13 11:41 K15nginx -> ../init.d/nginx
# ll /etc/rc.d/rc2.d/ | grep nginx
lrwxrwxrwx 1 root root 15 Jun 13 11:42 S85nginx -> ../init.d/nginx
# ll /etc/rc.d/rc3.d/ | grep nginx
lrwxrwxrwx 1 root root 15 Jun 13 11:42 S85nginx -> ../init.d/nginx
# ll /etc/rc.d/rc4.d/ | grep nginx
lrwxrwxrwx 1 root root 15 Jun 13 11:42 S85nginx -> ../init.d/nginx
# ll /etc/rc.d/rc5.d/ | grep nginx
lrwxrwxrwx 1 root root 15 Jun 13 11:42 S85nginx -> ../init.d/nginx
# ll /etc/rc.d/rc6.d/ | grep nginx
lrwxrwxrwx 1 root root 15 Jun 13 11:41 K15nginx -> ../init.d/nginx
阅读(2332) | 评论(0) | 转发(0) |
0

上一篇:rpm常用命令

下一篇:pgrep kill pkill killall

给主人留下些什么吧!~~