Thinking ...

记录所见,所思,所悟...

导航

统计

公告

2009年5月20日 #

编译的httpd不支持chkconfig的解决方法

用chkconfig将自编译设置为系统服务的时候,httpd 服务不支持 chkconfig。

解决过程如下:

1.编辑/etc/init.d/httpd

#!/bin/bash
#chkconfig:345 61 61

#description:Apache httpd

(哈哈,复制粘贴好像有问题,手动输入)

2.配置

[root@localhost ~]# chkconfig --add httpd
[root@localhost ~]# chkconfig --list|grep httpd

httpd           0:关闭 1:关闭  2:关闭 3:关闭  4:关闭  5:关闭  6:关闭

[root@localhost ~]# chkconfig --level 345 httpd on
[root@localhost ~]# chkconfig --list|grep httpd

httpd           0:关闭  1:关闭 2:关闭 3:启用 4:启用 5:启用  6:关闭

 




posted @ 2009-05-20 12:42 barry 阅读(591) 评论(0) 编辑