Thursday, December 9, 2010

Configuration of startup services on Debian (and Ubuntu)

sysvconfig is a tool which allows setting of what services start up on debian.  It works in conjunction with the /sbin/service command to start and stop them at runtime as well.

http://www.itoperationz.com/2010/04/how-to-configure-startup-services-in-debian-lenny/

There are various methods for managing access to system services:
1) /etc/init.d/service
2) rcconf
3) update-rc.d etc
 
svsvconfig – Services Startup Configuration Tool
Debian and Ubuntu Linux also offers service command. It can be used to execute System V style init script stored at /etc/init.d/service-name { start|stop|restart|action }.

sysvconfig package
First, install sysvconfig package:
$ sudo apt-get install sysvconfig 

Package sysvinit-utils has replaced it Ubuntu 10.10

To start / restart / stop service, use the following syntax:
$ sudo service {service-name} restart <-- Restart service
$ sudo service {service-name} stop <-- Stop service
$ sudo service {service-name} start <-- Start service


For example to stop apache service, enter:
$ sudo service apache stop

sysvconfig command

This is a text-based application that allows you to configure which services are started at boot time for each run level. It is simple interface for configuring run levels. sysvconfig is just like ntsysv under Redhat Linux. It has dialog based interactive, menus to help automate setting up Sys V style init script links:
  • Enable or disable services.
  • Edit individual links.
  • Restore from backup file if you make a mistake.
  • Menu or command line interface.
  • View all services, each with its status and a brief description.

No comments:

Post a Comment