Novell LINUX ENTERPRISE SERVER 10 SP2 - INSTALLATION AND ADMINISTRATION Installation Manual page 417

Hide thumbs Also See for LINUX ENTERPRISE SERVER 10 SP2 - INSTALLATION AND ADMINISTRATION:
Table of Contents

Advertisement

You can create your own scripts and easily integrate them into the scheme described
above. For instructions about formatting, naming, and organizing custom scripts, refer
to the specifications of the LSB and to the man pages of init, init.d, chkconfig,
and insserv. Additionally consult the man pages of startproc and killproc.
WARNING: Faulty init Scripts May Halt Your System
Faulty init scripts may hang your machine. Edit such scripts with great care and,
if possible, subject them to heavy testing in the multiuser environment. Find
some useful information about init scripts in Section 20.2.1, "Runlevels"
(page 393).
To create a custom init script for a given program or service, use the file /etc/init
.d/skeleton as a template. Save a copy of this file under the new name and edit
the relevant program and filenames, paths, and other details as needed. You may also
need to enhance the script with your own parts, so the correct actions are triggered by
the init procedure.
The INIT INFO block at the top is a required part of the script and must be edited.
See Example 20.1, "A Minimal INIT INFO Block" (page 399).
Example 20.1 A Minimal INIT INFO Block
### BEGIN INIT INFO
# Provides:
# Required-Start:
# Required-Stop:
# Default-Start:
# Default-Stop:
# Description:
### END INIT INFO
In the first line of the INFO block, after Provides:, specify the name of the program
or service controlled by this init script. In the Required-Start: and
Required-Stop: lines, specify all services that need to be started or stopped before
the service itself is started or stopped. This information is used later to generate the
numbering of script names, as found in the runlevel directories. After
Default-Start: and Default-Stop:, specify the runlevels in which the service
should automatically be started or stopped. Finally, for Description:, provide a
short description of the service in question.
FOO
$syslog $remote_fs
$syslog $remote_fs
3 5
0 1 2 6
Start FOO to allow XY and provide YZ
Booting and Configuring a Linux System
399

Advertisement

Table of Contents
loading

This manual is also suitable for:

Suse linux enterprise server 10 sp3

Table of Contents