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