xref: /netbsd/share/man/man4/options.4 (revision bf9ec67e)
1.\"	$NetBSD: options.4,v 1.168 2002/04/07 04:20:17 lukem 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 November 20, 2001
34.Os
35.Dt OPTIONS 4
36.Sh NAME
37.Nm options
38.Nd Miscellaneous kernel configuration options
39.Sh SYNOPSIS
40.Cd options ...
41.Sh DESCRIPTION
42This manual page describes a number of miscellaneous kernel
43configuration options that may be specified in a kernel config
44file.
45See
46.Xr config 8
47for information on how to configure and build kernels.
48.Em Note :
49Options are passed to the compile process as -D flags to the C
50compiler.
51.Ss Compatibility Options
52.Bl -ohang
53.It Cd options COMPAT_09
54Enable binary compatibility with
55.Nx 0.9 .
56This enables support for
5716-bit user, group, and process ids (following revisions support
5832-bit identifiers),
59It also allows the use of the deprecated
60.Xr getdomainname 3 ,
61.Xr setdomainname 3 ,
62and
63.Xr uname 3
64syscalls.
65This option also allows using numeric filesystem identifiers rather
66than strings.
67Post
68.Nx 0.9
69versions use string identifiers.
70.It Cd options COMPAT_10
71Enable binary compatibility with
72.Nx 1.0 .
73This option allows the use of the filesystem name of
74.Dq ufs
75as an alias for
76.Dq ffs .
77The name
78.Dq ffs
79should be used post 1.0 in
80.Pa /etc/fstab
81and other files.
82It also adds old syscalls for the
83.At V
84shared memory interface.
85This was changed post 1.0 to work on 64-bit architectures.
86This option also enables
87.Dq sgtty
88compatibility, without which programs using the old interface produce
89an
90.Dq inappropriate ioctl
91error, and
92.Pa /dev/io
93only works when this option is set in the kernel,
94see
95.Xr io 4
96on ports that support it.
97.It Cd options COMPAT_11
98Enable binary compatibility with
99.Nx 1.1 .
100This allows binaries running on the i386 port to gain direct access to
101the io ports by opening
102.Pa /dev/io
103read/write.
104This functionality was replaced by
105.Xr i386_iopl 2
106post 1.1.
107On the
108.Tn Atari
109port, the location of the disk label was moved after 1.1.
110When the
111.Em COMPAT_11
112option is set, the kernel will read (pre) 1.1 style disk labels as a
113last resort.
114When a disklabel is re-written, the old style label will be replaced
115with a post 1.1 style label.
116This also enables
117.Em EXEC_ELF_NOTELESS
118option.
119.It Cd options COMPAT_12
120Enable binary compatibility with
121.Nx 1.2 .
122This allows the use of old syscalls for
123.Fn reboot
124and
125.Fn swapon .
126The syscall numbers were changed post 1.2 to add functionality to the
127.Xr reboot 2
128syscall, and the new
129.Xr swapctl 2
130interface was introduced.
131This also enables
132.Em EXEC_ELF_NOTELESS
133option.
134.It Cd options COMPAT_13
135Enable binary compatibility with
136.Nx 1.3 .
137This allows the use of old syscalls for
138.Fn sigaltstack ,
139and also enables the old
140.Xr swapctl 2
141command
142.Dv SWAP_STATS
143(now called
144.Dv SWAP_OSTATS ) ,
145which does not include the
146.Fa se_path
147member of
148.Va struct swapent .
149.It Cd options COMPAT_14
150Enable binary compatibility with
151.Nx 1.4 .
152This allows some old
153.Xr ioctl 2
154on
155.Xr wscons 4
156to be performed, and allows the
157.Dv NFSSVC_BIOD
158mode of the
159.Xr nfssvc 2
160system call to be used for compatibility with the deprecated nfsiod program.
161.It Cd options COMPAT_43
162Enables compatibility with
163.Bx 4.3 .
164This adds an old syscall for
165.Xr lseek 2 .
166It also adds the ioctls for
167.Dv TIOCGETP
168and
169.Dv TIOCSETP .
170The return values for
171.Xr getpid 2 ,
172.Xr getgid 2 ,
173and
174.Xr getuid 2
175syscalls are modified as well, to return the parent's pid and
176uid as well as the current process's.
177It also enables the deprecated
178.Dv NTTYDISC
179terminal line discipline.
180It also provides backwards compatibility with
181.Dq old
182SIOC[GS]IF{ADDR,DSTADDR,BRDADDR,NETMASK} interface ioctls, including
183binary compatibility with code written before the introduction of the
184sa_len field in sockaddrs.
185It also enables
186support for some older pre
187.Bx 4.4
188socket calls.
189.It Cd options COMPAT_SVR4
190On those architectures that support it, this enables binary
191compatibility with
192.At V.4
193applications built for the same architecture.
194This currently includes the i386, m68k and sparc port.
195.It Cd options COMPAT_LINUX
196On those architectures that support it, this enables binary
197compatibility with Linux ELF and
198.Xr a.out 5
199applications built for the same architecture.
200This currently includes the alpha, i386, powerpc, and m68k
201ports. There is also a minimal support for running Linux
202binaries on Mips ports, but it is experimental at
203the moment.
204.It Cd options COMPAT_SUNOS
205On those architectures that support it, this enables binary
206compatibility with
207.Tn SunOS 4.1
208applications built for the same architecture.
209This currently includes the sparc, sparc64 and most or all m68k ports.
210Note that the sparc64 requires the
211.Em COMPAT_NETBSD32
212option for 64-bit kernels, in addition to this option.
213.It Cd options COMPAT_ULTRIX
214On those architectures that support it, this enables binary
215compatibility with
216.Tn Ultrix
217applications built for the same architecture.
218This currently is limited to the pmax.
219The functionality of this option is unknown.
220.It Cd options COMPAT_FREEBSD
221On those architectures that support it, this enables binary
222compatibility with
223.Fx
224applications built for the same architecture.
225At the moment this is limited to the i386 port.
226.It Cd options COMPAT_HPUX
227On those architectures that support it, this enables binary
228compatibility with
229.Tn HP/UX
230applications built for the same architecture.
231This is limited to the hp300 port, and has some known bugs.
232A limited set of programs do work.
233.It Cd options COMPAT_IBCS2
234On those architectures that support it, this enables binary
235compatibility with iBCS2 or SVR3 applications built for the same architecture.
236This is currently limited to the i386 and vax ports.
237.It Cd options COMPAT_IRIX
238On those architectures that support it, this enables binary
239compatibility with IRIX o32 binaries built for the same architecture.
240This feature is experimental, and it is currently limited to
241the sgimips port of
242.Nx .
243.It Cd options COMPAT_OSF1
244On those architectures that support it, this enables binary
245compatibility with
246.Tn Digital
247.Ux
248.Po
249formerly
250.Tn OSF/1
251.Pc
252applications built for the same architecture.
253This is currently limited to the alpha port.
254.It Cd options COMPAT_NOMID
255Enable compatibility with
256.Xr a.out 5
257executables that lack a machine ID.
258This includes
259.Nx 0.8 Ns 's
260ZMAGIC format, and 386BSD and BSDI's
261QMAGIC, NMAGIC, and OMAGIC
262.Xr a.out 5
263formats.
264.It Cd options COMPAT_NETBSD32
265On those architectures that support it, this enables binary
266compatibility with 32-bit applications built for the same architecture.
267This is currently limited to the sparc64 port, and only applicable for
26864-bit kernels.
269.It Cd options COMPAT_SVR4_32
270On those architectures that support it, this enables binary
271compatibility with 32-bit SVR4 applications built for the same architecture.
272This is currently limited to the sparc64 port, and only applicable for
27364-bit kernels.
274.It Cd options COMPAT_AOUT_M68K
275On m68k architectures which have switched to ELF,
276this enable binary compatibility with
277.Nx Ns Tn /m68k
278.Xr a.out 5
279executables on
280.Nx Ns Tn /m68k
281ELF kernel.
282This handles alignment incompatibility of m68k ABI between
283a.out and ELF which causes the structure padding differences.
284Currently only some system calls which use
285.Va struct stat
286are adjusted and some binaries which use
287.Xr sysctl 3
288to retrieve network details would not work properly.
289.It Cd options EXEC_ELF_NOTELESS
290Run unidentified ELF binaries as
291.Nx
292binaries.
293This might be needed for very old
294.Nx
295ELF binaries on some archs.
296These old binaries didn't contain an appropriate
297.Li .note.netbsd.ident
298section, and thus can't be identified by the kernel as
299.Nx
300binaries otherwise.
301Beware - if this option is on, the kernel would run
302.Em any
303unknown ELF binaries as if they were
304.Nx
305binaries.
306.El
307.Ss Debugging Options
308.Bl -ohang
309.It Cd options DDB
310Compiles in a kernel debugger for diagnosing kernel problems.
311See
312.Xr ddb 4
313for details.
314.Em NOTE :
315not available on all architectures.
316.It Cd options DDB_FROMCONSOLE=integer
317If set to non-zero, DDB may be entered by sending a break on a serial
318console or by a special key sequence on a graphics console.
319A value of "0" ignores console breaks or key sequences,
320It not explicitly specified, the default value is "1".
321Note that this sets the value of the
322.Em ddb.fromconsole
323.Xr sysctl 3
324variable which may be changed at run time -- see
325.Xr sysctl 8
326for details.
327.It Cd options DDB_HISTORY_SIZE=integer
328If this is non-zero, enable history editing in the kernel debugger
329and set the size of the history to this value.
330.It Cd options DDB_ONPANIC
331If set to non-zero, DDB will be entered upon kernel panic.
332The default if not specified is "1".
333Note that this sets the value of the
334.Em ddb.onpanic
335.Xr sysctl 3
336variable which may be changed at run time -- see
337.Xr sysctl 8
338for details.
339.It Cd options DDB_BREAK_CHAR=integer
340This option overrides the using break to enter the kernel debugger
341on the serial console.
342The value given will is the ascii value to be used instead.
343This is currently only supported by the com driver.
344.It Cd options KGDB
345Compiles in a remote kernel debugger stub for diagnosing kernel problems
346using the
347.Dq remote target
348feature of gdb.
349See
350.Xr gdb 1
351for details.
352.Em NOTE :
353not available on all architectures.
354.It Cd options KGDB_DEV
355Device number
356.Po
357as a
358.Dv dev_t
359.Pc
360of kgdb device.
361.It Cd options KGDB_DEVADDR
362Memory address of kgdb device.
363.It Cd options KGDB_DEVMODE
364Permissions of kgdb device.
365.It Cd options KGDB_DEVNAME
366Device name of kgdb device.
367.It Cd options KGDB_DEVRATE
368Baud rate of kgdb device.
369.It Cd makeoptions DEBUG="-g"
370The -g flag causes
371.Pa netbsd.gdb
372to be built in addition to
373.Pa netbsd .
374.Pa netbsd.gdb
375is useful for debugging kernel crash dumps with gdb.
376The command
377.Dl gdb -k
378invokes gdb in kernel debugger mode.
379See
380.Xr gdb 1
381for details.
382This also turns on
383.Em options DEBUG
384(which see).
385.It Cd options DEBUG
386Turns on miscellaneous kernel debugging.
387Since options are turned into preprocessor defines (see above),
388.Em options DEBUG
389is equivalent to doing a
390.Em #define DEBUG
391throughout the kernel.
392Much of the kernel has
393.Em #ifdef DEBUG
394conditionalized debugging code.
395Note that many parts of the kernel (typically device drivers) include their own
396.Em #ifdef XXX_DEBUG
397conditionals instead.
398This option also turns on certain other options,
399which may decrease system performance.
400.It Cd options DIAGNOSTIC
401Adds code to the kernel that does internal consistency checks.
402This code will cause the kernel to panic if corruption of internal data
403structures is detected. These checks can decrease performance up to 15%.
404.It Cd options KTRACE
405Add hooks for the system call tracing facility, which allows users to
406watch the system call invocation behavior of processes.
407See
408.Xr ktrace 1
409for details.
410.It Cd options MSGBUFSIZE=integer
411This option sets the size of the kernel message buffer.
412This buffer holds the kernel output of
413.Fn printf
414when not (yet) read by
415.Xr syslogd 8 .
416This is particularly useful when the system has crashed and you wish to lookup
417the kernel output from just before the crash.
418Also, since the autoconfig output becomes more and more verbose,
419it sometimes happens that the message buffer overflows before
420.Xr syslogd 8
421was able to read it.
422Note that not all systems are capable of obtaining a variable sized message
423buffer.
424There are also some systems on which memory contents are not preserved
425across reboots.
426.It Cd options MALLOCLOG
427Enables an event log for
428.Xr malloc 9 .
429Useful for tracking down
430.Dq Data modified on freelist
431and
432.Dq multiple free
433problems.
434.It Cd options MALLOCLOGSIZE=integer
435Defines the number of entries in the malloc log.
436Default is 100000 entries.
437.It Cd options UVMHIST
438Enables the UVM history logs, which create in-memory traces of
439various UVM activities. These logs can be displayed be calling
440.Fn uvmhist_dump
441or
442.Fn uvm_hist
443with appropriate arguments from DDB.
444See the kernel source file sys/uvm/uvm_stat.c for details.
445.It Cd options UVMHIST_PRINT
446Prints the UVM history logs on the system console as entries are added.
447Note that the output is
448.Em extremely
449voluminous, so this option is really only useful for debugging
450the very earliest parts of kernel initialization.
451.El
452.Ss File Systems
453.Bl -ohang
454.It Cd file-system FFS
455Includes code implementing the Berkeley Fast File System
456.Em ( FFS ) .
457Most machines need this if they are not running diskless.
458.It Cd file-system EXT2FS
459Includes code implementing the Second Extended File System
460.Em ( EXT2FS )
461, revision 0 and revision 1 with the
462.Em filetype
463and
464.Em sparse_super
465options.  This is the most commonly used file system on the Linux operating
466system, and is provided here for compatibility.
467Some of the specific features of
468.Em EXT2FS
469like the "behavior on errors" are not implemented.
470This file system can't be used with UID or GID greater than 65535.
471See
472.Xr mount_ext2fs 8
473for details.
474.It Cd file-system LFS
475.Em [EXPERIMENTAL]
476Include the Log-structured File System
477.Em ( LFS ) .
478See
479.Xr mount_lfs 8
480and
481.Xr newfs_lfs 8
482for details.
483.It Cd file-system MFS
484Include the Memory File System
485.Em ( MFS ) .
486This file system stores files in swappable memory, and produces
487notable performance improvements when it is used as the file store
488for
489.Pa /tmp
490and similar file systems.
491See
492.Xr mount_mfs 8
493for details.
494.It Cd file-system NFS
495Include the client side of the Network File System
496.Pq Tn NFS
497remote file sharing protocol.
498Although the bulk of the code implementing
499.Tn NFS
500is kernel based, several user level daemons are needed for it to work.
501See
502.Xr mount_nfs 8
503for details.
504.It Cd file-system CD9660
505Includes code for the
506.Tn ISO
5079660 + Rock Ridge file system, which is the standard file system on many
508.Tn CD-ROM
509discs.
510Useful primarily if you have a
511.Tn CD-ROM
512drive.
513See
514.Xr mount_cd9660 8
515for details.
516.It Cd file-system MSDOSFS
517Includes the
518.Tn MS-DOS
519FAT file system, which is reportedly still used
520by unfortunate people who have not heard about
521.Nx .
522Also implements the
523.Tn Windows 95
524extensions to the same, which permit the use of longer, mixed case
525file names.
526See
527.Xr mount_msdos 8
528and
529.Xr fsck_msdos 8
530for details.
531.It Cd file-system NTFS
532.Em [EXPERIMENTAL]
533Includes code for the
534.Tn Microsoft Windows NT
535file system.
536See
537.Xr mount_ntfs 8
538for details.
539.It Cd file-system FDESC
540Includes code for a file system, conventionally mounted on
541.Pa /dev/fd ,
542which permits access to the per-process file descriptor space via
543special files in the file system.
544See
545.Xr mount_fdesc 8
546for details.
547Note that this facility is redundant, and thus unneeded on most
548.Nx
549systems, since the
550.Xr fd 4
551pseudodevice driver already provides identical functionality.
552On most
553.Nx
554systems, instances of
555.Xr fd 4
556are mknoded under
557.Pa /dev/fd/
558and on
559.Pa /dev/stdin ,
560.Pa /dev/stdout ,
561and
562.Pa /dev/stderr .
563.It Cd file-system KERNFS
564Includes code which permits the mounting of a special file system
565(normally mounted on
566.Pa /kern )
567in which files representing various kernel variables and parameters
568may be found.
569See
570.Xr mount_kernfs 8
571for details.
572.It Cd file-system NULLFS
573Includes code for a loopback file system.
574This permits portions of the file hierarchy to be re-mounted in other places.
575The code really exists to provide an example of a stackable file system layer.
576See
577.Xr mount_null 8
578for details.
579.It Cd file-system OVERLAY
580Includes code for a file system filter.
581This permits the overlay file system to intercept all access to an underlying
582file system. This file system is intended to serve as an example of
583a stacking file system which has a need to interpose itself between an
584underlying file system and all other access.
585See
586.Xr mount_overlay 8
587for details.
588.It Cd file-system PORTAL
589.Em [EXPERIMENTAL]
590Includes the portal filesystem.
591This permits interesting tricks like opening
592.Tn TCP
593sockets by opening files in the file system.
594The portal file system is conventionally mounted on
595.Pa /p
596and is partially implemented by a special daemon.
597See
598.Xr mount_portal 8
599for details.
600.It Cd file-system PROCFS
601Includes code for a special file system (conventionally mounted on
602.Pa /proc )
603in which the process space becomes visible in the file system.
604Among
605other things, the memory spaces of processes running on the system are
606visible as files, and signals may be sent to processes by writing to
607.Pa ctl
608files in the procfs namespace.
609See
610.Xr mount_procfs 8
611for details.
612.It Cd file-system UMAPFS
613Includes a loopback file system in which user and group ids may be
614remapped -- this can be useful when mounting alien file systems with
615different uids and gids than the local system.
616See
617.Xr mount_umap 8
618for details.
619.It Cd file-system UNION
620.Em [EXPERIMENTAL]
621Includes code for the union file system, which permits directories to
622be mounted on top of each other in such a way that both file systems
623remain visible -- this permits tricks like allowing writing (and the
624deleting of files) on a read-only file system like a
625.Tn CD-ROM
626by mounting a local writable file system on top of the read-only file system.
627See
628.Xr mount_union 8
629for details.
630.It Cd file-system CODA
631.Em [EXPERIMENTAL]
632Includes code for the Coda file system.
633Coda is a distributed file system like NFS and AFS.  It is
634freely available, like NFS, but it functions much like AFS in being a
635.Dq stateful
636file system.  Both Coda and AFS cache files on your local
637machine to improve performance.  Then Coda goes a step further than AFS
638by letting you access the cached files when there is no available
639network, viz. disconnected laptops and network outages.  In Coda, both
640the client and server are outside the kernel which makes them easier
641to experiment with.  Coda is available for several UNIX and non-UNIX
642platforms.
643See http://www.coda.cs.cmu.edu for more details.
644NOTE: You also need to enable the pseudo-device, vcoda, for the Coda
645filesystem to work.
646.El
647.Ss File System Options
648.Bl -ohang
649.It Cd options NFSSERVER
650Include the server side of the
651.Em NFS
652(Network File System) remote file sharing protocol.
653Although the bulk of the code implementing
654.Em NFS
655is kernel based, several user level daemons are needed for it to
656work.
657See
658.Xr mountd 8
659and
660.Xr nfsd 8
661for details.
662.It Cd options QUOTA
663Enables kernel support for file system quotas.
664See
665.Xr quotaon 8 ,
666.Xr edquota 8 ,
667and
668.Xr quota 1
669for details.
670Note that quotas only work on
671.Dq ffs
672file systems, although
673.Xr rpc.rquotad 8
674permits them to be accessed over
675.Em NFS .
676.It Cd options FFS_EI
677Enable ``Endian-Independent'' FFS support.
678This allows a system to mount an FFS filesystem created for another
679architecture, at a small performance cost for all FFS filesystems.
680See also
681.Xr newfs 8 ,
682.Xr fsck_ffs 8 ,
683.Xr dumpfs 8
684for filesystem byte order status and manipulation.
685.It Cd options NVNODE=integer
686This option sets the size of the cache used by the name-to-inode translation
687routines, (a.k.a. the
688.Fn namei
689cache, though called by many other names in the kernel source).
690By default, this cache has
691.Dv NPROC
692(set as 20 + 16 * MAXUSERS) * (80 + NPROC / 8) entries.
693A reasonable way to derive a value of
694.Dv NVNODE ,
695should you notice a large number of namei cache misses with a tool such as
696.Xr systat 1 ,
697is to examine your system's current computed value with
698.Xr sysctl 8 ,
699(which calls this parameter "kern.maxvnodes") and to increase this value
700until either the namei cache hit rate improves or it is determined that
701your system does not benefit substantially from an increase in the size of
702the namei cache.
703.It Cd options NAMECACHE_ENTER_REVERSE
704Causes the namei cache to always enter a reverse mapping (vnode -\*[Gt] name)
705as well as a normal one. Normally, this is already done for directory
706vnodes, to speed up the getcwd operation. This option will cause
707longer hash chains in the reverse cache, and thus slow down
708getcwd somewhat. However, it does make vnode -\*[Gt] path translations
709possible in some cases. For now, only useful if strict /proc/#/maps
710emulation for Linux binaries is required.
711.It Cd options EXT2FS_SYSTEM_FLAGS
712This option changes the behavior of the APPEND and IMMUTABLE flags
713for a file on an
714.Em EXT2FS
715filesystem.
716Without this option, the superuser or owner of the file can
717set and clear them.
718With this option, only the superuser can set them, and
719they can't be cleared if the securelevel is greater than 0.
720See also
721.Xr chflags 1 .
722.It Cd options NFS_BOOT_BOOTP
723Enable use of the BOOTP protocol (RFC 951, 1048) to get configuration
724information if NFS is used to mount the root file system.
725See
726.Xr diskless 8
727for details.
728.It Cd options NFS_BOOT_DHCP
729Same as
730.Dq NFS_BOOT_BOOTP ,
731but use the DHCP extensions to the
732BOOTP protocol (RFC 1541).
733.It Cd options NFS_BOOT_BOOTP_REQFILE
734Specifies the string sent in the bp_file field of the BOOTP / DHCP
735request packet.
736.It Cd options NFS_BOOT_BOOTPARAM
737Enable use of the BOOTPARAM protocol, consisting of RARP and
738BOOTPARAM RPC, to get configuration information if NFS
739is used to mount the root file system.
740See
741.Xr diskless 8
742for details.
743.It Cd options NFS_BOOT_RWSIZE=value
744Set the initial NFS read and write sizes for diskless-boot requests.
745The normal default is 8Kbytes.  This option provides a way to lower
746the value (e.g., to 1024 bytes) as a workaround for buggy network
747interface cards or boot proms. Once booted, the read and write request
748sizes can be increased by remounting the filesystem. See
749.Xr mount_nfs 8
750for details.
751.It Cd options NFS_V2_ONLY
752Reduce the size of the NFS client code by omitting code that's only required
753for NFSv3 and NQNFS support, leaving only that code required to use NFSv2
754servers.
755.El
756.Ss Miscellaneous Options
757.Bl -ohang
758.It Cd options LKM
759Enable loadable kernel modules.
760See
761.Xr lkm 4
762for details.
763.Em NOTE :
764not available on all architectures.
765.It Cd options INSECURE
766Hardwires the kernel security level at -1.
767This means that the system
768always runs in secure level 0 mode, even when running multiuser.
769See the manual page for
770.Xr init 8
771for details on the implications of this.
772The kernel secure level may manipulated by the superuser by altering the
773.Em kern.securelevel
774.Xr sysctl 3
775variable (the secure level may only be lowered by a call from process ID 1,
776i.e.
777.Xr init 8 ) .
778See also
779.Xr sysctl 8
780and
781.Xr sysctl 3 .
782.It Cd options UCONSOLE
783Normally, only the superuser can execute the
784.Dv TIOCCONS
785.Xr ioctl 2 ,
786which redirects console output to a non-console tty.
787See
788.Xr tty 4
789for details.
790This option permits any user to execute the
791.Dv TIOCCONS
792.Xr ioctl 2 .
793This is useful on
794machines such as personal workstations which run
795.Xr X 7
796servers, where one would prefer to permit console output to be
797viewed in a window without requiring a suid root program to do it.
798.It Cd options MEMORY_DISK_HOOKS
799This option allows for some machine dependent functions to be called when
800the
801.Xr md 4
802.Tn RAM
803disk driver is configured.
804This can result in automatically loading a
805.Tn RAM
806disk from floppy on open (among other things).
807.It Cd options MEMORY_DISK_IS_ROOT
808Forces the
809.Xr md 4
810.Tn RAM
811disk to be the root device.
812This can only be overridden when
813the kernel is booted in the 'ask-for-root' mode.
814.It Cd options MEMORY_DISK_ROOT_SIZE=integer
815Allocates the given number of 512 byte blocks as memory for the
816.Xr md 4
817.Tn RAM
818disk, to be populated with
819.Xr mdsetimage 8 .
820.It Cd options VNODE_OP_NOINLINE
821Do not inline the VOP_*() calls in the kernel.
822On i386 GENERIC, this saves 36k of kernel text.  Useful
823for install media kernels, small memory systems and embedded systems.
824.It Cd options HZ=integer
825On ports that support it, set the system clock frequency (see
826.Xr hz 9 )
827to the supplied value. Handle with care.
828.It Cd options NTP
829Turns on in-kernel precision timekeeping support used by software
830implementing
831.Em NTP
832(Network Time Protocol, RFC1305).
833The
834.Em NTP
835option adds an in-kernel Phase-Locked Loop (PLL) for normal
836.Em NTP
837operation, and a Frequency-Locked Loop (FLL) for intermittently-connected
838operation.
839.Xr ntpd 8
840will employ a user-level PLL when kernel support is unavailable,
841but the in-kernel version has lower latency and more precision, and
842so typically keeps much better time.
843The interface to the kernel
844.Em NTP
845support is provided by the
846.Xr ntp_adjtime 2
847and
848.Xr ntp_gettime 2
849system calls, which are intended for use by
850.Xr ntpd 8
851and are enabled by the option.
852On systems with sub-microsecond resolution timers, or where (HZ / 100000)
853is not an integer, the
854.Em NTP
855option also enables extended-precision arithmetic to keep track of
856fractional clock ticks at NTP time-format precision.
857.It Cd options PPS_SYNC
858This option enables a kernel serial line discipline for receiving time
859phase signals from an external reference clock such as a radio clock.
860(The
861.Em NTP
862option (which see) must be on if the
863.Em PPS_SYNC
864option is used.)
865Some reference clocks generate a Pulse Per Second (PPS) signal in
866phase with their time source.
867The
868.Em PPS
869line discipline receives this signal on either the data leads
870or the DCD control lead of a serial port.
871.Em NTP
872uses the PPS signal to discipline the local clock oscillator to a high
873degree of precision (typically less than 50 microseconds in time and
8740.1 ppm in accuracy).
875.Em PPS
876can also generate a serial output pulse when the system receives a PPS
877interrupt.
878This can be used to measure the system interrupt latency and thus calibrate
879.Em NTP
880to account for it.
881Using
882.Em PPS
883usually requires a
884gadget box
885to convert from TTL to RS-232 signal levels.
886The gadget box and PPS are described in more detail in the HTML documentation
887for
888.Xr ntpd 8
889in
890.Pa /usr/share/doc/html/ntp .
891.It Cd options SETUIDSCRIPTS
892Allows scripts with the setuid bit set to execute as the effective
893user rather than the real user, just like binary executables.
894.Pp
895.Em NOTE :
896Using this option will also enable
897.Em options FDSCRIPTS
898.It Cd option FDSCRIPTS
899Allows execution of scripts with the execute bit set, but not the
900read bit, by opening the file and passing the file descriptor to
901the shell, rather than the filename.
902.Pp
903.Em NOTE :
904Execute only (non-readable) scripts will have
905.Va argv[0]
906set to
907.Pa /dev/fd/* .
908What this option allows as far as security is
909concerned, is the ability to safely ensure that the correct script
910is run by the interpreter, as it is passed as an already open file.
911.It Cd options PUCCN
912Enables treating serial ports found on PCI boards
913.Xr puc 4
914as potential console devices.  The method for choosing such a console
915device is port dependent.
916.It Cd options RTC_OFFSET=integer
917The kernel (and typically the hardware battery backed-up clock on
918those machines that have one) keeps time in
919.Em UTC
920(Universal Coordinated Time, once known as
921.Em GMT ,
922or Greenwich Mean Time)
923and not in the time of the local time zone.
924The
925.Em RTC_OFFSET
926option is used on some ports (such as the i386) to tell the kernel
927that the hardware clock is offset from
928.Em UTC
929by the specified number of minutes.
930This is typically used when a machine boots several operating
931systems and one of them wants the hardware clock to run in the
932local time zone and not in
933.Em UTC ,
934e.g.
935.Em RTC_OFFSET=300
936means
937the hardware clock is set to US Eastern Time (300 minutes behind
938.Em UTC ) ,
939and not
940.Em UTC .
941(Note:
942.Em RTC_OFFSET
943is used to initialize a kernel variable named
944.Va rtc_offset
945which is the source actually used to determine the clock offset, and
946which may be accessed via the kern.rtc_offset sysctl variable.
947See
948.Xr sysctl 8
949and
950.Xr sysctl 3
951for details.
952Since the kernel clock is initialized from the hardware clock very
953early in the boot process, it is not possible to meaningfully change
954.Va rtc_offset
955in system initialization scripts.
956Changing this value currently may only be done at kernel compile
957time or by patching the kernel and rebooting).
958.Pp
959.Em NOTE :
960Unfortunately, in many cases where the hardware clock
961is kept in local time, it is adjusted for Daylight Savings
962Time; this means that attempting to use
963.Em RTC_OFFSET
964to let
965.Nx
966coexist with such an operating system, like Windows,
967would necessitate changing
968.Em RTC_OFFSET
969twice a year. As such, this solution is imperfect.
970.It Cd options KMEMSTATS
971The kernel memory allocator,
972.Xr malloc 9 ,
973will keep statistics on its performance if this option is enabled.
974Unfortunately, this option therefore essentially disables the
975.Fn MALLOC
976and
977.Fn FREE
978forms of the memory allocator, which are used to enhance the performance
979of certain critical sections of code in the kernel.
980This option therefore can lead to a significant decrease in the
981performance of certain code in the kernel if enabled.
982Examples of such code include the
983.Fn namei
984routine, the
985.Xr ccd 4
986driver,
987the
988.Xr ncr 4
989driver,
990and much of the networking code.
991.It Cd options MAXUPRC=integer
992Sets the soft
993.Dv RLIMIT_NPROC
994resource limit, which specifies the maximum number of simultaneous
995processes a user is permitted to run, for process 0;
996this value is inherited by its child processes.
997It defaults to
998.Em CHILD_MAX ,
999which is currently defined to be 160.
1000Setting
1001.Em MAXUPRC
1002to a value less than
1003.Em CHILD_MAX
1004is not permitted, as this would result in a violation of the semantics of
1005.St -p1003.1-90 .
1006.It Cd options DEFCORENAME=string
1007Sets the default value of the
1008.Em kern.defcorename
1009sysctl variable, otherwise it is set to
1010.Nm %n.core .
1011See
1012.Xr sysctl 8
1013and
1014.Xr sysctl 3
1015for details.
1016.It Cd options RASOPS_CLIPPING
1017Enables clipping within the
1018.Nm rasops
1019raster-console output system.
1020.Em NOTE :
1021only available on architectures that use
1022.Nm rasops
1023for console output.
1024.It Cd options RASOPS_SMALL
1025Removes optimized character writing code from the
1026.Nm rasops
1027raster-console output system.
1028.Em NOTE :
1029only available on architectures that use
1030.Nm rasops
1031for console output.
1032.It Cd options INCLUDE_CONFIG_FILE
1033Embeds the kernel config file used to define the kernel in the kernel
1034binary itself.  The embedded data also includes any files directly
1035included by the config file itself, e.g.
1036.Pa GENERIC.local
1037or
1038.Pa std.$MACHINE .
1039The embedded config file can be extracted from the resulting kernel by
1040the following command:
1041.Bd -literal -offset indent
1042strings netbsd | sed -n 's/^_CFG_//p' | unvis
1043.Ed
1044.It Cd options INCLUDE_JUST_CONFIG
1045Similar to the above option, but includes just the actual config file,
1046not any included files.
1047.It Cd options PIPE_SOCKETPAIR
1048Use slower, but smaller socketpair(2)-based pipe implementation instead
1049of default faster, but bigger one. Primarily useful for installation
1050kernels.
1051.El
1052.Ss Networking Options
1053.Bl -ohang
1054.It Cd options GATEWAY
1055Enables
1056.Em IPFORWARDING
1057(which see)
1058and (on most ports) increases the size of
1059.Em NMBCLUSTERS
1060(which see).
1061In general,
1062.Em GATEWAY
1063is used to indicate that a system should act as a router, and
1064.Em IPFORWARDING
1065is not invoked directly.
1066(Note that
1067.Em GATEWAY
1068has no impact on protocols other than
1069.Tn IP ,
1070such as
1071.Tn CLNP
1072or
1073.Tn XNS ) .
1074.It Cd options IPFORWARDING=value
1075If
1076.Em value
1077is 1 this enables IP routing behavior. If
1078.Em value
1079is 0 (the default), it disables it. The
1080.Em GATEWAY
1081option sets this to 1 automatically.
1082With this option enabled, the machine will forward IP datagrams destined
1083for other machines between its interfaces.
1084Note that even without this option, the kernel will
1085still forward some packets (such as source routed packets) -- removing
1086.Em GATEWAY
1087and
1088.Em IPFORWARDING
1089is insufficient to stop all routing through a bastion host on a
1090firewall -- source routing is controlled independently.
1091To turn off source routing, use
1092.Em options IPFORWSRCRT=0
1093(which see).
1094Note that IP forwarding may be turned on and off independently of the
1095setting of the
1096.Em IPFORWARDING
1097option through the use of the
1098.Em net.inet.ip.forwarding
1099sysctl variable.
1100If
1101.Em net.inet.ip.forwarding
1102is 1, IP forwarding is on.
1103See
1104.Xr sysctl 8
1105and
1106.Xr sysctl 3
1107for details.
1108.It Cd options IPFORWSRCRT=value
1109If
1110.Em value
1111is set to zero, source routing of IP datagrams is turned off.
1112If
1113.Em value
1114is set to one (the default) or the option is absent, source routed IP
1115datagrams are forwarded by the machine.
1116Note that source routing of IP packets may be turned on and off
1117independently of the setting of the
1118.Em IPFORWSRCRT
1119option through the use of the
1120.Em net.inet.ip.forwsrcrt
1121sysctl variable.
1122If
1123.Em net.inet.ip.forwsrcrt
1124is 1, forwarding of source routed IP datagrams is on.
1125See
1126.Xr sysctl 8
1127and
1128.Xr sysctl 3
1129for details.
1130.It Cd options IFA_STATS
1131Tells the kernel to maintain per-address statistics on bytes sent
1132and received over (currently) internet and appletalk addresses.
1133.\"This can be a fairly expensive operation, so you probably want to
1134.\"keep this disabled.
1135The option is not recommended as it degrades system stability.
1136.It Cd options MROUTING
1137Includes support for IP multicast routers.
1138You certainly want
1139.Em INET
1140with this.
1141Multicast routing is controlled by the
1142.Xr mrouted 8
1143daemon.
1144.It Cd options INET
1145Includes support for the
1146.Tn TCP/IP
1147protocol stack.
1148You almost certainly want this.
1149See
1150.Xr inet 4
1151for details.
1152This option is currently required.
1153.It Cd options INET6
1154Includes support for the
1155.Tn IPv6
1156protocol stack.
1157See
1158.Xr inet6 4
1159for details.
1160Unlike
1161.Em INET ,
1162.Em INET6
1163enables multicast routing code as well.
1164This option requires
1165.Em INET
1166at this moment, but it should not.
1167.It Cd options ND6_DEBUG
1168The option sets the default value of net.inet6.icmp6.nd6_debug to 1,
1169for debugging IPv6 neighbor discovery protocol handling.
1170See
1171.Xr sysctl 3
1172for details.
1173.It Cd options IPSEC
1174Includes support for the
1175.Tn IPsec
1176protocol.
1177See
1178.Xr ipsec 4
1179for details.
1180.Em IPSEC
1181will enable
1182secret key management part,
1183policy management part,
1184.Tn AH
1185and
1186.Tn IPComp .
1187Kernel binary will not be subject to export control in most of countries,
1188even if compiled with
1189.Em IPSEC .
1190For example, it should be okay to export it from within the United States
1191to the outside.
1192.Em INET6
1193and
1194.Em IPSEC
1195are orthogonal so you can get IPv4-only kernel with IPsec support,
1196IPv4/v6 dual support kernel without IPsec, and so forth.
1197This option requires
1198.Em INET
1199at this moment, but it should not.
1200.It Cd options IPSEC_DEBUG
1201Enables debugging code in
1202.Tn IPsec
1203stack.
1204This option assumes
1205.Em IPSEC .
1206.It Cd options IPSEC_ESP
1207Includes support for
1208.Tn IPsec
1209.Tn ESP
1210protocol.
1211See
1212.Xr ipsec 4
1213for details.
1214.Em IPSEC_ESP
1215will enable source code that is subject to export control in some countries
1216.Pq including the United States ,
1217and compiled kernel binary will be subject to certain restriction.
1218This option assumes
1219.Em IPSEC .
1220.It Cd options SUBNETSARELOCAL
1221Sets default value for net.inet.ip.subnetsarelocal variable, which
1222controls whether non-directly-connected subnets of connected networks
1223are considered "local" for purposes of choosing the MSS for a TCP
1224connection.  This is mostly present for historic reasons and
1225completely irrelevant if you enable Path MTU discovery.
1226.It Cd options HOSTZEROBROADCAST
1227Sets default value for net.inet.ip.hostzerobroadcast variable, which
1228controls whether the zeroth host address of each connected subnet is
1229also considered a broadcast address.  Default value is "1", for
1230compatibility with old systems; if this is set to zero on all hosts on
1231a subnet, you should be able to fit an extra host per subnet on the
1232".0" address.
1233.It Cd options MCLSHIFT=value
1234This option is the base-2 logarithm of the size of mbuf clusters.
1235The
1236.Bx
1237networking stack keeps network packets in a linked
1238list, or chain, of kernel buffer objects called mbufs.
1239The system provides larger mbuf clusters as an optimization for
1240large packets, instead of using long chains for large packets.
1241The mbuf cluster size,
1242or
1243.Em MCLBYTES ,
1244must be a power of two, and is computed as two raised to the power
1245.Em MCLSHIFT .
1246On systems with Ethernet network adaptors,
1247.Em MCLSHIFT
1248is often set to 11, giving 2048-byte mbuf clusters, large enough to
1249hold a 1500-byte
1250.Tn Ethernet
1251frame in a single cluster.
1252Systems with network interfaces supporting larger frame sizes like
1253.Tn ATM ,
1254.Tn FDDI ,
1255or
1256.Tn HIPPI
1257may perform better with
1258.Em MCLSHIFT
1259set to 12 or 13, giving mbuf cluster sizes of 4096 and 8192 bytes,
1260respectively.
1261.It Cd options NS
1262Include support for the
1263.Tn Xerox
1264.Tn XNS
1265protocol stack.
1266See
1267.Xr ns 4
1268for details.
1269.It Cd options ISO,TPIP
1270Include support for the ubiquitous
1271.Tn OSI
1272protocol stack.
1273See
1274.Xr iso 4
1275for details.
1276This option assumes
1277.Em INET .
1278.It Cd options EON
1279Include support for tunneling
1280.Tn OSI
1281protocols over
1282.Tn IP .
1283Known to be broken, or at least very fragile, and undocumented.
1284.It Cd options CCITT,LLC,HDLC
1285Include support for the
1286.Tn CCITT
1287(nee
1288.Tn ITU-TSS )
1289.Tn X.25
1290protocol stack.
1291The state of this code is currently unknown, and probably contains bugs.
1292This option assumes
1293.Em INET .
1294.It Cd options NETATALK
1295Include support for the
1296.Tn AppleTalk
1297protocol stack.
1298The kernel provides provision for the
1299.Em Datagram Delivery Protocol
1300(DDP), providing SOCK_DGRAM support and
1301.Tn AppleTalk
1302routing.
1303This stack is used by the
1304.Em NETATALK
1305package, which adds support for
1306.Tn AppleTalk
1307server services via user libraries and applications.
1308.It Cd options IPNOPRIVPORTS
1309Normally, only root can bind a socket descriptor to a so-called
1310.Dq privileged
1311.Tn TCP
1312port, that is, a port number in the range 0-1023.
1313This option eliminates those checks from the kernel.
1314This can be useful if there is a desire to allow daemons without
1315privileges to bind those ports, e.g. on firewalls.
1316The security tradeoffs in doing this are subtle.
1317This option should only be used by experts.
1318.It Cd options TCP_COMPAT_42
1319.Tn TCP
1320bug compatibility with
1321.Bx 4.2 .
1322In
1323.Bx 4.2 ,
1324.Tn TCP
1325sequence numbers were 32-bit signed values.
1326Modern implementations of TCP use unsigned values.
1327This option clamps the initial sequence number to start in
1328the range 2^31 rather than the full unsigned range of 2^32.
1329Also, under
1330.Bx 4.2 ,
1331keepalive packets must contain at least one byte or else
1332the remote end would not respond.
1333.It Cd options TCP_DEBUG
1334Record the last
1335.Em TCP_NDEBUG
1336TCP packets with SO_DEBUG set, and decode to the console if
1337.Em tcpconsdebug
1338is set.
1339.It Cd options TCP_NDEBUG
1340Number of packets to record for
1341.Em TCP_DEBUG .
1342Defaults to 100.
1343.It Cd options PFIL_HOOKS
1344This option turns on the packet filter interface hooks.
1345See
1346.Xr pfil 9
1347for details.
1348This option assumes
1349.Em INET .
1350.It Cd options IPFILTER_LOG
1351This option, in conjunction with
1352.Em pseudo-device ipfilter ,
1353enables logging of IP packets using ip-filter.
1354.It Cd options IPFILTER_DEFAULT_BLOCK
1355This option sets the default policy of ip-filter.
1356If it is set, ip-filter will block packets by default.
1357.It Cd options PPP_BSDCOMP
1358Enable support for BSD-compress
1359.Pq Sq bsdcomp
1360compression in ppp.
1361.It Cd options PPP_DEFLATE
1362Enable support for deflate
1363compression in ppp.
1364.It Cd options PPP_FILTER
1365This option turns on
1366.Xr pcap 3
1367based filtering for ppp connections.
1368This option is used by
1369.Xr pppd 8
1370which needs to be compiled with
1371.Em PPP_FILTER
1372defined (the current default).
1373.El
1374.Ss System V IPC Options
1375.Bl -ohang
1376.It Cd options SYSVMSG
1377Includes support for
1378.At V
1379style message queues.
1380See
1381.Xr msgctl 2 ,
1382.Xr msgget 2 ,
1383.Xr msgrcv 2 ,
1384.Xr msgsnd 2 .
1385.It Cd options SYSVSEM
1386Includes support for
1387.At V
1388style semaphores.
1389See
1390.Xr semctl 2 ,
1391.Xr semget 2 ,
1392.Xr semop 2 .
1393.It Cd options SEMMNI=value
1394Sets the number of
1395.At V
1396style semaphore identifiers.  The GENERIC config file for your port
1397will have the default.
1398.It Cd options SEMMNS=value
1399Sets the number of
1400.At V
1401style semaphores in the system.  The GENERIC config file for your port
1402will have the default.
1403.It Cd options SEMUME=value
1404Sets the maximum number of undo entries per process for
1405.At V
1406style semaphores.  The GENERIC config file for your port
1407will have the default.
1408.It Cd options SEMMNU=value
1409Sets the number of undo structures in the system for
1410.At V
1411style semaphores.  The GENERIC config file for your port
1412will have the default.
1413.It Cd options SYSVSHM
1414Includes support for
1415.At V
1416style shared memory.
1417See
1418.Xr shmat 2 ,
1419.Xr shmctl 2 ,
1420.Xr shmdt 2 ,
1421.Xr shmget 2 .
1422.It Cd options SHMMAXPGS=value
1423Sets the maximum number of
1424.At V
1425style shared memory pages that are available through the
1426.Xr shmget 2
1427system call.
1428Default value is 1024 on most ports.
1429See
1430.Pa /usr/include/machine/vmparam.h
1431for the default.
1432.El
1433.Ss VM Related Options
1434.Bl -ohang
1435.It Cd options NMBCLUSTERS=value
1436The number of mbuf clusters the kernel supports.  Mbuf clusters are
1437MCLBYTES in size (usually 2k).  This is used to compute the size of
1438the kernel VM map
1439.Em mb_map ,
1440which maps mbuf clusters.
1441Default on most ports is 256 (512 with
1442.Dq options GATEWAY
1443).
1444See
1445.Pa /usr/include/machine/param.h
1446for exact default information.
1447Increase this value if you get
1448.Dq mb_map full
1449messages.
1450.It Cd options NKMEMPAGES=value
1451.It Cd options NKMEMPAGES_MIN=value
1452.It Cd options NKMEMPAGES_MAX=value
1453Size of kernel VM map
1454.Em kmem_map ,
1455in PAGE_SIZE-sized chunks (the VM page size; this value may be read
1456from the
1457.Xr sysctl 8
1458variable
1459.Em hw.pagesize
1460).
1461This VM map is used to map the kernel malloc arena.
1462The kernel attempts to auto-size this map based on the amount of
1463physical memory in the system.  Platform-specific code may place
1464bounds on this computed size, which may be viewed with the
1465.Xr sysctl 8
1466variable
1467.Em vm.nkmempages .
1468See
1469.Pa /usr/include/machine/param.h
1470for the default upper and lower bounds.
1471The related options
1472.Sq NKMEMPAGES_MIN
1473and
1474.Sq NKMEMPAGES_MAX
1475allow the bounds to be overridden in the kernel configuration file.
1476These options are provided in the event the computed value is
1477insufficient resulting in an
1478.Dq out of space in kmem_map
1479panic.
1480.It Cd options BUFCACHE=value
1481Size of the buffer cache as a percentage of total available
1482.Tn RAM .
1483Ignored if BUFPAGES is also specified.
1484.It Cd options NBUF=value
1485.It Cd options BUFPAGES=value
1486These options set the number of pages available for the buffer cache.
1487Their default value is a machine dependent value, often calculated as
1488between 5% and 10% of total available
1489.Tn RAM .
1490.It Cd options MAXTSIZ=bytes
1491Sets the maximum size limit of a process' text segment. See
1492.Pa /usr/include/machine/vmparam.h
1493for the port-specific default.
1494.It Cd options DFLDSIZ=bytes
1495Sets the default size limit of a process' data segment, the value that
1496will be returned as the soft limit for
1497.Dv RLIMIT_DATA
1498(as returned by
1499.Xr getrlimit 2 ) .
1500See
1501.Pa /usr/include/machine/vmparam.h
1502for the port-specific default.
1503.It Cd options MAXDSIZ=bytes
1504Sets the maximum size limit of a process' data segment, the value that
1505will be returned as the hard limit for
1506.Dv RLIMIT_DATA
1507(as returned by
1508.Xr getrlimit 2 ) .
1509See
1510.Pa /usr/include/machine/vmparam.h
1511for the port-specific default.
1512.It Cd options DFLSSIZ=bytes
1513Sets the default size limit of a process' stack segment, the value that
1514will be returned as the soft limit for
1515.Dv RLIMIT_STACK
1516(as returned by
1517.Xr getrlimit 2 ) .
1518See
1519.Pa /usr/include/machine/vmparam.h
1520for the port-specific default.
1521.It Cd options MAXSSIZ=bytes
1522Sets the maximum size limit of a process' stack segment, the value that
1523will be returned as the hard limit for
1524.Dv RLIMIT_STACK
1525(as returned by
1526.Xr getrlimit 2 ) .
1527See
1528.Pa /usr/include/machine/vmparam.h
1529for the port-specific default.
1530.El
1531.Ss amiga-specific Options
1532.Bl -ohang
1533.It Cd options BB060STUPIDROM
1534When the bootloader (which passes
1535.Tn AmigaOS
1536.Tn ROM
1537information) claims we have a 68060
1538.Tn CPU
1539without
1540.Tn FPU ,
1541go look into the Processor Configuration Register (PCR) to find out.
1542You need this with
1543.Tn Amiga
1544.Tn ROM Ns s
1545up to (at least) V40.xxx (OS3.1),
1546when you boot via the bootblocks and don't have a DraCo.
1547.It Cd options IOBZCLOCK=frequency
1548The IOBlix boards come with two different serial master clocks: older ones
1549use 24 MHz, newer ones use 22.1184 MHz. The driver normally assumes the latter.
1550If your board uses 24 MHz, you can recompile your kernel with
1551options IOBZCLOCK=24000000
1552or patch the kernel variable
1553.Tn iobzclock
1554to the same value.
1555.It Cd options LIMITMEM=value
1556If there, limit the part of the first memory bank used by
1557.Nx
1558to value megabytes.
1559Default is unlimited.
1560.It Cd options NKPTADD=addvalue
1561.It Cd options NKPTADDSHIFT=shiftvalue
1562The
1563.Tn CPU
1564specific
1565.Tn MMU
1566table for the kernel is pre-allocated at kernel startup time.
1567Part of it is scaled with
1568.Va maxproc ,
1569to have enough room to hold the user program
1570.Tn MMU
1571tables; the second part is a fixed amount for the kernel itself.
1572.Pp
1573The third part accounts for the size of the file buffer cache.
1574Its size is either
1575.Dv NKPTADD
1576pages (if defined) or memory size in bytes divided by two to
1577the power of
1578.Dv NKPTADDSHIFT .
1579The default is undefined
1580.Dv NKPTADD
1581and
1582.Dv NKPTADDSHIFT=24 ,
1583allowing for 16 buffers per megabyte of main memory (while
1584a GENERIC kernel allocates about half of that).
1585When you get "can't get KPT page" panics, you should increase
1586.Dv NKPTADD
1587(if defined), or decrease
1588.Dv NKPTADDSHIFT
1589by one.
1590.It Cd options P5PPC68KBOARD
1591Add special support for Phase5 mixed 68k+PPC boards. Currently, this only
1592affects rebooting from
1593.Nx
1594and is only needed on 68040+PPC, not on
159568060+PPC; without this, affected machines will hang after
1596.Nx
1597has shut
1598down and will only restart after a keyboard reset or a power cycle.
1599.El
1600.Ss arm32-specific Options
1601.Bl -ohang
1602.It Cd options FRENCH_KEYBOARD
1603Include translation for French keyboards when using
1604.Xr pccons 4
1605on a Shark.
1606.It Cd options FINNISH_KEYBOARD
1607Include translation for Finnish keyboards when using
1608.Xr pccons 4
1609on a Shark.
1610.It Cd options GERMAN_KEYBOARD
1611Include translation for German keyboards when using
1612.Xr pccons 4
1613on a Shark.
1614.It Cd options NORWEGIAN_KEYBOARD
1615Include translation for French keyboards when using
1616.Xr pccons 4
1617on a Shark.
1618.El
1619.Ss atari-specific Options
1620.Bl -ohang
1621.It Cd options DISKLABEL_AHDI
1622Include support for AHDI (native Atari) disklabels.
1623.It Cd options DISKLABEL_NBDA
1624Include support for
1625.Nx Ns Tn /atari
1626labels.
1627If you don't set this option, it will be set automatically.
1628.Nx Ns Tn /atari
1629will not work without it.
1630.It Cd options FALCON_SCSI
1631Include support for the 5380-SCSI configuration as found on the Falcon.
1632.It Cd options RELOC_KERNEL
1633If set, the kernel will relocate itself to TT-RAM, if possible.
1634This will give you a slightly faster system.
1635.Em Beware
1636that on some TT030 systems,
1637the system will frequently dump with MMU-faults with this option enabled.
1638.It Cd options SERCONSOLE
1639Allow the modem1-port to act as the system-console.
1640A carrier should be active on modem1 during system boot to active
1641the console functionality.
1642.It Cd options TT_SCSI
1643Include support for the 5380-SCSI configuration as found on the TT030
1644and Hades.
1645.El
1646.Ss i386-specific Options
1647.Bl -ohang
1648.It Cd options I386_CPU,I486_CPU,I586_CPU,I686_CPU
1649Include support for a particular class of
1650.Tn CPU
1651.Po
1652.Tn i386 ,
1653.Tn i486 ,
1654.Tn Pentium ,
1655or
1656.Tn Pentium Pro
1657.Pc .
1658If the appropriate class for your
1659.Tn CPU
1660is not configured, the kernel will use the highest class available
1661that will work.
1662In general, using the correct
1663.Tn CPU
1664class will result in the best performance.
1665At least one of these options must be present.
1666.It Cd options CPURESET_DELAY=value
1667specifies the time (in millisecond) to wait before doing a hardware reset
1668in the last phase of a reboot. This gives the user a chance to see error
1669messages from the shutdown operations (like NFS unmounts, buffer cache flush,
1670etc ...). Setting this to 0 will disable the delay. Default is 2 seconds.
1671.It Cd options MATH_EMULATE
1672Include the floating point emulator.
1673This is useful only for
1674.Tn CPU Ns s
1675that lack an
1676internal Floating Point Unit
1677.Pq Tn FPU
1678or co-processor.
1679.It Cd options VM86
1680Include support for virtual 8086 mode, used by
1681.Tn DOS
1682emulators and X servers to run BIOS code, e.g. for some VESA routines.
1683.It Cd options USER_LDT
1684Include i386-specific system calls for modifying the local descriptor table,
1685used by Windows emulators.
1686.It Cd options REALBASEMEM=integer
1687Overrides the base memory size passed in from the boot block.
1688(Value given in kilobytes.)
1689Use this option only if the boot block reports the size incorrectly.
1690(Note that some
1691.Tn BIOS Ns es
1692put the extended
1693.Tn BIOS
1694data area at the top of base memory, and therefore report a smaller
1695base memory size to prevent programs overwriting it.
1696This is correct behavior, and you should not use the
1697.Em REALBASEMEM
1698option to access this memory).
1699.It Cd options REALEXTMEM=integer
1700Overrides the extended memory size passed in from the boot block.
1701(Value given in kilobytes. Extended memory does not include the first megabyte.)
1702Use this option only if the boot block reports the size incorrectly.
1703.It Cd options FRENCH_KBD,FINNISH_KBD,GERMAN_KBD,NORWEGIAN_KBD
1704Select a non-US keyboard layout for the
1705.Em pccons
1706console driver.
1707.It Cd options CYRIX_CACHE_WORKS
1708Relevant only to the Cyrix 486DLC cpu. This option is used to turn on
1709the cache in hold-flush mode. It is not turned on by default because it
1710is known to have problems in certain motherboard implementations.
1711.It Cd options CYRIX_CACHE_REALLY_WORKS
1712Relevant only to the Cyrix 486DLC cpu. This option is used to turn on
1713the cache in write-back mode. It is not turned on by default because it
1714is known to have problems in certain motherboard implementations. In order
1715for this option to take effect, option
1716.Em CYRIX_CACHE_WORKS
1717must also be specified.
1718.It Cd options PCIBIOS
1719Enable support for initializing the
1720.Tn PCI
1721bus using information from the
1722.Tn BIOS .
1723See
1724.Xr pcibios 4
1725for details.
1726.El
1727.Ss isa-specific Options
1728Options specific to
1729.Xr isa 4
1730busses.
1731.Bl -ohang
1732.It Cd options PCIC_ISA_ALLOC_IOBASE=address, PCIC_ISA_ALLOC_IOSIZE=size
1733Control the section of IO bus space used for PCMCIA bus space mapping.
1734Ideally the probed defaults are satisfactory, however in practice
1735that is not always the case. See
1736.Xr pcmcia 4
1737for details.
1738.It Cd options PCIC_ISA_INTR_ALLOC_MASK=mask
1739Controls the allowable interrupts that may be used for
1740.Tn PCMCIA
1741devices. This mask is a logical-or of power-of-2s of allowable
1742interrupts:
1743.Bd -literal -offset 04n
1744.Em "IRQ Val      IRQ Val      IRQ Val       IRQ Val"
1745 0  0x0001    4  0x0010    8  0x0100    12  0x1000
1746 1  0x0002    5  0x0020    9  0x0200    13  0x2000
1747 2  0x0004    6  0x0040   10  0x0400    14  0x4000
1748 3  0x0008    7  0x0080   11  0x0800    15  0x8000
1749.Ed
1750.El
1751.Ss m68k-specific Options
1752.Bl -ohang
1753.It Cd options FPU_EMULATE
1754Include support for MC68881/MC68882 emulator.
1755.It Cd options FPSP
1756Include support for 68040 floating point.
1757.It Cd options M68020,M68030,M68040,M68060
1758Include support for a specific
1759.Tn CPU ,
1760at least one (the one you are using) should be specified.
1761.It Cd options M060SP
1762Include software support for 68060.
1763This provides emulation of unimplemented
1764integer instructions as well as emulation of unimplemented floating point
1765instructions and data types and software support for floating point traps.
1766.El
1767.Ss sparc-specific Options
1768.Bl -ohang
1769.It Cd options AUDIO_DEBUG
1770Enable simple event debugging of the logging of the
1771.Xr audio 4
1772device.
1773.It Cd options BLINK
1774Enable blinking of LED.  Blink rate is full cycle every N seconds for
1775N \*[Lt] then current load average.  See
1776.Xr getloadavg 3 .
1777.\" .It Cd options COLORFONT_CACHE
1778.\" this is totally fucked up.. what does this do?
1779.It Cd options COUNT_SW_LEFTOVERS
1780Count how many times the sw SCSI device has left 3, 2, 1 and 0 in the
1781sw_3_leftover, sw_2_leftover, sw_1_leftover, and sw_0_leftover
1782variables accessible from
1783.Xr ddb 4 .
1784See
1785.Xr sw 4 .
1786.It Cd options DEBUG_ALIGN
1787Adds debugging messages calls when user-requested alignment fault
1788handling happens.
1789.It Cd options DEBUG_EMUL
1790Adds debugging messages calls for emulated floating point and
1791alignment fixing operations.
1792.It Cd options DEBUG_SVR4
1793Prints registers messages calls for emulated SVR4 getcontext and
1794setcontext operations.  See
1795.Em options COMPAT_SVR4 .
1796.It Cd options EXTREME_DEBUG
1797Adds debugging functions callable from
1798.Xr ddb 4 .  The debug_pagetables, test_region and print_fe_map
1799functions print information about page tables for the SUN4M
1800platforms only.
1801.It Cd options EXTREME_EXTREME_DEBUG
1802Adds extra info to
1803.Em options EXTREME_DEBUG .
1804.It Cd options FPU_CONTEXT
1805Make
1806.Em options COMPAT_SVR4
1807getcontext and setcontext include floating point registers.
1808.It Cd options MAGMA_DEBUG
1809Adds debugging messages to the
1810.Xr magma 4
1811device.
1812.It Cd options RASTERCONS_FULLSCREEN
1813Use the entire screen for the console.
1814.It Cd options RASTERCONS_SMALLFONT
1815Use a the fixed font on the console, instead of the normal font.
1816.It Cd options SUN4
1817Support sun4 class machines.
1818.It Cd options SUN4C
1819Support sun4c class machines.
1820.It Cd options SUN4M
1821Support sun4m class machines.
1822.It Cd options SUN4_MMU3L
1823.\" XXX ???
1824Enable support for sun4 3-level MMU machines.
1825.It Cd options V9
1826Enable SPARC V9 assembler in
1827.Xr ddb 4 .
1828.El
1829.Ss sparc64-specific Options
1830.Bl -ohang
1831.It Cd options AUDIO_DEBUG
1832Enable simple event debugging of the logging of the
1833.Xr audio 4
1834device.
1835.It Cd options BLINK
1836Enable blinking of LED.  Blink rate is full cycle every N seconds for
1837N \*[Lt] then current load average.  See
1838.Xr getloadavg 3 .
1839.El
1840.Ss x68k-specific Options
1841.Bl -ohang
1842.It Cd options EXTENDED_MEMORY
1843Include support for extended memory e.g. TS-6BE16 and 060turbo on-board.
1844.It Cd options JUPITER
1845Include support for Jupiter-X MPU accelerator
1846.It Cd options ZSCONSOLE,ZSCN_SPEED=value
1847Use the built-in serial port as the system-console.
1848Speed is specified in bps, defaults to 9600.
1849.It Cd options ITE_KERNEL_ATTR=value
1850Set the kernel message attribute for ITE.
1851Value, an integer, is a logical or of the following values:
1852.Bl -tag -width 4n -compact -offset indent
1853.It 1
1854color inversed
1855.It 2
1856underlined
1857.It 4
1858bolded
1859.El
1860.El
1861.\" The following requests should be uncommented and used where appropriate.
1862.\" .Sh FILES
1863.\" .Sh EXAMPLES
1864.Sh SEE ALSO
1865.Xr gdb 1 ,
1866.Xr ktrace 1 ,
1867.Xr quota 1 ,
1868.Xr gettimeofday 2 ,
1869.Xr i386_iopl 2 ,
1870.Xr msgctl 2 ,
1871.Xr msgget 2 ,
1872.Xr msgrcv 2 ,
1873.Xr msgsnd 2 ,
1874.Xr ntp_adjtime 2 ,
1875.Xr ntp_gettime 2 ,
1876.Xr semctl 2 ,
1877.Xr semget 2 ,
1878.Xr semop 2 ,
1879.Xr shmat 2 ,
1880.Xr shmctl 2 ,
1881.Xr shmdt 2 ,
1882.Xr shmget 2 ,
1883.Xr sysctl 3 ,
1884.Xr apm 4 ,
1885.Xr ddb 4 ,
1886.Xr inet 4 ,
1887.Xr iso 4 ,
1888.Xr lkm 4 ,
1889.Xr md 4 ,
1890.Xr ns 4 ,
1891.Xr pcibios 4 ,
1892.Xr pcmcia 4 ,
1893.Xr config 8 ,
1894.Xr edquota 8 ,
1895.Xr init 8 ,
1896.Xr mdsetimage 8 ,
1897.Xr mount_cd9660 8 ,
1898.Xr mount_fdesc 8 ,
1899.Xr mount_kernfs 8 ,
1900.Xr mount_lfs 8 ,
1901.Xr mount_mfs 8 ,
1902.Xr mount_msdos 8 ,
1903.Xr mount_nfs 8 ,
1904.Xr mount_ntfs 8 ,
1905.Xr mount_null 8 ,
1906.Xr mount_portal 8 ,
1907.Xr mount_procfs 8 ,
1908.Xr mount_umap 8 ,
1909.Xr mount_union 8 ,
1910.Xr mrouted 8 ,
1911.Xr newfs_lfs 8 ,
1912.Xr ntpd 8 ,
1913.Xr quotaon 8 ,
1914.Xr rpc.rquotad 8 ,
1915.Xr sysctl 8
1916.Sh HISTORY
1917The
1918.Nm
1919man page first appeared in
1920.Nx 1.3 .
1921.Sh BUGS
1922The
1923.Em INET
1924and the
1925.Em VNODEPAGER
1926options should not be required.
1927The
1928.Em EON
1929option should be a pseudo-device, and is also very fragile.
1930