HPE Community read-only access December 15, 2018
This is a maintenance upgrade. You will be able to read articles and posts, but not post or reply.
Dec 15, 4:00 am to 10:00 am UTC
Dec 14, 10:00 pm CST to Dec 15, 4:00 am CST
Dec 14, 8:00 pm PST to Dec 15, 2:00 am PST
Showing results for 
Search instead for 
Did you mean: 

startup services

Go to solution
Frequent Contributor

startup services

i want to start appachy service at the time of booting automaticaly. how to do it. kinly explain steps.
Esteemed Contributor

Re: startup services

according to which default runlevel you have in /etc/inittab, the startup-scripts are executed in /sbin/rcX.d/ . Actually they are just symbolic links to scripts in /sbin/init.d/ .

You can try to make your own script, look at the /sbin/init.d/template file and modify it according to your needs. Then just rename it (S for startup script, K for killing/stopping script + the sequence execution number) and copy it to /sbin/init.d/ and make a symbolic link in /sbin/rcX.d/ , depending in which run-level you want to run the script.

But I think that apache should have it's own startup/shutdown script in /sbin/init.d

Honored Contributor

Re: startup services

Ismail Azad
Esteemed Contributor

Re: startup services

Hi Abubakkar,

The script you are looking for is /sbin/init.d/hpws_apache .

So the command is /sbin/init.d/hpws_apache start would start the Apache service . The corresponding configuration the script will look at is called as /etc/rc.config.d/hpws_apacheconf where you have a variable called as HPWS_APACHE_START which should be put as 1 in case you want the apache service to start at boot time. Don't forget to assign points

Ismail Azad
Read, read and read... Then read again until you read "between the lines".....
James R. Ferguson
Acclaimed Contributor

Re: startup services


If you question is more general and is how to write shutdown and startup scripts, read the 'rc(1M)' manpages.