1、优雅停止
信号:WINCH
[iyunv@localhost~]# /appl/apache/bin/apachectl -kgraceful-stop #
[iyunv@localhost ~]# elinks -dump http://192.168.137.3 #使用elinks访问测试
ELinks: 拒绝连接
2、优雅重启
信号:USR1 [iyunv@localhost ~]# /appl/apache/bin/apachectl -k graceful httpd not running, trying to start [iyunv@localhost ~]# ps aux |grep httpd root 5595 0.0 0.3 33420 3260 ? Ss 16:34 0:00 /appl/apache2.2.22/bin/httpd -k graceful daemon 5596 0.0 0.1 31976 1296 ? S 16:34 0:00 /appl/apache2.2.22/bin/httpd -k graceful daemon 5597 0.0 0.1 33152 1144 ? S 16:34 0:00 /appl/apache2.2.22/bin/httpd -k graceful daemon 5598 0.0 0.3 377680 3900 ? Sl 16:34 0:00 /appl/apache2.2.22/bin/httpd -k graceful daemon 5599 0.0 0.3 377680 3904 ? Sl 16:34 0:00 /appl/apache2.2.22/bin/httpd -k graceful daemon 5600 0.0 0.3 377680 3908 ? Sl 16:34 0:00 /appl/apache2.2.22/bin/httpd -k graceful root 5683 0.0 0.0 103248 836 pts/1 S+ 16:34 0:00 grep httpd 测试: It works! 3、Apache正常启动、关闭、重启
[iyunv@localhost ~]# /appl/apache/bin/apachectl -k stop httpd (no pid file) not running ELinks: 拒绝连接 [iyunv@localhost ~]# [iyunv@localhost ~]# /appl/apache/bin/apachectl -k start It works! [iyunv@localhost ~]# /appl/apache/bin/apachectl -k restart It works!
|