is a generic interface to execute System V style init script
actions, obeying runlevel constraints as well as any local
policies set by the system administrator.
All access to the init scripts by Debian packages' maintainer
scripts should be done through
This manpage documents only the usage and behavior of
For a discussion of the System V style init script arrangements please
dpkg Programmers' Manual.
More information on invoke-rc.d can be found in the section on
runlevels and init.d scripts of the
Debian Policy Manual.
INIT SCRIPT ACTIONS
The standard actions are:
Other actions are accepted, but they can cause problems to
INIT SCRIPT POLICY
section), so warnings are generated if the policy layer
Please note that not all init scripts will implement all
the actions listed above, and that the policy layer may
override an action to another action(s), or even deny it.
Any extra parameters will be passed to the init script(s) being
If an action must be carried out regardless of any local
policies, use the
Display usage help.
Quiet mode, no error messages are generated.
Tries to run the init script regardless of policy and
init script subsystem errors.
Use of this option in Debian maintainer scripts is severely discouraged.
Tries to run the init script if a non-fatal error is
Return status code 101 instead of status code 0 if
the init script action is denied by the policy layer.
Returns one of the status codes 100-106. Does not
run the init script, and implies
Ignores any fallback action requests by the policy
this is usually a very bad idea for any actions other
Should an init script be executed,
always returns the status code
returned by the init script. Init scripts should not return status codes in
the 100+ range (which is reserved in Debian and by the LSB). The status codes
returned by invoke-rc.d proper are:
Either the init script was run and returned exit status 0 (note
that a fallback action may have been run instead of the one given in the
command line), or it was not run because of runlevel/local policy constrains
is not in effect.
- 1 - 99
Reserved for init.d script, usually indicates a failure.
Init script ID
This means the init script was not registered successfully through
or that the init script does not exist.
Action not allowed.
The requested action will not be performed because of runlevel or local
Init script (or policy layer) subsystem malfunction. Also, forced
init script execution due to
Init script would be run, but
is in effect.
It cannot be determined if action should be carried out or not, and
is in effect.
Fallback action requested.
The policy layer denied the requested action, and
supplied an allowed fallback action to be used instead.
INIT SCRIPT POLICY
introduces the concept of a policy layer which is used to verify if
an init script should be run or not, or if something else should be
done instead. This layer has various uses, the most immediate ones
being avoiding that package upgrades start daemons out-of-runlevel,
and that a package starts or stops daemons while inside a chroot
The policy layer has the following abilities: deny or approve the
execution of an action; request that another action (called a
is to be taken, instead of the action requested in invoke-rc.d's
command line; or request multiple actions to be tried in order, until
one of them succeeds (a multiple
itself only pays attention to the current runlevel; it will block
any attempts to start a service in a runlevel in which the service is
disabled. Other policies are implemented with the use of the
helper, and are only available if
is installed in the system.
System V init scripts.
Init script policy layer helper (not required).
file-rc runlevel configuration (if the file-rc package is
System V runlevel configuration (if the sysv-rc package is
not being used).
Please report any bugs using the Debian bug tracking system,
http://bugs.debian.org/, packages sysv-rc or file-rc
(depending on which version of invoke-rc.d you are using).
dpkg Programmers' manual,
- INIT SCRIPT ACTIONS
- STATUS CODES
- INIT SCRIPT POLICY
- SEE ALSO
This document was created by
using the manual pages.
Time: 04:17:50 GMT, September 24, 2010