The scripts to control most services are stored in /etc/rc.d/init.d/ .
If you don't have one for httpd, copy the script for a similar service
(like inet), and modify it so that it refers to httpd.
However, this directory is just a common home for control scripts. You
make the program start on boot by symlinking to it from the appropriate
/etc/rc.d/rc?.d directory. http should be symlinked from
/etc/rc.d/rc3.d, /etc/rc.d/rc4.d, and /etc/rc.d/rc5.d, corresponding to
runlevels 3, 4, and 5.
You can use the program chkconfig to automate creating the symlinks for
you. Edit the
line in the httpd init script to read something like
# chkconfig: 345 85 15
and then run
/sbin/chkconfig --add httpd
This will create the appropriate symlinks for you, and cause httpd to be
started when entering runlevels that expect it.
> My linux is RH6.1 . For some reasons, I install the apache in tar format. It
> works fine.
> But the web server don't start up at boot time now. I need to start it up
> How can I set to make it start up at boot ? I've tried to put a script in
> /etc/rc.d/init.d to start web server. But don't work.
> How can I do ?