HP B2355-92068 Administration Manual page 127

System administration commands
Table of Contents

Advertisement

ch_rc(1M)
NAME
ch_rc - change system configuration file
SYNOPSIS
/usr/sbin/ch_rc -a
DESCRIPTION
manages the addition, modification, removal, and retrieval of information stored in files having the
ch_rc
format of those in the
Parameter names are treated as strings. Thus,
other parameters named
Options
file
Specify the file(s) to be used as the configuration database. If no file is specified, the set of
files
/etc/rc.config.d
Modification and deletion of configuration parameters occurs in the file where the parame-
ter is found.
Add or modify a parameter definition. For each parameter specified on the command line, if
-a
the parameter is found in the specified (or default) files, it is modified to reflect the specified
value. If the parameter is not found, it is added to the specified file(s).
If a new parameter is being defined, one or more files must be specified on the command
line; the specified files are those in which the parameter will be defined.
-r
Remove a parameter definition. For each parameter name specified on the command line,
remove any occurrence of that parameter from the specified file(s).
-l
List configuration values. For each parameter specified on the command line, output every
definition of the parameter from the specified file(s). Output consists of only the values,
one per line.
Specify a parameter name or name/value pair. If a name and value is expected, but only a
-p
name is specified, the value will be set to the empty string. For example, specifying
or
FOO=
Due to shell quoting rules, if you need a quoted parameter value, you must protect the
quotes from the shell. For example,
ch_rc -a -p VALUE="a b c" <file>
yields:
VALUE=a b c
which is an error, whereas,
ch_rc -a -p VALUE='"a b c"' <file>
yields:
VALUE="a b c"
Verbose. When used with the
-v
put. This listing includes a filename followed by the entire line containing the specified
parameter for each occurrence of the parameter.
The
-A
-A
specified on the command line.
For example,
ch_rc -l -A -v -p ZZZ file
may emit the following output:
file: ZZZ[0]=zero
file: ZZZ[5]=five
file: ZZZ[9]=fred
HP-UX 11i Version 2: December 2007 Update
|
-r
|
-l
[
-v
] [
-A
] [
-R
/etc/rc.config.d
directory.
X[1]
or
X
.
used
by
ch_rc
defaults
directory.
will result in
and
FOO
-l
option is used to list all occurrences of array parameters matching the parameters
− 1 −
root] [
-p
{parameter|parameter=value}...]
has no special meaning to
X[0]
to
/etc/TIMEZONE
respectively.
FOO=
option, the
option causes a verbose listing to be out-
-v
Hewlett-Packard Company
ch_rc(1M)
[ file ...]
in relation to
ch_rc
and
all
files
in
the
FOO
127
c

Advertisement

Table of Contents
loading

This manual is also suitable for:

Hp-ux 11i

Table of Contents