DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH
 

getconf(C)


getconf -- print configuration dependent values

Syntax

getconf system_variable

getconf path_variable pathname

Description

The getconf command writes the value of configuration dependent variables to standard output.

In the first syntax, getconf writes the value of the variable specified by system_variable.

In the second syntax, getconf writes the value of the variable specified by path_variable for the specified pathname.

If system_variable or path_variable is a legal variable, but is not defined on the current system or in pathname, getconf will display:

undefined

The following variables are recognized as system variables:


ARG_MAX
Maximum length of an argument. The minimum length is defined by {POSIX_ARG_MAX} (see below).

BC_BASE_MAX
Maximum obase values as permitted by the bc command. The minimum value is defined by {POSIX2_BC_BASE_MAX} (see below).

BC_DIM_MAX
Maximum number of array elements permitted by bc. The minimum number is defined by {POSIX2_BC_DIM_MAX} (see below).

BC_SCALE_MAX
Maximum value of scale allowed by bc. The minimum value is defined by {POSIX2_BC_SCALE_MAX} (see below).

BC_STRING_MAX
Maximum length of a string constant accepted by bc. The minimum length is defined by {POSIX2_BC_STRING_MAX} (see below).

CHARCLASS_NAME_MAX
Maximum number of bytes in a character class name.

CHAR_BIT
The number of bits in a type char variable.

CHAR_MAX
The highest possible value of a type char variable.

CHAR_MIN
The minimum possible value of a type char variable.

CHILD_MAX
Maximum number of simultaneous processes per real user ID. The minimum number is defined by {POSIX_CHILD_MAX} (see below).

CLK_TCK
Number of clock ticks per second.

COLL_WEIGHTS_MAX
Maximum number of weights that can be assigned to LC_COLLATE variable. The minimum number is defined by {POSIX2_COLL_WEIGHTS_MAX} (see below).

CS_PATH
The value of the PATH environment variable.

EXPR_NEST_MAX
The maximum number of expressions that can be nested within parentheses by the expr(C) command. The minimum number is defined by {POSIX2_EXPR_NEST_MAX} (see below).

INT_MAX
Maximum value of a type int variable.

INT_MIN
Minimum value of a type int variable.

IOV_MAX
Maximum number of iovec structures that can be used by readv(S) and writev(S) system calls.

KERNEL_CLISTS
Number of clists allocated.

KERNEL_CLISTS_MAX
Maximum number of clists.

KERNEL_DISK
Number of disk drives supported.

KERNEL_DISK_MAX
Maximum number of disk drives that can be supported.

KERNEL_FILE
Size of file table.

KERNEL_FILE_MAX
Maximum size of file table.

KERNEL_FLCKREC
Number of record locks.

KERNEL_FLCKREC_MAX
Maximum number of record locks.

KERNEL_INODE
Size of inode table.

KERNEL_INODE_MAX
Maximum size of inode table.

KERNEL_MOUNT
Size of mount table.

KERNEL_MOUNT_MAX
Maximum size of mount table.

KERNEL_PINODE
Size of High Performance Pipe System (HPPS) inode table.

KERNEL_PINODE_MAX
Maximum size of High Performance Pipe System (HPPS) inode table.

KERNEL_PROC
Size of process table.

KERNEL_PROC_MAX
Maximum size of process table.

KERNEL_REGION
Size of region table.

KERNEL_REGION_MAX
Maximum size of region table.

KERNEL_S5INODE
Size of s5inode table.

KERNEL_S5INODE_MAX
Maximum size of s5inode table.

LINE_MAX
The default maximum length, in bytes, of a command's input line. The length includes the trailing newline.

LONG_BIT
Set to the number of bits in a variable of type long int.

LONG_MAX
Set to the maximum number of bits in a variable of type long int.

LONG_MIN
Set to the minimum number of bits in a variable of type long int.

MB_LEN_MAX
Maximum number of bytes in a character, for any supported locale.

NGROUPS_MAX
This is the maximum number of simultaneous supplementary group IDs available to a process. The minimum number is defined by {POSIX_NGROUPS_MAX} (see below).

NL_ARGMAX
This is the maximum value of the variable digit as passed to the printf(S) and scanf(S) functions.

NL_LANGMAX
This is the maximum number of permissible bytes in a LANG name.

NL_MSGMAX
Set to the maximum number of a message.

NL_NMAX
This is set to the maximum number of permissible bytes in an N-to-1 collation mapping.

NL_SETMAX
The maximum set number.

NL_TEXTMAX
This is set to the maximum number of allowable bytes in a message string.

NZERO
This is the default process priority.

OPEN_MAX
The maximum number of per-process open files. The minimum number is defined by {POSIX_OPEN_MAX} (see below).

PASS_MAX
The maximum number of significant bytes in a

PATH
The path through which the shell searches for a specified command.

_POSIX_ARG_MAX
Maximum length of an argument, including environment data, to the exec(S) function, and the minimum value to which {ARG_MAX} can be set.

_POSIX_CHILD_MAX
Maximum number of simultaneous processes per real user ID, and the minimum value to which {CHILD_MAX} can be set.

_POSIX_JOB_CONTROL
If set to a value other than -1, the implementation supports job control.

_POSIX_LINK_MAX
Maximum number of permitted links to a single file, and the minimum value to which {LINK_MAX} can be set.

_POSIX_MAX_CANON
Maximum number of permitted bytes in a terminal canonical input queue, and the minimum value to which {MAX_CANON} can be set.

_POSIX_MAX_INPUT
Maximum number of permitted bytes in a terminal input queue. The minimum value to which {MAX_INPUT} can be set.

_POSIX_NAME_MAX
Maximum length (in bytes) of a filename, excluding terminating null, and the minimum value to which {NAME_MAX} can be set.

_POSIX_NGROUPS_MAX
Maximum number of simultaneous supplementary group IDs per process, and the minimum value to which {NGROUPS_MAX} can be set.

_POSIX_OPEN_MAX
Maximum number of per-process open files that can be simultaneously open, and the minimum value to which {OPEN_MAX} can be set.

_POSIX_PATH_MAX
Maximum length (in bytes) of a pathname, and the minimum value to which {PATH_MAX} can be set.

_POSIX_PIPE_BUF
Maximum number of bytes guaranteed to be atomic when writing to a pipe, and the minimum value to which {PIPE_BUF} can be set.

_POSIX_SAVED_IDS
If this constant is defined with a value other than -1, each process has a saved user-ID and a saved set-group ID.

_POSIX_SSIZE_MAX
Set to the value that can be stored in an object of size size_t, and the minimum value to which {SSIZE_MAX} can be set.

_POSIX_STREAM_MAX
The maximum number of streams that a single process can have open at any one time, and the minimum value to which {STREAM_MAX} can be set.

_POSIX_TZNAME_MAX
The maximum number of bytes that can make up the name of a timezone, and the minimum value to which {TZNAME_MAX} can be set.

_POSIX_VERSION
Integer value indicating the version of the IEEE POSIX standard supported.

POSIX2_BC_BASE_MAX
Maximum obase values as permitted by the bc command, and the minimum value to which {BC_BASE_MAX} can be set.

POSIX2_BC_DIM_MAX
Maximum number of array elements permitted by bc, and the minimum value to which {BC_DIM_MAX} can be set.

POSIX2_BC_SCALE_MAX
Maximum value of scale allowed by bc, and the minimum value to which {BC_SCALE_MAX} can be set.

POSIX2_BC_STRING_MAX
Maximum length of a string constant accepted by bc, and the minimum value to which {BC_STRING_MAX} can be set.

POSIX2_C_BIND
A figure other than -1 indicates support for the C language.

POSIX2_C_DEV
A figure other than -1 indicates support for the C language development utilities.

POSIX2_C_VERSION
Value indicating the version of the IEEE POSIX.2 standard supported by the implementation. It also indicates whether the X/Open POSIX2 C-language binding feature group is supported.

POSIX2_CHAR_TERM
Indicates whether the system supports at least one terminal type. Set to -1 if it does not, otherwise set to a value other than -1.

POSIX2_COLL_WEIGHTS_MAX
Maximum number of weights that can be assigned to the LC_COLLATE variable, and the minimum value to which {COLL_WEIGHTS_MAX} can be set.

POSIX2_EXPR_NEST_MAX
The maximum number of expressions that can be nested within parentheses by the expr(C) command, and the minimum value to which {EXPR_NESTS_MAX} can be set.

POSIX2_FORT_DEV
If set to a value other than -1, the implementation supports the FORTRAN development utilities option.

POSIX2_FORT_RUN
If set to a value other than -1, the implementation supports the FORTRAN run-time utilities option.

POSIX2_LINE_MAX
The default maximum length, in bytes, of a command's input line. The length includes the trailing newline.

POSIX2_LOCALEDEF
If set to a value other than -1, the implementation supports the localedef(C) utility.

POSIX2_RE_DUP_MAX
This is the maximum number of permitted repetitions of a regular expression when using the interval notation \f{m,n\f}.

POSIX2_SW_DEV
If set to a value other than -1, the implementation supports the software development utilities option.

POSIX2_UPE
If set to a value other than -1, the implementation supports the user portability utilities extension (UPE) option.

POSIX2_VERSION
Value indicating the version of the IEEE POSIX.2 standard supported by the implementation.

RE_DUP_MAX
This is the maximum number of permitted repetitions of a regular expression when using the interval notation \f{m,n\f}.

SCHAR_MAX
Maximum value of a variable of type signed char.

SCHAR_MIN
Minimum value of a variable of type signed char.

SHRT_MAX
Maximum value of a variable of type short.

SHRT_MIN
Minimum value of a variable of type short.

SSIZE_MAX
Maximum value of an object of type ssize_t. The minimum length is defined by {POSIX_SSIZE_MAX} (see above).

STREAM_MAX
The number of streams that any one process can have open at one time. If defined, this value is the same as {FOPEN_MAX} as defined in <stdio.h>. The minimum length is defined by {POSIX_STREAM_MAX} (see above).

TMP_MAX
The minimum number of unique pathnames that can be generated by tmpnam(S). Also the maximum number of times that an application can reliably call tmpnam.

TZNAME_MAX
The name of a time-zone can consist of this maximum number of bytes (this is not the TZ variable. The minimum length is defined by {POSIX_TZNAME_MAX} (see above).

UCHAR_MAX
Maximum value of a variable of type unsigned char.

UINT_MAX
Maximum value of a variable of type unsigned int.

ULONG_MAX
Maximum value of a variable of type unsigned long int.

USHRT_MAX
Maximum value of a variable of type unsigned short int.

WORD_BIT
The number of bits in a word or a variable of type int.

_XOPEN_VERSION
This value indicates the version of the X/Open specification to which this implementation conforms.

_XOPEN_XCU_VERSION
This integer value indicates the version of the X/Open commands and utilities specification (XCU) to which this implementation conforms. If the value is -1, no commands or utilities are provided on the implementation. If the value is greater than or equal to 4, the functionality defined by the following symbols is supported:

{POSIX2_C_BIND}
{POSIX2_C_VERSION}
{POSIX2_CHAR_TERM}
{POSIX2_LOCALEDEF}
{POSIX2_UPE}
{POSIX2_VERSION}


_XOPEN_CRYPT
If defined, the implementation supports the X/Open Encryption Feature Group.

_XOPEN_ENH_I18N
If defined, the implementation supports the X/Open Enhanced Internationalization (I18N) Feature Group.

_XOPEN_SHM
If defined, the implementation supports the X/Open Shared Memory Feature Group.

_XOPEN_XPG2
If defined, this implementation supports the X/Open Portability Guide, Version 2; Volume 2, XVS System Calls and Libraries, January 1987, ISBN 0-444-70174-5.

_XOPEN_XPG3
If defined, this implementation supports the X/Open Portability Guide, Version 3; Volume 2, XSI System Interfaces and Headers, December 1988, ISBN 0-13-685843-0.

_XOPEN_XPG4
If defined, this implementation supports X/Open CAE Specification, System Interfaces and Headers, Issue 4, 1992, July 1992, ISBN 1-872630-47-2.
The following variables are recognized as path variables (they depend on a pathname):

LINK_MAX
This is the maximum number of permissible links to a single file. The minimum length is defined by {POSIX_LINK_MAX}.

MAX_CANON
Maximum number of permitted bytes in a terminal canonical input queue. The minimum length is defined by {POSIX_MAX_CANON}.

MAX_INPUT
Maximum number of permitted bytes in a terminal input queue. The minimum length is defined by {POSIX_MAX_INPUT}.

NAME_MAX
Maximum length (in bytes) of a filename, excluding terminating null. The minimum length is defined by {POSIX_NAME_MAX}.

PATH_MAX
Maximum length (in bytes) of a pathname. The minimum length is defined by {POSIX_PATH_MAX}.

PIPE_BUF
Maximum number of bytes guaranteed to be atomic when writing to a pipe. The minimum length is defined by {POSIX_PIPE_BUF}.

_POSIX_CHOWN_RESTRICTED
If this is defined with a value other than -1, the chown(S) routine can only be executed by a process with appropriate privileges. In addition, the use of chown is restricted to the ability to change the group ID of a file to the effective group ID of the process or to one of its supplementary group ID.

_POSIX_NO_TRUNC
If this is set to a value other than -1, a pathname component longer than {NAME_MAX} will generate an error.

_POSIX_VDISABLE
If this value is set to -1, terminal special characters defined in <termio.h> will be disabled.

Exit values

getconf returns 0 (zero) if the specified variable exists or is undefined; a positive non-zero value is returned if the variable is invalid or an error occurs.

Examples

Entering the command getconf KERNEL_PROC will return the current size of the dynamic process table.

Limitations

The inclusion of a variable in one of the above tables does not imply that its value can be altered by reconfiguring the system; some of the values are fixed.

See also

confstr(S), pathconf(S), readv(S), setconf(ADM), sysconf(S), writev(S)

Standards conformance

getconf is conformant with:

ISO/IEC DIS 9945-2:1992, Information technology - Portable Operating System Interface (POSIX) - Part 2: Shell and Utilities (IEEE Std 1003.2-1992);
X/Open CAE Specification, Commands and Utilities, Issue 4, 1992.


© 2003 Caldera International, Inc. All rights reserved.
SCO OpenServer Release 5.0.7 -- 11 February 2003