#!/bin/bash # # Startup script for the Apache Web Server # # chkconfig: 345 85 15 # description: Apache is a World Wide Web server. It is used to serve \ # HTML files and CGI. # processname: httpd # pidfile: /var/run/httpd.pid # config: /etc/httpd/conf/access.conf # config: /etc/httpd/conf/httpd.conf # config: /etc/httpd/conf/srm.conf # Source function library. . /etc/rc.d/init.d/functions # Check that networking is up. [ "${NETWORKING}" = "no" ] && exit0 # See how we were called. case "$1" in start) show Starting httpd daemon +5 httpd touch /var/lock/subsys/httpd ;; stop) show Shutting down httpd killproc httpd rm -f /var/lock/subsys/httpd /var/run/httpd.pid ;; status) status httpd ;; restart) $0 stop $0 start ;; *) echo "Usage: $0 {start|stop|restart|status}" exit 1 ;; esac exit 0