2008-07-08 14:32:54 +00:00
|
|
|
.\" Copyright (c) 1993 by Thomas Koenig (ig25@rz.uni-karlsruhe.de)
|
2004-11-03 13:51:07 +00:00
|
|
|
.\"
|
|
|
|
.\" Permission is granted to make and distribute verbatim copies of this
|
|
|
|
.\" manual provided the copyright notice and this permission notice are
|
|
|
|
.\" preserved on all copies.
|
|
|
|
.\"
|
|
|
|
.\" Permission is granted to copy and distribute modified versions of this
|
|
|
|
.\" manual under the conditions for verbatim copying, provided that the
|
|
|
|
.\" entire resulting derived work is distributed under the terms of a
|
|
|
|
.\" permission notice identical to this one.
|
2007-04-12 22:42:49 +00:00
|
|
|
.\"
|
2004-11-03 13:51:07 +00:00
|
|
|
.\" Since the Linux kernel and libraries are constantly changing, this
|
|
|
|
.\" manual page may be incorrect or out-of-date. The author(s) assume no
|
|
|
|
.\" responsibility for errors or omissions, or for damages resulting from
|
|
|
|
.\" the use of the information contained herein. The author(s) may not
|
|
|
|
.\" have taken the same level of care in the production of this manual,
|
|
|
|
.\" which is licensed free of charge, as they might when working
|
|
|
|
.\" professionally.
|
2007-04-12 22:42:49 +00:00
|
|
|
.\"
|
2004-11-03 13:51:07 +00:00
|
|
|
.\" Formatted or processed versions of this manual, if unaccompanied by
|
|
|
|
.\" the source, must acknowledge the copyright and authors of this work.
|
|
|
|
.\" License.
|
|
|
|
.\" Modified Sat Jul 24 17:51:42 1993 by Rik Faith (faith@cs.unc.edu)
|
|
|
|
.\" Modified Tue Aug 17 11:42:20 1999 by Ariel Scolnicov (ariels@compugen.co.il)
|
fork.2, getpriority.2, ioprio_set.2, sched_setparam.2, sched_setscheduler.2, shmop.2, sigaction.2, unimplemented.2, makecontext.3, sysconf.3, resolv.conf.5, cpuset.7, ip.7, svipc.7, termio.7, zdump.8: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2013-02-12 02:51:12 +00:00
|
|
|
.TH SYSCONF 3 2013-02-12 "GNU" "Linux Programmer's Manual"
|
2004-11-03 13:51:07 +00:00
|
|
|
.SH NAME
|
2012-12-17 18:53:43 +00:00
|
|
|
sysconf \- get configuration information at run time
|
2004-11-03 13:51:07 +00:00
|
|
|
.SH SYNOPSIS
|
|
|
|
.nf
|
|
|
|
.B #include <unistd.h>
|
|
|
|
.sp
|
|
|
|
.BI "long sysconf(int " "name" );
|
|
|
|
.fi
|
|
|
|
.SH DESCRIPTION
|
2008-03-19 08:46:32 +00:00
|
|
|
POSIX allows an application to test at compile or run time
|
2004-11-03 13:51:07 +00:00
|
|
|
whether certain options are supported, or what the value is
|
|
|
|
of certain configurable constants or limits.
|
|
|
|
.LP
|
|
|
|
At compile time this is done by including
|
|
|
|
.I <unistd.h>
|
|
|
|
and/or
|
|
|
|
.I <limits.h>
|
|
|
|
and testing the value of certain macros.
|
|
|
|
.LP
|
|
|
|
At run time, one can ask for numerical values using the present function
|
|
|
|
.BR sysconf ().
|
2010-05-22 03:27:11 +00:00
|
|
|
One can ask for numerical values that may depend
|
2008-03-19 07:26:08 +00:00
|
|
|
on the file system a file is in using the calls
|
2004-11-03 13:51:07 +00:00
|
|
|
.BR fpathconf (3)
|
|
|
|
and
|
|
|
|
.BR pathconf (3).
|
|
|
|
One can ask for string values using
|
|
|
|
.BR confstr (3).
|
|
|
|
.LP
|
|
|
|
The values obtained from these functions are system configuration constants.
|
|
|
|
They do not change during the lifetime of a process.
|
|
|
|
.\" except that sysconf(_SC_OPEN_MAX) may change answer after a call
|
2008-07-01 14:15:13 +00:00
|
|
|
.\" to setrlimit( ) which changes the RLIMIT_NOFILE soft limit
|
2004-11-03 13:51:07 +00:00
|
|
|
.LP
|
|
|
|
For options, typically, there is a constant
|
|
|
|
.B _POSIX_FOO
|
|
|
|
that may be defined in
|
|
|
|
.IR <unistd.h> .
|
2008-03-19 08:46:32 +00:00
|
|
|
If it is undefined, one should ask at run time.
|
2004-11-03 13:51:07 +00:00
|
|
|
If it is defined to \-1, then the option is not supported.
|
|
|
|
If it is defined to 0, then relevant functions and headers exist,
|
2012-12-17 18:53:43 +00:00
|
|
|
but one has to ask at run time what degree of support is available.
|
2004-11-03 13:51:07 +00:00
|
|
|
If it is defined to a value other than \-1 or 0, then the option is
|
2007-04-12 22:42:49 +00:00
|
|
|
supported.
|
|
|
|
Usually the value (such as 200112L) indicates the year and month
|
|
|
|
of the POSIX revision describing the option.
|
|
|
|
Glibc uses the value 1
|
2004-11-03 13:51:07 +00:00
|
|
|
to indicate support as long as the POSIX revision has not been published yet.
|
|
|
|
.\" and 999 to indicate support for options no longer present in the latest
|
|
|
|
.\" standard. (?)
|
|
|
|
The
|
2005-10-19 07:07:02 +00:00
|
|
|
.BR sysconf ()
|
2004-11-03 13:51:07 +00:00
|
|
|
argument will be
|
|
|
|
.BR _SC_FOO .
|
|
|
|
For a list of options, see
|
|
|
|
.BR posixoptions (7).
|
|
|
|
.LP
|
|
|
|
For variables or limits, typically, there is a constant
|
|
|
|
.BR _FOO ,
|
|
|
|
maybe defined in
|
|
|
|
.IR <limits.h> ,
|
|
|
|
or
|
|
|
|
.BR _POSIX_FOO ,
|
|
|
|
maybe defined in
|
|
|
|
.IR <unistd.h> .
|
|
|
|
The constant will not be defined if the limit is unspecified.
|
|
|
|
If the constant is defined, it gives a guaranteed value, and
|
2008-07-14 14:26:50 +00:00
|
|
|
a greater value might actually be supported.
|
2004-11-03 13:51:07 +00:00
|
|
|
If an application wants to take advantage of values which may change
|
|
|
|
between systems, a call to
|
2005-10-19 07:07:02 +00:00
|
|
|
.BR sysconf ()
|
2004-11-03 13:51:07 +00:00
|
|
|
can be made.
|
2007-04-12 22:42:49 +00:00
|
|
|
The
|
2005-10-19 14:16:57 +00:00
|
|
|
.BR sysconf ()
|
2004-11-03 13:51:07 +00:00
|
|
|
argument will be
|
|
|
|
.BR _SC_FOO .
|
intro.1, time.1, _syscall.2, accept.2, brk.2, capget.2, faccessat.2, futimesat.2, gethostname.2, intro.2, ioprio_set.2, kill.2, madvise.2, mlock.2, mount.2, msgget.2, perf_event_open.2, poll.2, readv.2, sched_rr_get_interval.2, sched_setscheduler.2, select.2, select_tut.2, shmget.2, stat.2, timer_create.2, ustat.2, vfork.2, wait.2, alloca.3, atexit.3, catopen.3, crypt.3, dbopen.3, fenv.3, fopen.3, getaddrinfo_a.3, gethostbyname.3, getutent.3, intro.3, login.3, mallopt.3, queue.3, regex.3, sigpause.3, sigsetops.3, stdio.3, strftime.3, strptime.3, sysconf.3, ttyslot.3, undocumented.3, cciss.4, console_codes.4, hpsa.4, initrd.4, intro.4, rtc.4, st.4, tty_ioctl.4, wavelan.4, acct.5, charmap.5, dir_colors.5, hosts.5, intro.5, termcap.5, utmp.5, intro.6, armscii-8.7, boot.7, bootparam.7, capabilities.7, cpuset.7, credentials.7, ddp.7, epoll.7, glob.7, intro.7, ip.7, ipv6.7, iso_8859-1.7, iso_8859-10.7, iso_8859-11.7, iso_8859-13.7, iso_8859-14.7, iso_8859-15.7, iso_8859-16.7, iso_8859-2.7, iso_8859-3.7, iso_8859-4.7, iso_8859-5.7, iso_8859-6.7, iso_8859-7.7, iso_8859-8.7, iso_8859-9.7, koi8-r.7, koi8-u.7, man-pages.7, man.7, math_error.7, netlink.7, numa.7, packet.7, path_resolution.7, pipe.7, pthreads.7, raw.7, rtnetlink.7, signal.7, socket.7, spufs.7, svipc.7, tcp.7, time.7, udp.7, udplite.7, unicode.7, unix.7, uri.7, utf-8.7, x25.7, intro.8: Global fix: use consistent capitalization in .SS headings
Capitalization in .SS sections across pages (and sometimes even
within a single page) is wildly inconsistent. Make it consistent.
Capitalize first word in heading, but otherwise use lower case,
except where English usage (e.g., proper nouns) or programming
language requirements (e.g., identifier names) dictate otherwise.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2013-02-24 14:08:38 +00:00
|
|
|
.SS "POSIX.1 variables"
|
2004-11-03 13:51:07 +00:00
|
|
|
We give the name of the variable, the name of the
|
2005-10-19 07:07:02 +00:00
|
|
|
.BR sysconf ()
|
2008-07-10 20:53:08 +00:00
|
|
|
argument used to inquire about its value,
|
2004-11-03 13:51:07 +00:00
|
|
|
and a short description.
|
|
|
|
.LP
|
|
|
|
First, the POSIX.1 compatible values.
|
|
|
|
.\" [for the moment: only the things that are unconditionally present]
|
|
|
|
.\" .TP
|
|
|
|
.\" .BR AIO_LISTIO_MAX " - " _SC_AIO_LISTIO_MAX
|
|
|
|
.\" (if _POSIX_ASYNCHRONOUS_IO)
|
|
|
|
.\" Maximum number of I/O operations in a single list I/O call.
|
|
|
|
.\" Must not be less than _POSIX_AIO_LISTIO_MAX.
|
|
|
|
.\" .TP
|
|
|
|
.\" .BR AIO_MAX " - " _SC_AIO_MAX
|
|
|
|
.\" (if _POSIX_ASYNCHRONOUS_IO)
|
|
|
|
.\" Maximum number of outstanding asynchronous I/O operations.
|
|
|
|
.\" Must not be less than _POSIX_AIO_MAX.
|
|
|
|
.\" .TP
|
|
|
|
.\" .BR AIO_PRIO_DELTA_MAX " - " _SC_AIO_PRIO_DELTA_MAX
|
|
|
|
.\" (if _POSIX_ASYNCHRONOUS_IO)
|
|
|
|
.\" The maximum amount by which a process can decrease its
|
|
|
|
.\" asynchronous I/O priority level from its own scheduling priority.
|
_syscall.2, accept.2, epoll_create.2, inotify_add_watch.2, ioctl.2, msgget.2, msgop.2, open.2, prctl.2, sched_setscheduler.2, semctl.2, semget.2, swapon.2, addseverity.3, cacosh.3, csqrt.3, dirfd.3, drand48.3, fputws.3, mq_send.3, posix_openpt.3, puts.3, sched_getcpu.3, shm_open.3, sqrt.3, sysconf.3, tgamma.3, ulimit.3, credentials.7, svipc.7: Global fix: s/non-negative/nonnegative/
The tendency in English, as prescribed in style guides like
Chicago MoS, is towards removing hyphens after prefixes
like "non-" etc.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2010-01-16 16:44:48 +00:00
|
|
|
.\" Must be nonnegative.
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
|
|
|
.BR ARG_MAX " - " _SC_ARG_MAX
|
|
|
|
The maximum length of the arguments to the
|
2007-05-21 22:14:09 +00:00
|
|
|
.BR exec (3)
|
2004-11-03 13:51:07 +00:00
|
|
|
family of functions.
|
2007-07-08 16:21:19 +00:00
|
|
|
Must not be less than
|
|
|
|
.B _POSIX_ARG_MAX
|
|
|
|
(4096).
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
|
|
|
.BR CHILD_MAX " - " _SC_CHILD_MAX
|
2005-07-18 16:02:32 +00:00
|
|
|
The max number of simultaneous processes per user ID.
|
2007-07-08 16:21:19 +00:00
|
|
|
Must not be less than
|
|
|
|
.B _POSIX_CHILD_MAX
|
|
|
|
(25).
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
|
|
|
.BR HOST_NAME_MAX " - " _SC_HOST_NAME_MAX
|
2007-04-12 22:42:49 +00:00
|
|
|
Max length of a hostname, not including the terminating null byte,
|
2006-01-13 02:09:44 +00:00
|
|
|
as returned by
|
2004-11-03 13:51:07 +00:00
|
|
|
.BR gethostname (2).
|
2007-07-08 16:21:19 +00:00
|
|
|
Must not be less than
|
|
|
|
.B _POSIX_HOST_NAME_MAX
|
|
|
|
(255).
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
|
|
|
.BR LOGIN_NAME_MAX " - " _SC_LOGIN_NAME_MAX
|
2006-01-13 02:09:44 +00:00
|
|
|
Maximum length of a login name, including the terminating null byte.
|
2007-07-08 16:21:19 +00:00
|
|
|
Must not be less than
|
|
|
|
.B _POSIX_LOGIN_NAME_MAX
|
|
|
|
(9).
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
|
|
|
.BR "" "clock ticks - " _SC_CLK_TCK
|
|
|
|
The number of clock ticks per second.
|
2007-04-12 22:42:49 +00:00
|
|
|
The corresponding variable is obsolete.
|
|
|
|
It was of course called
|
2004-11-03 13:51:07 +00:00
|
|
|
.BR CLK_TCK .
|
|
|
|
(Note: the macro
|
|
|
|
.B CLOCKS_PER_SEC
|
|
|
|
does not give information: it must equal 1000000.)
|
|
|
|
.TP
|
|
|
|
.BR OPEN_MAX " - " _SC_OPEN_MAX
|
|
|
|
The maximum number of files that a process can have open at any time.
|
2007-07-08 16:21:19 +00:00
|
|
|
Must not be less than
|
|
|
|
.B _POSIX_OPEN_MAX
|
|
|
|
(20).
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
|
|
|
.BR PAGESIZE " - " _SC_PAGESIZE
|
2007-04-12 22:42:49 +00:00
|
|
|
Size of a page in bytes.
|
|
|
|
Must not be less than 1.
|
2004-11-03 13:51:07 +00:00
|
|
|
(Some systems use PAGE_SIZE instead.)
|
|
|
|
.TP
|
|
|
|
.BR RE_DUP_MAX " - " _SC_RE_DUP_MAX
|
|
|
|
The number of repeated occurrences of a BRE permitted by
|
|
|
|
.BR regexec (3)
|
|
|
|
and
|
|
|
|
.BR regcomp (3).
|
2007-07-08 16:21:19 +00:00
|
|
|
Must not be less than
|
|
|
|
.B _POSIX2_RE_DUP_MAX
|
|
|
|
(255).
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
|
|
|
.BR STREAM_MAX " - " _SC_STREAM_MAX
|
|
|
|
The maximum number of streams that a process can have open at any
|
2007-04-12 22:42:49 +00:00
|
|
|
time.
|
|
|
|
If defined, it has the same value as the standard C macro
|
2004-11-03 13:51:07 +00:00
|
|
|
.BR FOPEN_MAX .
|
2007-07-08 16:21:19 +00:00
|
|
|
Must not be less than
|
|
|
|
.B _POSIX_STREAM_MAX
|
|
|
|
(8).
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
2012-04-15 10:15:52 +00:00
|
|
|
.BR SYMLOOP_MAX " - " _SC_SYMLOOP_MAX
|
2004-11-03 13:51:07 +00:00
|
|
|
The maximum number of symbolic links seen in a pathname before resolution
|
2007-06-22 20:40:07 +00:00
|
|
|
returns
|
|
|
|
.BR ELOOP .
|
2007-07-08 16:21:19 +00:00
|
|
|
Must not be less than
|
|
|
|
.B _POSIX_SYMLOOP_MAX
|
|
|
|
(8).
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
|
|
|
.BR TTY_NAME_MAX " - " _SC_TTY_NAME_MAX
|
2007-04-12 22:42:49 +00:00
|
|
|
The maximum length of terminal device name,
|
2006-01-13 02:09:44 +00:00
|
|
|
including the terminating null byte.
|
2007-07-08 16:21:19 +00:00
|
|
|
Must not be less than
|
2007-09-20 16:26:31 +00:00
|
|
|
.B _POSIX_TTY_NAME_MAX
|
2007-07-08 16:21:19 +00:00
|
|
|
(9).
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
|
|
|
.BR TZNAME_MAX " - " _SC_TZNAME_MAX
|
|
|
|
The maximum number of bytes in a timezone name.
|
2007-07-08 16:21:19 +00:00
|
|
|
Must not be less than
|
2007-09-20 16:26:31 +00:00
|
|
|
.B _POSIX_TZNAME_MAX
|
2007-07-08 16:21:19 +00:00
|
|
|
(6).
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
|
|
|
.BR _POSIX_VERSION " - " _SC_VERSION
|
|
|
|
indicates the year and month the POSIX.1 standard was approved in the
|
|
|
|
format
|
2007-12-10 15:03:27 +00:00
|
|
|
.BR YYYYMML ;
|
|
|
|
the value
|
2004-11-03 13:51:07 +00:00
|
|
|
.B 199009L
|
|
|
|
indicates the Sept. 1990 revision.
|
intro.1, time.1, _syscall.2, accept.2, brk.2, capget.2, faccessat.2, futimesat.2, gethostname.2, intro.2, ioprio_set.2, kill.2, madvise.2, mlock.2, mount.2, msgget.2, perf_event_open.2, poll.2, readv.2, sched_rr_get_interval.2, sched_setscheduler.2, select.2, select_tut.2, shmget.2, stat.2, timer_create.2, ustat.2, vfork.2, wait.2, alloca.3, atexit.3, catopen.3, crypt.3, dbopen.3, fenv.3, fopen.3, getaddrinfo_a.3, gethostbyname.3, getutent.3, intro.3, login.3, mallopt.3, queue.3, regex.3, sigpause.3, sigsetops.3, stdio.3, strftime.3, strptime.3, sysconf.3, ttyslot.3, undocumented.3, cciss.4, console_codes.4, hpsa.4, initrd.4, intro.4, rtc.4, st.4, tty_ioctl.4, wavelan.4, acct.5, charmap.5, dir_colors.5, hosts.5, intro.5, termcap.5, utmp.5, intro.6, armscii-8.7, boot.7, bootparam.7, capabilities.7, cpuset.7, credentials.7, ddp.7, epoll.7, glob.7, intro.7, ip.7, ipv6.7, iso_8859-1.7, iso_8859-10.7, iso_8859-11.7, iso_8859-13.7, iso_8859-14.7, iso_8859-15.7, iso_8859-16.7, iso_8859-2.7, iso_8859-3.7, iso_8859-4.7, iso_8859-5.7, iso_8859-6.7, iso_8859-7.7, iso_8859-8.7, iso_8859-9.7, koi8-r.7, koi8-u.7, man-pages.7, man.7, math_error.7, netlink.7, numa.7, packet.7, path_resolution.7, pipe.7, pthreads.7, raw.7, rtnetlink.7, signal.7, socket.7, spufs.7, svipc.7, tcp.7, time.7, udp.7, udplite.7, unicode.7, unix.7, uri.7, utf-8.7, x25.7, intro.8: Global fix: use consistent capitalization in .SS headings
Capitalization in .SS sections across pages (and sometimes even
within a single page) is wildly inconsistent. Make it consistent.
Capitalize first word in heading, but otherwise use lower case,
except where English usage (e.g., proper nouns) or programming
language requirements (e.g., identifier names) dictate otherwise.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2013-02-24 14:08:38 +00:00
|
|
|
.SS "POSIX.2 variables"
|
2004-11-03 13:51:07 +00:00
|
|
|
Next, the POSIX.2 values, giving limits for utilities.
|
|
|
|
.TP
|
|
|
|
.BR BC_BASE_MAX " - " _SC_BC_BASE_MAX
|
|
|
|
indicates the maximum
|
|
|
|
.I obase
|
|
|
|
value accepted by the
|
|
|
|
.BR bc (1)
|
|
|
|
utility.
|
|
|
|
.TP
|
|
|
|
.BR BC_DIM_MAX " - " _SC_BC_DIM_MAX
|
|
|
|
indicates the maximum value of elements permitted in an array by
|
|
|
|
.BR bc (1).
|
|
|
|
.TP
|
|
|
|
.BR BC_SCALE_MAX " - " _SC_BC_SCALE_MAX
|
|
|
|
indicates the maximum
|
|
|
|
.I scale
|
|
|
|
value allowed by
|
|
|
|
.BR bc (1).
|
|
|
|
.TP
|
|
|
|
.BR BC_STRING_MAX " - " _SC_BC_STRING_MAX
|
|
|
|
indicates the maximum length of a string accepted by
|
|
|
|
.BR bc (1).
|
|
|
|
.TP
|
|
|
|
.BR COLL_WEIGHTS_MAX " - " _SC_COLL_WEIGHTS_MAX
|
|
|
|
indicates the maximum numbers of weights that can be assigned to an
|
|
|
|
entry of the
|
|
|
|
.B LC_COLLATE order
|
|
|
|
keyword in the locale definition file,
|
|
|
|
.TP
|
|
|
|
.BR EXPR_NEST_MAX " - " _SC_EXPR_NEST_MAX
|
|
|
|
is the maximum number of expressions which can be nested within
|
|
|
|
parentheses by
|
|
|
|
.BR expr (1).
|
|
|
|
.TP
|
|
|
|
.BR LINE_MAX " - " _SC_LINE_MAX
|
2011-09-08 15:17:50 +00:00
|
|
|
The maximum length of a utility's input line, either from
|
2007-04-12 22:42:49 +00:00
|
|
|
standard input or from a file.
|
2011-09-28 04:28:31 +00:00
|
|
|
This includes space for a trailing
|
2004-11-03 13:51:07 +00:00
|
|
|
newline.
|
|
|
|
.TP
|
|
|
|
.BR RE_DUP_MAX " - " _SC_RE_DUP_MAX
|
|
|
|
The maximum number of repeated occurrences of a regular expression when
|
|
|
|
the interval notation
|
time.1, atexit.3, bsearch.3, dlopen.3, envz_add.3, errno.3, fmtmsg.3, getgrent_r.3, getline.3, getmntent.3, getnameinfo.3, getpass.3, getpwent_r.3, gets.3, isalpha.3, printf.3, puts.3, recno.3, scandir.3, stdarg.3, sysconf.3, termios.3, wordexp.3, null.4, core.5, dir_colors.5, issue.5, proc.5, termcap.5, utmp.5, ascii.7, cpuset.7, glob.7, man-pages.7, man.7, mdoc.7, mdoc.samples.7, regex.7: Revert 9f8e673e623d (whose global s%\\e%\\\\% caused problems)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-09-26 21:56:54 +00:00
|
|
|
.B \e{m,n\e}
|
2004-11-03 13:51:07 +00:00
|
|
|
is used.
|
|
|
|
.TP
|
|
|
|
.BR POSIX2_VERSION " - " _SC_2_VERSION
|
|
|
|
indicates the version of the POSIX.2 standard in the format of
|
|
|
|
YYYYMML.
|
|
|
|
.TP
|
2005-06-21 11:30:37 +00:00
|
|
|
.BR POSIX2_C_DEV " - " _SC_2_C_DEV
|
2004-11-03 13:51:07 +00:00
|
|
|
indicates whether the POSIX.2 C language development facilities are
|
|
|
|
supported.
|
|
|
|
.TP
|
2004-12-20 10:45:56 +00:00
|
|
|
.BR POSIX2_FORT_DEV " - " _SC_2_FORT_DEV
|
2004-11-03 13:51:07 +00:00
|
|
|
indicates whether the POSIX.2 FORTRAN development utilities are
|
|
|
|
supported.
|
|
|
|
.TP
|
|
|
|
.BR POSIX2_FORT_RUN " - " _SC_2_FORT_RUN
|
2012-12-17 18:53:43 +00:00
|
|
|
indicates whether the POSIX.2 FORTRAN run-time utilities are supported.
|
2004-11-03 13:51:07 +00:00
|
|
|
.TP
|
|
|
|
.BR _POSIX2_LOCALEDEF " - " _SC_2_LOCALEDEF
|
|
|
|
indicates whether the POSIX.2 creation of locates via
|
|
|
|
.BR localedef (1)
|
|
|
|
is supported.
|
|
|
|
.TP
|
|
|
|
.BR POSIX2_SW_DEV " - " _SC_2_SW_DEV
|
|
|
|
indicates whether the POSIX.2 software development utilities option is
|
|
|
|
supported.
|
|
|
|
.PP
|
|
|
|
These values also exist, but may not be standard.
|
|
|
|
.TP
|
|
|
|
.BR "" " - " _SC_PHYS_PAGES
|
2007-04-12 22:42:49 +00:00
|
|
|
The number of pages of physical memory.
|
|
|
|
Note that it is possible
|
2004-11-03 13:51:07 +00:00
|
|
|
for the product of this value and the value of
|
2013-02-09 23:52:00 +00:00
|
|
|
.B _SC_PAGESIZE
|
2004-11-03 13:51:07 +00:00
|
|
|
to overflow.
|
|
|
|
.TP
|
|
|
|
.BR "" " - " _SC_AVPHYS_PAGES
|
|
|
|
The number of currently available pages of physical memory.
|
2007-11-29 21:16:50 +00:00
|
|
|
.TP
|
|
|
|
.BR "" " - " _SC_NPROCESSORS_CONF
|
|
|
|
The number of processors configured.
|
|
|
|
.TP
|
|
|
|
.BR "" " - " _SC_NPROCESSORS_ONLN
|
|
|
|
The number of processors currently online (available).
|
2004-11-03 13:51:07 +00:00
|
|
|
.SH "RETURN VALUE"
|
|
|
|
If
|
|
|
|
.I name
|
|
|
|
is invalid, \-1 is returned, and
|
|
|
|
.I errno
|
|
|
|
is set to
|
|
|
|
.BR EINVAL .
|
|
|
|
Otherwise, the value returned is the value of the system resource and
|
|
|
|
.I errno
|
|
|
|
is not changed.
|
|
|
|
In the case of options, a positive value is returned if a queried option
|
|
|
|
is available, and \-1 if it is not.
|
|
|
|
In the case of limits, \-1 means that there is no definite limit.
|
|
|
|
.SH "CONFORMING TO"
|
2006-08-03 13:57:30 +00:00
|
|
|
POSIX.1-2001.
|
2004-11-03 13:51:07 +00:00
|
|
|
.SH BUGS
|
|
|
|
It is difficult to use
|
|
|
|
.B ARG_MAX
|
|
|
|
because it is not specified how much of the argument space for
|
2007-05-21 22:14:09 +00:00
|
|
|
.BR exec (3)
|
2004-11-03 13:51:07 +00:00
|
|
|
is consumed by the user's environment variables.
|
|
|
|
.PP
|
|
|
|
Some returned values may be huge; they are not suitable for allocating
|
|
|
|
memory.
|
|
|
|
.SH "SEE ALSO"
|
|
|
|
.BR bc (1),
|
|
|
|
.BR expr (1),
|
2007-05-21 08:55:27 +00:00
|
|
|
.BR getconf (1),
|
2004-11-03 13:51:07 +00:00
|
|
|
.BR locale (1),
|
|
|
|
.BR fpathconf (3),
|
|
|
|
.BR pathconf (3),
|
|
|
|
.BR posixoptions (7)
|