3.6.2 Enabling and Disabling Configuration Modules (ovm-chkconfig)

When a module is enabled, symlinks to the module script are made to other subdirectories within /etc/template.d based on the type of target the module provides, in much the same way that the System V init process works. When a module gets added, the header of the module script is read to verify the name, priority and targets and then a symlink is made to the corresponding subdirectories under /etc/template.d.

Enabling and disabling targets for any module is handled using the ovm-chkconfig script. Usage of this command is outlined using the --help parameter.

Syntax

ovm-chkconfig [ --list [ name ] ] [ --add name ] [ --del name ] [ --target= target ... name { on | off } ] [ --version ] [ { -h | --help } ]

Where target is:

{ configure | unconfigure | reconfigure | cleanup | suspend | resume | migrate | shutdown }

Options

The following table shows the available options for this command.

Option

Description

[ --list [ name ] ]

Lists the status of the script name.

[ --add name ]

Add a new script name.

[ --del name ]

Delete a script name.

[ --target= target ... name { on | off } ]

Specify the targets in a comma separated list, for example:

--target="configure,unconfigure"

--version

Show the ovm-chkconfig script version number and exit.

{ -h | --help }

Show help on the ovm-chkconfig command options.

Examples

Example 3.13 Listing available modules and their target runtime status

# ovm-chkconfig --list
name            configure  unconfigure reconfigure cleanup  suspend  resume  migrate  shutdown 
authentication  on:90      off         off         off      off      off     off      off     
datetime        on:50      off         off         off      off      off     off      off     
firewall        on:41      off         off         off      off      off     off      off     
network         off        off         off         off      off      off     off      off     
selinux         off        off         off         off      off      off     off      off     
ssh             off        off         off         off      off      off     off      off     
system          off        off         off         off      off      off     off      off     
user            off        off         off         off      off      off     off      off

Example 3.14 Enabling all targets supported by a module

# ovm-chkconfig --add authentication

Example 3.15 Disabling all targets supported by a module

# ovm-chkconfig --del datetime

Example 3.16 Disabling particular targets for a module

# ovm-chkconfig --target=cleanup user off