Jump to content

Running and Stopping processes [solved]


Recommended Posts

Hi.

 

I've been searching this forum for answer to my question, but haven't found anything related to this.

 

I can do this from Webmin, but i've forbidden all outside access to my server's Webmin. I want to do this via SSH.

 

So my question is:

 

How do i make processes run/not to run at boot time?

 

My httpd (just an example) process starts at boot, but i don't want it to start automatically. Is there a command to do this or do i have to change some file under /etc ?

 

I know that i can run and stop processes like this:

 

su root
service httpd start

 

And stop:

 

su root
service httpd stop

 

But i don't know where to look for this setting.

 

Thanks.

Murda

Link to comment
Share on other sites

To get a list of services using ssh:

 

chkconfig --list

 

of course, if you want to filter, let's say the service for apache is httpd, so:

 

chkconfig --list httpd

 

it will then list the runlevels it is set to "On", normally these will be runlevels 3 or 5, but also include some other runlevels too.

 

To stop it so that it never starts at boot:

 

chkconfig httpd off

 

this will mean it will never start when the system is rebooted. Therefore, if you want to start it manually:

 

service httpd start

 

other parameters are to replace start with stop to stop the service, or with status to find out if it's running.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...