[BACK]Return to sysctl.7 CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / share / man / man7

Annotation of src/share/man/man7/sysctl.7, Revision 1.124

1.124   ! sevan       1: .\"    $NetBSD: sysctl.7,v 1.123 2018/02/22 14:37:53 sevan Exp $
1.1       pavel       2: .\"
                      3: .\" Copyright (c) 1993
                      4: .\"    The Regents of the University of California.  All rights reserved.
                      5: .\"
                      6: .\" Redistribution and use in source and binary forms, with or without
                      7: .\" modification, are permitted provided that the following conditions
                      8: .\" are met:
                      9: .\" 1. Redistributions of source code must retain the above copyright
                     10: .\"    notice, this list of conditions and the following disclaimer.
                     11: .\" 2. Redistributions in binary form must reproduce the above copyright
                     12: .\"    notice, this list of conditions and the following disclaimer in the
                     13: .\"    documentation and/or other materials provided with the distribution.
                     14: .\" 3. Neither the name of the University nor the names of its contributors
                     15: .\"    may be used to endorse or promote products derived from this software
                     16: .\"    without specific prior written permission.
                     17: .\"
                     18: .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
                     19: .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
                     20: .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
                     21: .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
                     22: .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
                     23: .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
                     24: .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
                     25: .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
                     26: .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
                     27: .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
                     28: .\" SUCH DAMAGE.
                     29: .\"
                     30: .\"    @(#)sysctl.3    8.4 (Berkeley) 5/9/95
                     31: .\"
1.122     sevan      32: .Dd February 22, 2018
1.1       pavel      33: .Dt SYSCTL 7
                     34: .Os
                     35: .Sh NAME
                     36: .Nm sysctl
                     37: .Nd system information variables
                     38: .Sh DESCRIPTION
                     39: The
                     40: .Xr sysctl 3
                     41: library function and the
                     42: .Xr sysctl 8
                     43: utility are used to get and set values of system variables, maintained
                     44: by the kernel.
                     45: The variables are organized in a tree and identified by a sequence of
                     46: numbers, conventionally separated by dots with the topmost identifier
                     47: at the left side.
                     48: The numbers have corresponding text names.
                     49: The
                     50: .Xr sysctlnametomib 3
                     51: function or the
                     52: .Fl M
                     53: argument to the
                     54: .Xr sysctl 8
                     55: utility can be used to convert the text representation to the
                     56: numeric one.
                     57: .Pp
                     58: The individual sysctl variables are described below, both the textual
                     59: and numeric form where applicable.
                     60: The textual names can be used as argument to the
                     61: .Xr sysctl 8
                     62: utility and in the file
                     63: .Pa /etc/sysctl.conf .
                     64: The numeric names are usually defined as preprocessor constants and
                     65: are intended for use by programs.
                     66: Every such constant expands to one integer, which identifies the
                     67: sysctl variable relative to the upper level of the tree.
                     68: See the
                     69: .Xr sysctl 3
                     70: manual page for programming examples.
1.50      jruoho     71: .Ss Top level names
1.56      uwe        72: The top level names are defined with a
                     73: .Va CTL_
                     74: prefix in
1.33      joerg      75: .In sys/sysctl.h ,
1.1       pavel      76: and are as follows.
                     77: The next and subsequent levels down are found in the include files
                     78: listed here, and described in separate sections below.
1.56      uwe        79: .Bl -column "security" ".Dv CTL_SECURITY" ".In uvm/uvm_param.h" "High kernel limits"
                     80: .It Sy Name  Ta Sy Constant     Ta Sy Next level names Ta Sy Description
                     81: .It kern     Ta Dv CTL_KERN     Ta In sys/sysctl.h     Ta High kernel limits
                     82: .It vm       Ta Dv CTL_VM       Ta In uvm/uvm_param.h  Ta Virtual memory
                     83: .It vfs      Ta Dv CTL_VFS      Ta In sys/mount.h      Ta Filesystem
                     84: .It net      Ta Dv CTL_NET      Ta In sys/socket.h     Ta Networking
                     85: .It debug    Ta Dv CTL_DEBUG    Ta In sys/sysctl.h     Ta Debugging
                     86: .It hw       Ta Dv CTL_HW       Ta In sys/sysctl.h     Ta Generic CPU, I/O
                     87: .It machdep  Ta Dv CTL_MACHDEP  Ta In sys/sysctl.h     Ta Machine dependent
                     88: .It user     Ta Dv CTL_USER     Ta In sys/sysctl.h     Ta User-level
                     89: .It ddb      Ta Dv CTL_DDB      Ta In sys/sysctl.h     Ta In-kernel debugger
                     90: .It proc     Ta Dv CTL_PROC     Ta In sys/sysctl.h     Ta Per-process
                     91: .It vendor   Ta Dv CTL_VENDOR   Ta ?                   Ta Vendor specific
                     92: .It emul     Ta Dv CTL_EMUL     Ta In sys/sysctl.h     Ta Emulation settings
                     93: .It security Ta Dv CTL_SECURITY Ta In sys/sysctl.h     Ta Security settings
1.1       pavel      94: .El
1.50      jruoho     95: .Ss The debug.* subtree
1.1       pavel      96: The debugging variables vary from system to system.
                     97: A debugging variable may be added or deleted without need to recompile
                     98: .Nm
                     99: to know about it.
                    100: Each time it runs,
                    101: .Nm
                    102: gets the list of debugging variables from the kernel and
                    103: displays their current values.
                    104: The system defines twenty
1.56      uwe       105: .Vt ( struct ctldebug )
1.1       pavel     106: variables named
                    107: .Dv debug0
                    108: through
                    109: .Dv debug19 .
                    110: They are declared as separate variables so that they can be
                    111: individually initialized at the location of their associated variable.
                    112: The loader prevents multiple use of the same variable by issuing errors
                    113: if a variable is initialized in more than one place.
                    114: For example, to export the variable
1.56      uwe       115: .Va dospecialcheck
1.1       pavel     116: as a debugging variable, the following declaration would be used:
1.43      jruoho    117: .Pp
1.1       pavel     118: .Bd -literal -offset indent -compact
                    119: int dospecialcheck = 1;
1.114     wiz       120: struct ctldebug debug5 = { "dospecialcheck", &dospecialcheck };
1.1       pavel     121: .Ed
                    122: .Pp
                    123: Note that the dynamic implementation of
                    124: .Nm
                    125: currently in use largely makes this particular
                    126: .Nm
                    127: interface obsolete.
                    128: See
                    129: .Xr sysctl 8
                    130: .\" and
                    131: .\" .Xr sysctl 9
                    132: for more information.
1.50      jruoho    133: .Ss The vfs.* subtree
1.1       pavel     134: A distinguished second level name,
1.91      kamil     135: .Li vfs.generic ( Dv VFS_GENERIC ) ,
1.57      wiz       136: is used to get general information about all file systems.
1.26      elad      137: It has the following third level identifiers:
1.56      uwe       138: .Bl -tag -width "123456"
1.91      kamil     139: .It Li vfs.generic.maxtypenum ( Dv VFS_MAXTYPENUM )
1.57      wiz       140: The highest valid file system type number.
1.91      kamil     141: .It Li vfs.generic.conf ( Dv VFS_CONF )
1.57      wiz       142: Returns configuration information about the file system type given as a fourth
1.26      elad      143: level identifier.
1.91      kamil     144: .It Li vfs.generic.usermount ( Dv VFS_USERMOUNT )
1.68      jym       145: Determines if non superuser mounts are allowed, defaults to
1.59      christos  146: .Dv 0 .
1.91      kamil     147: .It Li vfs.generic.magiclinks ( Dv VFS_MAGICLINKS )
1.59      christos  148: Controls if expansion of variables is going to be performed on pathnames
                    149: or not.
                    150: Defaults to no variable expansion,
                    151: .Dv 0 .
                    152: Variables are of the form
                    153: .Li @name
1.60      christos  154: and the variables supported are described in
                    155: .Xr symlink 7
                    156: under
                    157: .Dq "MAGIC SYMLINKS" .
1.26      elad      158: .El
                    159: .Pp
1.54      christos  160: A second level name for controlling the
                    161: .Xr wapbl 4
                    162: (Write Ahead Physical Block Logging file system journalling)
                    163: capabilities with the following third level identifiers:
1.56      uwe       164: .Bl -tag -width "123456"
                    165: .It Li vfs.wapbl.flush_disk_cache
1.55      wiz       166: Controls whether to attempt to flush the disk cache on each commit.
1.77      apb       167: It defaults to 1 and it should always be on to ensure integrity
                    168: of file system metadata in the event of a power loss.
1.54      christos  169: For slow disks, turning it off can improve performance.
1.56      uwe       170: .It Li vfs.wapbl.verbose_commit
1.55      wiz       171: For each transaction log commit, print the number of bytes written
                    172: and the time it took to commit as seconds.nanoseconds.
1.54      christos  173: .El
                    174: .Pp
1.57      wiz       175: The remaining second level identifiers are the file system names, identified
1.26      elad      176: by the type number returned by a
1.1       pavel     177: .Xr statvfs 2
                    178: call or from
1.27      wiz       179: .Li vfs.generic.conf .
1.56      uwe       180: .Pp
1.57      wiz       181: The third level identifiers available for each file system
1.1       pavel     182: are given in the header file that defines the mount
1.57      wiz       183: argument structure for that file system.
1.50      jruoho    184: .Ss The hw.* subtree
1.1       pavel     185: The string and integer information available for the
                    186: .Li hw
                    187: level is detailed below.
                    188: The changeable column shows whether a process with appropriate
                    189: privilege may change the value.
1.37      jruoho    190: .Bl -column "hw.machine_arch" "integer" "Changeable" -offset indent
1.107     wiz       191: .It Sy Second level name Ta Sy Type Ta Sy Changeable
1.1       pavel     192: .It hw.alignbytes      integer no
                    193: .It hw.byteorder       integer no
                    194: .It hw.cnmagic string  yes
                    195: .It hw.disknames       string  no
                    196: .It hw.diskstats       struct  no
                    197: .It hw.machine string  no
                    198: .It hw.machine_arch    string  no
                    199: .It hw.model   string  no
                    200: .It hw.ncpu    integer no
1.84      njoly     201: .It hw.ncpuonline      integer no
1.1       pavel     202: .It hw.pagesize        integer no
                    203: .It hw.physmem integer no
                    204: .It hw.physmem64       quad    no
                    205: .It hw.usermem integer no
                    206: .It hw.usermem64       quad    no
                    207: .El
                    208: .Bl -tag -width "123456"
1.91      kamil     209: .It Li hw.alignbytes ( Dv HW_ALIGNBYTES )
1.1       pavel     210: Alignment constraint for all possible data types.
                    211: This shows the value
                    212: .Dv ALIGNBYTES
                    213: in
1.56      uwe       214: .In machine/param.h ,
1.1       pavel     215: at the kernel compilation time.
1.91      kamil     216: .It Li hw.byteorder ( Dv HW_BYTEORDER )
1.56      uwe       217: The byteorder (4321, or 1234).
1.91      kamil     218: .It Li hw.cnmagic ( Dv HW_CNMAGIC )
1.1       pavel     219: The console magic key sequence.
1.91      kamil     220: .It Li hw.disknames ( Dv HW_DISKNAMES )
1.1       pavel     221: The list of (space separated) disk device names on the system.
1.91      kamil     222: .It Li hw.iostatnames ( Dv HW_IOSTATNAMES )
1.1       pavel     223: A space separated list of devices that will have I/O statistics
                    224: collected on them.
1.91      kamil     225: .It Li hw.iostats ( Dv HW_IOSTATS )
1.1       pavel     226: Return statistical information on the NFS mounts, disk and tape
                    227: devices on the system.
                    228: An array of
1.56      uwe       229: .Vt struct io_sysctl
1.1       pavel     230: structures is returned,
                    231: whose size depends on the current number of such objects in the system.
                    232: The third level name is the size of the
1.56      uwe       233: .Vt struct io_sysctl .
1.1       pavel     234: The type of object can be determined by examining the
                    235: .Va type
                    236: element of
1.56      uwe       237: .Vt struct io_sysctl .
1.1       pavel     238: Which can be
                    239: .Dv IOSTAT_DISK
                    240: (disk drive),
                    241: .Dv IOSTAT_TAPE
                    242: (tape drive), or
                    243: .Dv IOSTAT_NFS
                    244: (NFS mount).
1.91      kamil     245: .It Li hw.machine ( Dv HW_MACHINE )
1.1       pavel     246: The machine class.
1.91      kamil     247: .It Li hw.machine_arch ( Dv HW_MACHINE_ARCH )
1.1       pavel     248: The machine CPU class.
1.91      kamil     249: .It Li hw.model ( Dv HW_MODEL )
1.1       pavel     250: The machine model.
1.91      kamil     251: .It Li hw.ncpu ( Dv HW_NCPU )
1.84      njoly     252: The number of CPUs configured.
1.91      kamil     253: .It Li hw.ncpuonline ( Dv HW_NCPUONLINE )
1.84      njoly     254: The number of CPUs online.
1.91      kamil     255: .It Li hw.pagesize ( Dv HW_PAGESIZE )
1.1       pavel     256: The software page size.
1.91      kamil     257: .It Li hw.physmem ( Dv HW_PHYSMEM )
1.1       pavel     258: The bytes of physical memory as a 32-bit integer.
1.91      kamil     259: .It Li hw.physmem64 ( Dv HW_PHYSMEM64 )
1.1       pavel     260: The bytes of physical memory as a 64-bit integer.
1.91      kamil     261: .It Li hw.usermem ( Dv HW_USERMEM )
1.1       pavel     262: The bytes of non-kernel memory as a 32-bit integer.
1.91      kamil     263: .It Li hw.usermem64 ( Dv HW_USERMEM64 )
1.1       pavel     264: The bytes of non-kernel memory as a 64-bit integer.
                    265: .El
1.50      jruoho    266: .Ss The kern.* subtree
1.43      jruoho    267: This subtree includes data generally related to the kernel.
1.1       pavel     268: The string and integer information available for the
                    269: .Li kern
                    270: level is detailed below.
                    271: The changeable column shows whether a process with appropriate
                    272: privilege may change the value.
1.43      jruoho    273: .Bl -column "kern.posix_reader_writer_locks" \
                    274: "struct kinfo_drivers" "not applicable"
1.107     wiz       275: .It Sy Second level name Ta Sy Type Ta Sy Changeable
1.51      jruoho    276: .It kern.aio_listio_max        integer yes
                    277: .It kern.aio_max       integer yes
1.44      jruoho    278: .It kern.arandom       integer no
1.1       pavel     279: .It kern.argmax        integer no
1.39      jruoho    280: .It kern.boothowto     integer no
1.1       pavel     281: .It kern.boottime      struct timeval  no
1.85      apb       282: .It kern.buildinfo     string  no
1.39      jruoho    283: .\".It kern.bufq       node    not applicable
1.1       pavel     284: .It kern.ccpu  integer no
                    285: .It kern.clockrate     struct clockinfo        no
                    286: .It kern.consdev       integer no
1.39      jruoho    287: .It kern.coredump      node    not applicable
1.21      joerg     288: .It kern.cp_id struct  no
                    289: .It kern.cp_time       uint64_t[\|]    no
1.46      jruoho    290: .It kern.cryptodevallowsoft    integer yes
1.1       pavel     291: .It kern.defcorename   string  yes
1.38      jruoho    292: .It kern.detachall     integer yes
1.1       pavel     293: .It kern.domainname    string  yes
                    294: .It kern.drivers       struct kinfo_drivers    no
1.39      jruoho    295: .It kern.dump_on_panic integer yes
1.1       pavel     296: .It kern.file  struct file     no
                    297: .It kern.forkfsleep    integer yes
                    298: .It kern.fscale        integer no
                    299: .It kern.fsync integer no
1.21      joerg     300: .It kern.hardclock_ticks       integer no
1.1       pavel     301: .It kern.hostid        integer yes
                    302: .It kern.hostname      string  yes
1.21      joerg     303: .It kern.iov_max       integer no
1.39      jruoho    304: .It kern.ipc   node    not applicable
1.21      joerg     305: .It kern.job_control   integer no
1.1       pavel     306: .It kern.labeloffset   integer no
                    307: .It kern.labelsector   integer no
1.21      joerg     308: .It kern.login_name_max        integer no
1.1       pavel     309: .It kern.logsigexit    integer yes
1.21      joerg     310: .It kern.mapped_files  integer no
1.1       pavel     311: .It kern.maxfiles      integer yes
1.70      christos  312: .It kern.maxlwp        integer yes
1.1       pavel     313: .It kern.maxpartitions integer no
                    314: .It kern.maxphys       integer no
                    315: .It kern.maxproc       integer yes
                    316: .It kern.maxptys       integer yes
                    317: .It kern.maxvnodes     integer yes
1.116     wiz       318: .It kern.messages      integer yes
1.1       pavel     319: .It kern.mbuf  node    not applicable
                    320: .It kern.memlock       integer no
1.21      joerg     321: .It kern.memlock_range integer no
                    322: .It kern.memory_protection     integer no
1.42      jruoho    323: .It kern.module        node    not applicable
1.21      joerg     324: .It kern.monotonic_clock       integer no
1.49      jruoho    325: .It kern.mqueue        node    not applicable
1.1       pavel     326: .It kern.msgbuf        integer no
                    327: .It kern.msgbufsize    integer no
                    328: .It kern.ngroups       integer no
1.41      jruoho    329: .\".It kern.no_sa_support      integer yes
1.1       pavel     330: .It kern.ntptime       struct ntptimeval       no
                    331: .It kern.osrelease     string  no
1.39      jruoho    332: .It kern.osrevision    integer no
1.1       pavel     333: .It kern.ostype        string  no
1.41      jruoho    334: .\".It kern.panic_now  integer yes
1.1       pavel     335: .It kern.pipe  node    not applicable
1.82      joerg     336: .It kern.pool  struct pool_sysctl      no
1.39      jruoho    337: .\" .It kern.posix     node    not applicable
                    338: .It kern.posix1version integer no
1.51      jruoho    339: .It kern.posix_aio     integer no
1.21      joerg     340: .It kern.posix_barriers        integer no
                    341: .It kern.posix_reader_writer_locks     integer no
1.39      jruoho    342: .\".It kern.posix_sched        integer yes
1.21      joerg     343: .It kern.posix_semaphores      integer no
                    344: .It kern.posix_spin_locks      integer no
                    345: .It kern.posix_threads integer no
                    346: .It kern.posix_timers  integer no
1.1       pavel     347: .It kern.proc  struct kinfo_proc       no
                    348: .It kern.proc2 struct kinfo_proc2      no
1.21      joerg     349: .It kern.proc_args     string  no
1.39      jruoho    350: .It kern.profiling     node    not applicable
1.41      jruoho    351: .\".It kern.pset       node    not applicable
1.1       pavel     352: .It kern.rawpartition  integer no
1.21      joerg     353: .It kern.root_device   string  no
                    354: .It kern.root_partition        integer no
                    355: .It kern.rtc_offset    integer yes
                    356: .It kern.saved_ids     integer no
1.39      jruoho    357: .It kern.sbmax integer yes
1.108     hubertf   358: .It kern.sched node    not applicable
1.1       pavel     359: .It kern.securelevel   integer raise only
1.39      jruoho    360: .It kern.somaxkva      integer yes
1.21      joerg     361: .It kern.synchronized_io       integer no
1.19      christos  362: .It kern.timecounter   node    not applicable
1.1       pavel     363: .It kern.timex struct  no
                    364: .It kern.tkstat        node    not applicable
1.66      christos  365: .It kern.tty   node    not applicable
1.1       pavel     366: .It kern.urandom       integer no
1.45      jruoho    367: .It kern.usercrypto    integer yes
                    368: .It kern.userasymcrypto        integer yes
1.39      jruoho    369: .It kern.veriexec      node    not applicable
1.1       pavel     370: .It kern.version       string  no
                    371: .It kern.vnode struct vnode    no
                    372: .El
                    373: .Bl -tag -width "123456"
1.51      jruoho    374: .It Li kern.aio_listio_max
1.119     wiz       375: The maximum number of asynchronous I/O operations in a single list
                    376: I/O call.
1.51      jruoho    377: Like with all variables related to
                    378: .Xr aio 3 ,
                    379: the variable may be created and removed dynamically
                    380: upon loading or unloading the corresponding kernel module.
                    381: .It Li kern.aio_max
                    382: The maximum number of asynchronous I/O operations.
1.44      jruoho    383: .It Li kern.arandom
                    384: This variable picks a random number each time it is queried.
                    385: The used random number generator
1.119     wiz       386: .Pf ( RNG )
1.44      jruoho    387: is based on
                    388: .Xr arc4random 3 .
1.91      kamil     389: .It Li kern.argmax ( Dv KERN_ARGMAX )
1.1       pavel     390: The maximum bytes of argument to
                    391: .Xr execve 2 .
1.23      apb       392: .It Li kern.boothowto
                    393: Flags passed from the boot loader; see
                    394: .Xr reboot 2
                    395: for the meanings of the flags.
1.91      kamil     396: .It Li kern.boottime ( Dv KERN_BOOTTIME )
1.1       pavel     397: A
1.56      uwe       398: .Vt struct timeval
1.1       pavel     399: structure is returned.
                    400: This structure contains the time that the system was booted.
1.104     pgoyette  401: .It Li kern.bufq
                    402: This variable contains information on the
                    403: .Xr bufq 9
                    404: subsystem.
                    405: Currently, the only third level name implemented is
                    406: .Dv kern.bufq.strategies
                    407: which provides a list of buffer queue strategies currently available.
1.85      apb       408: .It Li kern.buildinfo
                    409: When the kernel is built, the build environment may optionally provide
                    410: arbitrary information to be stored in this variable.
1.91      kamil     411: .It Li kern.ccpu ( Dv KERN_CCPU )
1.1       pavel     412: The scheduler exponential decay value.
1.91      kamil     413: .It Li kern.clockrate ( Dv KERN_CLOCKRATE )
1.1       pavel     414: A
1.56      uwe       415: .Vt struct clockinfo
1.1       pavel     416: structure is returned.
                    417: This structure contains the clock, statistics clock and profiling clock
                    418: frequencies, the number of micro-seconds per hz tick, and the clock
                    419: skew rate.
1.36      jruoho    420: Refer to
                    421: .Xr hz 9
                    422: for additional details.
1.91      kamil     423: .It Li kern.consdev ( Dv KERN_CONSDEV )
1.1       pavel     424: Console device.
1.39      jruoho    425: .It Li kern.coredump
                    426: Settings related to set-id processes coredumps.
                    427: By default, set-id processes do not dump core in situations where
                    428: other processes would.
                    429: The settings in this node allows an administrator to change this
                    430: behavior.
                    431: .Pp
                    432: The third level name is
                    433: .Dv kern.coredump.setid
1.40      jruoho    434: and fourth level variables are described below.
                    435: .Bl -column "kern.coredump.setid.group" "integer" "Changeable" -offset indent
1.107     wiz       436: .It Sy Fourth level name Ta Sy Type Ta Sy Changeable
1.40      jruoho    437: .It kern.coredump.setid.dump   integer yes
                    438: .It kern.coredump.setid.group  integer yes
                    439: .It kern.coredump.setid.mode   integer yes
                    440: .It kern.coredump.setid.owner  integer yes
                    441: .It kern.coredump.setid.path   string  yes
                    442: .El
1.39      jruoho    443: .Bl -tag -width "123456"
                    444: .It Li kern.coredump.setid.dump
                    445: If non-zero, set-id processes will dump core.
                    446: .It Li kern.coredump.setid.group
                    447: The group-id for the set-id processes' coredump.
                    448: .It Li kern.coredump.setid.mode
                    449: The mode for the set-id processes' coredump.
                    450: See
                    451: .Xr chmod 1 .
                    452: .It Li kern.coredump.setid.owner
                    453: The user-id that will be used as the owner of the set-id processes'
                    454: coredump.
                    455: .It Li kern.coredump.setid.path
                    456: The path to which set-id processes' coredumps will be saved to.
                    457: Same syntax as kern.defcorename.
                    458: .El
1.91      kamil     459: .It Li kern.cp_id ( Dv KERN_CP_ID )
1.1       pavel     460: Mapping of CPU number to CPU id.
1.91      kamil     461: .It Li kern.cp_time ( Dv KERN_CP_TIME )
1.56      uwe       462: Returns an array of
                    463: .Dv CPUSTATES
1.101     wiz       464: .Vt uint64_t Ns s .
1.1       pavel     465: This array contains the
                    466: number of clock ticks spent in different CPU states.
                    467: On multi-processor systems, the sum across all CPUs is returned unless
                    468: appropriate space is given for one data set for each CPU.
                    469: Data for a specific CPU can also be obtained by adding the number of the
                    470: CPU at the end of the MIB, enlarging it by one.
1.46      jruoho    471: .It Li kern.cryptodevallowsoft
                    472: This variable controls userland access to hardware versus software transforms
                    473: in the
                    474: .Xr crypto 4
                    475: system.
                    476: The available values are as follows:
1.47      wiz       477: .Bl -tag -width XX0 -offset indent
1.114     wiz       478: .It Dv < 0
1.46      jruoho    479: Always force userlevel requests to use software transforms.
                    480: .It Dv = 0
                    481: If present, use hardware and grant userlevel requests for
                    482: non-accelerated transforms (handling the latter in software).
1.114     wiz       483: .It Dv > 0
1.46      jruoho    484: Allow user requests only for transforms which are hardware-accelerated.
                    485: .El
1.91      kamil     486: .It Li kern.defcorename ( Dv KERN_DEFCORENAME )
1.1       pavel     487: Default template for the name of core dump files (see also
                    488: .Li proc.pid.corename
                    489: in the per-process variables
                    490: .Li proc.* ,
                    491: and
                    492: .Xr core 5
                    493: for format of this template).
                    494: The default value is
1.56      uwe       495: .Pa %n.core
1.1       pavel     496: and can be changed with the kernel configuration option
                    497: .Cd options DEFCORENAME
                    498: (see
                    499: .Xr options 4
                    500: ).
1.38      jruoho    501: .It Li kern.detachall
                    502: Detach all devices at shutdown.
1.91      kamil     503: .It Li kern.domainname ( Dv KERN_DOMAINNAME )
1.1       pavel     504: Get or set the YP domain name.
1.91      kamil     505: .It Li kern.drivers ( Dv KERN_DRIVERS )
1.1       pavel     506: Return an array of
1.56      uwe       507: .Vt struct kinfo_drivers
1.1       pavel     508: that contains the name and major device numbers of all the device drivers
                    509: in the current kernel.
                    510: The
                    511: .Va d_name
                    512: field is always a NUL terminated string.
                    513: The
                    514: .Va d_bmajor
                    515: field will be set to \-1 if the driver doesn't have a block device.
1.91      kamil     516: .It Li kern.dump_on_panic ( Dv KERN_DUMP_ON_PANIC )
1.41      jruoho    517: Perform a crash dump on system
                    518: .Xr panic 9 .
1.91      kamil     519: .It Li kern.file ( Dv KERN_FILE )
1.1       pavel     520: Return the entire file table.
                    521: The returned data consists of a single
1.56      uwe       522: .Vt struct filelist
1.1       pavel     523: followed by an array of
1.56      uwe       524: .Vt struct file ,
1.1       pavel     525: whose size depends on the current number of such objects in the system.
1.91      kamil     526: .It Li kern.forkfsleep ( Dv KERN_FORKFSLEEP )
1.1       pavel     527: If
                    528: .Xr fork 2
                    529: system call fails due to limit on number of processes (either
                    530: the global maxproc limit or user's one), wait for this many
                    531: milliseconds before returning
                    532: .Er EAGAIN
                    533: error to process.
                    534: Useful to keep heavily forking runaway processes in bay.
                    535: Default zero (no sleep).
                    536: Maximum is 20 seconds.
1.91      kamil     537: .It Li kern.fscale ( Dv KERN_FSCALE )
1.1       pavel     538: The kernel fixed-point scale factor.
1.91      kamil     539: .It Li kern.fsync ( Dv KERN_FSYNC )
1.58      wiz       540: Return 1 if the
                    541: .St -p1003.1b-93
                    542: File Synchronization Option is available
1.1       pavel     543: on this system,
1.56      uwe       544: otherwise\ 0.
1.91      kamil     545: .It Li kern.hardclock_ticks ( Dv KERN_HARDCLOCK_TICKS )
1.1       pavel     546: Returns the number of
                    547: .Xr hardclock 9
                    548: ticks.
1.105     pgoyette  549: .It Li kern.hist
                    550: This variable contains kernel history data if the kernel was
                    551: configured for any of the options
                    552: .Dv UVHMIST ,
                    553: .Dv USB_DEBUG ,
                    554: .Dv BIOHIST ,
                    555: or
                    556: .Dv SCDEBUG .
                    557: (See
                    558: .Xr options 4
                    559: for more details.)
                    560: The third-level names correspond to each available history table.
                    561: The values of the history tables are in an internal format, and can be
                    562: decoded by the
                    563: .Xr vmstat 1
                    564: utility's
1.106     wiz       565: .Fl U
1.105     pgoyette  566: and
1.106     wiz       567: .Fl u
1.105     pgoyette  568: options;
1.106     wiz       569: the
                    570: .Fl l
                    571: option can be used to see which tables are available.
1.91      kamil     572: .It Li kern.hostid ( Dv KERN_HOSTID )
1.39      jruoho    573: Get or set the host identifier.
                    574: This is aimed to replace the legacy
                    575: .Xr gethostid 3
                    576: and
                    577: .Xr sethostid 3
                    578: system calls.
1.91      kamil     579: .It Li kern.hostname ( Dv KERN_HOSTNAME )
1.39      jruoho    580: Get or set the
                    581: .Xr hostname 1 .
1.91      kamil     582: .It Li kern.iov_max ( Dv KERN_IOV_MAX )
1.1       pavel     583: Return the maximum number of
1.56      uwe       584: .Vt iovec
1.1       pavel     585: structures that a process has available for use with
                    586: .Xr preadv 2 ,
                    587: .Xr pwritev 2 ,
                    588: .Xr readv 2 ,
                    589: .Xr recvmsg 2 ,
                    590: .Xr sendmsg 2
                    591: and
                    592: .Xr writev 2 .
1.91      kamil     593: .It Li kern.ipc ( Dv KERN_SYSVIPC )
1.39      jruoho    594: Return information about the SysV IPC parameters.
                    595: The third level names for the ipc variables are detailed below.
                    596: .Bl -column "kern.ipc.shm_use_phys" "integer" "Changeable" -offset indent
1.107     wiz       597: .It Sy Third level name Ta Sy Type Ta Sy Changeable
1.39      jruoho    598: .It kern.ipc.sysvmsg   integer no
                    599: .It kern.ipc.sysvsem   integer no
                    600: .It kern.ipc.sysvshm   integer no
                    601: .It kern.ipc.sysvipc_info      struct  no
                    602: .It kern.ipc.shmmax    integer yes
                    603: .It kern.ipc.shmmni    integer yes
                    604: .It kern.ipc.shmseg    integer yes
                    605: .It kern.ipc.shmmaxpgs integer yes
                    606: .It kern.ipc.shm_use_phys      integer yes
                    607: .It kern.ipc.msgmni    integer yes
                    608: .It kern.ipc.msgseg    integer yes
                    609: .It kern.ipc.semmni    integer yes
                    610: .It kern.ipc.semmns    integer yes
                    611: .It kern.ipc.semmnu    integer yes
                    612: .El
                    613: .Bl -tag -width "123456"
1.91      kamil     614: .It Li kern.ipc.sysvmsg ( Dv KERN_SYSVIPC_MSG )
1.39      jruoho    615: Returns 1 if System V style message queue functionality is available
                    616: on this system,
1.56      uwe       617: otherwise\ 0.
1.91      kamil     618: .It Li kern.ipc.sysvsem ( Dv KERN_SYSVIPC_SEM )
1.39      jruoho    619: Returns 1 if System V style semaphore functionality is available
                    620: on this system,
1.56      uwe       621: otherwise\ 0.
1.91      kamil     622: .It Li kern.ipc.sysvshm ( Dv KERN_SYSVIPC_SHM )
1.39      jruoho    623: Returns 1 if System V style share memory functionality is available
                    624: on this system,
1.56      uwe       625: otherwise\ 0.
1.91      kamil     626: .It Li kern.ipc.sysvipc_info ( Dv KERN_SYSVIPC_INFO )
1.39      jruoho    627: Return System V style IPC configuration and run-time information.
                    628: The fourth level name selects the System V style IPC facility.
                    629: .Bl -column "KERN_SYSVIPC_MSG_INFO" "struct shm_sysctl_info" -offset indent
1.107     wiz       630: .It Sy Fourth level name Ta Sy Type
1.39      jruoho    631: .It KERN_SYSVIPC_MSG_INFO      struct msg_sysctl_info
                    632: .It KERN_SYSVIPC_SEM_INFO      struct sem_sysctl_info
                    633: .It KERN_SYSVIPC_SHM_INFO      struct shm_sysctl_info
                    634: .El
                    635: .Bl -tag -width "123456"
                    636: .It Li KERN_SYSVIPC_MSG_INFO
                    637: Return information on the System V style message facility.
                    638: The
                    639: .Sy msg_sysctl_info
                    640: structure is defined in
                    641: .In sys/msg.h .
                    642: .It Li KERN_SYSVIPC_SEM_INFO
                    643: Return information on the System V style semaphore facility.
                    644: The
                    645: .Sy sem_sysctl_info
                    646: structure is defined in
                    647: .In sys/sem.h .
                    648: .It Li KERN_SYSVIPC_SHM_INFO
                    649: Return information on the System V style shared memory facility.
                    650: The
                    651: .Sy shm_sysctl_info
                    652: structure is defined in
                    653: .In sys/shm.h .
                    654: .El
1.91      kamil     655: .It Li kern.ipc.shmmax ( Dv KERN_SYSVIPC_SHMMAX )
1.39      jruoho    656: Max shared memory segment size in bytes.
1.91      kamil     657: .It Li kern.ipc.shmmni ( Dv KERN_SYSVIPC_SHMMNI )
1.39      jruoho    658: Max number of shared memory identifiers.
1.91      kamil     659: .It Li kern.ipc.shmseg ( Dv KERN_SYSVIPC_SHMSEG )
1.39      jruoho    660: Max shared memory segments per process.
1.91      kamil     661: .It Li kern.ipc.shmmaxpgs ( Dv KERN_SYSVIPC_SHMMAXPGS )
1.39      jruoho    662: Max amount of shared memory in pages.
1.91      kamil     663: .It Li kern.ipc.shm_use_phys ( Dv KERN_SYSVIPC_SHMUSEPHYS )
1.39      jruoho    664: Locking of shared memory in physical memory.
                    665: If 0, memory can be swapped
                    666: out, otherwise it will be locked in physical memory.
                    667: .It Li kern.ipc.msgmni
                    668: Max number of message queue identifiers.
                    669: .It Li kern.ipc.msgseg
                    670: Max number of number of message segments.
                    671: .It Li kern.ipc.semmni
                    672: Max number of number of semaphore identifiers.
                    673: .It Li kern.ipc.semmns
                    674: Max number of number of semaphores in system.
                    675: .It Li kern.ipc.semmnu
                    676: Max number of undo structures in system.
                    677: .El
1.91      kamil     678: .It Li kern.job_control ( Dv KERN_JOB_CONTROL )
1.56      uwe       679: Return 1 if job control is available on this system, otherwise\ 0.
1.91      kamil     680: .It Li kern.labeloffset ( Dv KERN_LABELOFFSET )
1.56      uwe       681: The offset within the sector specified by
                    682: .Dv KERN_LABELSECTOR
                    683: of the
1.1       pavel     684: .Xr disklabel 5 .
1.91      kamil     685: .It Li kern.labelsector ( Dv KERN_LABELSECTOR )
1.1       pavel     686: The sector number containing the
                    687: .Xr disklabel 5 .
1.91      kamil     688: .It Li kern.login_name_max ( Dv KERN_LOGIN_NAME_MAX )
1.1       pavel     689: The size of the storage required for a login name, in bytes,
                    690: including the terminating NUL.
1.91      kamil     691: .It Li kern.logsigexit ( Dv KERN_LOGSIGEXIT )
1.1       pavel     692: If this flag is non-zero, the kernel will
                    693: .Xr log 9
                    694: all process exits due to signals which create a
                    695: .Xr core 5
                    696: file, and whether the coredump was created.
1.91      kamil     697: .It Li kern.mapped_files ( Dv KERN_MAPPED_FILES )
1.58      wiz       698: Returns 1 if the
                    699: .St -p1003.1b-93
                    700: Memory Mapped Files Option is available on this system,
1.56      uwe       701: otherwise\ 0.
1.91      kamil     702: .It Li kern.maxfiles ( Dv KERN_MAXFILES )
1.1       pavel     703: The maximum number of open files that may be open in the system.
1.91      kamil     704: .It Li kern.maxpartitions ( Dv KERN_MAXPARTITIONS )
1.1       pavel     705: The maximum number of partitions allowed per disk.
1.71      wiz       706: .It Li kern.maxlwp
1.70      christos  707: The maximum number of Lightweight Processes (threads) the system allows
                    708: per uid.
1.91      kamil     709: .It Li kern.maxphys ( Dv KERN_MAXPHYS )
1.1       pavel     710: Maximum raw I/O transfer size.
1.91      kamil     711: .It Li kern.maxproc ( Dv KERN_MAXPROC )
1.1       pavel     712: The maximum number of simultaneous processes the system will allow.
1.91      kamil     713: .It Li kern.maxptys ( Dv KERN_MAXPTYS )
1.1       pavel     714: The maximum number of pseudo terminals.
                    715: This value can be both raised and lowered, though it cannot
                    716: be set lower than number of currently used ptys.
                    717: See also
                    718: .Xr pty 4 .
1.91      kamil     719: .It Li kern.maxvnodes ( Dv KERN_MAXVNODES )
1.1       pavel     720: The maximum number of vnodes available on the system.
                    721: This can only be raised.
1.91      kamil     722: .It Li kern.mbuf ( Dv KERN_MBUF )
1.1       pavel     723: Return information about the mbuf control variables.
                    724: Mbufs are data structures which store network packets and other data
                    725: structures in the networking code, see
                    726: .Xr mbuf 9 .
                    727: The third level names for the mbuf variables are detailed below.
                    728: The changeable column shows whether a process with appropriate
                    729: privilege may change the value.
1.21      joerg     730: .Bl -column "kern.mbuf.nmbclusters" "integer" "Changeable" -offset indent
1.107     wiz       731: .It Sy Third level name Ta Sy Type Ta Sy Changeable
1.1       pavel     732: .\" XXX Changeable? really?
                    733: .It kern.mbuf.mblowat  integer yes
                    734: .It kern.mbuf.mclbytes integer yes
                    735: .It kern.mbuf.mcllowat integer yes
                    736: .It kern.mbuf.msize    integer yes
                    737: .It kern.mbuf.nmbclusters      integer yes
                    738: .El
                    739: .Pp
                    740: The variables are as follows:
                    741: .Bl -tag -width "123456"
1.91      kamil     742: .It Li kern.mbuf.mblowat ( Dv MBUF_MBLOWAT )
1.1       pavel     743: The mbuf low water mark.
1.91      kamil     744: .It Li kern.mbuf.mclbytes ( Dv MBUF_MCLBYTES )
1.1       pavel     745: The mbuf cluster size.
1.91      kamil     746: .It Li kern.mbuf.mcllowat ( Dv MBUF_MCLLOWAT )
1.1       pavel     747: The mbuf cluster low water mark.
1.91      kamil     748: .It Li kern.mbuf.msize ( Dv MBUF_MSIZE )
1.1       pavel     749: The mbuf base size.
1.91      kamil     750: .It Li kern.mbuf.nmbclusters ( Dv MBUF_NMBCLUSTERS )
1.1       pavel     751: The limit on the number of mbuf clusters.
                    752: The variable can only be increased, and only increased on machines with
                    753: direct-mapped pool pages.
                    754: .El
1.91      kamil     755: .It Li kern.memlock ( Dv KERN_MEMLOCK )
1.58      wiz       756: Returns 1 if the
                    757: .St -p1003.1b-93
                    758: Process Memory Locking Option is available on this system,
1.56      uwe       759: otherwise\ 0.
1.91      kamil     760: .It Li kern.memlock_range ( Dv KERN_MEMLOCK_RANGE )
1.58      wiz       761: Returns 1 if the
                    762: .St -p1003.1b-93
                    763: Range Memory Locking Option is available on this system,
1.56      uwe       764: otherwise\ 0.
1.91      kamil     765: .It Li kern.memory_protection ( Dv KERN_MEMORY_PROTECTION )
1.58      wiz       766: Returns 1 if the
                    767: .St -p1003.1b-93
                    768: Memory Protection Option is available on this system,
1.56      uwe       769: otherwise\ 0.
1.102     pgoyette  770: .It Li kern.messages
                    771: Kernel console message verbosity.
                    772: See
1.116     wiz       773: .Aq Pa sys/reboot.h
1.102     pgoyette  774: .Bl -column "verbosity" "setting" -offset indent
1.116     wiz       775: .It Sy Value Ta Sy Verbosity Ta Sy sys/reboot.h equivalent
                    776: .It 0 Ta Silent Ta Sy AB_SILENT
                    777: .It 1 Ta Quiet Ta Sy AB_QUIET
                    778: .It 2 Ta Normal Ta Sy AB_NORMAL
                    779: .It 3 Ta Verbose Ta Sy AB_VERBOSE
                    780: .It 4 Ta Debug Ta Sy AB_DEBUG
1.102     pgoyette  781: .El
1.42      jruoho    782: .It Li kern.module
                    783: Settings related to kernel modules.
                    784: The third level names for the settings are described below.
                    785: .Bl -column "kern.module.autoload" "integer" "Changeable" -offset indent
1.107     wiz       786: .It Sy Third level name Ta Sy Type Ta Sy Changeable
1.42      jruoho    787: .It kern.module.autoload       integer yes
1.78      pgoyette  788: .It kern.module.autotime       integer yes
1.121     pgoyette  789: .It kern.module.verbose        boolean yes
1.42      jruoho    790: .El
                    791: .Pp
                    792: The variables are as follows:
                    793: .Bl -tag -width "123456"
                    794: .It Li kern.module.autoload
                    795: A boolean that controls whether kernel modules are loaded automatically.
1.52      jruoho    796: See
1.53      jruoho    797: .Xr module 7
1.42      jruoho    798: for additional details.
1.78      pgoyette  799: .It Li kern.module.autotime
                    800: An integer that controls the delay before an attempt is made to
1.79      wiz       801: automatically unload a module that was auto-loaded.
                    802: Setting this value to zero disables the auto-unload function.
1.42      jruoho    803: .It Li kern.module.verbose
                    804: A boolean that enables or disables verbose
                    805: debug messages related to kernel modules.
                    806: .El
1.91      kamil     807: .It Li kern.monotonic_clock ( Dv KERN_MONOTONIC_CLOCK )
1.58      wiz       808: Returns the standard version the implementation of the
                    809: .St -p1003.1b-93
1.49      jruoho    810: Monotonic Clock Option conforms to,
1.56      uwe       811: otherwise\ 0.
1.48      jruoho    812: .It Li kern.mqueue
1.119     wiz       813: Settings related to POSIX message queues; see
1.48      jruoho    814: .Xr mqueue 3 .
                    815: This node is created dynamically when
                    816: the corresponding kernel module is loaded.
                    817: The third level names for the settings are described below.
                    818: .Bl -column "kern.mqueue.mq_max_msgsize" "integer" "Changeable" -offset indent
1.107     wiz       819: .It Sy Third level name Ta Sy Type Ta Sy Changeable
1.48      jruoho    820: .It kern.mqueue.mq_open_max    integer yes
                    821: .It kern.mqueue.mq_prio_max    integer yes
                    822: .It kern.mqueue.mq_max_msgsize integer yes
                    823: .It kern.mqueue.mq_def_maxmsg  integer yes
                    824: .It kern.mqueue.mq_max_maxmsg  integer yes
                    825: .El
                    826: .Pp
                    827: The variables are:
                    828: .Bl -tag -width "123456"
                    829: .It Li kern.mqueue.mq_open_max
                    830: The maximum number of message queue descriptors any single process can open.
                    831: .It Li kern.mqueue.mq_prio_max
                    832: The maximum priority of a message.
                    833: .It Li kern.mqueue.mq_max_msgsize
                    834: The maximum size of a message in a message queue.
                    835: .It Li kern.mqueue.mq_def_maxmsg
                    836: The default maximum message count.
                    837: .It Li kern.mqueue.mq_max_maxmsg
                    838: The maximum number of messages in a message queue.
                    839: .El
1.91      kamil     840: .It Li kern.msgbuf ( Dv KERN_MSGBUF )
1.1       pavel     841: The kernel message buffer, rotated so that the head of the circular kernel
                    842: message buffer is at the start of the returned data.
                    843: The returned data may contain NUL bytes.
1.91      kamil     844: .It Li kern.msgbufsize ( Dv KERN_MSGBUFSIZE )
1.1       pavel     845: The maximum number of characters that the kernel message buffer can hold.
1.91      kamil     846: .It Li kern.ngroups ( Dv KERN_NGROUPS )
1.1       pavel     847: The maximum number of supplemental groups.
1.41      jruoho    848: .\" .It Li kern.no_sa_support
                    849: .\" XXX: Undocumented.
1.91      kamil     850: .It Li kern.ntptime ( Dv KERN_NTPTIME )
1.1       pavel     851: A
1.56      uwe       852: .Vt struct ntptimeval
1.1       pavel     853: structure is returned.
                    854: This structure contains data used by the
                    855: .Xr ntpd 8
                    856: program.
1.91      kamil     857: .It Li kern.osrelease ( Dv KERN_OSRELEASE )
1.1       pavel     858: The system release string.
1.91      kamil     859: .It Li kern.osrevision ( Dv KERN_OSREV )
1.1       pavel     860: The system revision string.
1.91      kamil     861: .It Li kern.ostype ( Dv KERN_OSTYPE )
1.1       pavel     862: The system type string.
1.41      jruoho    863: .\".It Li kern.panic_now
                    864: .\" XXX: Undocumented.
1.91      kamil     865: .It Li kern.pipe ( Dv KERN_PIPE )
1.1       pavel     866: Pipe settings.
                    867: The third level names for the  integer pipe settings is detailed below.
                    868: The changeable column shows whether a process with appropriate
                    869: privilege may change the value.
1.21      joerg     870: .Bl -column "kern.pipe.maxbigpipes" "integer" "Changeable" -offset indent
1.107     wiz       871: .It Sy Third level name Ta Sy Type Ta Sy Changeable
1.1       pavel     872: .It kern.pipe.kvasiz   integer yes
                    873: .It kern.pipe.maxbigpipes      integer yes
                    874: .It kern.pipe.maxkvasz integer yes
                    875: .It kern.pipe.limitkva integer yes
                    876: .It kern.pipe.nbigpipes        integer yes
                    877: .El
                    878: .Pp
                    879: The variables are as follows:
                    880: .Bl -tag -width "123456"
1.91      kamil     881: .It Li kern.pipe.kvasiz ( Dv KERN_PIPE_KVASIZ )
1.1       pavel     882: Amount of kernel memory consumed by pipe buffers.
1.91      kamil     883: .It Li kern.pipe.maxbigpipes ( Dv KERN_PIPE_MAXBIGPIPES )
1.56      uwe       884: Maximum number of
                    885: .Dq big
                    886: pipes.
1.91      kamil     887: .It Li kern.pipe.maxkvasz ( Dv KERN_PIPE_MAXKVASZ )
1.1       pavel     888: Maximum amount of kernel memory to be used for pipes.
1.91      kamil     889: .It Li kern.pipe.limitkva ( Dv KERN_PIPE_LIMITKVA )
1.1       pavel     890: Limit for direct transfers via page loan.
1.91      kamil     891: .It Li kern.pipe.nbigpipes ( Dv KERN_PIPE_NBIGPIPES )
1.56      uwe       892: Number of
                    893: .Dq big
                    894: pipes.
1.1       pavel     895: .El
1.82      joerg     896: .It Li kern.pool
                    897: Provides statistics about the
1.83      wiz       898: .Xr pool 9
1.82      joerg     899: and
                    900: .Xr pool_cache 9
                    901: subsystems.
1.39      jruoho    902: .\" XXX: Undocumented .It Li kern.posix ( ? )
                    903: .\"     This is a node in which the only variable is semmax.
1.91      kamil     904: .It Li kern.posix1version ( Dv KERN_POSIX1 )
1.58      wiz       905: The version of ISO/IEC 9945
                    906: .Pq St -p1003.1
                    907: with which the system attempts to comply.
1.51      jruoho    908: .It Li kern.posix_aio
                    909: The version of
                    910: .St -p1003.1
                    911: and its Asynchronous I/O option to which the system attempts to conform.
1.91      kamil     912: .It Li kern.posix_barriers ( Dv KERN_POSIX_BARRIERS )
1.1       pavel     913: The version of
                    914: .St -p1003.1
                    915: and its
                    916: Barriers
                    917: option to which the system attempts to conform,
1.56      uwe       918: otherwise\ 0.
1.91      kamil     919: .It Li kern.posix_reader_writer_locks ( Dv KERN_POSIX_READER_WRITER_LOCKS )
1.1       pavel     920: The version of
                    921: .St -p1003.1
                    922: and its
                    923: Read-Write Locks
                    924: option to which the system attempts to conform,
1.56      uwe       925: otherwise\ 0.
1.41      jruoho    926: .\".It Li kern.posix_sched
                    927: .\" XXX: Undocumented.
1.91      kamil     928: .It Li kern.posix_semaphores ( Dv KERN_POSIX_SEMAPHORES )
1.1       pavel     929: The version of
                    930: .St -p1003.1
                    931: and its
                    932: Semaphores
                    933: option to which the system attempts to conform,
1.56      uwe       934: otherwise\ 0.
1.91      kamil     935: .It Li kern.posix_spin_locks ( Dv KERN_POSIX_SPIN_LOCKS )
1.1       pavel     936: The version of
                    937: .St -p1003.1
                    938: and its
                    939: Spin Locks
                    940: option to which the system attempts to conform,
1.56      uwe       941: otherwise\ 0.
1.91      kamil     942: .It Li kern.posix_threads ( Dv KERN_POSIX_THREADS )
1.1       pavel     943: The version of
                    944: .St -p1003.1
                    945: and its
                    946: Threads
                    947: option to which the system attempts to conform,
1.56      uwe       948: otherwise\ 0.
1.91      kamil     949: .It Li kern.posix_timers ( Dv KERN_POSIX_TIMERS )
1.1       pavel     950: The version of
                    951: .St -p1003.1
                    952: and its
                    953: Timers
                    954: option to which the system attempts to conform,
1.56      uwe       955: otherwise\ 0.
1.91      kamil     956: .It Li kern.proc ( Dv KERN_PROC )
1.1       pavel     957: Return the entire process table, or a subset of it.
                    958: An array of
1.56      uwe       959: .Vt struct kinfo_proc
1.1       pavel     960: structures is returned,
                    961: whose size depends on the current number of such objects in the system.
                    962: The third and fourth level numeric names are as follows:
1.21      joerg     963: .Bl -column "KERN_PROC_SESSION" "Fourth level is:" -offset indent
1.111     pgoyette  964: .It Sy Third level name Ta Sy Fourth level is :
1.21      joerg     965: .It KERN_PROC_ALL      None
                    966: .It KERN_PROC_GID      A group ID
                    967: .It KERN_PROC_PID      A process ID
                    968: .It KERN_PROC_PGRP     A process group
                    969: .It KERN_PROC_RGID     A real group ID
                    970: .It KERN_PROC_RUID     A real user ID
                    971: .It KERN_PROC_SESSION  A session ID
                    972: .It KERN_PROC_TTY      A tty device
                    973: .It KERN_PROC_UID      A user ID
1.1       pavel     974: .El
1.91      kamil     975: .It Li kern.proc2 ( Dv KERN_PROC2 )
1.56      uwe       976: As for
                    977: .Dv KERN_PROC ,
                    978: but an array of
                    979: .Vt struct kinfo_proc2
1.1       pavel     980: structures are returned.
                    981: The fifth level name is the size of the
1.56      uwe       982: .Vt struct kinfo_proc2
1.1       pavel     983: and the sixth level name is the number of structures to return.
1.91      kamil     984: .It Li kern.proc_args ( Dv KERN_PROC_ARGS )
1.1       pavel     985: Return the argv or environment strings (or the number thereof)
                    986: of a process.
                    987: Multiple strings are returned separated by NUL characters.
                    988: The third level name is the process ID.
                    989: The fourth level name is as follows:
1.93      christos  990: .Bl -column "KERN_PROG_PATHNAME" "The full pathname of the executable" -offset indent
1.92      wiz       991: .It Dv KERN_PROC_ARGV  The argv strings
                    992: .It Dv KERN_PROC_ENV   The environ strings
                    993: .It Dv KERN_PROC_NARGV The number of argv strings
                    994: .It Dv KERN_PROC_NENV  The number of environ strings
1.93      christos  995: .It Dv KERN_PROC_PATHNAME      The full pathname of the executable
1.1       pavel     996: .El
1.91      kamil     997: .It Li kern.profiling ( Dv KERN_PROF )
1.1       pavel     998: Return profiling information about the kernel.
                    999: If the kernel is not compiled for profiling,
1.56      uwe      1000: attempts to retrieve any of the
                   1001: .Dv KERN_PROF
                   1002: values will fail with
1.1       pavel    1003: .Er EOPNOTSUPP .
                   1004: The third level names for the string and integer profiling information
                   1005: is detailed below.
                   1006: The changeable column shows whether a process with appropriate
                   1007: privilege may change the value.
1.21      joerg    1008: .Bl -column "kern.profiling.gmonparam" "struct gmonparam" "Changeable" -offset indent
1.107     wiz      1009: .It Sy Third level name Ta Sy Type Ta Sy Changeable
1.1       pavel    1010: .It kern.profiling.count       u_short[\|]     yes
                   1011: .It kern.profiling.froms       u_short[\|]     yes
                   1012: .It kern.profiling.gmonparam   struct gmonparam        no
                   1013: .It kern.profiling.state       integer yes
                   1014: .It kern.profiling.tos struct tostruct yes
                   1015: .El
                   1016: .Pp
                   1017: The variables are as follows:
                   1018: .Bl -tag -width "123456"
1.91      kamil    1019: .It Li kern.profiling.count ( Dv GPROF_COUNT )
1.1       pavel    1020: Array of statistical program counter counts.
1.91      kamil    1021: .It Li kern.profiling.froms ( Dv GPROF_FROMS )
1.1       pavel    1022: Array indexed by program counter of call-from points.
1.91      kamil    1023: .It Li kern.profiling.gmonparams ( Dv GPROF_GMONPARAM )
1.1       pavel    1024: Structure giving the sizes of the above arrays.
1.91      kamil    1025: .It Li kern.profiling.state ( Dv GPROF_STATE )
1.1       pavel    1026: Profiling state.
1.56      uwe      1027: If set to
                   1028: .Dv GMON_PROF_ON ,
                   1029: starts profiling.
                   1030: If set to
                   1031: .Dv GMON_PROF_OFF ,
                   1032: stops profiling.
1.91      kamil    1033: .It Li kern.profiling.tos ( Dv GPROF_TOS )
1.1       pavel    1034: Array of
1.56      uwe      1035: .Vt struct tostruct
1.1       pavel    1036: describing destination of calls and their counts.
                   1037: .El
1.41      jruoho   1038: .\" .It Li kern.pset
                   1039: .\" XXX: Undocumented.
1.91      kamil    1040: .It Li kern.rawpartition ( Dv KERN_RAWPARTITION )
1.1       pavel    1041: The raw partition of a disk (a == 0).
1.91      kamil    1042: .It Li kern.root_device ( Dv KERN_ROOT_DEVICE )
1.1       pavel    1043: The name of the root device (e.g.,
                   1044: .Dq wd0 ) .
1.91      kamil    1045: .It Li kern.root_partition ( Dv KERN_ROOT_PARTITION )
1.1       pavel    1046: The root partition on the root device (a == 0).
1.91      kamil    1047: .It Li kern.rtc_offset ( Dv KERN_RTC_OFFSET )
1.1       pavel    1048: Return the offset of real time clock from UTC in minutes.
1.91      kamil    1049: .It Li kern.saved_ids ( Dv KERN_SAVED_IDS )
1.1       pavel    1050: Returns 1 if saved set-group and saved set-user ID is available.
1.91      kamil    1051: .It Li kern.sbmax ( Dv KERN_SBMAX )
1.1       pavel    1052: Maximum socket buffer size.
                   1053: .\" XXX units?
1.91      kamil    1054: .It Li kern.securelevel ( Dv KERN_SECURELVL )
1.25      elad     1055: See
                   1056: .Xr secmodel_securelevel 9 .
1.108     hubertf  1057: .It Li kern.sched ( dynamic )
                   1058: Influence the scheduling of LWPs, their priorisation and how they are
                   1059: distributed on and moved between CPUs.
                   1060: .Bl -column "kern.sched.balance_period" "integer" "Changeable" -offset indent
                   1061: .It Sy Third level name           Sy Type       Sy Changeable
                   1062: .It kern.sched.cacheht_time       integer       yes
                   1063: .It kern.sched.balance_period     integer       yes
                   1064: .It kern.sched.average_weight     integer       yes
                   1065: .It kern.sched.min_catch          integer       yes
                   1066: .It kern.sched.timesoftints       integer       yes
                   1067: .It kern.sched.kpreempt_pri       integer       yes
                   1068: .It kern.sched.upreempt_pri       integer       yes
                   1069: .It kern.sched.maxts      integer       yes
1.109     wiz      1070: .It kern.sched.mints      integer       yes
                   1071: .It kern.sched.name       string        no
1.108     hubertf  1072: .It kern.sched.rtts       integer       no
                   1073: .It kern.sched.pri_min    integer       no
                   1074: .It kern.sched.pri_max    integer       no
                   1075: .El
                   1076: .Pp
                   1077: The variables are as follows:
                   1078: .Bl -tag -width "123456"
                   1079: .It Li kern.sched.cacheht_time ( dynamic )
                   1080: Cache hotness time in which a LWP is kept on one particular CPU
1.109     wiz      1081: and not moved to another CPU.
                   1082: This reduces the overhead of flushing and reloading caches.
1.108     hubertf  1083: Defaults to 3ms.
1.109     wiz      1084: Needs to be given in
1.108     hubertf  1085: .Dq hz
                   1086: units, see
                   1087: .Xr mstohz 9 .
                   1088: .It Li kern.sched.balance_period ( dynamic )
                   1089: Interval at which the CPU queues are checked for re-balancing.
                   1090: Defaults to 300ms.
1.109     wiz      1091: Needs to be given in
1.108     hubertf  1092: .Dq hz
                   1093: units, see
                   1094: .Xr mstohz 9 .
                   1095: .It Li kern.sched.average_weight ( dynamic )
                   1096: Can be used to influence how likely LWPs are to be migrated from
1.109     wiz      1097: one CPU's queue of LWPs that are ready to run to a different, idle CPU.
1.108     hubertf  1098: The value gives the percentage for weighting the average count of
                   1099: migratable threads from the past against the current number of
1.109     wiz      1100: migratable threads.
                   1101: A small value gives more weight to the past, a larger values more weight
1.108     hubertf  1102: on the current situation.
1.109     wiz      1103: Defaults to 50 and must be between 0 and 100.
1.108     hubertf  1104: .It Li kern.sched.min_catch ( dynamic )
                   1105: Minimum count of migratable (runable) threads for catching (stealing)
                   1106: from another CPU.
                   1107: Defaults to 1 but can be increased to decrease chance of thread
1.109     wiz      1108: migration between CPUs.
1.108     hubertf  1109: .It Li kern.sched.timesoftints ( dynamic )
                   1110: Enable tracking of CPU time for soft interrupts
                   1111: as part of a LWP's real execution time.
                   1112: Set to a non-zero value to enable,
                   1113: and see
                   1114: .Xr ps 1
                   1115: for printing CPU times.
                   1116: .It Li kern.sched.kpreempt_pri ( dynamic )
                   1117: Minimum priority to trigger kernel preemption.
                   1118: .It Li kern.sched.upreempt_pri ( dynamic )
                   1119: Minimum priority to trigger user preemption.
                   1120: .It Li kern.sched.maxts ( dynamic )
                   1121: Scheduler specific maximal time quantum (in milliseconds).
                   1122: Must be set to a value larger than
                   1123: .Dq mints
                   1124: and between 10 and
1.109     wiz      1125: .Dq hz
1.108     hubertf  1126: as given by the
                   1127: .Dv kern.clockrate
                   1128: sysctl.
                   1129: Provided by the M2 scheduler.
                   1130: .It Li kern.sched.mints ( dynamic )
                   1131: Scheduler specific minimal time quantum (in milliseconds).
                   1132: Must be set to a value smaller than
                   1133: .Dq maxts
                   1134: and between 1 and
1.109     wiz      1135: .Dq hz
1.108     hubertf  1136: as given by the
                   1137: .Dq kern.clockrate
                   1138: sysctl.
                   1139: Provided by the M2 scheduler.
                   1140: .It Li kern.sched.name ( dynamic )
1.109     wiz      1141: Scheduler name.
1.108     hubertf  1142: Provided both by the M2 and the 4BSD scheduler.
                   1143: .It Li kern.sched.rtts ( dynamic )
                   1144: Fixed scheduler specific round-robin time quantum in milliseconds.
                   1145: Provided both by the M2 and the 4BSD scheduler.
                   1146: .It Li kern.sched.pri_min ( dynamic )
                   1147: Minimal POSIX real-time priority.
                   1148: See
                   1149: .Xr sched 3 .
                   1150: .It Li kern.sched.pri_max ( dynamic )
                   1151: Maximal POSIX real-time priority.
                   1152: See
                   1153: .Xr sched 3 .
                   1154: .El
1.91      kamil    1155: .It Li kern.somaxkva ( Dv KERN_SOMAXKVA )
1.1       pavel    1156: Maximum amount of kernel memory to be used for socket buffers.
                   1157: .\" XXX units?
1.91      kamil    1158: .It Li kern.synchronized_io ( Dv KERN_SYNCHRONIZED_IO )
1.58      wiz      1159: Returns 1 if the
                   1160: .St -p1003.1b-93
                   1161: Synchronized I/O Option is available on this system,
1.56      uwe      1162: otherwise\ 0.
1.19      christos 1163: .It Li kern.timecounter ( dynamic )
                   1164: Display and control the timecounter source of the system.
1.21      joerg    1165: .Bl -column "kern.timecounter.timestepwarnings" "integer" "Changeable" -offset indent
1.107     wiz      1166: .It Sy Third level name Ta Sy Type Ta Sy Changeable
1.19      christos 1167: .It kern.timecounter.choice    string  no
                   1168: .It kern.timecounter.hardware  string  yes
                   1169: .It kern.timecounter.timestepwarnings  integer yes
                   1170: .El
                   1171: .Pp
                   1172: The variables are as follows:
                   1173: .Bl -tag -width "123456"
                   1174: .It Li kern.timecounter.choice ( dynamic )
                   1175: The list of available timecounters with their quality and frequency.
                   1176: .It Li kern.timecounter.hardware ( dynamic )
                   1177: The currently selected timecounter source.
                   1178: .It Li kern.timecounter.timestepwarnings ( dynamic )
                   1179: If non-zero display a message each time the time is stepped.
                   1180: .El
1.91      kamil    1181: .It Li kern.timex ( Dv KERN_TIMEX )
1.1       pavel    1182: Not available.
1.91      kamil    1183: .It Li kern.tkstat ( Dv KERN_TKSTAT )
1.1       pavel    1184: Return information about the number of characters sent and received
                   1185: on ttys.
                   1186: The third level names for the tty statistic variables are detailed below.
                   1187: The changeable column shows whether a process
                   1188: with appropriate privilege may change the value.
1.21      joerg    1189: .Bl -column "kern.tkstat.cancc" "quad" "Changeable" -offset indent
1.107     wiz      1190: .It Sy Third level name Ta Sy Type Ta Sy Changeable
1.1       pavel    1191: .It kern.tkstat.cancc  quad    no
                   1192: .It kern.tkstat.nin    quad    no
                   1193: .It kern.tkstat.nout   quad    no
                   1194: .It kern.tkstat.rawcc  quad    no
                   1195: .El
                   1196: .Pp
                   1197: The variables are as follows:
                   1198: .Bl -tag -width "123456"
1.91      kamil    1199: .It Li kern.tkstat.cancc ( Dv KERN_TKSTAT_CANCC )
1.1       pavel    1200: The number of canonical input characters.
1.91      kamil    1201: .It Li kern.tkstat.nin ( Dv KERN_TKSTAT_NIN )
1.1       pavel    1202: The total number of input characters.
1.91      kamil    1203: .It Li kern.tkstat.nout ( Dv KERN_TKSTAT_NOUT )
1.1       pavel    1204: The total number of output characters.
1.91      kamil    1205: .It Li kern.tkstat.rawcc ( Dv KERN_TKSTAT_RAWCC )
1.1       pavel    1206: The number of raw input characters.
                   1207: .El
1.66      christos 1208: .It Li kern.tty
                   1209: The third level names for the tty setup variables are detailed below.
                   1210: The changeable column shows whether a process
                   1211: with appropriate privilege may change the value.
                   1212: .Bl -column "kern.tty.qsize" "int" "Changeable" -offset indent
1.107     wiz      1213: .It Sy Third level name Ta Sy Type Ta Sy Changeable
1.66      christos 1214: .It kern.tty.qsize     int     yes
                   1215: .El
                   1216: .Pp
                   1217: The variables are as follows:
                   1218: .Bl -tag -width "123456"
                   1219: .It Li kern.tty.qsize
                   1220: Control/display the size of the default input and output queues selected
                   1221: during tty creation.
                   1222: Is converted to a power of two and its range is between
                   1223: .Dv 1024
                   1224: and
                   1225: .Dv 65536 .
                   1226: .El
1.70      christos 1227: .It Li kern.uidinfo
                   1228: Resource usage for the current user.
                   1229: .Bl -column "kern.uidinfo.proccnt" "integer" "Changeable" -offset indent
1.107     wiz      1230: .It Sy Third level name Ta Sy Type Ta Sy Changeable
1.70      christos 1231: .It kern.uidinfo.proccnt       integer no
                   1232: .It kern.uidinfo.lwpcnt        integer no
                   1233: .It kern.uidinfo.lockcnt       integer no
                   1234: .It kern.uidinfo.sbsize        integer no
                   1235: .El
                   1236: .Bl -tag -width "123456"
                   1237: .It Li kern.uidinfo.proccnt
                   1238: Returns the number of active processes for the current user.
                   1239: .It Li kern.uidinfo.lwpcnt
                   1240: Returns the number of active threads for the current user; the first thread
                   1241: of each process is not counted.
                   1242: .It Li kern.uidinfo.lockcnt
                   1243: Number of locks held by the current user.
                   1244: .It Li kern.uidinfo.sbsize
                   1245: Number of bytes in socket buffers allocated to the current user.
                   1246: .El
1.91      kamil    1247: .It Li kern.urandom ( Dv KERN_URND )
1.1       pavel    1248: Random integer value.
1.45      jruoho   1249: .It Li kern.usercrypto
                   1250: When enabled, allows userland to
                   1251: .Xr open 2
                   1252: the
                   1253: .Pa /dev/crypto
                   1254: special device, used by the
                   1255: .Xr crypto 4
                   1256: system.
                   1257: .It Li kern.userasymcrypto
                   1258: Enables or disables the use of software asymmetric crypto support in the
                   1259: .Xr crypto 4
                   1260: system.
1.1       pavel    1261: .It Li kern.veriexec
1.40      jruoho   1262: Runtime information for
                   1263: .Xr veriexec 8 .
                   1264: .Bl -column "kern.veriexec.algorithms" "integer" "Changeable" -offset indent
1.107     wiz      1265: .It Sy Third level name Ta Sy Type Ta Sy Changeable
1.40      jruoho   1266: .It kern.veriexec.algorithms   string  no
                   1267: .It kern.veriexec.count        node    not applicable
                   1268: .It kern.veriexec.strict       integer yes
                   1269: .It kern.veriexec.verbose      integer yes
                   1270: .El
1.1       pavel    1271: .Bl -tag -width "123456"
                   1272: .It Li kern.veriexec.algorithms
                   1273: Returns a string with the supported algorithms in Veriexec.
                   1274: .It Li kern.veriexec.count
                   1275: Sub-nodes are added to this node as new mounts are monitored by Veriexec.
                   1276: Each mount will be under its own
                   1277: .No tableN
                   1278: node.
                   1279: Under each node there will be three variables, indicating the mount
1.57      wiz      1280: point, the file system type, and the number of entries.
1.1       pavel    1281: .It Li kern.veriexec.strict
                   1282: Controls the strict level of Veriexec.
                   1283: See
1.62      jruoho   1284: .Xr security 7
1.1       pavel    1285: for more information on each level's implications.
                   1286: .It Li kern.veriexec.verbose
                   1287: Controls the verbosity level of Veriexec.
                   1288: If 0, only the minimal
                   1289: indication required will be given about what's happening - fingerprint
                   1290: mismatches, removal of entries from the tables, modification of a
                   1291: fingerprinted file.
                   1292: If 1, more messages will be printed (ie., when a file with a valid
                   1293: fingerprint is accessed).
                   1294: Verbose level 2 is debug mode.
                   1295: .El
1.91      kamil    1296: .It Li kern.version ( Dv KERN_VERSION )
1.1       pavel    1297: The system version string.
1.91      kamil    1298: .It Li kern.vnode ( Dv KERN_VNODE )
1.1       pavel    1299: Return the entire vnode table.
                   1300: Note, the vnode table is not necessarily a consistent snapshot of
                   1301: the system.
                   1302: The returned data consists of an array whose size depends on the
                   1303: current number of such objects in the system.
                   1304: Each element of the array contains the kernel address of a vnode
1.56      uwe      1305: .Vt struct vnode *
1.1       pavel    1306: followed by the vnode itself
1.56      uwe      1307: .Vt struct vnode .
1.43      jruoho   1308: .\" XXX: Undocumented: kern.lwp: no children?
1.1       pavel    1309: .El
1.50      jruoho   1310: .Ss The machdep.* subtree
1.1       pavel    1311: The set of variables defined is architecture dependent.
                   1312: Most architectures define at least the following variables.
1.43      jruoho   1313: .Bl -column "machdep.booted_kernel" "Type" "Changeable" -offset indent
1.107     wiz      1314: .It Sy Second level name Ta Sy Type Ta Sy Changeable
1.43      jruoho   1315: .It Li machdep.booted_kernel   string  no
1.1       pavel    1316: .El
1.43      jruoho   1317: .\" XXX: Document the above.
1.50      jruoho   1318: .Ss The net.* subtree
1.1       pavel    1319: The string and integer information available for the
                   1320: .Li net
                   1321: level is detailed below.
                   1322: The changeable column shows whether a process with appropriate
                   1323: privilege may change the value.
                   1324: The second and third levels are typically the protocol family and
                   1325: protocol number, though this is not always the case.
1.21      joerg    1326: .Bl -column "Second level name" "IPsec key management values" "Changeable" -offset indent
1.107     wiz      1327: .It Sy Second level name Ta Sy Type Ta Sy Changeable
1.1       pavel    1328: .It net.route  routing messages        no
                   1329: .It net.inet   IPv4 values     yes
                   1330: .It net.inet6  IPv6 values     yes
                   1331: .It net.key    IPsec key management values     yes
                   1332: .El
                   1333: .Bl -tag -width "123456"
1.91      kamil    1334: .It Li net.route ( Dv PF_ROUTE )
1.1       pavel    1335: .\" XXX really?
                   1336: Return the entire routing table or a subset of it.
                   1337: The data is returned as a sequence of routing messages (see
                   1338: .Xr route 4
                   1339: for the header file, format and meaning).
                   1340: The length of each message is contained in the message header.
                   1341: .Pp
1.56      uwe      1342: The third level name is a protocol number, which is currently always\ 0.
1.1       pavel    1343: The fourth level name is an address family, which may be set to 0 to
                   1344: select all address families.
                   1345: The fifth and sixth level names are as follows:
1.21      joerg    1346: .Bl -column "Fifth level name" "Sixth level is:" -offset indent
1.111     pgoyette 1347: .It Sy Fifth level name Ta Sy Sixth level is :
1.21      joerg    1348: .It NET_RT_FLAGS       rtflags
                   1349: .It NET_RT_DUMP        None
                   1350: .It NET_RT_IFLIST      None
1.1       pavel    1351: .El
1.91      kamil    1352: .It Li net.inet ( Dv PF_INET )
1.1       pavel    1353: Get or set various global information about the IPv4
                   1354: .Pq Internet Protocol version 4 .
                   1355: The third level name is the protocol.
                   1356: The fourth level name is the variable name.
                   1357: The currently defined protocols and names are:
1.92      wiz      1358: .Bl -column "Protocol" "anonportalgo.available" "integer" "Changeable" -offset indent
1.107     wiz      1359: .It Sy Protocol        Variable Ta Sy Type Ta Sy Changeable
1.1       pavel    1360: .It arp        down    integer yes
                   1361: .It arp        keep    integer yes
1.65      christos 1362: .It arp        log_movements   integer yes
                   1363: .It arp        log_permanent_modify    integer yes
1.86      christos 1364: .It arp        log_unknown_network     integer yes
1.65      christos 1365: .It arp        log_wrong_iface integer yes
1.1       pavel    1366: .It carp       allow   integer yes
                   1367: .It carp       preempt integer yes
                   1368: .It carp       log     integer yes
                   1369: .It carp       arpbalance      integer yes
                   1370: .It icmp       errppslimit     integer yes
                   1371: .It icmp       maskrepl        integer yes
                   1372: .It icmp       rediraccept     integer yes
                   1373: .It icmp       redirtimeout    integer yes
1.28      christos 1374: .It icmp       bmcastecho      integer yes
1.1       pavel    1375: .It ip allowsrcrt      integer yes
1.72      christos 1376: .It ip         anonportalgo.selected   string  yes
                   1377: .It ip         anonportalgo.available  string  yes
1.74      christos 1378: .It ip         anonportalgo.reserve    struct  yes
1.1       pavel    1379: .It ip anonportmax     integer yes
                   1380: .It ip anonportmin     integer yes
                   1381: .It ip checkinterface  integer yes
1.103     roy      1382: .It ip dad_count       integer yes
1.1       pavel    1383: .It ip directed-broadcast      integer yes
                   1384: .It ip do_loopback_cksum       integer yes
                   1385: .It ip forwarding      integer yes
                   1386: .It ip forwsrcrt       integer yes
                   1387: .It ip gifttl  integer yes
                   1388: .It ip grettl  integer yes
1.8       liamjfoy 1389: .It ip hashsize        integer yes
1.1       pavel    1390: .It ip hostzerobroadcast       integer yes
                   1391: .It ip lowportmin      integer yes
                   1392: .It ip lowportmax      integer yes
                   1393: .It ip maxflows        integer yes
                   1394: .It ip maxfragpackets  integer yes
                   1395: .It ip mtudisc integer yes
                   1396: .It ip mtudisctimeout  integer yes
                   1397: .It ip random_id       integer yes
                   1398: .It ip redirect        integer yes
                   1399: .It ip subnetsarelocal integer yes
                   1400: .It ip ttl     integer yes
                   1401: .It tcp        rfc1323 integer yes
                   1402: .It tcp        sendspace       integer yes
                   1403: .It tcp        recvspace       integer yes
                   1404: .It tcp        mssdflt integer yes
                   1405: .It tcp        syn_cache_limit integer yes
                   1406: .It tcp        syn_bucket_limit        integer yes
                   1407: .It tcp        syn_cache_interval      integer yes
                   1408: .It tcp        init_win        integer yes
                   1409: .It tcp        init_win_local  integer yes
                   1410: .It tcp        mss_ifmtu       integer yes
                   1411: .It tcp        win_scale       integer yes
                   1412: .It tcp        timestamps      integer yes
                   1413: .It tcp        cwm     integer yes
                   1414: .It tcp        cwm_burstsize   integer yes
                   1415: .It tcp        ack_on_push     integer yes
                   1416: .It tcp        keepidle        integer yes
                   1417: .It tcp        keepintvl       integer yes
                   1418: .It tcp        keepcnt integer yes
                   1419: .It tcp        slowhz  integer no
1.12      christos 1420: .It tcp        keepinit        integer yes
1.1       pavel    1421: .It tcp        log_refused     integer yes
                   1422: .It tcp        rstppslimit     integer yes
                   1423: .It tcp        ident   struct  no
1.13      christos 1424: .It tcp        drop    struct  no
1.1       pavel    1425: .It tcp        sack.enable     integer yes
                   1426: .It tcp        sack.globalholes        integer no
                   1427: .It tcp        sack.globalmaxholes     integer yes
                   1428: .It tcp        sack.maxholes   integer yes
                   1429: .It tcp        ecn.enable      integer yes
                   1430: .It tcp        ecn.maxretries  integer yes
                   1431: .It tcp        congctl.selected        string  yes
                   1432: .It tcp        congctl.available       string  yes
                   1433: .It tcp        abc.enable      integer yes
                   1434: .It tcp        abc.aggressive  integer yes
                   1435: .It udp        checksum        integer yes
                   1436: .It udp        do_loopback_cksum       integer yes
                   1437: .It udp        recvspace       integer yes
                   1438: .It udp        sendspace       integer yes
                   1439: .El
                   1440: .Pp
                   1441: The variables are as follows:
                   1442: .Bl -tag -width "123456"
                   1443: .It Li arp.down
                   1444: Failed ARP entry lifetime.
                   1445: .It Li arp.keep
                   1446: Valid ARP entry lifetime.
                   1447: .It Li carp.allow
                   1448: If set to 0, incoming
                   1449: .Xr carp 4
                   1450: packets will not be processed.
                   1451: If set to any other value, processing will occur.
                   1452: Enabled by default.
                   1453: .It Li carp.arpbalance
                   1454: If set to any value other than 0, the ARP balancing functionality of
                   1455: .Xr carp 4
                   1456: is enabled.
                   1457: When ARP requests are received for an IP address which is part of any virtual
                   1458: host, carp will hash the source IP in the ARP request to select one of the
                   1459: virtual hosts from the set of all the virtual hosts which have that IP address.
                   1460: The master of that host will respond with the correct virtual MAC address.
                   1461: Disabled by default.
                   1462: .It Li carp.log
                   1463: If set to any value other than 0,
                   1464: .Xr carp 4
                   1465: will log errors.
                   1466: Disabled by default.
                   1467: .It Li carp.preempt
                   1468: If set to 0,
                   1469: .Xr carp 4
                   1470: will not attempt to become master if it is receiving advertisements from
                   1471: another active master.
                   1472: If set to any other value, carp will become master of the virtual host if it
                   1473: believes it can send advertisements more frequently than the current master.
                   1474: Disabled by default.
                   1475: .It Li ip.allowsrcrt
                   1476: If set to 1, the host accepts source routed packets.
1.72      christos 1477: .It Li ip.anonportalgo.available
                   1478: The available RFC 6056 port randomization algorithms.
1.74      christos 1479: .It Li ip.anonportalgo.reserve
                   1480: A bitmask of ports that will not be used during anonymous or privileged
                   1481: port selection.
1.72      christos 1482: .It Li ip.anonportalgo.selected
                   1483: The currently selected RFC 6056 port randomization algorithm.
1.1       pavel    1484: .It Li ip.anonportmax
                   1485: The highest port number to use for TCP and UDP ephemeral port allocation.
                   1486: This cannot be set to less than 1024 or greater than 65535, and must
                   1487: be greater than
                   1488: .Li ip.anonportmin .
                   1489: .It Li ip.anonportmin
                   1490: The lowest port number to use for TCP and UDP ephemeral port allocation.
                   1491: This cannot be set to less than 1024 or greater than 65535.
                   1492: .It Li ip.checkinterface
                   1493: If set to non-zero, the host will reject packets addressed to it
                   1494: that arrive on an interface not bound to that address.
                   1495: Currently, this must be disabled if ipnat is used to translate the
                   1496: destination address to another local interface, or if addresses
                   1497: are added to the loopback interface instead of the interface where
                   1498: the packets for those packets are received.
1.103     roy      1499: .It Li ip.dad_count
                   1500: The number of
                   1501: .Xr arp 4
                   1502: probes sent for Address Conflict Detection.
                   1503: Set to 0 to disable this.
1.1       pavel    1504: .It Li ip.directed-broadcast
                   1505: If set to 1, enables directed broadcast behavior for the host.
                   1506: .It Li ip.do_loopback_cksum
                   1507: Perform IP checksum on loopback.
                   1508: .It Li ip.forwarding
                   1509: If set to 1, enables IP forwarding for the host,
                   1510: meaning that the host is acting as a router.
                   1511: .It Li ip.forwsrcrt
                   1512: If set to 1, enables forwarding of source-routed packets for the host.
                   1513: This value may only be changed if the kernel security level is less than 1.
                   1514: .It Li ip.gifttl
                   1515: The maximum time-to-live (hop count) value for an IPv4 packet generated by
                   1516: .Xr gif 4
                   1517: tunnel interface.
                   1518: .It Li ip.grettl
                   1519: The maximum time-to-live (hop count) value for an IPv4 packet generated by
                   1520: .Xr gre 4
                   1521: tunnel interface.
1.8       liamjfoy 1522: .It Li ip.hashsize
                   1523: The size of IPv4 Fast Forward hash table.
                   1524: This value must be a power of 2 (64, 256...).
                   1525: A larger hash table size results in fewer collisions.
                   1526: Also see
                   1527: .Li ip.maxflows .
1.1       pavel    1528: .It Li ip.hostzerobroadcast
                   1529: All zeroes address is broadcast address.
                   1530: .It Li ip.lowportmax
                   1531: The highest port number to use for TCP and UDP reserved port allocation.
                   1532: This cannot be set to less than 0 or greater than 1024, and must
                   1533: be greater than
                   1534: .Li ip.lowportmin .
                   1535: .It Li ip.lowportmin
                   1536: The lowest port number to use for TCP and UDP reserved port allocation.
                   1537: This cannot be set to less than 0 or greater than 1024, and must
                   1538: be smaller than
                   1539: .Li ip.lowportmax .
                   1540: .It Li ip.maxflows
1.5       liamjfoy 1541: IPv4 Fast Forwarding is enabled by default.
                   1542: If set to 0, IPv4 Fast Forwarding is disabled.
1.1       pavel    1543: .Li ip.maxflows
                   1544: controls the maximum amount of flows which can be created.
                   1545: The default value is 256.
                   1546: .It Li ip.maxfragpackets
                   1547: The maximum number of fragmented packets the node will accept.
                   1548: 0 means that the node will not accept any fragmented packets.
                   1549: \-1 means that the node will accept as many fragmented packets as it receives.
                   1550: The flag is provided basically for avoiding possible DoS attacks.
                   1551: .It Li ip.mtudisc
                   1552: If set to 1, enables Path MTU Discovery (RFC 1191).
                   1553: When Path MTU Discovery is enabled, the transmitted TCP segment
                   1554: size will be determined by the advertised maximum segment size
                   1555: (MSS) from the remote end, as constrained by the path MTU.
                   1556: If MTU Discovery is disabled, the transmitted segment size will
                   1557: never be greater than
                   1558: .Li tcp.mssdflt
                   1559: (the local maximum segment size).
                   1560: .It Li ip.mtudisctimeout
                   1561: The number of seconds in which a route added by the Path MTU
                   1562: Discovery engine will time out.
                   1563: When the route times out, the Path
                   1564: MTU Discovery engine will attempt to probe a larger path MTU.
                   1565: .It Li ip.random_id
                   1566: Assign random ip_id values.
                   1567: .It Li ip.redirect
                   1568: If set to 1, ICMP redirects may be sent by the host.
                   1569: This option is ignored unless the host is routing IP packets,
                   1570: and should normally be enabled on all systems.
                   1571: .It Li ip.subnetsarelocal
                   1572: If set to 1, subnets are to be considered local addresses.
                   1573: .It Li ip.ttl
                   1574: The maximum time-to-live (hop count) value for an IP packet sourced by
                   1575: the system.
                   1576: This value applies to normal transport protocols, not to ICMP.
                   1577: .It Li icmp.errppslimit
                   1578: The variable specifies the maximum number of outgoing ICMP error messages,
                   1579: per second.
                   1580: ICMP error messages that exceeded the value are subject to rate limitation
                   1581: and will not go out from the node.
                   1582: Negative value disables rate limitation.
                   1583: .It Li icmp.maskrepl
                   1584: If set to 1, ICMP network mask requests are to be answered.
                   1585: .It Li icmp.rediraccept
                   1586: If set to non-zero, the host will accept ICMP redirect packets.
                   1587: Note that routers will never accept ICMP redirect packets,
                   1588: and the variable is meaningful on IP hosts only.
                   1589: .It Li icmp.redirtimeout
                   1590: The variable specifies lifetime of routing entries generated by incoming
                   1591: ICMP redirect.
                   1592: This defaults to 600 seconds.
                   1593: .It Li icmp.returndatabytes
                   1594: Number of bytes to return in an ICMP error message.
1.28      christos 1595: .It Li icmp.bmcastecho
                   1596: If set to 1, enables responding to ICMP echo or timestamp request to the
                   1597: broadcast address.
1.1       pavel    1598: .It Li tcp.ack_on_push
                   1599: If set to 1, TCP is to immediately transmit an ACK upon reception of
                   1600: a packet with PUSH set.
                   1601: This can avoid losing a round trip time in some rare situations,
                   1602: but has the caveat of potentially defeating TCP's delayed ACK algorithm.
                   1603: Use of this option is generally not recommended, but
                   1604: the variable exists in case your configuration really needs it.
                   1605: .It Li tcp.cwm
                   1606: If set to 1, enables use of the Hughes/Touch/Heidemann Congestion Window
                   1607: Monitoring algorithm.
                   1608: This algorithm prevents line-rate bursts of packets that could
                   1609: otherwise occur when data begins flowing on an idle TCP connection.
                   1610: These line-rate bursts can contribute to network and router congestion.
                   1611: This can be particularly useful on World Wide Web servers
                   1612: which support HTTP/1.1, which has lingering connections.
                   1613: .It Li tcp.cwm_burstsize
                   1614: The Congestion Window Monitoring allowed burst size, in terms
                   1615: of packet count.
                   1616: .It Li tcp.delack_ticks
                   1617: Number of ticks to delay sending an ACK.
                   1618: .It Li tcp.do_loopback_cksum
                   1619: Perform TCP checksum on loopback.
                   1620: .It Li tcp.init_win
1.76      wiz      1621: A value indicating the TCP initial congestion window.
                   1622: The valid range
1.87      matt     1623: is 0 to 10 (maximum specified by RFC6928),
1.75      christos 1624: with a default of 4 (approximately 4K per RFC3390).
1.1       pavel    1625: .It Li tcp.init_win_local
                   1626: Like
                   1627: .Li tcp.init_win ,
                   1628: but used when communicating with hosts on a local network.
                   1629: .It Li tcp.keepcnt
                   1630: Number of keepalive probes sent before declaring a connection dead.
                   1631: If set to zero, there is no limit;
                   1632: keepalives will be sent until some kind of
                   1633: response is received from the peer.
                   1634: .It Li tcp.keepidle
                   1635: Time a connection must be idle before keepalives are sent (if keepalives
                   1636: are enabled for the connection).
                   1637: See also tcp.slowhz.
                   1638: .It Li tcp.keepintvl
                   1639: Time after a keepalive probe is sent until, in the absence of any response,
                   1640: another probe is sent.
                   1641: See also tcp.slowhz.
                   1642: .It Li tcp.log_refused
                   1643: If set to 1, refused TCP connections to the host will be logged.
1.12      christos 1644: .It Li tcp.keepinit
                   1645: Timeout in seconds during connection establishment.
1.1       pavel    1646: .It Li tcp.mss_ifmtu
                   1647: If set to 1, TCP calculates the outgoing maximum segment size based on
                   1648: the MTU of the appropriate interface.
                   1649: If set to 0, it is calculated based on the greater of the MTU of the
                   1650: interface, and the largest (non-loopback) interface MTU on the system.
                   1651: .It Li tcp.mssdflt
                   1652: The default maximum segment size both advertised to the peer
                   1653: and to use when either the peer does not advertise a maximum segment size to
                   1654: us during connection setup or Path MTU Discovery
                   1655: .Li ( ip.mtudisc )
                   1656: is disabled.
                   1657: Do not change this value unless you really know what you are doing.
                   1658: .It Li tcp.recvspace
                   1659: The default TCP receive buffer size.
                   1660: .It Li tcp.rfc1323
                   1661: If set to 1, enables RFC 1323 extensions to TCP.
                   1662: .It Li tcp.rstppslimit
                   1663: The variable specifies the maximum number of outgoing TCP RST packets,
                   1664: per second.
                   1665: TCP RST packet that exceeded the value are subject to rate limitation
                   1666: and will not go out from the node.
                   1667: Negative value disables rate limitation.
1.13      christos 1668: .It Li tcp.ident
                   1669: Return the user ID of a connected socket pair.
                   1670: (RFC1413 Identification Protocol lookups.)
                   1671: .It Li tcp.drop
                   1672: Drop a TCP socket pair connection.
1.1       pavel    1673: .It Li tcp.sack.enable
                   1674: If set to 1, enables RFC 2018 Selective ACKnowledgement.
                   1675: .It Li tcp.sack.globalholes
                   1676: Global number of TCP SACK holes.
                   1677: .It Li tcp.sack.globalmaxholes
                   1678: Global maximum number of TCP SACK holes.
                   1679: .It Li tcp.sack.maxholes
                   1680: Maximum number of TCP SACK holes allowed per connection.
                   1681: .It Li tcp.ecn.enable
                   1682: If set to 1, enables RFC 3168 Explicit Congestion Notification.
                   1683: .It Li tcp.ecn.maxretries
                   1684: Number of times to retry sending the ECN-setup packet.
                   1685: .It Li tcp.sendspace
                   1686: The default TCP send buffer size.
                   1687: .It Li tcp.slowhz
                   1688: The units for tcp.keepidle and tcp.keepintvl; those variables are in ticks
                   1689: of a clock that ticks tcp.slowhz times per second.
                   1690: (That is, their values
                   1691: must be divided by the tcp.slowhz value to get times in seconds.)
                   1692: .It Li tcp.syn_bucket_limit
                   1693: The maximum number of entries allowed per hash bucket in the TCP
                   1694: compressed state engine.
                   1695: .It Li tcp.syn_cache_limit
                   1696: The maximum number of entries allowed in the TCP compressed state
                   1697: engine.
                   1698: .It Li tcp.timestamps
                   1699: If rfc1323 is enabled, a value of 1 indicates RFC 1323 time stamp options,
                   1700: used for measuring TCP round trip times, are enabled.
                   1701: .It Li tcp.win_scale
                   1702: If rfc1323 is enabled, a value of 1 indicates RFC 1323 window scale options,
                   1703: for increasing the TCP window size, are enabled.
                   1704: .It Li tcp.congctl.available
                   1705: The available TCP congestion control algorithms.
                   1706: .It Li tcp.congctl.selected
                   1707: The currently selected TCP congestion control algorithm.
                   1708: .It Li tcp.abc.enable
                   1709: If set to 1, use RFC 3465 Appropriate Byte Counting (ABC).
                   1710: If set to 0, use traditional Packet Counting.
                   1711: .It Li tcp.abc.aggressive
                   1712: Choose the L parameter found in RFC 3465.
                   1713: L is the maximum cwnd increase for an ack during slow start.
                   1714: If set to 1, use L=2*SMSS.
                   1715: If set to 0, use L=1*SMSS.
                   1716: It has no effect unless tcp.abc.enable is set to 1.
                   1717: .It Li udp.checksum
                   1718: If set to 1, UDP checksums are being computed.
                   1719: Received non-zero UDP checksums are always checked.
                   1720: Disabling UDP checksums is strongly discouraged.
1.67      christos 1721: .It Li udp.recvspace
                   1722: The default UDP receive buffer size.
1.1       pavel    1723: .It Li udp.sendspace
                   1724: The default UDP send buffer size.
                   1725: .El
                   1726: .Pp
                   1727: For variables net.*.ipsec, please refer to
                   1728: .Xr ipsec 4 .
1.91      kamil    1729: .It Li net.inet6 ( Dv PF_INET6 )
1.1       pavel    1730: Get or set various global information about the IPv6
                   1731: .Pq Internet Protocol version 6 .
                   1732: The third level name is the protocol.
                   1733: The fourth level name is the variable name.
                   1734: The currently defined protocols and names are:
1.92      wiz      1735: .Bl -column "Protocol" "anonportalgo.available" "integer" "Changeable" -offset indent
1.107     wiz      1736: .It Sy Protocol        Variable Ta Sy Type Ta Sy Changeable
1.1       pavel    1737: .It icmp6      errppslimit     integer yes
                   1738: .It icmp6      mtudisc_hiwat   integer yes
                   1739: .It icmp6      mtudisc_lowat   integer yes
                   1740: .It icmp6      nd6_debug       integer yes
                   1741: .It icmp6      nd6_delay       integer yes
                   1742: .It icmp6      nd6_maxnudhint  integer yes
                   1743: .It icmp6      nd6_mmaxtries   integer yes
                   1744: .It icmp6      nd6_prune       integer yes
                   1745: .It icmp6      nd6_umaxtries   integer yes
                   1746: .It icmp6      nd6_useloopback integer yes
                   1747: .It icmp6      nodeinfo        integer yes
                   1748: .It icmp6      rediraccept     integer yes
                   1749: .It icmp6      redirtimeout    integer yes
                   1750: .It ip6        accept_rtadv    integer yes
1.96      christos 1751: .It ip6        addctlpolicy    struct in6_addrpolicy   no
1.72      christos 1752: .It ip6        anonportalgo.selected   string  yes
                   1753: .It ip6        anonportalgo.available  string  yes
1.90      kamil    1754: .It ip6        anonportalgo.reserve    struct  yes
1.1       pavel    1755: .It ip6        anonportmax     integer yes
                   1756: .It ip6        anonportmin     integer yes
                   1757: .It ip6        auto_flowlabel  integer yes
                   1758: .It ip6        dad_count       integer yes
                   1759: .It ip6        defmcasthlim    integer yes
                   1760: .It ip6        forwarding      integer yes
                   1761: .It ip6        gifhlim integer yes
1.7       liamjfoy 1762: .It ip6        hashsize        integer yes
1.1       pavel    1763: .It ip6        hlim    integer yes
                   1764: .It ip6        hdrnestlimit    integer yes
                   1765: .It ip6        kame_version    string  no
                   1766: .It ip6        keepfaith       integer yes
                   1767: .It ip6        log_interval    integer yes
                   1768: .It ip6        lowportmax      integer yes
                   1769: .It ip6        lowportmin      integer yes
1.73      christos 1770: .It ip6        maxdynroutes    integer yes
                   1771: .It ip6        maxifprefixes   integer yes
                   1772: .It ip6        maxifdefrouters integer yes
1.5       liamjfoy 1773: .It ip6        maxflows        integer yes
1.1       pavel    1774: .It ip6        maxfragpackets  integer yes
                   1775: .It ip6        maxfrags        integer yes
1.73      christos 1776: .It ip6        neighborgcthresh        integer yes
1.1       pavel    1777: .It ip6        redirect        integer yes
                   1778: .It ip6        rr_prune        integer yes
                   1779: .It ip6        use_deprecated  integer yes
                   1780: .It ip6        v6only  integer yes
                   1781: .It udp6       do_loopback_cksum       integer yes
                   1782: .It udp6       recvspace       integer yes
                   1783: .It udp6       sendspace       integer yes
                   1784: .El
                   1785: .Pp
                   1786: The variables are as follows:
                   1787: .Bl -tag -width "123456"
                   1788: .It Li ip6.accept_rtadv
                   1789: If set to non-zero, the node will accept ICMPv6 router advertisement packets
                   1790: and autoconfigures address prefixes and default routers.
                   1791: The node must be a host
                   1792: .Pq not a router
                   1793: for the option to be meaningful.
1.72      christos 1794: .It Li ip6.anonportalgo.available
                   1795: The available RFC 6056 port randomization algorithms.
1.74      christos 1796: .It Li ip6.anonportalgo.reserve
                   1797: A bitmask of ports that will not be used during anonymous or privileged
                   1798: port selection.
1.72      christos 1799: .It Li ip6.anonportalgo.selected
                   1800: The currently selected RFC 6056 port randomization algorithm.
1.1       pavel    1801: .It Li ip6.anonportmax
                   1802: The highest port number to use for TCP and UDP ephemeral port allocation.
                   1803: This cannot be set to less than 1024 or greater than 65535, and must
                   1804: be greater than
                   1805: .Li ip6.anonportmin .
                   1806: .It Li ip6.anonportmin
                   1807: The lowest port number to use for TCP and UDP ephemeral port allocation.
                   1808: This cannot be set to less than 1024 or greater than 65535.
                   1809: .It Li ip6.auto_flowlabel
                   1810: On connected transport protocol packets,
                   1811: fill IPv6 flowlabel field to help intermediate routers to identify packet flows.
                   1812: .It Li ip6.dad_count
                   1813: The variable configures number of IPv6 DAD
                   1814: .Pq duplicated address detection
                   1815: probe packets.
                   1816: The packets will be generated when IPv6 interface addresses are configured.
                   1817: .It Li ip6.defmcasthlim
                   1818: The default hop limit value for an IPv6 multicast packet sourced by the node.
                   1819: This value applies to all the transport protocols on top of IPv6.
                   1820: There are APIs to override the value, as documented in
                   1821: .Xr ip6 4 .
                   1822: .It Li ip6.forwarding
                   1823: If set to 1, enables IPv6 forwarding for the node,
                   1824: meaning that the node is acting as a router.
                   1825: If set to 0, disables IPv6 forwarding for the node,
                   1826: meaning that the node is acting as a host.
                   1827: IPv6 specification defines node behavior for
                   1828: .Dq router
                   1829: case and
                   1830: .Dq host
                   1831: case quite differently, and changing this variable during operation
                   1832: may cause serious trouble.
                   1833: It is recommended to configure the variable at bootstrap time,
                   1834: and bootstrap time only.
                   1835: .It Li ip6.gifhlim
                   1836: The maximum hop limit value for an IPv6 packet generated by
                   1837: .Xr gif 4
                   1838: tunnel interface.
                   1839: .It Li ip6.hdrnestlimit
                   1840: The number of IPv6 extension headers permitted on incoming IPv6 packets.
                   1841: If set to 0, the node will accept as many extension headers as possible.
1.7       liamjfoy 1842: .It Li ip6.hashsize
                   1843: The size of IPv6 Fast Forward hash table.
1.56      uwe      1844: This value must be a power of 2 (64, 256, ...).
1.7       liamjfoy 1845: A larger hash table size results in fewer collisions.
                   1846: Also see
                   1847: .Li ip6.maxflows .
1.1       pavel    1848: .It Li ip6.hlim
                   1849: The default hop limit value for an IPv6 unicast packet sourced by the node.
                   1850: This value applies to all the transport protocols on top of IPv6.
                   1851: There are APIs to override the value, as documented in
                   1852: .Xr ip6 4 .
                   1853: .It Li ip6.kame_version
                   1854: The string identifies the version of KAME IPv6 stack implemented in the kernel.
                   1855: .It Li ip6.keepfaith
                   1856: If set to non-zero, it enables
                   1857: .Dq FAITH
                   1858: TCP relay IPv6-to-IPv4 translator code in the kernel.
                   1859: Refer
                   1860: .Xr faith 4
                   1861: and
                   1862: .Xr faithd 8
                   1863: for detail.
                   1864: .It Li ip6.log_interval
                   1865: The variable controls amount of logs generated by IPv6 packet
                   1866: forwarding engine, by setting interval between log output
                   1867: .Pq in seconds .
                   1868: .It Li ip6.lowportmax
                   1869: The highest port number to use for TCP and UDP reserved port allocation.
                   1870: This cannot be set to less than 0 or greater than 1024, and must
                   1871: be greater than
                   1872: .Li ip6.lowportmin .
                   1873: .It Li ip6.lowportmin
                   1874: The lowest port number to use for TCP and UDP reserved port allocation.
                   1875: This cannot be set to less than 0 or greater than 1024, and must
                   1876: be smaller than
                   1877: .Li ip6.lowportmax .
1.73      christos 1878: .It Li ip6.maxdynroutes
                   1879: Maximum number of routes created by redirect.
                   1880: Set it to negative to disable.
                   1881: The default value is 4096.
                   1882: .It Li ip6.maxifprefixes
                   1883: Maximum number of prefixes created by route advertisements per interface.
                   1884: Set it to negative to disable.
                   1885: The default value is 16.
                   1886: .It Li ip6.maxifdefrouters 16
                   1887: Maximum number of default routers created by route advertisements per interface.
                   1888: Set it to negative to disable.
                   1889: The default value is 16.
1.5       liamjfoy 1890: .It Li ip6.maxflows
                   1891: IPv6 Fast Forwarding is enabled by default.
                   1892: If set to 0, IPv6 Fast Forwarding is disabled.
                   1893: .Li ip6.maxflows
                   1894: controls the maximum amount of flows which can be created.
1.6       liamjfoy 1895: The default value is 256.
1.1       pavel    1896: .It Li ip6.maxfragpackets
                   1897: The maximum number of fragmented packets the node will accept.
                   1898: 0 means that the node will not accept any fragmented packets.
                   1899: \-1 means that the node will accept as many fragmented packets as it receives.
                   1900: The flag is provided basically for avoiding possible DoS attacks.
                   1901: .It Li ip6.maxfrags
                   1902: The maximum number of fragments the node will accept.
                   1903: 0 means that the node will not accept any fragments.
                   1904: \-1 means that the node will accept as many fragments as it receives.
                   1905: The flag is provided basically for avoiding possible DoS attacks.
1.73      christos 1906: .It Li ip6.neighborgcthresh
1.98      ozaki-r  1907: Maximum number of entries in neighbor cache per interface.
1.73      christos 1908: Set to negative to disable.
                   1909: The default value is 2048.
1.1       pavel    1910: .It Li ip6.redirect
                   1911: If set to 1, ICMPv6 redirects may be sent by the node.
                   1912: This option is ignored unless the node is routing IP packets,
                   1913: and should normally be enabled on all systems.
                   1914: .It Li ip6.rr_prune
                   1915: The variable specifies interval between IPv6 router renumbering prefix
                   1916: babysitting, in seconds.
                   1917: .It Li ip6.use_deprecated
                   1918: The variable controls use of deprecated address, specified in RFC 2462 5.5.4.
                   1919: .It Li ip6.v6only
                   1920: The variable specifies initial value for
                   1921: .Dv IPV6_V6ONLY
                   1922: socket option for
                   1923: .Dv AF_INET6
                   1924: socket.
                   1925: Please refer to
                   1926: .Xr ip6 4
                   1927: for detail.
                   1928: .It Li icmp6.errppslimit
                   1929: The variable specifies the maximum number of outgoing ICMPv6 error messages,
                   1930: per second.
                   1931: ICMPv6 error messages that exceeded the value are subject to rate limitation
                   1932: and will not go out from the node.
                   1933: Negative value disables rate limitation.
                   1934: .It Li icmp6.mtudisc_hiwat
                   1935: .It Li icmp6.mtudisc_lowat
                   1936: The variables define the maximum number of routing table entries,
                   1937: created due to path MTU discovery
                   1938: .Pq prevents denial-of-service attacks with ICMPv6 too big messages .
                   1939: When IPv6 path MTU discovery happens, we keep path MTU information into
                   1940: the routing table.
                   1941: If the number of routing table entries exceed the value,
                   1942: the kernel will not attempt to keep the path MTU information.
                   1943: .Li icmp6.mtudisc_hiwat
                   1944: is used when we have verified ICMPv6 too big messages.
                   1945: .Li icmp6.mtudisc_lowat
                   1946: is used when we have unverified ICMPv6 too big messages.
                   1947: Verification is performed by using address/port pairs kept in connected pcbs.
                   1948: Negative value disables the upper limit.
                   1949: .It Li icmp6.nd6_debug
                   1950: If set to non-zero, kernel IPv6 neighbor discovery code will generate
                   1951: debugging messages.
                   1952: The debug outputs are useful to diagnose IPv6 interoperability issues.
                   1953: The flag must be set to 0 for normal operation.
                   1954: .It Li icmp6.nd6_delay
                   1955: The variable specifies
                   1956: .Dv DELAY_FIRST_PROBE_TIME
                   1957: timing constant in IPv6 neighbor discovery specification
                   1958: .Pq RFC 2461 ,
                   1959: in seconds.
                   1960: .It Li icmp6.nd6_maxnudhint
                   1961: IPv6 neighbor discovery permits upper layer protocols to supply reachability
                   1962: hints, to avoid unnecessary neighbor discovery exchanges.
                   1963: The variable defines the number of consecutive hints the neighbor discovery
                   1964: layer will take.
                   1965: For example, by setting the variable to 3, neighbor discovery layer
                   1966: will take 3 consecutive hints in maximum.
                   1967: After receiving 3 hints, neighbor discovery layer will perform
                   1968: normal neighbor discovery process.
                   1969: .It Li icmp6.nd6_mmaxtries
                   1970: The variable specifies
                   1971: .Dv MAX_MULTICAST_SOLICIT
                   1972: constant in IPv6 neighbor discovery specification
                   1973: .Pq RFC 2461 .
                   1974: .It Li icmp6.nd6_prune
                   1975: The variable specifies interval between IPv6 neighbor cache babysitting,
                   1976: in seconds.
                   1977: .It Li icmp6.nd6_umaxtries
                   1978: The variable specifies
                   1979: .Dv MAX_UNICAST_SOLICIT
                   1980: constant in IPv6 neighbor discovery specification
                   1981: .Pq RFC 2461 .
                   1982: .It Li icmp6.nd6_useloopback
                   1983: If set to non-zero, kernel IPv6 stack will use loopback interface for
                   1984: local traffic.
                   1985: .It Li icmp6.nodeinfo
                   1986: The variable enables responses to ICMPv6 node information queries.
                   1987: If you set the variable to 0, responses will not be generated for
                   1988: ICMPv6 node information queries.
                   1989: Since node information queries can have a security impact, it is
                   1990: possible to fine tune which responses should be answered.
                   1991: Two separate bits can be set.
                   1992: .Bl -tag -width "12345"
                   1993: .It 1
                   1994: Respond to ICMPv6 FQDN queries, e.g.
                   1995: .Li ping6 -w .
                   1996: .It 2
                   1997: Respond to ICMPv6 node addresses queries, e.g.
                   1998: .Li ping6 -a .
                   1999: .El
                   2000: .It Li icmp6.rediraccept
                   2001: If set to non-zero, the host will accept ICMPv6 redirect packets.
                   2002: Note that IPv6 routers will never accept ICMPv6 redirect packets,
                   2003: and the variable is meaningful on IPv6 hosts
                   2004: .Pq non-router
                   2005: only.
                   2006: .It Li icmp6.redirtimeout
                   2007: The variable specifies lifetime of routing entries generated by incoming
                   2008: ICMPv6 redirect.
                   2009: .It Li udp6.do_loopback_cksum
                   2010: Perform UDP checksum on loopback.
                   2011: .It Li udp6.recvspace
                   2012: Default UDP receive buffer size.
                   2013: .It Li udp6.sendspace
                   2014: Default UDP send buffer size.
                   2015: .El
                   2016: .Pp
1.119     wiz      2017: We reuse net.*.tcp for TCP over IPv6,
1.1       pavel    2018: and therefore we do not have variables net.*.tcp6.
                   2019: Variables net.inet6.udp6 have identical meaning to net.inet.udp.
                   2020: Please refer to
                   2021: .Li PF_INET
                   2022: section above.
                   2023: For variables net.*.ipsec6, please refer to
                   2024: .Xr ipsec 4 .
1.91      kamil    2025: .It Li net.key ( Dv PF_KEY )
1.1       pavel    2026: Get or set various global information about the IPsec key management.
                   2027: The third level name is the variable name.
                   2028: The currently defined variable and names are:
1.21      joerg    2029: .Bl -column "blockacq_lifetime" "integer" "Changeable" -offset indent
1.107     wiz      2030: .It Sy Variable        Type Ta Sy Changeable
1.1       pavel    2031: .It debug      integer yes
1.80      christos 2032: .It enabled    integer yes
                   2033: .It used       integer no
1.1       pavel    2034: .It spi_try    integer yes
                   2035: .It spi_min_value      integer yes
                   2036: .It spi_max_value      integer yes
                   2037: .It larval_lifetime    integer yes
                   2038: .It blockacq_count     integer yes
                   2039: .It blockacq_lifetime  integer yes
                   2040: .It esp_keymin integer yes
                   2041: .It esp_auth   integer yes
                   2042: .It ah_keymin  integer yes
                   2043: .El
1.21      joerg    2044: .Pp
1.1       pavel    2045: The variables are as follows:
                   2046: .Bl -tag -width "123456"
                   2047: .It Li debug
                   2048: Turn on debugging message from within the kernel.
                   2049: The value is a bitmap, as defined in
1.56      uwe      2050: .In netkey/key_debug.h .
1.80      christos 2051: .It Li enabled
1.81      christos 2052: Control processing of IPsec control messages.
                   2053: .Bl -tag -width indent
                   2054: .It 0
                   2055: Never allow IPsec processing
                   2056: .It 1
                   2057: Allow IPsec processing when SPD policies are present.
                   2058: .It 2
                   2059: Force IPsec processing even when SPD policies are not present.
                   2060: .El
1.80      christos 2061: .It Li used
                   2062: Based on if IPsec is enabled, and SPD rule existance, show if
                   2063: IPsec is being used.
1.110     abhinav  2064: Note that currently once IPsec is being used, it cannot be disabled.
1.1       pavel    2065: .It Li spi_try
                   2066: The number of times the kernel will try to obtain an unique SPI
                   2067: when it generates it from random number generator.
                   2068: .It Li spi_min_value
                   2069: Minimum SPI value when generating it within the kernel.
                   2070: .It Li spi_max_value
                   2071: Maximum SPI value when generating it within the kernel.
                   2072: .It Li larval_lifetime
                   2073: Lifetime for LARVAL SAD entries, in seconds.
                   2074: .It Li blockacq_count
                   2075: Number of ACQUIRE PF_KEY messages to be blocked after an ACQUIRE message.
                   2076: It avoids flood of ACQUIRE PF_KEY from being sent from the kernel to the
                   2077: key management daemon.
                   2078: .It Li blockacq_lifetime
                   2079: Lifetime of ACQUIRE PF_KEY message.
                   2080: .It Li esp_keymin
                   2081: Minimum ESP key length, in bits.
                   2082: The value is used when the kernel creates proposal payload
                   2083: on ACQUIRE PF_KEY message.
                   2084: .It Li esp_auth
                   2085: Whether ESP authentication should be used or not.
                   2086: Non-zero value indicates that ESP authentication should be used.
                   2087: The value is used when the kernel creates proposal payload
                   2088: on ACQUIRE PF_KEY message.
                   2089: .It Li ah_keymin
                   2090: Minimum AH key length, in bits,
                   2091: The value is used when the kernel creates proposal payload
                   2092: on ACQUIRE PF_KEY message.
                   2093: .El
                   2094: .El
1.50      jruoho   2095: .Ss The proc.* subtree
1.1       pavel    2096: The string and integer information available for the
                   2097: .Li proc
                   2098: level is detailed below.
                   2099: The changeable column shows whether a process with appropriate
                   2100: privilege may change the value.
                   2101: These values are per-process,
                   2102: and as such may change from one process to another.
                   2103: When a process is created,
                   2104: the default values are inherited from its parent.
                   2105: When a set-user-ID or set-group-ID binary is executed, the
                   2106: value of PROC_PID_CORENAME is reset to the system default value.
                   2107: The second level name is either the magic value PROC_CURPROC, which
                   2108: points to the current process, or the PID of the target process.
1.21      joerg    2109: .Bl -column "proc.pid.corename" "string" "not applicable" -offset indent
1.107     wiz      2110: .It Sy Third level name Ta Sy Type Ta Sy Changeable
1.1       pavel    2111: .It proc.pid.corename  string  yes
                   2112: .It proc.pid.rlimit    node    not applicable
                   2113: .It proc.pid.stopfork  int     yes
                   2114: .It proc.pid.stopexec  int     yes
                   2115: .It proc.pid.stopexit  int     yes
1.111     pgoyette 2116: .It proc.pid.paxflags  int     no
1.1       pavel    2117: .El
                   2118: .Bl -tag -width "123456"
1.91      kamil    2119: .It Li proc.pid.corename ( Dv PROC_PID_CORENAME )
1.1       pavel    2120: The template used for the core dump file name (see
                   2121: .Xr core 5
                   2122: for details).
                   2123: The base name must either be
1.56      uwe      2124: .Pa core
                   2125: or end with the suffix
                   2126: .Pa .core
                   2127: (the super-user may set arbitrary names).
                   2128: By default it points to
                   2129: .Dv KERN_DEFCORENAME .
1.91      kamil    2130: .It Li proc.pid.rlimit ( Dv PROC_PID_LIMIT )
1.1       pavel    2131: Return resources limits, as defined for the
                   2132: .Xr getrlimit 2
                   2133: and
                   2134: .Xr setrlimit 2
                   2135: system calls.
                   2136: The fourth level name is one of:
1.56      uwe      2137: .Bl -tag -width "123456"
1.91      kamil    2138: .It Li proc.pid.rlimit.cputime ( Dv PROC_PID_LIMIT_CPU )
1.1       pavel    2139: The maximum amount of CPU time (in seconds) to be used by each process.
1.91      kamil    2140: .It Li proc.pid.rlimit.filesize ( Dv PROC_PID_LIMIT_FSIZE )
1.1       pavel    2141: The largest size (in bytes) file that may be created.
1.91      kamil    2142: .It Li proc.pid.rlimit.datasize ( Dv PROC_PID_LIMIT_DATA )
1.1       pavel    2143: The maximum size (in bytes) of the data segment for a process;
                   2144: this defines how far a program may extend its break with the
                   2145: .Xr sbrk 2
                   2146: system call.
1.91      kamil    2147: .It Li proc.pid.rlimit.stacksize ( Dv PROC_PID_LIMIT_STACK )
1.1       pavel    2148: The maximum size (in bytes) of the stack segment for a process;
                   2149: this defines how far a program's stack segment may be extended.
                   2150: Stack extension is performed automatically by the system.
1.91      kamil    2151: .It Li proc.pid.rlimit.coredumpsize ( Dv PROC_PID_LIMIT_CORE )
1.1       pavel    2152: The largest size (in bytes)
                   2153: .Pa core
                   2154: file that may be created.
1.91      kamil    2155: .It Li proc.pid.rlimit.memoryuse ( Dv PROC_PID_LIMIT_RSS )
1.1       pavel    2156: The maximum size (in bytes) to which a process's resident set size may
                   2157: grow.
                   2158: This imposes a limit on the amount of physical memory to be given to
                   2159: a process; if memory is tight, the system will prefer to take memory
                   2160: from processes that are exceeding their declared resident set size.
1.91      kamil    2161: .It Li proc.pid.rlimit.memorylocked ( Dv PROC_PID_LIMIT_MEMLOCK )
1.1       pavel    2162: The maximum size (in bytes) which a process may lock into memory
                   2163: using the
                   2164: .Xr mlock 2
                   2165: function.
1.91      kamil    2166: .It Li proc.pid.rlimit.maxproc ( Dv PROC_PID_LIMIT_NPROC )
1.1       pavel    2167: The maximum number of simultaneous processes for this user id.
1.91      kamil    2168: .It Li proc.pid.rlimit.descriptors ( Dv PROC_PID_LIMIT_NOFILE )
1.1       pavel    2169: The maximum number of open files for this process.
1.91      kamil    2170: .It Li proc.pid.rlimit.sbsize ( Dv PROC_PID_LIMIT_SBSIZE )
1.22      snj      2171: The maximum size (in bytes) of the socket buffers
                   2172: set by the
                   2173: .Xr setsockopt 2
                   2174: .Dv SO_RCVBUF
                   2175: and
                   2176: .Dv SO_SNDBUF
                   2177: options.
1.91      kamil    2178: .It Li proc.pid.rlimit.vmemoryuse ( Dv PROC_PID_LIMIT_AS )
1.88      kamil    2179: The maximum size (in bytes) which a process can obtain.
1.91      kamil    2180: .It Li proc.pid.rlimit.maxlwp ( Dv PROC_PID_LIMIT_NTHR )
1.88      kamil    2181: The maximum number of threads that cen be created and running at one time in
                   2182: the process.
                   2183: The first thread of each process is not counted against this.
1.1       pavel    2184: .El
                   2185: .Pp
                   2186: The fifth level name is one of
1.91      kamil    2187: .Li soft ( Dv PROC_PID_LIMIT_TYPE_SOFT )
1.56      uwe      2188: or
1.91      kamil    2189: .Li hard ( Dv PROC_PID_LIMIT_TYPE_HARD ) ,
1.1       pavel    2190: to select respectively the soft or hard limit.
                   2191: Both are of type integer.
1.91      kamil    2192: .It Li proc.pid.stopfork ( Dv PROC_PID_STOPFORK )
1.1       pavel    2193: If non zero, the process' children will be stopped after
                   2194: .Xr fork 2
                   2195: calls.
1.112     pgoyette 2196: The children are created in the SSTOP state and are never scheduled
1.1       pavel    2197: for running before being stopped.
1.113     pgoyette 2198: This feature enables attaching to a process with a debugger such as
1.1       pavel    2199: .Xr gdb 1
1.113     pgoyette 2200: before the process has the opportunity to actually do anything.
1.1       pavel    2201: .Pp
                   2202: This value is inherited by the process's children, and it also
1.112     pgoyette 2203: applies to emulation specific system calls that fork a new process, such as
1.1       pavel    2204: .Fn sproc
                   2205: or
                   2206: .Fn clone .
1.91      kamil    2207: .It Li proc.pid.stopexec ( Dv PROC_PID_STOPEXEC )
1.112     pgoyette 2208: If non zero, the process will be stopped on the next
1.1       pavel    2209: .Xr exec 3
                   2210: call.
                   2211: The process created by
                   2212: .Xr exec 3
                   2213: is created in the SSTOP state and is never scheduled for running
                   2214: before being stopped.
1.112     pgoyette 2215: This feature enables attaching to a process with a debugger such as
1.1       pavel    2216: .Xr gdb 1
1.113     pgoyette 2217: before the process has the opportunity to actually do anything.
1.1       pavel    2218: .Pp
                   2219: This value is inherited by the process's children.
1.91      kamil    2220: .It Li proc.pid.stopexit ( Dv PROC_PID_STOPEXIT )
1.112     pgoyette 2221: If non zero, the process will be stopped when it has cause to exit,
1.1       pavel    2222: either by way of calling
                   2223: .Xr exit 3 ,
                   2224: .Xr _exit 2 ,
                   2225: or by the receipt of a specific signal.
                   2226: The process is stopped before any of its resources or vm space is
1.112     pgoyette 2227: released allowing examination of the termination state of the process
1.1       pavel    2228: before it disappears.
                   2229: This feature can be used to examine the final conditions of the
                   2230: process's vmspace via
                   2231: .Xr pmap 1
                   2232: or its resource settings with
                   2233: .Xr sysctl 8
                   2234: before it disappears.
                   2235: .Pp
                   2236: This value is also inherited by the process's children.
1.111     pgoyette 2237: .It Li proc.pid.paxflags ( Dv PROC_PID_PAXFLAGS )
                   2238: This read-only variable returns the current value of the process's pax
                   2239: flags (see
                   2240: .Xr paxctl 8 ) .
1.1       pavel    2241: .El
1.91      kamil    2242: .Ss The user.* subtree ( Dv CTL_USER )
1.1       pavel    2243: The string and integer information available for the
                   2244: .Li user
                   2245: level is detailed below.
                   2246: The changeable column shows whether a process with appropriate
                   2247: privilege may change the value.
1.21      joerg    2248: .Bl -column "user.coll_weights_max" "integer" "Changeable" -offset indent
1.107     wiz      2249: .It Sy Second level name Ta Sy Type Ta Sy Changeable
1.1       pavel    2250: .It user.atexit_max    integer no
                   2251: .It user.bc_base_max   integer no
                   2252: .It user.bc_dim_max    integer no
                   2253: .It user.bc_scale_max  integer no
                   2254: .It user.bc_string_max integer no
                   2255: .It user.coll_weights_max      integer no
                   2256: .It user.cs_path       string  no
                   2257: .It user.expr_nest_max integer no
                   2258: .It user.line_max      integer no
                   2259: .It user.posix2_c_bind integer no
                   2260: .It user.posix2_c_dev  integer no
                   2261: .It user.posix2_char_term      integer no
                   2262: .It user.posix2_fort_dev       integer no
                   2263: .It user.posix2_fort_run       integer no
                   2264: .It user.posix2_localedef      integer no
                   2265: .It user.posix2_sw_dev integer no
                   2266: .It user.posix2_upe    integer no
                   2267: .It user.posix2_version        integer no
                   2268: .It user.re_dup_max    integer no
                   2269: .It user.stream_max    integer no
                   2270: .It user.stream_max    integer no
                   2271: .It user.tzname_max    integer no
                   2272: .El
                   2273: .Bl -tag -width "123456"
1.91      kamil    2274: .It Li user.atexit_max ( Dv USER_ATEXIT_MAX )
1.1       pavel    2275: The maximum number of functions that may be registered with
                   2276: .Xr atexit 3 .
1.91      kamil    2277: .It Li user.bc_base_max ( Dv USER_BC_BASE_MAX )
1.1       pavel    2278: The maximum ibase/obase values in the
                   2279: .Xr bc 1
                   2280: utility.
1.91      kamil    2281: .It Li user.bc_dim_max ( Dv USER_BC_DIM_MAX )
1.1       pavel    2282: The maximum array size in the
                   2283: .Xr bc 1
                   2284: utility.
1.91      kamil    2285: .It Li user.bc_scale_max ( Dv USER_BC_SCALE_MAX )
1.1       pavel    2286: The maximum scale value in the
                   2287: .Xr bc 1
                   2288: utility.
1.91      kamil    2289: .It Li user.bc_string_max ( Dv USER_BC_STRING_MAX )
1.1       pavel    2290: The maximum string length in the
                   2291: .Xr bc 1
                   2292: utility.
1.91      kamil    2293: .It Li user.coll_weights_max ( Dv USER_COLL_WEIGHTS_MAX )
1.1       pavel    2294: The maximum number of weights that can be assigned to any entry of
                   2295: the LC_COLLATE order keyword in the locale definition file.
                   2296: .It Li user.cs_path ( USER_CS_PATH )
                   2297: Return a value for the
                   2298: .Ev PATH
                   2299: environment variable that finds all the standard utilities.
1.91      kamil    2300: .It Li user.expr_nest_max ( Dv USER_EXPR_NEST_MAX )
1.1       pavel    2301: The maximum number of expressions that can be nested within
                   2302: parenthesis by the
                   2303: .Xr expr 1
                   2304: utility.
1.91      kamil    2305: .It Li user.line_max ( Dv USER_LINE_MAX )
1.1       pavel    2306: The maximum length in bytes of a text-processing utility's input
                   2307: line.
1.91      kamil    2308: .It Li user.posix2_char_term ( Dv USER_POSIX2_CHAR_TERM )
1.1       pavel    2309: Return 1 if the system supports at least one terminal type capable of
1.58      wiz      2310: all operations described in
                   2311: .St -p1003.2 ,
                   2312: otherwise\ 0.
1.91      kamil    2313: .It Li user.posix2_c_bind ( Dv USER_POSIX2_C_BIND )
1.1       pavel    2314: Return 1 if the system's C-language development facilities support the
1.56      uwe      2315: C-Language Bindings Option, otherwise\ 0.
1.91      kamil    2316: .It Li user.posix2_c_dev ( Dv USER_POSIX2_C_DEV )
1.1       pavel    2317: Return 1 if the system supports the C-Language Development Utilities Option,
1.56      uwe      2318: otherwise\ 0.
1.91      kamil    2319: .It Li user.posix2_fort_dev ( Dv USER_POSIX2_FORT_DEV )
1.1       pavel    2320: Return 1 if the system supports the FORTRAN Development Utilities Option,
1.56      uwe      2321: otherwise\ 0.
1.91      kamil    2322: .It Li user.posix2_fort_run ( Dv USER_POSIX2_FORT_RUN )
1.1       pavel    2323: Return 1 if the system supports the FORTRAN Runtime Utilities Option,
1.56      uwe      2324: otherwise\ 0.
1.91      kamil    2325: .It Li user.posix2_localedef ( Dv USER_POSIX2_LOCALEDEF )
1.56      uwe      2326: Return 1 if the system supports the creation of locales, otherwise\ 0.
1.91      kamil    2327: .It Li user.posix2_sw_dev ( Dv USER_POSIX2_SW_DEV )
1.1       pavel    2328: Return 1 if the system supports the Software Development Utilities Option,
1.56      uwe      2329: otherwise\ 0.
1.91      kamil    2330: .It Li user.posix2_upe ( Dv USER_POSIX2_UPE )
1.1       pavel    2331: Return 1 if the system supports the User Portability Utilities Option,
1.56      uwe      2332: otherwise\ 0.
1.91      kamil    2333: .It Li user.posix2_version ( Dv USER_POSIX2_VERSION )
1.58      wiz      2334: The version of
                   2335: .St -p1003.2
                   2336: with which the system attempts to comply.
1.91      kamil    2337: .It Li user.re_dup_max ( Dv USER_RE_DUP_MAX )
1.1       pavel    2338: The maximum number of repeated occurrences of a regular expression
                   2339: permitted when using interval notation.
1.91      kamil    2340: .It Li user.stream_max ( Dv USER_STREAM_MAX )
1.1       pavel    2341: The minimum maximum number of streams that a process may have open
                   2342: at any one time.
1.91      kamil    2343: .It Li user.tzname_max ( Dv USER_TZNAME_MAX )
1.1       pavel    2344: The minimum maximum number of types supported for the name of a
                   2345: timezone.
                   2346: .El
1.91      kamil    2347: .Ss The vm.* subtree ( Dv CTL_VM )
1.1       pavel    2348: The string and integer information available for the
                   2349: .Li vm
                   2350: level is detailed below.
                   2351: The changeable column shows whether a process with appropriate
                   2352: privilege may change the value.
1.21      joerg    2353: .Bl -column "Second level name" "struct uvmexp_sysctl" "Changeable" -offset indent
1.107     wiz      2354: .It Sy Second level name Ta Sy Type Ta Sy Changeable
1.1       pavel    2355: .It vm.anonmax int     yes
                   2356: .It vm.anonmin int     yes
                   2357: .It vm.bufcache        int     yes
                   2358: .It vm.bufmem  int     no
                   2359: .It vm.bufmem_hiwater  int     yes
                   2360: .It vm.bufmem_lowater  int     yes
                   2361: .It vm.execmax int     yes
                   2362: .It vm.execmin int     yes
                   2363: .It vm.filemax int     yes
                   2364: .It vm.filemin int     yes
                   2365: .It vm.loadavg struct loadavg  no
                   2366: .It vm.maxslp  int     no
                   2367: .It vm.nkmempages      int     no
                   2368: .It vm.uspace  int     no
                   2369: .It vm.uvmexp  struct uvmexp   no
                   2370: .It vm.uvmexp2 struct uvmexp_sysctl    no
                   2371: .It vm.vmmeter struct vmtotal  no
1.93      christos 2372: .It vm.proc.map        struct kinfo_vmentry    no
1.115     joerg    2373: .It vm.guard_size      unsigned int    no
                   2374: .It vm.thread_guard_size       unsigned int    yes
1.1       pavel    2375: .El
                   2376: .Bl -tag -width "123456"
1.91      kamil    2377: .It Li vm.anonmax ( Dv VM_ANONMAX )
1.1       pavel    2378: The percentage of physical memory which will be reclaimed
                   2379: from other types of memory usage to store anonymous application data.
1.91      kamil    2380: .It Li vm.anonmin ( Dv VM_ANONMIN )
1.1       pavel    2381: The percentage of physical memory which will be always be available for
                   2382: anonymous application data.
1.91      kamil    2383: .It Li vm.bufcache ( Dv VM_BUFCACHE )
1.1       pavel    2384: The percentage of physical memory which will be available
                   2385: for the buffer cache.
1.91      kamil    2386: .It Li vm.bufmem ( Dv VM_BUFMEM )
1.1       pavel    2387: The amount of kernel memory that is being used by the buffer cache.
1.91      kamil    2388: .It Li vm.bufmem_lowater ( Dv VM_BUFMEM_LOWATER )
1.1       pavel    2389: The minimum amount of kernel memory to reserve for the
                   2390: buffer cache.
1.91      kamil    2391: .It Li vm.bufmem_hiwater ( Dv VM_BUFMEM_HIWATER )
1.1       pavel    2392: The maximum amount of kernel memory to be used for the
                   2393: buffer cache.
1.91      kamil    2394: .It Li vm.execmax ( Dv VM_EXECMAX )
1.1       pavel    2395: The percentage of physical memory which will be reclaimed
                   2396: from other types of memory usage to store cached executable data.
1.91      kamil    2397: .It Li vm.execmin ( Dv VM_EXECMIN )
1.1       pavel    2398: The percentage of physical memory which will be always be available for
                   2399: cached executable data.
1.91      kamil    2400: .It Li vm.filemax ( Dv VM_FILEMAX )
1.1       pavel    2401: The percentage of physical memory which will be reclaimed
                   2402: from other types of memory usage to store cached file data.
1.91      kamil    2403: .It Li vm.filemin ( Dv VM_FILEMIN )
1.1       pavel    2404: The percentage of physical memory which will be always be available for
                   2405: cached file data.
1.91      kamil    2406: .It Li vm.loadavg ( Dv VM_LOADAVG )
1.1       pavel    2407: Return the load average history.
                   2408: The returned data consists of a
1.56      uwe      2409: .Vt struct loadavg .
1.91      kamil    2410: .It Li vm.maxslp ( Dv VM_MAXSLP )
1.1       pavel    2411: The value of the maxslp kernel global variable.
1.91      kamil    2412: .It Li vm.vmmeter ( Dv VM_METER )
1.1       pavel    2413: Return system wide virtual memory statistics.
                   2414: The returned data consists of a
1.56      uwe      2415: .Vt struct vmtotal .
1.31      drochner 2416: .It vm.user_va0_disable
1.56      uwe      2417: A flag which controls whether user processes can map virtual address\ 0.
1.93      christos 2418: .It Li vm.proc.map ( Dv VM_PROC )
1.94      wiz      2419: The third level is
1.116     wiz      2420: .Dv VM_PROC_MAP ,
1.93      christos 2421: the fourth is the pid of the process to display the vm object entries for, and
                   2422: the fifth is the size of
                   2423: .Vt struct kinfo_vmentry .
                   2424: Returns an array of
                   2425: .Vt struct kinfo_vmentry
                   2426: objects.
1.91      kamil    2427: .It Li vm.uspace ( Dv VM_USPACE )
1.1       pavel    2428: The number of bytes allocated for each kernel stack.
1.91      kamil    2429: .It Li vm.uvmexp ( Dv VM_UVMEXP )
1.1       pavel    2430: Return system wide virtual memory statistics.
                   2431: The returned data consists of a
1.56      uwe      2432: .Vt struct uvmexp .
1.91      kamil    2433: .It Li vm.uvmexp2 ( Dv VM_UVMEXP2 )
1.1       pavel    2434: Return system wide virtual memory statistics.
                   2435: The returned data consists of a
1.56      uwe      2436: .Vt struct uvmexp_sysctl .
1.115     joerg    2437: .It Li vm.guard_size
                   2438: Return system wide guard size for the main thread of a program.
                   2439: .It Li vm.thread_guard_size
                   2440: Return system wide default size for the guard area of all other threads
                   2441: of a program.
1.1       pavel    2442: .\" XXX vm.idlezero
                   2443: .El
1.91      kamil    2444: .Ss The ddb.* subtree ( Dv CTL_DDB )
1.34      jruoho   2445: The information available for the
1.1       pavel    2446: .Li ddb
                   2447: level is detailed below.
                   2448: The changeable column shows whether a process with appropriate
                   2449: privilege may change the value.
1.21      joerg    2450: .Bl -column "Second level name" "integer" "Changeable" -offset indent
1.107     wiz      2451: .It Sy Second level name Ta Sy Type Ta Sy Changeable
1.122     sevan    2452: .It ddb.commandonenter string  yes
1.123     sevan    2453: .It ddb.dumpstack      integer yes
1.122     sevan    2454: .It ddb.fromconsole    integer yes
                   2455: .It ddb.lines  integer yes
1.1       pavel    2456: .It ddb.maxoff integer yes
1.34      jruoho   2457: .It ddb.maxwidth       integer yes
1.122     sevan    2458: .It ddb.onpanic        integer yes
                   2459: .It ddb.panicstackframes       integer yes
                   2460: .It ddb.radix  integer yes
1.1       pavel    2461: .It ddb.tabstops       integer yes
1.34      jruoho   2462: .It ddb.tee_msgbuf     integer yes
1.1       pavel    2463: .El
                   2464: .Bl -tag -width "123456"
1.122     sevan    2465: .It Li ddb.commandonenter
1.124   ! sevan    2466: If not empty, the string is used as the DDB command to be executed each time
        !          2467: DDB is entered.
1.123     sevan    2468: .It Li ddb.dumpstack
                   2469: A value of 1 causes a stack trace to be printed on entering ddb from a panic.
                   2470: A value of 0 disables this behaviour. The default value is 1.
1.122     sevan    2471: .It Li ddb.fromconsole ( Dv DDBCTL_FROMCONSOLE )
                   2472: If not zero, DDB may be entered by sending a break on a serial
                   2473: console or by a special key sequence on a graphics console.
                   2474: .It Li ddb.lines ( Dv DDBCTL_LINES )
                   2475: Number of display lines.
1.91      kamil    2476: .It Li ddb.maxoff ( Dv DDBCTL_MAXOFF )
1.1       pavel    2477: The maximum symbol offset.
1.91      kamil    2478: .It Li ddb.maxwidth ( Dv DDBCTL_MAXWIDTH )
1.34      jruoho   2479: The maximum output line width.
1.91      kamil    2480: .It Li ddb.onpanic ( Dv DDBCTL_ONPANIC )
1.63      riz      2481: If greater than zero, DDB will be entered if the kernel panics.
1.123     sevan    2482: A value of 1 causes the system to enter DDB on panic.
1.63      riz      2483: A value of 0 causes the kernel to attempt to print a stack trace, then
1.64      wiz      2484: reboot, while a value of \-1 means neither a stack trace will be printed
1.63      riz      2485: nor DDB entered.
1.118     christos 2486: .It Li ddb.panicstackframes
                   2487: Number of stack frames to display on panic.
1.120     wiz      2488: Useful to avoid scrolling away the interesting frames on a glass tty.
1.118     christos 2489: Default value is
                   2490: .Dv 65535
                   2491: (all frames), useful value around
                   2492: .Dv 10 .
1.122     sevan    2493: .It Li ddb.radix ( Dv DDBCTL_RADIX )
                   2494: The input and output radix.
                   2495: .It Li ddb.tabstops ( Dv DDBCTL_TABSTOPS )
                   2496: Tab width.
                   2497: .It Li ddb.tee_msgbuf
                   2498: If not zero, DDB will output also to the kernel message buffer.
1.1       pavel    2499: .El
                   2500: .Pp
1.119     wiz      2501: Some of these MIB
1.34      jruoho   2502: nodes are also available as variables from within the debugger.
1.1       pavel    2503: See
                   2504: .Xr ddb 4
                   2505: for more details.
1.91      kamil    2506: .Ss The security.* subtree ( Dv CTL_SECURITY )
1.1       pavel    2507: The
                   2508: .Li security
                   2509: level contains various security-related settings for
1.2       wiz      2510: the system.
1.43      jruoho   2511: The available second level names are:
                   2512: .Bl -column "Second level name" "integer" "Changeable" -offset indent
1.107     wiz      2513: .It Sy Second level name Ta Sy Type Ta Sy Changeable
1.43      jruoho   2514: .It Li security.curtain        integer yes
                   2515: .It Li security.models node    not applicable
                   2516: .It Li security.pax    node    not applicable
                   2517: .El
                   2518: .Pp
1.2       wiz      2519: Available settings are detailed below.
1.1       pavel    2520: .Bl -tag -width "123456"
                   2521: .It Li security.curtain
1.119     wiz      2522: If non-zero, will filter return objects according to the user ID
1.95      pgoyette 2523: requesting information about them, preventing users from
                   2524: accessing any objects they do not own.
1.1       pavel    2525: .Pp
                   2526: At the moment, it affects
                   2527: .Xr ps 1 ,
                   2528: .Xr netstat 1
                   2529: (for
                   2530: .Dv PF_INET ,
                   2531: .Dv PF_INET6 ,
                   2532: and
                   2533: .Dv PF_UNIX
                   2534: PCBs), and
                   2535: .Xr w 1 .
1.4       elad     2536: .It Li security.models
                   2537: .Nx
                   2538: supports pluggable security models.
1.17      ad       2539: Every security model used, whether if loaded as a module or built with the system,
1.4       elad     2540: is required to add an entry to this node with at least one element,
                   2541: .Dq name ,
                   2542: indicating the name of the security model.
                   2543: .Pp
                   2544: In addition to the name, any settings and other information private to the
                   2545: security model will be available under this node.
                   2546: See
                   2547: .Xr secmodel 9
                   2548: for more information.
1.1       pavel    2549: .It Li security.pax
                   2550: Settings for PaX -- exploit mitigation features.
1.4       elad     2551: For more information on any of the PaX features, please see
                   2552: .Xr paxctl 8
                   2553: and
1.62      jruoho   2554: .Xr security 7 .
1.43      jruoho   2555: The available third and fourth level names are:
                   2556: .Bl -column "security.pax.segvguard.suspend_timeout" "integer" "Changeable" \
                   2557: -offset 2n
                   2558: .It Sy Third and fourth level names Ta Sy Type Ta Sy Changeable
                   2559: .It Li security.pax.aslr.enabled       integer yes
                   2560: .\".It Li security.pax.aslr.exec_len   integer yes
                   2561: .It Li security.pax.aslr.global        integer yes
                   2562: .\".It Li security.pax.aslr.mmap_len   integer yes
                   2563: .\".It Li security.pax.aslr.stack_len  integer yes
                   2564: .It Li security.pax.mprotect.enabled   integer yes
                   2565: .It Li security.pax.mprotect.global    integer yes
1.100     christos 2566: .It Li security.pax.mprotect.ptrace    integer yes
1.43      jruoho   2567: .It Li security.pax.segvguard.enabled  integer yes
                   2568: .It Li security.pax.segvguard.expiry_timeout   integer yes
                   2569: .It Li security.pax.segvguard.global   integer yes
                   2570: .It Li security.pax.segvguard.max_crashes      integer yes
                   2571: .It Li security.pax.segvguard.suspend_timeout  integer yes
                   2572: .El
1.1       pavel    2573: .Bl -tag -width "123456"
1.43      jruoho   2574: .It Li security.pax.aslr.enabled
1.14      elad     2575: Enable PaX ASLR (Address Space Layout Randomization).
                   2576: .Pp
                   2577: The value of this
                   2578: knob must be non-zero for PaX ASLR to be enabled, even if a program is set to
                   2579: explicit enable.
1.43      jruoho   2580: .\".It Li security.pax.aslr.exec_len
                   2581: .\" XXX: Undocumented.
1.14      elad     2582: .It Li security.pax.aslr.global
                   2583: Specifies the default global policy for programs without an
                   2584: explicit enable/disable flag.
                   2585: .Pp
                   2586: When non-zero, all programs will get PaX ASLR, except those exempted with
1.69      wiz      2587: .Xr paxctl 8 .
1.14      elad     2588: Otherwise, all programs will not get PaX ASLR, except those specifically
                   2589: marked as such with
                   2590: .Xr paxctl 8 .
1.43      jruoho   2591: .\".It Li security.pax.aslr.mmap_len
                   2592: .\" XXX: Undocumented.
                   2593: .\" .It Li security.pax.aslr.stack_len
                   2594: .\" XXX: Undocumented.
                   2595: .It Li security.pax.mprotect.enabled
1.1       pavel    2596: Enable PaX MPROTECT restrictions.
                   2597: .Pp
                   2598: These are
                   2599: .Xr mprotect 2
1.2       wiz      2600: restrictions to better enforce a W^X policy.
                   2601: The value of this
1.1       pavel    2602: knob must be non-zero for PaX MPROTECT to be enabled, even if a
                   2603: program is set to explicit enable.
                   2604: .It Li security.pax.mprotect.global
                   2605: Specifies the default global policy for programs without an
                   2606: explicit enable/disable flag.
                   2607: .Pp
                   2608: When non-zero, all programs will get the PaX MPROTECT restrictions,
                   2609: except those exempted with
1.69      wiz      2610: .Xr paxctl 8 .
1.1       pavel    2611: Otherwise, all programs will not get the PaX MPROTECT restrictions,
                   2612: except those specifically marked as such with
1.4       elad     2613: .Xr paxctl 8 .
1.100     christos 2614: .It Li security.pax.mprotect.ptrace
                   2615: This variable allows
                   2616: .Xr ptrace 2
                   2617: to override PaX MPROTECT permissions.
                   2618: It can have the following values:
                   2619: .Bl -tag -width XX -compact
                   2620: .It 0
                   2621: Does not let override any permissions.
                   2622: .It 1
                   2623: Disables PaX MPROTECT from processes that start executing while traced (default).
                   2624: .It 2
                   2625: Bypasses PaX MPROTECT for all processes being traced.
                   2626: .El
1.43      jruoho   2627: .It Li security.pax.segvguard.enabled
1.1       pavel    2628: Enable PaX Segvguard.
                   2629: .Pp
                   2630: PaX Segvguard can detect and prevent certain exploitation attempts, where
                   2631: an attacker may try for example to brute-force function return addresses
                   2632: of respawning daemons.
                   2633: .Pp
                   2634: .Em Note :
                   2635: The
                   2636: .Nx
                   2637: interface and implementation of the Segvguard is still experimental, and may
                   2638: change in future releases.
1.43      jruoho   2639: .It Li security.pax.segvguard.expiry_timeout
                   2640: If the max number was not reached within this timeout (in seconds), the entry
                   2641: will expire.
1.1       pavel    2642: .It Li security.pax.segvguard.global
                   2643: Specifies the default global policy for programs without an
                   2644: explicit enable/disable flag.
                   2645: .Pp
                   2646: When non-zero, all programs will get the PaX Segvguard,
                   2647: except those exempted with
1.69      wiz      2648: .Xr paxctl 8 .
1.2       wiz      2649: Otherwise, no program will get the PaX Segvguard restrictions,
1.1       pavel    2650: except those specifically marked as such with
1.4       elad     2651: .Xr paxctl 8 .
1.43      jruoho   2652: .It Li security.pax.segvguard.max_crashes
                   2653: The maximum number of segfaults a program can receive before suspension.
1.1       pavel    2654: .It Li security.pax.segvguard.suspend_timeout
                   2655: Number of seconds to suspend a user from running a faulting program when the
                   2656: limit was exceeded.
                   2657: .El
                   2658: .El
1.91      kamil    2659: .Ss The vendor.* subtree ( Dv CTL_VENDOR )
1.1       pavel    2660: The
                   2661: .Li vendor
                   2662: toplevel name is reserved to be used by vendors who wish to
                   2663: have their own private MIB tree.
                   2664: Intended use is to store values under
1.114     wiz      2665: .Dq vendor.<yourname>.* .
1.1       pavel    2666: .Sh SEE ALSO
                   2667: .Xr sysctl 3 ,
                   2668: .Xr ipsec 4 ,
                   2669: .Xr tcp 4 ,
1.62      jruoho   2670: .Xr security 7 ,
1.1       pavel    2671: .Xr sysctl 8
                   2672: .Sh HISTORY
                   2673: The
                   2674: .Nm
                   2675: variables first appeared in
                   2676: .Bx 4.4 .

CVSweb <webmaster@jp.NetBSD.org>