Apr 1, 2007

System Startup File

A single Linux system can provide several different services such as mail, Web, or FTP servers. Each service operates as a continually running daemon looking for requests for its particular services from remote users. We can turn services on or off by starting or shutting down their daemons. The process of starting or shutting down a service is handled by service scripts
1. System Startup File: /etc/rc.d and /etc/sysconfig
A series of startup commands are located in /etc/rc.d directory.
/etc/rc.d/rc.sysinit
holds the commands for initializing system, including the mounting and unmounting of file systems.
System Startup Files:
/etc/sysconfig: Directory that holds system configuration files and directories.
/etc/rc.d: Directory that holds system startup and shutdown files.
/etc/rc.d/rc.sysinit: Initialization file for system.
/etc/rc.d/rc.local: Initialization file for my own commands, can be free edit this file to add my own startup commands, this is the last startup file executed.
/etc/rc.d/modules: Loads kernel modules
/etc/rc.d/init.d:
Directory that holds network scripts to start up network connections.
/etc/rc.d/rc.num.d: Directories for different runlevels, where num is the runlevel. The directories hold links to scripts in the /etc/rd.d/init.d directory.
/etc/rc.d/init.d/halt: Operations performed each time you shut down the system, such as unmounting file systems, called rc.halt in other distributions.
/etc/rc.d/init.d/cups: Start up and shutdown the cups printer daemons.
/etc/rc.d/init.d/xinetd: Operations to start up or shutdown the xinetd daemon.
/etc/rc.d/init.d/network: Operations to start up or shutdown the network connections.
/etc/rc.d/init.d/httpd: Operations to start up or shutdown the Web server daemon, httpd.
To configure a service to start up automatically at boot, we can use te redhat-config-services tool available on the desktop or the chkconfig tool, which is run at a command line.

No comments: