12.07.2015 Views

Red Hat Enterprise Linux 5 Administration Unleashed

Red Hat Enterprise Linux 5 Administration Unleashed

Red Hat Enterprise Linux 5 Administration Unleashed

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Initialization Scripts 1194FIGURE 4.10Changing File PermissionsDepending on how your system is configured, files might also have access control lists orSecurity-Enhanced <strong>Linux</strong> rules associated with them. Refer to the next section on “AccessControl Lists” and Chapter 23, “Protecting Against Intruders with Security-Enhanced<strong>Linux</strong>,” for details.Initialization ScriptsNetwork services such as the Apache HTTP Server and DHCP along with other programssuch as cron and syslog require a daemon to be running at all times. The daemon performsactions such as listening for connections to a service on specific ports, making surecommands are executed at specific times, and capturing data such as log messages whenthey are sent out by other programs.Programs that require a daemon to be started have aninitialization script in the /etc/rc.d/init.d/ directory. An initialization script can also beused to run a command at boot time such as the readahead_early and readahead_laterscripts, which run the readahead utility so that programs used at startup are loaded intomemory before they are needed. Doing so decreases the amount of time it takes to start thesystem. When you boot a <strong>Red</strong> <strong>Hat</strong> <strong>Enterprise</strong> <strong>Linux</strong> system, the init program is run last inthe kernel boot process. This program first executes the /etc/rc.d/rc.sysinit script toperform actions such as loading kernel modules for hardware support, loading the defaultkeymap, and setting the hostname. The /etc/inittab script is run next, which then tellsinit which runlevel to start. The runlevel defines which services to start at boot time, orwhich initialization scripts to execute. Refer to the later section “Runlevels” for details onhow runlevels are configured.Lastly, the /etc/rc.d/rc.local script is executed. Commands can be added to this file forcustom initialization.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!