xref: /netbsd-src/share/man/man4/options.4 (revision d48f14661dda8638fee055ba15d35bdfb29b9fa8)
1.\"	$NetBSD: options.4,v 1.322 2006/06/19 15:44:36 gdamore Exp $
2.\"
3.\" Copyright (c) 1996
4.\" 	Perry E. Metzger.  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. All advertising materials mentioning features or use of this software
15.\"    must display the following acknowledgment:
16.\"	This product includes software developed for the NetBSD Project
17.\"	by Perry E. Metzger.
18.\" 4. The name of the author may not be used to endorse or promote products
19.\"    derived from this software without specific prior written permission.
20.\"
21.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
22.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
23.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
24.\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
25.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
26.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
30.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31.\"
32.\"
33.Dd May 19, 2006
34.Os
35.Dt OPTIONS 4
36.Sh NAME
37.Nm options
38.Nd Miscellaneous kernel configuration options
39.Sh SYNOPSIS
40.Cd cinclude ...
41.Cd config ...
42.Cd [no] file-system ...
43.Cd ident ...
44.Cd include ...
45.Cd [no] makeoptions ...
46.Cd maxusers ...
47.Cd [no] options ...
48.Cd [no] pseudo-device ...
49.Sh DESCRIPTION
50This manual page describes a number of miscellaneous kernel
51configuration options that may be specified in a kernel config
52file.
53See
54.Xr config 1
55and
56.Xr config 5
57for information on how to configure and build kernels.
58.Pp
59The
60.Ar no
61form removes a previously specified option.
62.Ss Keywords
63The following keywords are recognized in a kernel configuration file:
64.Bl -ohang
65.It Sy cinclude Xo
66.Qq Ar filename
67.Xc
68Conditionally includes another kernel configuration file whose name is
69.Ar filename ,
70which may be double-quoted and may be an explicit path or relative to
71the kernel source directory.
72Failure to open the named file is ignored.
73.It Sy config Xo
74.Ar exec_name
75.No root on
76.Ar rootdev
77.Op type Ar fstype
78.Op dumps on Ar dumpdev
79.Xc
80Defines a configuration whose kernel executable is named
81.Ar exec_name ,
82normally
83.Dq netbsd ,
84with its root file system of type
85.Ar fstype
86on the device
87.Ar rootdev ,
88and optionally specifying the location of kernel core dumps on the device
89.Ar dumpdev .
90.Ar dev
91or
92.Ar dumpdev
93and
94.Ar fstype
95may be specified as
96.Dq \&? ,
97which is a wild card.
98The root
99.Ar fstype
100and
101.Ar dumpdev
102are optional and assumed to be wild carded if they are not specified.
103.It Ar device_instance Xo
104at
105.Ar attachment
106.Op Ar locators value Op ...
107.Op flags Ar value
108.Xc
109Define an instance of the device driver
110.Ar device_instance
111that attaches to the bus or device named
112.Ar attachment .
113An
114.Ar attachment
115may require additional information on where the device can be found, such
116as an address, channel, function, offset, and/or slot, referred to as
117.Ar locators ,
118whose
119.Ar value
120often may be a wild card,
121.Dq \&? .
122Some device drivers have one or more
123.Ar flags
124that can be adjusted to affect the way they operate.
125.It Sy file-system Xo
126.Ar fs_name Op , Ar fs_name Op ...
127.Xc
128Include support for the file-system
129.Ar fs_name .
130.It Sy ident Xo
131.Qq Ar string
132.Xc
133Sets the kernel identification string to
134.Ar string .
135.It Sy include Xo
136.Qq Ar filename
137.Xc
138Functions the same as
139.Ar cinclude ,
140except failure to open
141.Ar filename
142produces a fatal error.
143.It Sy options Xo
144.Ar option_name Op , Ar option_name=value Op ...
145.Xc
146Specifies (or sets) the option, or comma-separated list of options,
147.Ar option_name .
148Some options expect to be assigned a value, which may be an integer,
149a double-quoted word, a bare word, or an empty string
150.Pq Qq .
151Note that those are eventually handled by the C compiler, so the rules
152of that language apply.
153.Pp
154.Em Note :
155Options that are not defined by device definition files are passed to
156the compile process as
157.Fl D
158flags to the C compiler.
159.It Sy makeoptions Xo
160.Ar name=value
161.Xc
162Defines a
163.Xr make 1
164macro
165.Ar name
166with the value
167.Ar value
168in the kernel Makefile.
169.It Sy maxusers Xo
170.Ar integer
171.Xc
172Set the maxusers variable in the kernel.
173.It Sy no Xo
174.Ar keyword Ar name Op Ar arguments Op ...
175.Xc
176For the
177.Xr config 1
178.Ar keywords
179file-system, makeoptions, options, and pseudo-device,
180.Ar no
181removes the file-system, makeoption, options, or pseudo-device,
182.Ar name .
183This is useful when a kernel configuration file includes another which
184has undesired options.
185.Pp
186For example, a local configuration file that wanted the kitchen sink, but
187not COMPAT_09 or bridging, might be:
188.Bd -literal -offset indent
189include "arch/i386/conf/GENERIC"
190no options COMPAT_09
191no pseudo-device bridge
192.Ed
193.It Sy pseudo-device Xo
194.Ar name
195.Op Ar N
196.Xc
197Includes support for the pseudo-device
198.Ar name .
199Some pseudo-devices can have multiple or
200.Ar N
201instances.
202.El
203.Ss Compatibility Options
204.Bl -ohang
205.It Cd options COMPAT_09
206Enable binary compatibility with
207.Nx 0.9 .
208This enables support for
20916-bit user, group, and process IDs (following revisions support
21032-bit identifiers).
211It also allows the use of the deprecated
212.Xr getdomainname 3 ,
213.Xr setdomainname 3 ,
214and
215.Xr uname 3
216syscalls.
217This option also allows using numeric file system identifiers rather
218than strings.
219Post
220.Nx 0.9
221versions use string identifiers.
222.It Cd options COMPAT_10
223Enable binary compatibility with
224.Nx 1.0 .
225This option allows the use of the file system name of
226.Dq ufs
227as an alias for
228.Dq ffs .
229The name
230.Dq ffs
231should be used post 1.0 in
232.Pa /etc/fstab
233and other files.
234It also adds old syscalls for the
235.At V
236shared memory interface.
237This was changed post 1.0 to work on 64-bit architectures.
238This option also enables
239.Dq sgtty
240compatibility, without which programs using the old interface produce
241an
242.Dq inappropriate ioctl
243error, and
244.Pa /dev/io
245only works when this option is set in the kernel,
246see
247.Xr io 4
248on ports that support it.
249.It Cd options COMPAT_11
250Enable binary compatibility with
251.Nx 1.1 .
252This allows binaries running on the i386 port to gain direct access to
253the io ports by opening
254.Pa /dev/io
255read/write.
256This functionality was replaced by
257.Xr i386_iopl 2
258post 1.1.
259On the
260.Tn Atari
261port, the location of the disk label was moved after 1.1.
262When the
263.Em COMPAT_11
264option is set, the kernel will read (pre) 1.1 style disk labels as a
265last resort.
266When a disklabel is re-written, the old style label will be replaced
267with a post 1.1 style label.
268This also enables the
269.Em EXEC_ELF_NOTELESS
270option.
271.It Cd options COMPAT_12
272Enable binary compatibility with
273.Nx 1.2 .
274This allows the use of old syscalls for
275.Fn reboot
276and
277.Fn swapon .
278The syscall numbers were changed post 1.2 to add functionality to the
279.Xr reboot 2
280syscall, and the new
281.Xr swapctl 2
282interface was introduced.
283This also enables the
284.Em EXEC_ELF_NOTELESS
285option.
286.It Cd options COMPAT_13
287Enable binary compatibility with
288.Nx 1.3 .
289This allows the use of old syscalls for
290.Fn sigaltstack ,
291and also enables the old
292.Xr swapctl 2
293command
294.Dv SWAP_STATS
295(now called
296.Dv SWAP_OSTATS ) ,
297which does not include the
298.Fa se_path
299member of
300.Va struct swapent .
301.It Cd options COMPAT_14
302Enable binary compatibility with
303.Nx 1.4 .
304This allows some old
305.Xr ioctl 2
306on
307.Xr wscons 4
308to be performed, and allows the
309.Dv NFSSVC_BIOD
310mode of the
311.Xr nfssvc 2
312system call to be used for compatibility with the deprecated nfsiod program.
313.It Cd options COMPAT_16
314Enable binary compatibility with
315.Nx 1.6 .
316This allows the use of old signal trampoline code which has been deprecated
317with the addition of
318.Xr siginfo 2 .
319.It Cd options COMPAT_20
320Enable binary compatibility with
321.Nx 2.0 .
322This allows the use of old syscalls for
323.Fn statfs ,
324.Fn fstatfs ,
325.Fn getfsstat
326and
327.Fn fhstatfs ,
328which have been deprecated with the addition of the
329.Xr statvfs 2 ,
330.Xr fstatvfs 2 ,
331.Xr getvfsstat 2
332and
333.Xr fhstatvfs 2
334system calls.
335.It Cd options COMPAT_30
336Enable binary compatibility with
337.Nx 3.0 .
338This allows the use of old syscalls for
339.Fn getdents ,
340.Fn stat ,
341.Fn fstat ,
342.Fn lstat
343and
344.Fn fhstat .
345The syscall numbers were changed post 3.0 to introduce 64 bit inode.
346.It Cd options COMPAT_43
347Enables compatibility with
348.Bx 4.3 .
349This adds an old syscall for
350.Xr lseek 2 .
351It also adds the ioctls for
352.Dv TIOCGETP
353and
354.Dv TIOCSETP .
355The return values for
356.Xr getpid 2 ,
357.Xr getgid 2 ,
358and
359.Xr getuid 2
360syscalls are modified as well, to return the parent's PID and
361UID as well as the current process's.
362It also enables the deprecated
363.Dv NTTYDISC
364terminal line discipline.
365It also provides backwards compatibility with
366.Dq old
367SIOC[GS]IF{ADDR,DSTADDR,BRDADDR,NETMASK} interface ioctls, including
368binary compatibility with code written before the introduction of the
369sa_len field in sockaddrs.
370It also enables
371support for some older pre
372.Bx 4.4
373socket calls.
374.It Cd options COMPAT_BSDPTY
375This option is currenty on by default and enables the pty multiplexor
376.Xr ptm 4
377and
378.Xr ptmx 4
379to find and use ptys named
380.Pa /dev/ptyXX
381(master) and
382.Pa /dev/ttyXX
383(slave).
384Eventually this option will become optional as ptyfs based pseudo-ttys become
385the default, see
386.Xr mount_ptyfs 8 .
387.It Cd options COMPAT_SVR4
388On those architectures that support it, this enables binary
389compatibility with
390.At V.4
391applications built for the same architecture.
392This currently includes the i386, m68k, and sparc ports.
393.It Cd options COMPAT_LINUX
394On those architectures that support it, this enables binary
395compatibility with Linux ELF and
396.Xr a.out 5
397applications built for the same architecture.
398This currently includes the alpha, arm, i386, m68k, mips, powerpc, and
399x86_64 ports.
400.It Cd options COMPAT_LINUX32
401On those 64 bit architectures that support it, this enables binary
402compatibility with 32 bit Linux binaries.
403For now this is limited to running i386 ELF Linux binaries on amd64.
404.It Cd options COMPAT_SUNOS
405On those architectures that support it, this enables binary
406compatibility with
407.Tn SunOS 4.1
408applications built for the same architecture.
409This currently includes the sparc, sparc64 and most or all m68k ports.
410Note that the sparc64 requires the
411.Em COMPAT_NETBSD32
412option for 64-bit kernels, in addition to this option.
413.It Cd options COMPAT_ULTRIX
414On those architectures that support it, this enables binary
415compatibility with
416.Tn ULTRIX
417applications built for the same architecture.
418This currently is limited to the pmax.
419The functionality of this option is unknown.
420.It Cd options COMPAT_DARWIN
421On those architectures that support it, this enables binary compatibility with
422.Tn Darwin
423applications built for the same architecture.
424This feature is highly experimental, it requires COMPAT_MACH and
425EXEC_MACHO and it is currently limited to i386 and powerpc ports of
426.Nx .
427.It Cd options COMPAT_FREEBSD
428On those architectures that support it, this enables binary
429compatibility with
430.Fx
431applications built for the same architecture.
432At the moment this is limited to the i386 port.
433.It Cd options COMPAT_HPUX
434On those architectures that support it, this enables binary
435compatibility with
436.Tn HP/UX
437applications built for the same architecture.
438This is limited to the hp300 port, and has some known bugs.
439A limited set of programs do work.
440.It Cd options COMPAT_IBCS2
441On those architectures that support it, this enables binary
442compatibility with iBCS2 or SVR3 applications built for the same architecture.
443This is currently limited to the i386 and vax ports.
444.It Cd options COMPAT_IRIX
445On those architectures that support it, this enables binary
446compatibility with IRIX o32 binaries built for the same architecture.
447This feature is experimental, and it is currently limited to
448the sgimips port.
449.It Cd options COMPAT_MACH
450On those architectures that support it, this enables the emulation of
451Mach kernel traps for binaries built for the same architecture.
452This feature is highly experimental and it is currently
453limited to the i386 and powerpc ports of
454.Nx .
455.It Cd options COMPAT_OSF1
456On those architectures that support it, this enables binary
457compatibility with
458.Tn Digital
459.Ux
460.Po
461formerly
462.Tn OSF/1
463.Pc
464applications built for the same architecture.
465This is currently limited to the alpha port.
466.It Cd options COMPAT_NOMID
467Enable compatibility with
468.Xr a.out 5
469executables that lack a machine ID.
470This includes
471.Nx 0.8 Ns 's
472ZMAGIC format, and 386BSD and BSDI's
473QMAGIC, NMAGIC, and OMAGIC
474.Xr a.out 5
475formats.
476.It Cd options COMPAT_NETBSD32
477On those architectures that support it, this enables binary
478compatibility with 32-bit applications built for the same architecture.
479This is currently limited to the amd64 and sparc64 ports, and only
480applicable for 64-bit kernels.
481.It Cd options COMPAT_SVR4_32
482On those architectures that support it, this enables binary
483compatibility with 32-bit SVR4 applications built for the same architecture.
484This is currently limited to the sparc64 port, and only applicable for
48564-bit kernels.
486.It Cd options COMPAT_AOUT_M68K
487On m68k architectures which have switched to ELF,
488this enables binary compatibility with
489.Nx Ns Tn /m68k
490.Xr a.out 5
491executables on
492.Nx Ns Tn /m68k
493ELF kernels.
494This handles alignment incompatibility of m68k ABI between
495a.out and ELF which causes the structure padding differences.
496Currently only some system calls which use
497.Va struct stat
498are adjusted and some binaries which use
499.Xr sysctl 3
500to retrieve network details would not work properly.
501.It Cd options EXEC_MACHO
502On those architectures that support it, this adds support for running
503Mach-O executables.
504This is currently limited to the i386 and powerpc ports of
505.Nx .
506.It Cd options EXEC_ELF_NOTELESS
507Run unidentified ELF binaries as
508.Nx
509binaries.
510This might be needed for very old
511.Nx
512ELF binaries on some archs.
513These old binaries didn't contain an appropriate
514.Li .note.netbsd.ident
515section, and thus can't be identified by the kernel as
516.Nx
517binaries otherwise.
518Beware - if this option is on, the kernel would run
519.Em any
520unknown ELF binaries as if they were
521.Nx
522binaries.
523.It Cd options P1003_1B_SEMAPHORE
524Includes kernel support for the standard C library
525.Pq libc
526functions that implement semaphores as specified in
527.St -p1003.1-96 .
528.El
529.Ss Debugging Options
530.Bl -ohang
531.It Cd options DDB
532Compiles in a kernel debugger for diagnosing kernel problems.
533See
534.Xr ddb 4
535for details.
536.Em NOTE :
537not available on all architectures.
538.It Cd options DDB_FROMCONSOLE=integer
539If set to non-zero, DDB may be entered by sending a break on a serial
540console or by a special key sequence on a graphics console.
541A value of "0" ignores console breaks or key sequences.
542If not explicitly specified, the default value is "1".
543Note that this sets the value of the
544.Em ddb.fromconsole
545.Xr sysctl 3
546variable which may be changed at run time -- see
547.Xr sysctl 8
548for details.
549.It Cd options DDB_HISTORY_SIZE=integer
550If this is non-zero, enable history editing in the kernel debugger
551and set the size of the history to this value.
552.It Cd options DDB_ONPANIC
553The default if not specified is
554.Dq 1
555- just enter into DDB.
556If set to
557.Dq 2
558the kernel will
559attempt to print out a stack trace before entering into DDB.
560If set to
561.Dq 0
562the kernel will attempt to print out a stack trace
563and reboot the system.
564If set to
565.Dq -1
566then neither a stack trace is printed or DDB entered -
567it is as if DDB were not compiled into the kernel.
568Note that this sets the value of the
569.Em ddb.onpanic
570.Xr sysctl 3
571variable which may be changed at run time -- see
572.Xr sysctl 8
573for details.
574.It Cd options DDB_COMMANDONENTER=string
575This option specify commands which will be executed on each entry to DDB.
576This sets the default value of the
577.Em ddb.commandonenter
578.Xr sysctl 3
579variable which may be changed at run time.
580.It Cd options DDB_BREAK_CHAR=integer
581This option overrides using break to enter the kernel debugger
582on the serial console.
583The value given is the ascii value to be used instead.
584This is currently only supported by the com driver.
585.It Cd options KGDB
586Compiles in a remote kernel debugger stub for diagnosing kernel problems
587using the
588.Dq remote target
589feature of gdb.
590See
591.Xr gdb 1
592for details.
593.Em NOTE :
594not available on all architectures.
595.It Cd options KGDB_DEV
596Device number
597.Po
598as a
599.Dv dev_t
600.Pc
601of kgdb device.
602.It Cd options KGDB_DEVADDR
603Memory address of kgdb device.
604.It Cd options KGDB_DEVMODE
605Permissions of kgdb device.
606.It Cd options KGDB_DEVNAME
607Device name of kgdb device.
608.It Cd options KGDB_DEVRATE
609Baud rate of kgdb device.
610.It Cd makeoptions DEBUG="-g"
611The
612.Fl g
613flag causes
614.Pa netbsd.gdb
615to be built in addition to
616.Pa netbsd .
617.Pa netbsd.gdb
618is useful for debugging kernel crash dumps with gdb.
619See
620.Xr gdb 1
621for details.
622This also turns on
623.Em options DEBUG
624(which see).
625.It Cd options DEBUG
626Turns on miscellaneous kernel debugging.
627Since options are turned into preprocessor defines (see above),
628.Em options DEBUG
629is equivalent to doing a
630.Em #define DEBUG
631throughout the kernel.
632Much of the kernel has
633.Em #ifdef DEBUG
634conditionalized debugging code.
635Note that many parts of the kernel (typically device drivers) include their own
636.Em #ifdef XXX_DEBUG
637conditionals instead.
638This option also turns on certain other options,
639which may decrease system performance.
640.It Cd options DIAGNOSTIC
641Adds code to the kernel that does internal consistency checks.
642This code will cause the kernel to panic if corruption of internal data
643structures is detected.
644These checks can decrease performance up to 15%.
645.It Cd options KSTACK_CHECK_MAGIC
646Check kernel stack usage and panic if stack overflow is detected.
647This check is performance sensitive because it scans stack on each context
648switch.
649.It Cd options KTRACE
650Add hooks for the system call tracing facility, which allows users to
651watch the system call invocation behavior of processes.
652See
653.Xr ktrace 1
654for details.
655.It Cd options MSGBUFSIZE=integer
656This option sets the size of the kernel message buffer.
657This buffer holds the kernel output of
658.Fn printf
659when not (yet) read by
660.Xr syslogd 8 .
661This is particularly useful when the system has crashed and you wish to lookup
662the kernel output from just before the crash.
663Also, since the autoconfig output becomes more and more verbose,
664it sometimes happens that the message buffer overflows before
665.Xr syslogd 8
666was able to read it.
667Note that not all systems are capable of obtaining a variable sized message
668buffer.
669There are also some systems on which memory contents are not preserved
670across reboots.
671.It Cd options MALLOCLOG
672Enables an event log for
673.Xr malloc 9 .
674Useful for tracking down
675.Dq Data modified on freelist
676and
677.Dq multiple free
678problems.
679.It Cd options MALLOCLOGSIZE=integer
680Defines the number of entries in the malloc log.
681Default is 100000 entries.
682.It Cd options SYSTRACE
683Add hooks for the system call policy facility.
684See
685.Xr systrace 1
686for details.
687.It Cd options UVMHIST
688Enables the UVM history logs, which create in-memory traces of
689various UVM activities.
690These logs can be displayed be calling
691.Fn uvmhist_dump
692or
693.Fn uvm_hist
694with appropriate arguments from DDB.
695See the kernel source file sys/uvm/uvm_stat.c for details.
696.It Cd options UVMHIST_PRINT
697Prints the UVM history logs on the system console as entries are added.
698Note that the output is
699.Em extremely
700voluminous, so this option is really only useful for debugging
701the very earliest parts of kernel initialization.
702.El
703.Ss File Systems
704.Bl -ohang
705.It Cd file-system FFS
706Includes code implementing the Berkeley Fast File System
707.Em ( FFS ) .
708Most machines need this if they are not running diskless.
709.It Cd file-system EXT2FS
710Includes code implementing the Second Extended File System
711.Em ( EXT2FS ) ,
712revision 0 and revision 1 with the
713.Em filetype
714and
715.Em sparse_super
716options.
717This is the most commonly used file system on the Linux operating system,
718and is provided here for compatibility.
719Some of the specific features of
720.Em EXT2FS
721like the "behavior on errors" are not implemented.
722This file system can't be used with UID or GID greater than 65535.
723See
724.Xr mount_ext2fs 8
725for details.
726.It Cd file-system LFS
727.Bq Em EXPERIMENTAL
728Include the Log-structured File System
729.Em ( LFS ) .
730See
731.Xr mount_lfs 8
732and
733.Xr newfs_lfs 8
734for details.
735.It Cd file-system MFS
736Include the Memory File System
737.Em ( MFS ) .
738This file system stores files in swappable memory, and produces
739notable performance improvements when it is used as the file store
740for
741.Pa /tmp
742and similar file systems.
743See
744.Xr mount_mfs 8
745for details.
746.It Cd file-system NFS
747Include the client side of the Network File System
748.Pq Tn NFS
749remote file sharing protocol.
750Although the bulk of the code implementing
751.Tn NFS
752is kernel based, several user level daemons are needed for it to work.
753See
754.Xr mount_nfs 8
755for details.
756.It Cd file-system CD9660
757Includes code for the
758.Tn ISO
7599660 + Rock Ridge file system, which is the standard file system on many
760.Tn CD-ROM
761discs.
762Useful primarily if you have a
763.Tn CD-ROM
764drive.
765See
766.Xr mount_cd9660 8
767for details.
768.It Cd file-system MSDOSFS
769Includes the
770.Tn MS-DOS
771FAT file system, which is reportedly still used
772by unfortunate people who have not heard about
773.Nx .
774Also implements the
775.Tn Windows 95
776extensions to the same, which permit the use of longer, mixed case
777file names.
778See
779.Xr mount_msdos 8
780and
781.Xr fsck_msdos 8
782for details.
783.It Cd file-system NTFS
784.Bq Em EXPERIMENTAL
785Includes code for the
786.Tn Microsoft Windows NT
787file system.
788See
789.Xr mount_ntfs 8
790for details.
791.It Cd file-system FDESC
792Includes code for a file system, conventionally mounted on
793.Pa /dev/fd ,
794which permits access to the per-process file descriptor space via
795special files in the file system.
796See
797.Xr mount_fdesc 8
798for details.
799Note that this facility is redundant, and thus unneeded on most
800.Nx
801systems, since the
802.Xr fd 4
803pseudo-device driver already provides identical functionality.
804On most
805.Nx
806systems, instances of
807.Xr fd 4
808are mknoded under
809.Pa /dev/fd/
810and on
811.Pa /dev/stdin ,
812.Pa /dev/stdout ,
813and
814.Pa /dev/stderr .
815.It Cd file-system KERNFS
816Includes code which permits the mounting of a special file system
817(normally mounted on
818.Pa /kern )
819in which files representing various kernel variables and parameters
820may be found.
821See
822.Xr mount_kernfs 8
823for details.
824.It Cd file-system NULLFS
825Includes code for a loopback file system.
826This permits portions of the file hierarchy to be re-mounted in other places.
827The code really exists to provide an example of a stackable file system layer.
828See
829.Xr mount_null 8
830for details.
831.It Cd file-system OVERLAY
832Includes code for a file system filter.
833This permits the overlay file system to intercept all access to an underlying
834file system.
835This file system is intended to serve as an example of a stacking file
836system which has a need to interpose itself between an underlying file
837system and all other access.
838See
839.Xr mount_overlay 8
840for details.
841.It Cd file-system PORTAL
842.Bq Em EXPERIMENTAL
843Includes the portal file system.
844This permits interesting tricks like opening
845.Tn TCP
846sockets by opening files in the file system.
847The portal file system is conventionally mounted on
848.Pa /p
849and is partially implemented by a special daemon.
850See
851.Xr mount_portal 8
852for details.
853.It Cd file-system PROCFS
854Includes code for a special file system (conventionally mounted on
855.Pa /proc )
856in which the process space becomes visible in the file system.
857Among
858other things, the memory spaces of processes running on the system are
859visible as files, and signals may be sent to processes by writing to
860.Pa ctl
861files in the procfs namespace.
862See
863.Xr mount_procfs 8
864for details.
865.It Cd file-system UDF
866.Bq Em EXPERIMENTAL
867Includes code for the UDF file system commonly found on CD and DVD
868media but also more and more on USB sticks.
869Useful primarily if you have a CD or a DVD drive, be it a read-only
870or a rewritable device.
871Currently only supports read-access.
872See
873.Xr mount_udf 8
874for details.
875.It Cd file-system UMAPFS
876Includes a loopback file system in which user and group IDs may be
877remapped -- this can be useful when mounting alien file systems with
878different UIDs and GIDs than the local system.
879See
880.Xr mount_umap 8
881for details.
882.It Cd file-system UNION
883.Bq Em EXPERIMENTAL
884Includes code for the union file system, which permits directories to
885be mounted on top of each other in such a way that both file systems
886remain visible -- this permits tricks like allowing writing (and the
887deleting of files) on a read-only file system like a
888.Tn CD-ROM
889by mounting a local writable file system on top of the read-only file system.
890See
891.Xr mount_union 8
892for details.
893.It Cd file-system CODA
894.Bq Em EXPERIMENTAL
895Includes code for the Coda file system.
896Coda is a distributed file system like NFS and AFS.
897It is freely available, like NFS, but it functions much like AFS in being a
898.Dq stateful
899file system.
900Both Coda and AFS cache files on your local machine to improve performance.
901Then Coda goes a step further than AFS by letting you access the cached
902files when there is no available network, viz. disconnected laptops and
903network outages.
904In Coda, both the client and server are outside the kernel which makes
905them easier to experiment with.
906Coda is available for several UNIX and non-UNIX platforms.
907See http://www.coda.cs.cmu.edu for more details.
908.Em NOTE :
909You also need to enable the pseudo-device, vcoda, for the Coda
910file system to work.
911.It Cd file-system SMBFS
912.Bq Em EXPERIMENTAL
913Includes code for the SMB/CIFS file system.
914See
915.Xr mount_smbfs 8
916for details.
917.Em NOTE :
918You also need to enable the pseudo-device, nsmb, for the SMB
919file system to work.
920.It Cd file-system PTYFS
921.Bq Em EXPERIMENTAL
922Includes code for a special file system (normally mounted on
923.Pa /dev/pts )
924in which pseudo-terminal slave devices become visible in the file system.
925See
926.Xr mount_ptyfs 8
927for details.
928.It Cd file-system TMPFS
929.Bq Em EXPERIMENTAL
930Includes code for the efficient memory file system, normally used over
931.Pa /tmp .
932See
933.Xr mount_tmpfs 8
934for details.
935.El
936.Ss File System Options
937.Bl -ohang
938.It Cd options MAGICLINKS
939Enables the expansion of special strings
940.Po
941beginning with
942.Dq @
943.Pc
944when traversing symbolic links.
945See
946.Xr symlink 7
947for a list of supported strings.
948Note that this option only controls the enabling of this feature
949by the kernel at boot-up.
950This feature can still be manipulated with the
951.Xr sysctl 8
952command regardless of the setting of this option.
953.It Cd options NFSSERVER
954Include the server side of the
955.Em NFS
956(Network File System) remote file sharing protocol.
957Although the bulk of the code implementing
958.Em NFS
959is kernel based, several user level daemons are needed for it to
960work.
961See
962.Xr mountd 8
963and
964.Xr nfsd 8
965for details.
966.It Cd options QUOTA
967Enables kernel support for file system quotas.
968See
969.Xr quotaon 8 ,
970.Xr edquota 8 ,
971and
972.Xr quota 1
973for details.
974Note that quotas only work on
975.Dq ffs
976file systems, although
977.Xr rpc.rquotad 8
978permits them to be accessed over
979.Em NFS .
980.It Cd options FFS_EI
981Enable ``Endian-Independent'' FFS support.
982This allows a system to mount an FFS file system created for another
983architecture, at a small performance cost for all FFS file systems.
984See also
985.Xr newfs 8 ,
986.Xr fsck_ffs 8 ,
987.Xr dumpfs 8
988for file system byte order status and manipulation.
989.It Cd options FFS_NO_SNAPSHOT
990Disable the
991.Dq file system snapshot
992support in FFS file systems.
993Maybe useful for install media kernels, small memory systems and
994embedded systems which don't require the snapshot support.
995.It Cd options NVNODE=integer
996This option sets the size of the cache used by the name-to-inode translation
997routines, (a.k.a. the
998.Fn namei
999cache, though called by many other names in the kernel source).
1000By default, this cache has
1001.Dv NPROC
1002(set as 20 + 16 * MAXUSERS) * (80 + NPROC / 8) entries.
1003A reasonable way to derive a value of
1004.Dv NVNODE ,
1005should you notice a large number of namei cache misses with a tool such as
1006.Xr systat 1 ,
1007is to examine your system's current computed value with
1008.Xr sysctl 8 ,
1009(which calls this parameter "kern.maxvnodes") and to increase this value
1010until either the namei cache hit rate improves or it is determined that
1011your system does not benefit substantially from an increase in the size of
1012the namei cache.
1013.It Cd options NAMECACHE_ENTER_REVERSE
1014Causes the namei cache to always enter a reverse mapping (vnode -\*[Gt] name)
1015as well as a normal one.
1016Normally, this is already done for directory vnodes, to speed up the getcwd
1017operation.
1018This option will cause longer hash chains in the reverse cache, and thus
1019slow down getcwd somewhat.
1020However, it does make vnode -\*[Gt] path translations possible in some cases.
1021For now, only useful if strict /proc/#/maps emulation for Linux binaries is
1022required.
1023.It Cd options EXT2FS_SYSTEM_FLAGS
1024This option changes the behavior of the APPEND and IMMUTABLE flags
1025for a file on an
1026.Em EXT2FS
1027file system.
1028Without this option, the superuser or owner of the file can
1029set and clear them.
1030With this option, only the superuser can set them, and
1031they can't be cleared if the securelevel is greater than 0.
1032See also
1033.Xr chflags 1 .
1034.It Cd options NFS_BOOT_BOOTP
1035Enable use of the BOOTP protocol (RFCs 951 and 1048) to get configuration
1036information if NFS is used to mount the root file system.
1037See
1038.Xr diskless 8
1039for details.
1040.It Cd options NFS_BOOT_DHCP
1041Same as
1042.Dq NFS_BOOT_BOOTP ,
1043but use the DHCP extensions to the
1044BOOTP protocol (RFC 1541).
1045.It Cd options NFS_BOOT_BOOTP_REQFILE
1046Specifies the string sent in the bp_file field of the BOOTP / DHCP
1047request packet.
1048.It Cd options NFS_BOOT_BOOTPARAM
1049Enable use of the BOOTPARAM protocol, consisting of RARP and
1050BOOTPARAM RPC, to get configuration information if NFS
1051is used to mount the root file system.
1052See
1053.Xr diskless 8
1054for details.
1055.It Cd options NFS_BOOT_RWSIZE=value
1056Set the initial NFS read and write sizes for diskless-boot requests.
1057The normal default is 8Kbytes.
1058This option provides a way to lower the value (e.g., to 1024 bytes)
1059as a workaround for buggy network interface cards or boot PROMs.
1060Once booted, the read and write request sizes can be increased by
1061remounting the file system.
1062See
1063.Xr mount_nfs 8
1064for details.
1065.It Cd options NFS_V2_ONLY
1066Reduce the size of the NFS client code by omitting code that's only required
1067for NFSv3 and NQNFS support, leaving only that code required to use NFSv2
1068servers.
1069.It Cd options SOFTDEP
1070Enable kernel support for soft-dependencies in FFS filesystems.
1071Softdep improves write performance by aggregating and properly
1072ordering disk metadata writes, achieving near-asynchronous write
1073performance while maintaining the filesystem consistency of
1074synchronous writes.
1075Soft-dependencies are enabled on a per-mount basis.
1076See
1077.Xr mount 8
1078for details.
1079.It Cd options UFS_DIRHASH
1080Increase lookup performance by maintaining in-core hash tables
1081for large directories.
1082.El
1083.Ss Buffer queue strategy options
1084The following options enable alternative buffer queue strategies.
1085.Bl -ohang
1086.It Cd options BUFQ_READPRIO
1087Enable experimental buffer queue strategy for disk I/O.
1088In the default strategy, outstanding disk requests are ordered by
1089sector number and sent to the disk, regardless of whether the
1090operation is a read or write; this option gives priority to issuing
1091read requests over write requests.
1092Although requests may therefore be issued out of sector-order, causing
1093more seeks and thus lower overall throughput, interactive system
1094responsiveness under heavy disk I/O load may be improved, as processes
1095blocking on disk reads are serviced sooner (file writes typically
1096don't cause applications to block).
1097The performance effect varies greatly depending on the hardware, drive
1098firmware, filesystem configuration, workload, and desired performance
1099trade-off.
1100Systems using drive write-cache (most modern IDE disks, by default)
1101are unlikely to benefit and may well suffer; such disks acknowledge
1102writes very quickly, and optimise them internally according to
1103physical layout.
1104Giving these disks as many requests to work with as possible (the
1105standard strategy) will typically produce the best results, especially
1106if the drive has a large cache; the drive will silently complete
1107writes from cache as it seeks for reads.
1108Disks that support a large number of concurrent tagged requests (SCSI
1109disks and many hardware RAID controllers) expose this internal
1110scheduling with tagged responses, and don't block for reads; such
1111disks may not see a noticable difference with either strategy.
1112However, if IDE disks are run with write-cache disabled for safety,
1113writes are not acknowledged until actually completed, and only one
1114request can be outstanding; a large number of small writes in one
1115locality can keep the disk busy, starving reads elsewhere on the disk.
1116Such systems are likely to see the most benefit from this option.
1117Finally, the performance interaction of this option with ffs soft
1118dependencies can be subtle, as that mechanism can drastically alter
1119the workload for filesystem metadata writes.
1120.It Cd options BUFQ_PRIOCSCAN
1121Enable another experimental buffer queue strategy for disk I/O,
1122Per-priority cyclical scan.
1123.It Cd options NEW_BUFQ_STRATEGY
1124Synonym of
1125.Em BUFQ_READPRIO .
1126.El
1127.Ss Miscellaneous Options
1128.Bl -ohang
1129.It Cd options LKM
1130Enable loadable kernel modules.
1131See
1132.Xr lkm 4
1133for details.
1134.Em NOTE :
1135not available on all architectures.
1136.It Cd options MEMORY_DISK_DYNAMIC
1137This option makes the
1138.Xr md 4
1139.Tn RAM
1140disk size dynamically sized.
1141It is incompatible with
1142.Xr mdsetimage 8 .
1143.It Cd options MEMORY_DISK_HOOKS
1144This option allows for some machine dependent functions to be called when
1145the
1146.Xr md 4
1147.Tn RAM
1148disk driver is configured.
1149This can result in automatically loading a
1150.Tn RAM
1151disk from floppy on open (among other things).
1152.It Cd options MEMORY_DISK_IS_ROOT
1153Forces the
1154.Xr md 4
1155.Tn RAM
1156disk to be the root device.
1157This can only be overridden when
1158the kernel is booted in the 'ask-for-root' mode.
1159.It Cd options MEMORY_DISK_ROOT_SIZE=integer
1160Allocates the given number of 512 byte blocks as memory for the
1161.Xr md 4
1162.Tn RAM
1163disk, to be populated with
1164.Xr mdsetimage 8 .
1165.It Cd options MEMORY_DISK_SERVER=0
1166Do not include the interface to a userland memory disk server process.
1167Per default, this option is set to 1, including the support code.
1168Useful for install media kernels.
1169.It Cd options VND_COMPRESSION
1170Enables the
1171.Xr vnd 4
1172driver to also handle compressed images.
1173See
1174.Xr vndcompress 1 ,
1175.Xr vnd 4
1176and
1177.Xr vnconfig 8
1178for more information.
1179.It Cd options MALLOC_NOINLINE
1180Time critical fixed size memory allocation is performed with
1181.Fn MALLOC
1182and
1183.Fn FREE .
1184Normally these expand to inline code, but with
1185.Em MALLOC_NOINLINE
1186these call the normal
1187.Fn malloc
1188and
1189.Fn free
1190functions.
1191Useful for install media kernels, small memory systems and embedded systems.
1192.It Cd options HZ=integer
1193On ports that support it, set the system clock frequency (see
1194.Xr hz 9 )
1195to the supplied value.
1196Handle with care.
1197.It Cd options NTP
1198Turns on in-kernel precision timekeeping support used by software
1199implementing
1200.Em NTP
1201(Network Time Protocol, RFC 1305).
1202The
1203.Em NTP
1204option adds an in-kernel Phase-Locked Loop (PLL) for normal
1205.Em NTP
1206operation, and a Frequency-Locked Loop (FLL) for intermittently-connected
1207operation.
1208.Xr ntpd 8
1209will employ a user-level PLL when kernel support is unavailable,
1210but the in-kernel version has lower latency and more precision, and
1211so typically keeps much better time.
1212The interface to the kernel
1213.Em NTP
1214support is provided by the
1215.Xr ntp_adjtime 2
1216and
1217.Xr ntp_gettime 2
1218system calls, which are intended for use by
1219.Xr ntpd 8
1220and are enabled by the option.
1221On systems with sub-microsecond resolution timers, or where (HZ / 100000)
1222is not an integer, the
1223.Em NTP
1224option also enables extended-precision arithmetic to keep track of
1225fractional clock ticks at NTP time-format precision.
1226.It Cd options PPS_SYNC
1227This option enables a kernel serial line discipline for receiving time
1228phase signals from an external reference clock such as a radio clock.
1229(The
1230.Em NTP
1231option (which see) must be on if the
1232.Em PPS_SYNC
1233option is used.)
1234Some reference clocks generate a Pulse Per Second (PPS) signal in
1235phase with their time source.
1236The
1237.Em PPS
1238line discipline receives this signal on either the data leads
1239or the DCD control lead of a serial port.
1240.Em NTP
1241uses the PPS signal to discipline the local clock oscillator to a high
1242degree of precision (typically less than 50 microseconds in time and
12430.1 ppm in accuracy).
1244.Em PPS
1245can also generate a serial output pulse when the system receives a PPS
1246interrupt.
1247This can be used to measure the system interrupt latency and thus calibrate
1248.Em NTP
1249to account for it.
1250Using
1251.Em PPS
1252usually requires a
1253gadget box
1254to convert from TTL to RS-232 signal levels.
1255The gadget box and PPS are described in more detail in the HTML documentation
1256for
1257.Xr ntpd 8
1258in
1259.Pa /usr/share/doc/html/ntp .
1260.It Cd options NO_TSC_TIME
1261Don't use TSC microtime, even if available (i386 only).
1262Improves time behavior under VMware.
1263.It Cd options SETUIDSCRIPTS
1264Allows scripts with the setuid bit set to execute as the effective
1265user rather than the real user, just like binary executables.
1266.Pp
1267.Em NOTE :
1268Using this option will also enable
1269.Em options FDSCRIPTS
1270.It Cd options FDSCRIPTS
1271Allows execution of scripts with the execute bit set, but not the
1272read bit, by opening the file and passing the file descriptor to
1273the shell, rather than the filename.
1274.Pp
1275.Em NOTE :
1276Execute only (non-readable) scripts will have
1277.Va argv[0]
1278set to
1279.Pa /dev/fd/* .
1280What this option allows as far as security is
1281concerned, is the ability to safely ensure that the correct script
1282is run by the interpreter, as it is passed as an already open file.
1283.It Cd options PUCCN
1284Enables treating serial ports found on PCI boards
1285.Xr puc 4
1286as potential console devices.
1287The method for choosing such a console device is port dependent.
1288.It Cd options RTC_OFFSET=integer
1289The kernel (and typically the hardware battery backed-up clock on
1290those machines that have one) keeps time in
1291.Em UTC
1292(Universal Coordinated Time, once known as
1293.Em GMT ,
1294or Greenwich Mean Time)
1295and not in the time of the local time zone.
1296The
1297.Em RTC_OFFSET
1298option is used on some ports (such as the i386) to tell the kernel
1299that the hardware clock is offset from
1300.Em UTC
1301by the specified number of minutes.
1302This is typically used when a machine boots several operating
1303systems and one of them wants the hardware clock to run in the
1304local time zone and not in
1305.Em UTC ,
1306e.g.
1307.Em RTC_OFFSET=300
1308means
1309the hardware clock is set to US Eastern Time (300 minutes behind
1310.Em UTC ) ,
1311and not
1312.Em UTC .
1313(Note:
1314.Em RTC_OFFSET
1315is used to initialize a kernel variable named
1316.Va rtc_offset
1317which is the source actually used to determine the clock offset, and
1318which may be accessed via the kern.rtc_offset sysctl variable.
1319See
1320.Xr sysctl 8
1321and
1322.Xr sysctl 3
1323for details.
1324Since the kernel clock is initialized from the hardware clock very
1325early in the boot process, it is not possible to meaningfully change
1326.Va rtc_offset
1327in system initialization scripts.
1328Changing this value currently may only be done at kernel compile
1329time or by patching the kernel and rebooting).
1330.Pp
1331.Em NOTE :
1332Unfortunately, in many cases where the hardware clock
1333is kept in local time, it is adjusted for Daylight Savings
1334Time; this means that attempting to use
1335.Em RTC_OFFSET
1336to let
1337.Nx
1338coexist with such an operating system, like Windows,
1339would necessitate changing
1340.Em RTC_OFFSET
1341twice a year.
1342As such, this solution is imperfect.
1343.It Cd options KMEMSTATS
1344The kernel memory allocator,
1345.Xr malloc 9 ,
1346will keep statistics on its performance if this option is enabled.
1347Unfortunately, this option therefore essentially disables the
1348.Fn MALLOC
1349and
1350.Fn FREE
1351forms of the memory allocator, which are used to enhance the performance
1352of certain critical sections of code in the kernel.
1353This option therefore can lead to a significant decrease in the
1354performance of certain code in the kernel if enabled.
1355Examples of such code include the
1356.Fn namei
1357routine, the
1358.Xr ccd 4
1359driver,
1360and much of the networking code.
1361.It Cd options MAXUPRC=integer
1362Sets the soft
1363.Dv RLIMIT_NPROC
1364resource limit, which specifies the maximum number of simultaneous
1365processes a user is permitted to run, for process 0;
1366this value is inherited by its child processes.
1367It defaults to
1368.Em CHILD_MAX ,
1369which is currently defined to be 160.
1370Setting
1371.Em MAXUPRC
1372to a value less than
1373.Em CHILD_MAX
1374is not permitted, as this would result in a violation of the semantics of
1375.St -p1003.1-90 .
1376.It Cd options NOFILE=integer
1377Sets the soft
1378.Dv RLIMIT_NOFILE
1379resource limit, which specifies the maximum number of open
1380file descriptors for each process;
1381this value is inherited by its child processes.
1382It defaults to
1383.Em OPEN_MAX ,
1384which is currently defined to be 64.
1385.It Cd options MAXFILES=integer
1386Sets the default value of the
1387.Em kern.maxfiles
1388sysctl variable, which indicates the maximum number of files that may
1389be open in the system.
1390.It Cd options DEFCORENAME=string
1391Sets the default value of the
1392.Em kern.defcorename
1393sysctl variable, otherwise it is set to
1394.Nm %n.core .
1395See
1396.Xr sysctl 8
1397and
1398.Xr sysctl 3
1399for details.
1400.It Cd options RASOPS_CLIPPING
1401Enables clipping within the
1402.Nm rasops
1403raster-console output system.
1404.Em NOTE :
1405only available on architectures that use
1406.Nm rasops
1407for console output.
1408.It Cd options RASOPS_SMALL
1409Removes optimized character writing code from the
1410.Nm rasops
1411raster-console output system.
1412.Em NOTE :
1413only available on architectures that use
1414.Nm rasops
1415for console output.
1416.It Cd options INCLUDE_CONFIG_FILE
1417Embeds the kernel config file used to define the kernel in the kernel
1418binary itself.
1419The embedded data also includes any files directly included by the config
1420file itself, e.g.
1421.Pa GENERIC.local
1422or
1423.Pa std.$MACHINE .
1424The embedded config file can be extracted from the resulting kernel with
1425.Xr config 1
1426.Fl x ,
1427or by the following command:
1428.Bd -literal -offset indent
1429strings netbsd | sed -n 's/^_CFG_//p' | unvis
1430.Ed
1431.It Cd options INCLUDE_JUST_CONFIG
1432Similar to the above option, but includes just the actual config file,
1433not any included files.
1434.It Cd options PIPE_SOCKETPAIR
1435Use slower, but smaller socketpair(2)-based pipe implementation instead
1436of default faster, but bigger one.
1437Primarily useful for installation kernels.
1438.It Cd options USERCONF
1439Compiles in the in-kernel device configuration manager.
1440See
1441.Xr userconf 4
1442for details.
1443.It Cd options PERFCTRS
1444Compiles in kernel support for CPU performance-monitoring counters.
1445See
1446.Xr pmc 1
1447for details.
1448.Em NOTE :
1449not available on all architectures.
1450.It Cd options XSERVER
1451Compiles in kernel support for
1452.Tn X11
1453on architectures that still use (or can use) the legacy
1454.Em pccons
1455console drivers rather than
1456.Xr wscons 4 .
1457These include bebox, i386, shark.
1458.It Cd options XSERVER_DDB
1459A supplement to XSERVER that adds support for entering
1460.Xr ddb 4
1461while in
1462.Tn X11 .
1463.El
1464.Ss Networking Options
1465.Bl -ohang
1466.It Cd options GATEWAY
1467Enables
1468.Em IPFORWARDING
1469(which see)
1470and (on most ports) increases the size of
1471.Em NMBCLUSTERS
1472(which see).
1473In general,
1474.Em GATEWAY
1475is used to indicate that a system should act as a router, and
1476.Em IPFORWARDING
1477is not invoked directly.
1478(Note that
1479.Em GATEWAY
1480has no impact on protocols other than
1481.Tn IP ,
1482such as
1483.Tn CLNP
1484or
1485.Tn XNS ) .
1486.Em GATEWAY
1487option also compiles IPv4 fast forwarding code into the kernel.
1488.It Cd options ICMPPRINTFS
1489The
1490.Em ICMPPRINTFS
1491option will enable debugging information to be printed about
1492the
1493.Xr icmp 4
1494protocol.
1495.It Cd options IPFORWARDING=value
1496If
1497.Em value
1498is 1 this enables IP routing behavior.
1499If
1500.Em value
1501is 0 (the default), it disables it.
1502The
1503.Em GATEWAY
1504option sets this to 1 automatically.
1505With this option enabled, the machine will forward IP datagrams destined
1506for other machines between its interfaces.
1507Note that even without this option, the kernel will
1508still forward some packets (such as source routed packets) -- removing
1509.Em GATEWAY
1510and
1511.Em IPFORWARDING
1512is insufficient to stop all routing through a bastion host on a
1513firewall -- source routing is controlled independently.
1514To turn off source routing, use
1515.Em options IPFORWSRCRT=0
1516(which see).
1517Note that IP forwarding may be turned on and off independently of the
1518setting of the
1519.Em IPFORWARDING
1520option through the use of the
1521.Em net.inet.ip.forwarding
1522sysctl variable.
1523If
1524.Em net.inet.ip.forwarding
1525is 1, IP forwarding is on.
1526See
1527.Xr sysctl 8
1528and
1529.Xr sysctl 3
1530for details.
1531.It Cd options IPFORWSRCRT=value
1532If
1533.Em value
1534is set to zero, source routing of IP datagrams is turned off.
1535If
1536.Em value
1537is set to one (the default) or the option is absent, source routed IP
1538datagrams are forwarded by the machine.
1539Note that source routing of IP packets may be turned on and off
1540independently of the setting of the
1541.Em IPFORWSRCRT
1542option through the use of the
1543.Em net.inet.ip.forwsrcrt
1544sysctl variable.
1545If
1546.Em net.inet.ip.forwsrcrt
1547is 1, forwarding of source routed IP datagrams is on.
1548See
1549.Xr sysctl 8
1550and
1551.Xr sysctl 3
1552for details.
1553.It Cd options IFA_STATS
1554Tells the kernel to maintain per-address statistics on bytes sent
1555and received over (currently) internet and appletalk addresses.
1556.\"This can be a fairly expensive operation, so you probably want to
1557.\"keep this disabled.
1558The option is not recommended as it degrades system stability.
1559.It Cd options IFQ_MAXLEN=value
1560Increases the allowed size of the network interface packet queues.
1561The default queue size is 50 packets, and you do not normally need
1562to increase it.
1563.It Cd options MROUTING
1564Includes support for IP multicast routers.
1565You certainly want
1566.Em INET
1567with this.
1568Multicast routing is controlled by the
1569.Xr mrouted 8
1570daemon.
1571See also option
1572.Cd PIM .
1573.It Cd options PIM
1574Includes support for Protocol Independent Multicast (PIM) routing.
1575You need
1576.Em MROUTING
1577and
1578.Em INET
1579with this.
1580Software using this can be found e.g. in
1581.Pa pkgsrc/net/xorp .
1582.It Cd options INET
1583Includes support for the
1584.Tn TCP/IP
1585protocol stack.
1586You almost certainly want this.
1587See
1588.Xr inet 4
1589for details.
1590.It Cd options INET6
1591Includes support for the
1592.Tn IPv6
1593protocol stack.
1594See
1595.Xr inet6 4
1596for details.
1597Unlike
1598.Em INET ,
1599.Em INET6
1600enables multicast routing code as well.
1601This option requires
1602.Em INET
1603at this moment, but it should not.
1604.It Cd options ND6_DEBUG
1605The option sets the default value of net.inet6.icmp6.nd6_debug to 1,
1606for debugging IPv6 neighbor discovery protocol handling.
1607See
1608.Xr sysctl 3
1609for details.
1610.It Cd options IPSEC
1611Includes support for the
1612.Tn IPsec
1613protocol.
1614See
1615.Xr ipsec 4
1616for details.
1617.It Cd options IPSEC_DEBUG
1618Enables debugging code in
1619.Tn IPsec
1620stack.
1621See
1622.Xr ipsec 4
1623for details.
1624.It Cd options IPSEC_ESP
1625Includes support for
1626.Tn IPsec
1627.Tn ESP
1628protocol.
1629See
1630.Xr ipsec 4
1631for details.
1632.It Cd options IPSEC_NAT_T
1633Includes support for
1634.Tn IPsec
1635Network Address Translator traversal (NAT-T), as described in RFCs 3947
1636and 3948.
1637This feature might be patent-encumbered in some countries.
1638.It Cd options ALTQ
1639Enabled ALTQ (Alternate Queueing).
1640For simple rate-limiting, use
1641.Xr tbrconfig 8
1642to set up the interface transmission rate.
1643To use queueing disciplines, their appropriate kernel options should also
1644be defined (documented below).
1645Queueing disciplines are managed by
1646.Xr altqd 8 .
1647See
1648.Xr altq 9
1649for details.
1650.It Cd options ALTQ_HFSC
1651Include support for ALTQ-implemented HFSC (Hierarchical Fair Service Curve)
1652module.
1653HFSC supports both link-sharing and guaranteed real-time services.
1654HFSC employs a service curve based QoS model, and its unique feature
1655is an ability to decouple delay and bandwidth allocation.
1656Requires
1657.Em ALTQ_RED
1658to use the RED queueing discipline on HFSC classes, or
1659.Em ALTQ_RIO
1660to use the RIO queueing discipline on HFSC classes.
1661This option assumes
1662.Em ALTQ .
1663.It Cd options ALTQ_PRIQ
1664Include support for ALTQ-implemented PRIQ (Priority Queueing).
1665PRIQ implements a simple priority-based queueing discipline.
1666A higher priority class is always served first.
1667Requires
1668.Em ALTQ_RED
1669to use the RED queueing discipline on HFSC classes, or
1670.Em ALTQ_RIO
1671to use the RIO queueing discipline on HFSC classes.
1672This option assumes
1673.Em ALTQ .
1674.It Cd options ALTQ_WFQ
1675Include support for ALTQ-implemented WFQ (Weighted Fair Queueing).
1676WFQ implements a weighted-round robin scheduler for a set of queues.
1677A weight can be assigned to each queue to give a different proportion
1678of the link capacity.
1679A hash function is used to map a flow to one of a set of queues.
1680This option assumes
1681.Em ALTQ .
1682.It Cd options ALTQ_FIFOQ
1683Include support for ALTQ-implemented FIFO queueing.
1684FIFOQ is a simple drop-tail FIFO (First In, First Out) queueing discipline.
1685This option assumes
1686.Em ALTQ .
1687.It Cd options ALTQ_RIO
1688Include support for ALTQ-implemented RIO (RED with In/Out).
1689The original RIO has 2 sets of RED parameters; one for in-profile
1690packets and the other for out-of-profile packets.
1691At the ingress of the network, profile meters tag packets as IN or
1692OUT based on contracted profiles for customers.
1693Inside the network, IN packets receive preferential treatment by
1694the RIO dropper.
1695ALTQ/RIO has 3 drop precedence levels defined for the Assured Forwarding
1696PHB of DiffServ (RFC 2597).
1697This option assumes
1698.Em ALTQ .
1699.It Cd options ALTQ_BLUE
1700Include support for ALTQ-implemented Blue buffer management.
1701Blue is another active buffer management mechanism.
1702This option assumes
1703.Em ALTQ .
1704.It Cd options ALTQ_FLOWVALVE
1705Include support for ALTQ-implemented Flowvalve.
1706Flowvalve is a simple implementation of a RED penalty box that identifies
1707and punishes misbehaving flows.
1708This option requires
1709.Em ALTQ_RED
1710and assumes
1711.Em ALTQ .
1712.It Cd options ALTQ_CDNR
1713Include support for ALTQ-implemented CDNR (diffserv traffic conditioner)
1714packet marking/manipulation.
1715Traffic conditioners are components to meter, mark, or drop incoming
1716packets according to some rules.
1717As opposed to queueing disciplines, traffic conditioners handle incoming
1718packets at an input interface.
1719This option assumes
1720.Em ALTQ .
1721.It Cd options ALTQ_NOPCC
1722Disables use of processor cycle counter to measure time in ALTQ.
1723This option should be defined for a non-Pentium i386 CPU which does not
1724have TSC, SMP (per-CPU counters are not in sync), or power management
1725which affects processor cycle counter.
1726This option assumes
1727.Em ALTQ .
1728.It Cd options ALTQ_IPSEC
1729Include support for IPsec in IPv4 ALTQ.
1730This option assumes
1731.Em ALTQ .
1732.It Cd options ALTQ_JOBS
1733Undocumented at this time.
1734.It Cd options ALTQ_AFMAP
1735Include support for an undocumented ALTQ feature that is used to map an IP
1736flow to an ATM VC (Virtual Circuit).
1737This option assumes
1738.Em ALTQ .
1739.It Cd options ALTQ_LOCALQ
1740Include support for ALTQ-implemented local queues.
1741Its practical use is undefined.
1742Assumes
1743.Em ALTQ .
1744.It Cd options SUBNETSARELOCAL
1745Sets default value for net.inet.ip.subnetsarelocal variable, which
1746controls whether non-directly-connected subnets of connected networks
1747are considered "local" for purposes of choosing the MSS for a TCP
1748connection.
1749This is mostly present for historic reasons and completely irrelevant if
1750you enable Path MTU discovery.
1751.It Cd options HOSTZEROBROADCAST
1752Sets default value for net.inet.ip.hostzerobroadcast variable, which
1753controls whether the zeroth host address of each connected subnet is
1754also considered a broadcast address.
1755Default value is "1", for compatibility with old systems; if this is
1756set to zero on all hosts on a subnet, you should be able to fit an extra
1757host per subnet on the
1758".0" address.
1759.It Cd options MCLSHIFT=value
1760This option is the base-2 logarithm of the size of mbuf clusters.
1761The
1762.Bx
1763networking stack keeps network packets in a linked
1764list, or chain, of kernel buffer objects called mbufs.
1765The system provides larger mbuf clusters as an optimization for
1766large packets, instead of using long chains for large packets.
1767The mbuf cluster size,
1768or
1769.Em MCLBYTES ,
1770must be a power of two, and is computed as two raised to the power
1771.Em MCLSHIFT .
1772On systems with Ethernet network adaptors,
1773.Em MCLSHIFT
1774is often set to 11, giving 2048-byte mbuf clusters, large enough to
1775hold a 1500-byte
1776.Tn Ethernet
1777frame in a single cluster.
1778Systems with network interfaces supporting larger frame sizes like
1779.Tn ATM ,
1780.Tn FDDI ,
1781or
1782.Tn HIPPI
1783may perform better with
1784.Em MCLSHIFT
1785set to 12 or 13, giving mbuf cluster sizes of 4096 and 8192 bytes,
1786respectively.
1787.It Cd options NS
1788Include support for the
1789.Tn Xerox
1790.Tn XNS
1791protocol stack.
1792See
1793.Xr ns 4
1794for details.
1795.It Cd options ISO,TPIP
1796Include support for the ubiquitous
1797.Tn OSI
1798protocol stack.
1799See
1800.Xr iso 4
1801for details.
1802This option assumes
1803.Em INET .
1804.It Cd options EON
1805Include support for tunneling
1806.Tn OSI
1807protocols over
1808.Tn IP .
1809Known to be broken, or at least very fragile, and undocumented.
1810.It Cd options CCITT,LLC,HDLC
1811Include support for the
1812.Tn CCITT
1813(nee
1814.Tn ITU-TSS )
1815.Tn X.25
1816protocol stack.
1817The state of this code is currently unknown, and probably contains bugs.
1818This option assumes
1819.Em INET .
1820.It Cd options NETATALK
1821Include support for the
1822.Tn AppleTalk
1823protocol stack.
1824The kernel provides provision for the
1825.Em Datagram Delivery Protocol
1826(DDP), providing SOCK_DGRAM support and
1827.Tn AppleTalk
1828routing.
1829This stack is used by the
1830.Em NETATALK
1831package, which adds support for
1832.Tn AppleTalk
1833server services via user libraries and applications.
1834.It Cd options BLUETOOTH
1835Include support for the
1836.Tn Bluetooth
1837protocol stack. See
1838.Xr bluetooth 4
1839for details.
1840.It Cd options IPNOPRIVPORTS
1841Normally, only root can bind a socket descriptor to a so-called
1842.Dq privileged
1843.Tn TCP
1844port, that is, a port number in the range 0-1023.
1845This option eliminates those checks from the kernel.
1846This can be useful if there is a desire to allow daemons without
1847privileges to bind those ports, e.g., on firewalls.
1848The security tradeoffs in doing this are subtle.
1849This option should only be used by experts.
1850.It Cd options TCP_COMPAT_42
1851.Tn TCP
1852bug compatibility with
1853.Bx 4.2 .
1854In
1855.Bx 4.2 ,
1856.Tn TCP
1857sequence numbers were 32-bit signed values.
1858Modern implementations of TCP use unsigned values.
1859This option clamps the initial sequence number to start in
1860the range 2^31 rather than the full unsigned range of 2^32.
1861Also, under
1862.Bx 4.2 ,
1863keepalive packets must contain at least one byte or else
1864the remote end would not respond.
1865.It Cd options TCP_DEBUG
1866Record the last
1867.Em TCP_NDEBUG
1868TCP packets with SO_DEBUG set, and decode to the console if
1869.Em tcpconsdebug
1870is set.
1871.It Cd options TCP_NDEBUG
1872Number of packets to record for
1873.Em TCP_DEBUG .
1874Defaults to 100.
1875.It Cd options TCP_SENDSPACE=value
1876.It Cd options TCP_RECVSPACE=value
1877These options set the max TCP window size to other sizes than the default.
1878The TCP window sizes can be altered via
1879.Xr sysctl 8
1880as well.
1881.It Cd options TCP_INIT_WIN=value
1882This option sets the initial TCP window size for non-local connections,
1883which is used when the transmission starts.
1884The default size is 1, but if the machine should act more aggressively,
1885the initial size can be set to some other value.
1886The initial TCP window size can be set via
1887.Xr sysctl 8
1888as well.
1889.It Cd options PFIL_HOOKS
1890This option turns on the packet filter interface hooks.
1891See
1892.Xr pfil 9
1893for details.
1894This option assumes
1895.Em INET .
1896.It Cd options IPFILTER_LOG
1897This option, in conjunction with
1898.Em pseudo-device ipfilter ,
1899enables logging of IP packets using ip-filter.
1900.It Cd options IPFILTER_DEFAULT_BLOCK
1901This option sets the default policy of ip-filter.
1902If it is set, ip-filter will block packets by default.
1903.It Cd options BRIDGE_IPF
1904This option causes
1905.Em bridge
1906devices to use the IP and/or IPv6 filtering hooks, forming
1907a link-layer filter that uses protocol-layer rules.
1908This option assumes the presence of
1909.Em pseudo-device ipfilter .
1910.It Cd options MBUFTRACE
1911This option can help track down mbuf leaks.
1912When enabled, mbufs are tagged with the devices and protocols using them,
1913which slightly decreases network performance.
1914This additional information can be viewed with
1915.Xr netstat 1 :
1916.Dl Ic netstat Fl mssv
1917Not all devices or protocols support this option.
1918.El
1919.Ss Sysctl Related Options
1920.Bl -ohang
1921.It Cd options SYSCTL_DISALLOW_CREATE
1922Disallows the creation or deletion of nodes from the sysctl tree, as
1923well as the assigning of descriptions to nodes that lack them, by any
1924process.
1925These operations are still available to kernel sub-systems, including
1926loadable kernel modules.
1927.It Cd options SYSCTL_DISALLOW_KWRITE
1928Prevents processes from adding nodes to the sysctl tree that make
1929existing kernel memory areas writeable.
1930Sections of kernel memory can still be read and new nodes that own
1931their own data may still be writeable.
1932.It Cd options SYSCTL_DEBUG_SETUP
1933Causes the SYSCTL_SETUP routines to print a brief message when they
1934are invoked.
1935This is merely meant as an aid in determining the order in which
1936sections of the tree are created.
1937.It Cd options SYSCTL_DEBUG_CREATE
1938Prints a message each time
1939.Fn sysctl_create ,
1940the function that adds nodes to the tree, is called.
1941.It Cd options SYSCTL_INCLUDE_DESCR
1942Causes the kernel to include short, human readable descriptions for
1943nodes in the sysctl tree.
1944The descriptions can be retrieved programmatically (see
1945.Xr sysctl 3 ) ,
1946or by the sysctl binary itself (see
1947.Xr sysctl 8 ) .
1948The descriptions are meant to give an indication of the purpose and/or
1949effects of a given node's value, not replace the documentation for the
1950given subsystem as a whole.
1951.El
1952.Ss System V IPC Options
1953.Bl -ohang
1954.It Cd options SYSVMSG
1955Includes support for
1956.At V
1957style message queues.
1958See
1959.Xr msgctl 2 ,
1960.Xr msgget 2 ,
1961.Xr msgrcv 2 ,
1962.Xr msgsnd 2 .
1963.It Cd options SYSVSEM
1964Includes support for
1965.At V
1966style semaphores.
1967See
1968.Xr semctl 2 ,
1969.Xr semget 2 ,
1970.Xr semop 2 .
1971.It Cd options SEMMNI=value
1972Sets the number of
1973.At V
1974style semaphore identifiers.
1975The GENERIC config file for your port will have the default.
1976.It Cd options SEMMNS=value
1977Sets the number of
1978.At V
1979style semaphores in the system.
1980The GENERIC config file for your port will have the default.
1981.It Cd options SEMUME=value
1982Sets the maximum number of undo entries per process for
1983.At V
1984style semaphores.
1985The GENERIC config file for your port will have the default.
1986.It Cd options SEMMNU=value
1987Sets the number of undo structures in the system for
1988.At V
1989style semaphores.
1990The GENERIC config file for your port will have the default.
1991.It Cd options SYSVSHM
1992Includes support for
1993.At V
1994style shared memory.
1995See
1996.Xr shmat 2 ,
1997.Xr shmctl 2 ,
1998.Xr shmdt 2 ,
1999.Xr shmget 2 .
2000.It Cd options SHMMAXPGS=value
2001Sets the maximum number of
2002.At V
2003style shared memory pages that are available through the
2004.Xr shmget 2
2005system call.
2006Default value is 1024 on most ports.
2007See
2008.Pa /usr/include/machine/vmparam.h
2009for the default.
2010.El
2011.Ss VM Related Options
2012.Bl -ohang
2013.It Cd options NMBCLUSTERS=value
2014The number of mbuf clusters the kernel supports.
2015Mbuf clusters are MCLBYTES in size (usually 2k).
2016This is used to compute the size of the kernel VM map
2017.Em mb_map ,
2018which maps mbuf clusters.
2019Default on most ports is 1024 (2048 with
2020.Dq options GATEWAY
2021).
2022See
2023.Pa /usr/include/machine/param.h
2024for exact default information.
2025Increase this value if you get
2026.Dq mclpool limit reached
2027messages.
2028.It Cd options NKMEMPAGES=value
2029.It Cd options NKMEMPAGES_MIN=value
2030.It Cd options NKMEMPAGES_MAX=value
2031Size of kernel VM map
2032.Em kmem_map ,
2033in PAGE_SIZE-sized chunks (the VM page size; this value may be read
2034from the
2035.Xr sysctl 8
2036variable
2037.Em hw.pagesize
2038).
2039This VM map is used to map the kernel malloc arena.
2040The kernel attempts to auto-size this map based on the amount of
2041physical memory in the system.
2042Platform-specific code may place bounds on this computed size,
2043which may be viewed with the
2044.Xr sysctl 8
2045variable
2046.Em vm.nkmempages .
2047See
2048.Pa /usr/include/machine/param.h
2049for the default upper and lower bounds.
2050The related options
2051.Sq NKMEMPAGES_MIN
2052and
2053.Sq NKMEMPAGES_MAX
2054allow the bounds to be overridden in the kernel configuration file.
2055These options are provided in the event the computed value is
2056insufficient resulting in an
2057.Dq out of space in kmem_map
2058panic.
2059.It Cd options SB_MAX=value
2060Sets the max size in bytes that a socket buffer is allowed to occupy.
2061The default is 256k, but sometimes it needs to be increased, for example
2062when using large TCP windows.
2063This option can be changed via
2064.Xr sysctl 8
2065as well.
2066.It Cd options SOMAXKVA=value
2067Sets the maximum size of kernel virtual memory that the socket buffers
2068are allowed to use.
2069The default is 16MB, but in situations where for example large TCP
2070windows are used this value must also be increased.
2071This option can be changed via
2072.Xr sysctl 8
2073as well.
2074.It Cd options BUFCACHE=value
2075Size of the buffer cache as a percentage of total available
2076.Tn RAM .
2077Ignored if BUFPAGES is also specified.
2078.It Cd options NBUF=value
2079Sets the number of buffer headers available, i.e., the number of
2080open files that may have a buffer cache entry.
2081Each buffer header
2082requires MAXBSIZE (machine dependent, but usually 65536) bytes.
2083The default value is machine dependent, but is usually equal to the
2084value of BUFPAGES.
2085If an architecture dependent VM_MAX_KERNEL_BUF constant is defined
2086then NBUF may be reduced at run time so that the storage allocated
2087for buffer headers doesn't exceed that limit.
2088.It Cd options BUFPAGES=value
2089These options set the number of pages available for the buffer cache.
2090Their default value is a machine dependent value, often calculated as
2091between 5% and 10% of total available
2092.Tn RAM .
2093.It Cd options MAXTSIZ=bytes
2094Sets the maximum size limit of a process' text segment.
2095See
2096.Pa /usr/include/machine/vmparam.h
2097for the port-specific default.
2098.It Cd options DFLDSIZ=bytes
2099Sets the default size limit of a process' data segment, the value that
2100will be returned as the soft limit for
2101.Dv RLIMIT_DATA
2102(as returned by
2103.Xr getrlimit 2 ) .
2104See
2105.Pa /usr/include/machine/vmparam.h
2106for the port-specific default.
2107.It Cd options MAXDSIZ=bytes
2108Sets the maximum size limit of a process' data segment, the value that
2109will be returned as the hard limit for
2110.Dv RLIMIT_DATA
2111(as returned by
2112.Xr getrlimit 2 ) .
2113See
2114.Pa /usr/include/machine/vmparam.h
2115for the port-specific default.
2116.It Cd options DFLSSIZ=bytes
2117Sets the default size limit of a process' stack segment, the value that
2118will be returned as the soft limit for
2119.Dv RLIMIT_STACK
2120(as returned by
2121.Xr getrlimit 2 ) .
2122See
2123.Pa /usr/include/machine/vmparam.h
2124for the port-specific default.
2125.It Cd options MAXSSIZ=bytes
2126Sets the maximum size limit of a process' stack segment, the value that
2127will be returned as the hard limit for
2128.Dv RLIMIT_STACK
2129(as returned by
2130.Xr getrlimit 2 ) .
2131See
2132.Pa /usr/include/machine/vmparam.h
2133for the port-specific default.
2134.It Cd options DUMP_ON_PANIC=integer
2135Defaults to one.
2136If set to zero, the kernel will not dump to the dump device when
2137it panics, though dumps can still be forced via
2138.Xr ddb 4
2139with the
2140.Dq sync
2141command.
2142Note that this sets the value of the
2143.Em kern.dump_on_panic
2144.Xr sysctl 3
2145variable which may be changed at run time -- see
2146.Xr sysctl 8
2147for details.
2148.It Cd options USE_TOPDOWN_VM
2149User space memory allocations (as made by
2150.Xr mmap 2 )
2151will be arranged in a
2152.Dq top down
2153fashion instead of the traditional
2154.Dq upwards from MAXDSIZ \+ vm_daddr
2155method.
2156This includes the placement of
2157.Xr ld.so 1 .
2158Arranging memory in this manner allows either (or both of) the heap or
2159.Xr mmap 2
2160allocated space to grow larger than traditionally possible.
2161This option is not available on all ports, but is instead expected to be
2162offered on a port-by-port basis, after which some ports will commit to
2163using it by default.
2164See the files
2165.Pa /usr/include/uvm/uvm_param.h
2166for some implementation details, and
2167.Pa /usr/include/machine/vmparam.h
2168for port specific details including availability.
2169.It Cd options VMSWAP
2170Enable paging device/file support.
2171This option is on by default.
2172.El
2173.Ss Security Options
2174.Bl -ohang
2175.It Cd options INSECURE
2176Hardwires the kernel security level at \-1.
2177This means that the system
2178always runs in secure level \-1 mode, even when running multiuser.
2179See the manual page for
2180.Xr init 8
2181for details on the implications of this.
2182The kernel secure level may manipulated by the superuser by altering the
2183.Em kern.securelevel
2184.Xr sysctl 3
2185variable (the secure level may only be lowered by a call from process ID 1,
2186i.e.,
2187.Xr init 8 ) .
2188See also
2189.Xr sysctl 8
2190and
2191.Xr sysctl 3 .
2192.It Cd options VERIFIED_EXEC
2193Enables Veriexec, the in-kernel file integrity subsystem.
2194.It Cd options VERIFIED_EXEC_FP_MD5
2195Enables support for MD5 hashes in Veriexec.
2196.It Cd options VERIFIED_EXEC_FP_SHA1
2197Enables support for SHA1 hashes in Veriexec.
2198.It Cd options VERIFIED_EXEC_FP_RMD160
2199Enables support for RMD160 hashes in Veriexec.
2200.It Cd options VERIFIED_EXEC_FP_SHA256
2201Enables support for SHA256 hashes in Veriexec.
2202.It Cd options VERIFIED_EXEC_FP_SHA384
2203Enables support for SHA384 hashes in Veriexec.
2204.It Cd options VERIFIED_EXEC_FP_SHA512
2205Enables support for SHA512 hashes in Veriexec.
2206.It Cd options PAX_MPROTECT=value
2207Enables PaX MPROTECT,
2208.Xr mprotect 2
2209restrictions from the PaX project.
2210.Pp
2211The
2212.Ar value
2213is the default value for the
2214.Em global_protection
2215knob, see
2216.Xr sysctl 3 .
2217If 0, PaX MPROTECT will be enabled only if explicitly set on programs
2218using
2219.Xr paxctl 1 .
2220If 1, PaX MPROTECT will be enabled to all programs, and exemption can
2221be done using
2222.Xr paxctl 1 .
2223.El
2224.Ss amiga-specific Options
2225.Bl -ohang
2226.It Cd options BB060STUPIDROM
2227When the bootloader (which passes
2228.Tn AmigaOS
2229.Tn ROM
2230information) claims we have a 68060
2231.Tn CPU
2232without
2233.Tn FPU ,
2234go look into the Processor Configuration Register (PCR) to find out.
2235You need this with
2236.Tn Amiga
2237.Tn ROM Ns s
2238up to (at least) V40.xxx (OS3.1),
2239when you boot via the bootblocks and don't have a DraCo.
2240.It Cd options IOBZCLOCK=frequency
2241The IOBlix boards come with two different serial master clocks: older ones
2242use 24 MHz, newer ones use 22.1184 MHz.
2243The driver normally assumes the latter.
2244If your board uses 24 MHz, you can recompile your kernel with
2245options IOBZCLOCK=24000000
2246or patch the kernel variable
2247.Tn iobzclock
2248to the same value.
2249.It Cd options LIMITMEM=value
2250If there, limit the part of the first memory bank used by
2251.Nx
2252to value megabytes.
2253Default is unlimited.
2254.It Cd options NKPTADD=addvalue
2255.It Cd options NKPTADDSHIFT=shiftvalue
2256The
2257.Tn CPU
2258specific
2259.Tn MMU
2260table for the kernel is pre-allocated at kernel startup time.
2261Part of it is scaled with
2262.Va maxproc ,
2263to have enough room to hold the user program
2264.Tn MMU
2265tables; the second part is a fixed amount for the kernel itself.
2266.Pp
2267The third part accounts for the size of the file buffer cache.
2268Its size is either
2269.Dv NKPTADD
2270pages (if defined) or memory size in bytes divided by two to
2271the power of
2272.Dv NKPTADDSHIFT .
2273The default is undefined
2274.Dv NKPTADD
2275and
2276.Dv NKPTADDSHIFT=24 ,
2277allowing for 16 buffers per megabyte of main memory (while
2278a GENERIC kernel allocates about half of that).
2279When you get "can't get KPT page" panics, you should increase
2280.Dv NKPTADD
2281(if defined), or decrease
2282.Dv NKPTADDSHIFT
2283by one.
2284.It Cd options P5PPC68KBOARD
2285Add special support for Phase5 mixed 68k+PPC boards.
2286Currently, this only affects rebooting from
2287.Nx
2288and is only needed on 68040+PPC, not on
228968060+PPC; without this, affected machines will hang after
2290.Nx
2291has shut
2292down and will only restart after a keyboard reset or a power cycle.
2293.El
2294.Ss arm32-specific Options
2295.Bl -ohang
2296.It Cd options FRENCH_KBD
2297Include translation for French keyboards when using
2298.Em pccons
2299on a Shark.
2300.It Cd options FINNISH_KBD
2301Include translation for Finnish keyboards when using
2302.Em pccons
2303on a Shark.
2304.It Cd options GERMAN_KBD
2305Include translation for German keyboards when using
2306.Em pccons
2307on a Shark.
2308.It Cd options NORWEGIAN_KBD
2309Include translation for French keyboards when using
2310.Em pccons
2311on a Shark.
2312.El
2313.Ss atari-specific Options
2314.Bl -ohang
2315.It Cd options DISKLABEL_AHDI
2316Include support for AHDI (native Atari) disklabels.
2317.It Cd options DISKLABEL_NBDA
2318Include support for
2319.Nx Ns Tn /atari
2320labels.
2321If you don't set this option, it will be set automatically.
2322.Nx Ns Tn /atari
2323will not work without it.
2324.It Cd options FALCON_SCSI
2325Include support for the 5380-SCSI configuration as found on the Falcon.
2326.It Cd options RELOC_KERNEL
2327If set, the kernel will relocate itself to TT-RAM, if possible.
2328This will give you a slightly faster system.
2329.Em Beware
2330that on some TT030 systems,
2331the system will frequently dump with MMU-faults with this option enabled.
2332.It Cd options SERCONSOLE
2333Allow the modem1-port to act as the system-console.
2334A carrier should be active on modem1 during system boot to active
2335the console functionality.
2336.It Cd options TT_SCSI
2337Include support for the 5380-SCSI configuration as found on the TT030
2338and Hades.
2339.El
2340.Ss i386-specific Options
2341.Bl -ohang
2342.It Cd options I386_CPU,I486_CPU,I586_CPU,I686_CPU
2343Include support for a particular class of
2344.Tn CPU
2345.Po
2346.Tn i386 ,
2347.Tn i486 ,
2348.Tn Pentium ,
2349or
2350.Tn Pentium Pro
2351.Pc .
2352If the appropriate class for your
2353.Tn CPU
2354is not configured, the kernel will use the highest class available
2355that will work.
2356In general, using the correct
2357.Tn CPU
2358class will result in the best performance.
2359At least one of these options must be present.
2360.It Cd options ENHANCED_SPEEDSTEP
2361Include support for the
2362.Tn Enhanced SpeedStep Technology
2363present in newer
2364.Tn CPU Ns s .
2365.It Cd options EST_FREQ_USERWRITE
2366Allow any user to change the frequency of an
2367.Tn Enhanced SpeedStep Technology
2368capable
2369.Tn CPU .
2370.It Cd options POWERNOW_K7
2371Include support for the AMD
2372.Tn PowerNow! Technology
2373present in AMD Athlon Mobile processors.
2374.It Cd options CPURESET_DELAY=value
2375Specifies the time (in millisecond) to wait before doing a hardware reset
2376in the last phase of a reboot.
2377This gives the user a chance to see error messages from the shutdown
2378operations (like NFS unmounts, buffer cache flush, etc ...).
2379Setting this to 0 will disable the delay.
2380Default is 2 seconds.
2381.It Cd options MATH_EMULATE
2382Include the floating point emulator.
2383This is useful only for
2384.Tn CPU Ns s
2385that lack an
2386internal Floating Point Unit
2387.Pq Tn FPU
2388or co-processor.
2389.It Cd options VM86
2390Include support for virtual 8086 mode, used by
2391.Tn DOS
2392emulators and X servers to run BIOS code, e.g., for some VESA routines.
2393.It Cd options USER_LDT
2394Include i386-specific system calls for modifying the local descriptor table,
2395used by Windows emulators.
2396.It Cd options REALBASEMEM=integer
2397Overrides the base memory size passed in from the boot block.
2398(Value given in kilobytes.)
2399Use this option only if the boot block reports the size incorrectly.
2400(Note that some
2401.Tn BIOS Ns es
2402put the extended
2403.Tn BIOS
2404data area at the top of base memory, and therefore report a smaller
2405base memory size to prevent programs overwriting it.
2406This is correct behavior, and you should not use the
2407.Em REALBASEMEM
2408option to access this memory).
2409.It Cd options REALEXTMEM=integer
2410Overrides the extended memory size passed in from the boot block.
2411(Value given in kilobytes.
2412Extended memory does not include the first megabyte.)
2413Use this option only if the boot block reports the size incorrectly.
2414.It Cd options FRENCH_KBD,FINNISH_KBD,GERMAN_KBD,NORWEGIAN_KBD
2415Select a non-US keyboard layout for the
2416.Em pccons
2417console driver.
2418.It Cd options CYRIX_CACHE_WORKS
2419Relevant only to the Cyrix 486DLC CPU.
2420This option is used to turn on the cache in hold-flush mode.
2421It is not turned on by default because it is known to have problems in
2422certain motherboard implementations.
2423.It Cd options CYRIX_CACHE_REALLY_WORKS
2424Relevant only to the Cyrix 486DLC CPU.
2425This option is used to turn on the cache in write-back mode.
2426It is not turned on by default because it is known to have problems in
2427certain motherboard implementations.
2428In order for this option to take effect, option
2429.Em CYRIX_CACHE_WORKS
2430must also be specified.
2431.It Cd options PCIBIOS
2432Enable support for initializing the
2433.Tn PCI
2434bus using information from the
2435.Tn BIOS .
2436See
2437.Xr pcibios 4
2438for details.
2439.It Cd options KSTACK_CHECK_DR0
2440Detect kernel stack overflow using DR0 register.
2441This option uses DR0 register exclusively so you can't use DR0 register for
2442other purpose (e.g., hardware breakpoint) if you turn this on.
2443.It Cd options MTRR
2444Include support for accessing MTRR registers from user-space.
2445See
2446.Xr i386_get_mtrr 2 .
2447.It Cd options BEEP_ONHALT
2448Make the system speaker emit several beeps when it is completely safe to
2449power down the computer after a
2450.Xr halt 8
2451command.
2452Requires
2453.Xr sysbeep 4
2454support.
2455.It Cd options BEEP_ONHALT_COUNT=times
2456Number of times to beep the speaker when
2457.Cd options BEEP_ONHALT
2458is enabled.
2459Defaults to 3.
2460.It Cd options BEEP_ONHALT_PITCH=hz
2461The tone frequency used when
2462.Cd options BEEP_ONHALT
2463option, in hertz.
2464Defaults to 1500.
2465.It Cd options BEEP_ONHALT_PERIOD=msecs
2466The duration of each beep when
2467.Cd options BEEP_ONHALT
2468is enabled, in milliseconds.
2469Defaults to 250.
2470.It Cd options MULTIBOOT
2471Makes the kernel Multiboot-compliant, allowing it to be booted through
2472a Multiboot-compliant boot manager such as GRUB.
2473See
2474.Xr multiboot 8
2475for more information.
2476.It Cd options MULTIBOOT_SYMTAB_SPACE=nbytes
2477Space (in bytes) reserved in memory to store the kernel's symbol table.
2478If the symbol table is bigger than this space, it will not be loaded;
2479if it is smaller, the unused memory will be claimed by the kernel and
2480used normally.
2481You shouldn't need to touch this variable.
2482Defaults to 1048576 bytes (one megabyte).
2483.El
2484.Ss isa-specific Options
2485Options specific to
2486.Xr isa 4
2487busses.
2488.Bl -ohang
2489.It Cd options PCIC_ISA_ALLOC_IOBASE=address, PCIC_ISA_ALLOC_IOSIZE=size
2490Control the section of IO bus space used for PCMCIA bus space mapping.
2491Ideally the probed defaults are satisfactory, however in practice
2492that is not always the case.
2493See
2494.Xr pcmcia 4
2495for details.
2496.It Cd options PCIC_ISA_INTR_ALLOC_MASK=mask
2497Controls the allowable interrupts that may be used for
2498.Tn PCMCIA
2499devices.
2500This mask is a logical-or of power-of-2s of allowable interrupts:
2501.Bd -literal -offset 04n
2502.Em "IRQ Val      IRQ Val      IRQ Val       IRQ Val"
2503 0  0x0001    4  0x0010    8  0x0100    12  0x1000
2504 1  0x0002    5  0x0020    9  0x0200    13  0x2000
2505 2  0x0004    6  0x0040   10  0x0400    14  0x4000
2506 3  0x0008    7  0x0080   11  0x0800    15  0x8000
2507.Ed
2508.It Cd options PCKBC_CNATTACH_SELFTEST
2509Perform a self test of the keyboard controller before attaching it as a
2510console.
2511This might be necessary on machines where we boot on cold iron, and
2512pckbc refuses to talk until we request a self test.
2513Currently only the netwinder port uses it.
2514.It Cd options PCKBD_CNATTACH_MAY_FAIL
2515If this option is set the PS/2 keyboard will not be used as the console
2516if it cannot be found during boot.
2517This allows other keyboards, like USB, to be the console keyboard.
2518.It Cd options PCKBD_LAYOUT=layout
2519Sets the default keyboard layout, see
2520.Xr pckbd 4 .
2521.El
2522.Ss m68k-specific Options
2523.Bl -ohang
2524.It Cd options FPU_EMULATE
2525Include support for MC68881/MC68882 emulator.
2526.It Cd options FPSP
2527Include support for 68040 floating point.
2528.It Cd options M68020,M68030,M68040,M68060
2529Include support for a specific
2530.Tn CPU ,
2531at least one (the one you are using) should be specified.
2532.It Cd options M060SP
2533Include software support for 68060.
2534This provides emulation of unimplemented
2535integer instructions as well as emulation of unimplemented floating point
2536instructions and data types and software support for floating point traps.
2537.El
2538.Ss powerpc-specific Options (OEA Only)
2539.Bl -ohang
2540.It Cd options PMAP_MEMLIMIT=value
2541Limit the amount of memory seen by the kernel to
2542.Ar value
2543bytes.
2544.It Cd options PTEGCOUNT=value
2545Specify the size of the page table as
2546.Ar value
2547PTE groups.
2548Normally, one PTEG is allocated per physical page frame.
2549.El
2550.Ss sparc-specific Options
2551.Bl -ohang
2552.It Cd options AUDIO_DEBUG
2553Enable simple event debugging of the logging of the
2554.Xr audio 4
2555device.
2556.It Cd options BLINK
2557Enable blinking of LED.
2558Blink rate is full cycle every N seconds for
2559N \*[Lt] then current load average.
2560See
2561.Xr getloadavg 3 .
2562.\" .It Cd options COLORFONT_CACHE
2563.\" What does this do?
2564.It Cd options COUNT_SW_LEFTOVERS
2565Count how many times the sw SCSI device has left 3, 2, 1 and 0 in the
2566sw_3_leftover, sw_2_leftover, sw_1_leftover, and sw_0_leftover
2567variables accessible from
2568.Xr ddb 4 .
2569See
2570.Xr sw 4 .
2571.It Cd options DEBUG_ALIGN
2572Adds debugging messages calls when user-requested alignment fault
2573handling happens.
2574.It Cd options DEBUG_EMUL
2575Adds debugging messages calls for emulated floating point and
2576alignment fixing operations.
2577.It Cd options DEBUG_SVR4
2578Prints registers messages calls for emulated SVR4 getcontext and
2579setcontext operations.
2580See
2581.Em options COMPAT_SVR4 .
2582.It Cd options EXTREME_DEBUG
2583Adds debugging functions callable from
2584.Xr ddb 4 .
2585The debug_pagetables, test_region and print_fe_map
2586functions print information about page tables for the SUN4M
2587platforms only.
2588.It Cd options EXTREME_EXTREME_DEBUG
2589Adds extra info to
2590.Em options EXTREME_DEBUG .
2591.It Cd options FPU_CONTEXT
2592Make
2593.Em options COMPAT_SVR4
2594getcontext and setcontext include floating point registers.
2595.It Cd options MAGMA_DEBUG
2596Adds debugging messages to the
2597.Xr magma 4
2598device.
2599.It Cd options RASTERCONS_FULLSCREEN
2600Use the entire screen for the console.
2601.It Cd options RASTERCONS_SMALLFONT
2602Use the Fixed font on the console, instead of the normal font.
2603.It Cd options SUN4
2604Support sun4 class machines.
2605.It Cd options SUN4C
2606Support sun4c class machines.
2607.It Cd options SUN4M
2608Support sun4m class machines.
2609.It Cd options SUN4_MMU3L
2610.\" XXX ???
2611Enable support for sun4 3-level MMU machines.
2612.It Cd options V9
2613Enable SPARC V9 assembler in
2614.Xr ddb 4 .
2615.El
2616.Ss sparc64-specific Options
2617.Bl -ohang
2618.It Cd options AUDIO_DEBUG
2619Enable simple event debugging of the logging of the
2620.Xr audio 4
2621device.
2622.It Cd options BLINK
2623Enable blinking of LED.
2624Blink rate is full cycle every N seconds for
2625N \*[Lt] then current load average.
2626See
2627.Xr getloadavg 3 .
2628.El
2629.Ss x68k-specific Options
2630.Bl -ohang
2631.It Cd options EXTENDED_MEMORY
2632Include support for extended memory, e.g., TS-6BE16 and 060turbo on-board.
2633.It Cd options JUPITER
2634Include support for Jupiter-X MPU accelerator
2635.It Cd options ZSCONSOLE,ZSCN_SPEED=value
2636Use the built-in serial port as the system-console.
2637Speed is specified in bps, defaults to 9600.
2638.It Cd options ITE_KERNEL_ATTR=value
2639Set the kernel message attribute for ITE.
2640Value, an integer, is a logical or of the following values:
2641.Bl -tag -width 4n -compact -offset indent
2642.It 1
2643color inversed
2644.It 2
2645underlined
2646.It 4
2647bolded
2648.El
2649.El
2650.\" The following requests should be uncommented and used where appropriate.
2651.\" .Sh FILES
2652.\" .Sh EXAMPLES
2653.Sh SEE ALSO
2654.Xr config 1 ,
2655.Xr gdb 1 ,
2656.Xr ktrace 1 ,
2657.Xr pmc 1 ,
2658.Xr quota 1 ,
2659.Xr vndcompress 1 ,
2660.Xr gettimeofday 2 ,
2661.Xr i386_get_mtrr 2 ,
2662.Xr i386_iopl 2 ,
2663.Xr msgctl 2 ,
2664.Xr msgget 2 ,
2665.Xr msgrcv 2 ,
2666.Xr msgsnd 2 ,
2667.Xr ntp_adjtime 2 ,
2668.Xr ntp_gettime 2 ,
2669.Xr semctl 2 ,
2670.Xr semget 2 ,
2671.Xr semop 2 ,
2672.Xr shmat 2 ,
2673.Xr shmctl 2 ,
2674.Xr shmdt 2 ,
2675.Xr shmget 2 ,
2676.Xr sysctl 3 ,
2677.Xr apm 4 ,
2678.Xr ddb 4 ,
2679.Xr inet 4 ,
2680.Xr iso 4 ,
2681.Xr lkm 4 ,
2682.Xr md 4 ,
2683.Xr ns 4 ,
2684.Xr pcibios 4 ,
2685.Xr pcmcia 4 ,
2686.Xr ppp 4 ,
2687.Xr userconf 4 ,
2688.Xr vnd 4 ,
2689.Xr wscons 4 ,
2690.Xr config 5 ,
2691.Xr edquota 8 ,
2692.Xr init 8 ,
2693.Xr mdsetimage 8 ,
2694.Xr mount_cd9660 8 ,
2695.Xr mount_fdesc 8 ,
2696.Xr mount_kernfs 8 ,
2697.Xr mount_lfs 8 ,
2698.Xr mount_mfs 8 ,
2699.Xr mount_msdos 8 ,
2700.Xr mount_nfs 8 ,
2701.Xr mount_ntfs 8 ,
2702.Xr mount_null 8 ,
2703.Xr mount_portal 8 ,
2704.Xr mount_procfs 8 ,
2705.Xr mount_udf 8 ,
2706.Xr mount_umap 8 ,
2707.Xr mount_union 8 ,
2708.Xr mrouted 8 ,
2709.Xr newfs_lfs 8 ,
2710.Xr ntpd 8 ,
2711.Xr quotaon 8 ,
2712.Xr rpc.rquotad 8 ,
2713.Xr sysctl 8
2714.Sh HISTORY
2715The
2716.Nm
2717man page first appeared in
2718.Nx 1.3 .
2719.Sh BUGS
2720The
2721.Em EON
2722option should be a pseudo-device, and is also very fragile.
2723