Kbase P9114: Scripts and RUNLEVELS on AIX.
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  3/18/2003 |
|
Status: Unverified
GOAL:
Scripts and RUNLEVELS on AIX.
GOAL:
How to boot an AIX machine at a specific RUNLEVEL.
GOAL:
Running a script when an AIX machine boots at a specific RUNLEVEL.
FACT(s) (Environment):
IBM AIX 4.3.3
Progress 9.1D
FIX:
An entry in the inittab file has to be made. This file controls the initialization process. Unless it has been moved elsewhere, inittab will be located in the /etc directory. The first inittab entry covers the initdefault, which determines the initial RUNLEVEL. For instance, an entry such as
init:2:initdefault:
means that the machine boots with an initial RUNLEVEL of 2. Replacing the 2 with a 3 will see the machine boot with RUNLEVEL 3.
Scripts can then be added to the relevant rcx.d file in the /etc/rc.d directory, where x is the RUNLEVEL at which the script should run, e.g. a script that should run if the machine boots at RUNLEVEL 3 should be located in /etc/rc.d/rc3.d. When the machine boots with the specific RUNLEVEL, the script will run.
who -r can be used to confirm the RUNLEVEL.
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Disclaimer:
Refer to your system documentation for further clarification of inittab file and the rc.d directory before making any changes.