1.\" Copyright (c) 1990, 1993 2.\" The Regents of the University of California. All rights reserved. 3.\" 4.\" Redistribution and use in source and binary forms, with or without 5.\" modification, are permitted provided that the following conditions 6.\" are met: 7.\" 1. Redistributions of source code must retain the above copyright 8.\" notice, this list of conditions and the following disclaimer. 9.\" 2. Redistributions in binary form must reproduce the above copyright 10.\" notice, this list of conditions and the following disclaimer in the 11.\" documentation and/or other materials provided with the distribution. 12.\" 3. Neither the name of the University nor the names of its contributors 13.\" may be used to endorse or promote products derived from this software 14.\" without specific prior written permission. 15.\" 16.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 17.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 18.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 19.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 20.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 21.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 22.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 23.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 24.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 25.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 26.\" SUCH DAMAGE. 27.\" 28.\" @(#)hier.7 8.1 (Berkeley) 6/5/93 29.\" $FreeBSD$ 30.\" 31.Dd November 16, 2017 32.Dt HIER 7 33.Os 34.Sh NAME 35.Nm hier 36.Nd layout of file systems 37.Sh DESCRIPTION 38A sketch of the file system hierarchy. 39.Bl -tag -width "/libexec/" 40.It Pa / 41root directory of the file system 42.It Pa /bin/ 43user utilities fundamental to both single-user and multi-user environments 44.It Pa /boot/ 45programs and configuration files used during operating system bootstrap 46.Pp 47.Bl -tag -width "defaults/" -compact 48.It Pa defaults/ 49default bootstrapping configuration files; see 50.Xr loader.conf 5 51.It Pa dtb/ 52Compiled flattened device tree (FDT) files; see 53.Xr fdt 4 54and 55.Xr dtc 1 56.It Pa firmware/ 57loadable kernel modules containing binary firmware for hardware that needs 58firmware downloaded to it to function 59.It Pa kernel/ 60pure kernel executable (the operating system loaded into memory 61at boot time) and kernel modules 62.It Pa modules/ 63third-party loadable kernel modules; 64see 65.Xr kldstat 8 66.It Pa zfs/ 67.Xr zfs 8 68zpool cache files 69.El 70.It Pa /cdrom/ 71default mount point for CD-ROM drives 72.It Pa /compat/ 73normally a link to 74.Pa /usr/compat . 75If not, then the 76.Pa /usr/compat 77comments apply 78.It Pa /dev/ 79device special files managed by 80.Xr devfs 5 81.Pp 82.Bl -tag -width "net/" -compact 83.It Pa fd/ 84file descriptor files; 85see 86.Xr \&fd 4 87.El 88.It Pa /etc/ 89system configuration files and scripts 90.Pp 91.Bl -tag -width "bluetooth/" -compact 92.It Pa defaults/ 93default system configuration files; 94see 95.Xr rc 8 96.It Pa bluetooth/ 97bluetooth configuration files 98.It Pa localtime 99local timezone information; 100see 101.Xr ctime 3 102.It Pa mail/ 103Sendmail control files 104.It Pa mtree/ 105mtree configuration files; 106see 107.Xr mtree 8 108.It Pa pam.d/ 109configuration files for the Pluggable Authentication Modules (PAM) 110library 111.It Pa periodic/ 112scripts that are run daily, weekly, and monthly, via 113.Xr cron 8 ; 114see 115.Xr periodic 8 116.It Pa rc.d/ 117system and daemon startup/control scripts; 118see 119.Xr rc 8 120.It Pa security/ 121OpenBSM audit configuration files; 122see 123.Xr audit 8 124.It Pa ppp/ 125ppp configuration files; 126see 127.Xr ppp 8 128.It Pa ssh/ 129OpenSSH configuration files; 130see 131.Xr ssh 1 132.It Pa ssl/ 133OpenSSL configuration files 134.El 135.It Pa /lib/ 136critical system libraries needed for binaries in 137.Pa /bin 138and 139.Pa /sbin 140.Pp 141.Bl -tag -width "geom/" -compact 142.It Pa geom/ 143class-specific libraries for the 144.Xr geom 8 145utility 146.El 147.It Pa /libexec/ 148critical system utilities needed for binaries in 149.Pa /bin 150and 151.Pa /sbin 152.It Pa /media/ 153contains subdirectories to be used as mount points 154for removable media such as CDs, USB drives, and 155floppy disks 156.It Pa /mnt/ 157empty directory commonly used by 158system administrators as a temporary mount point 159.It Pa /net/ 160automounted NFS shares; 161see 162.Xr auto_master 5 163.It Pa /proc/ 164process file system; 165see 166.Xr procfs 5 167.It Pa /rescue/ 168statically linked programs for emergency recovery; 169see 170.Xr rescue 8 171.It Pa /root/ 172root's HOME directory 173.It Pa /sbin/ 174system programs and administration utilities 175fundamental to both single-user and multi-user environments 176.It Pa /tmp/ 177temporary files that are not guaranteed to persist across system reboots 178.It Pa /usr/ 179contains the majority of user utilities and applications 180.Pp 181.Bl -tag -width "libdata/" -compact 182.It Pa bin/ 183common utilities, programming tools, and applications 184.It Pa compat/ 185files needed to support binary compatibility with other operating systems, 186such as Linux 187.It Pa include/ 188standard C include files 189.Pp 190.Bl -tag -width "kerberos5/" -compact 191.It Pa arpa/ 192C include files for Internet service protocols 193.It Pa bsnmp/ 194C include files for the SNMP daemon 195.It Pa c++/ 196C++ include files 197.It Pa cam/ 198C include files for the Common Access Methods Layer 199.Bl -tag -width "kerberos5/" -compact 200.It Pa scsi/ 201SCSI device on top of CAM 202.El 203.It Pa dev/ 204C include files for programming various 205.Fx 206devices 207.Bl -tag -width "kerberos5/" -compact 208.It Pa ic/ 209various header files describing driver- and bus-independent 210hardware circuits 211.It Pa ofw/ 212Open Firmware support 213.It Pa pbio/ 2148255 PPI cards; 215see 216.Xr pbio 4 217.It Pa ppbus/ 218parallel port bus; 219see 220.Xr ppbus 4 221.It Pa usb/ 222USB subsystem 223.It Pa wi/ 224.Xr wi 4 225WaveLAN driver 226.El 227.It Pa fs/ 228.Bl -tag -width "kerberos5/" -compact 229.It Pa fdescfs/ 230per-process file descriptors file system 231.It Pa msdosfs/ 232MS-DOS file system 233.It Pa nfs/ 234C include files for NFS (Network File System) version 2, 3 and 4 235.It Pa nullfs/ 236loopback file system 237.It Pa procfs/ 238process file system 239.It Pa smbfs/ 240SMB/CIFS file system 241.It Pa udf/ 242UDF file system 243.It Pa unionfs 244union file system 245.El 246.It Pa geom/ 247GEOM framework 248.Bl -tag -width "kerberos5/" -compact 249.It Pa concat/ 250CONCAT GEOM class 251.It Pa gate/ 252GATE GEOM class 253.It Pa mirror/ 254MIRROR GEOM class 255.It Pa nop/ 256NOP GEOM class 257.It Pa raid3/ 258RAID3 GEOM class 259.It Pa stripe/ 260STRIPE GEOM class 261.El 262.Pp 263.It Pa libmilter/ 264C include files for libmilter, 265the 266.Xr sendmail 8 267mail filter API 268.It Pa machine/ 269machine-specific C include files 270.It Pa net/ 271miscellaneous network C include files 272.Bl -tag -width "altq/" -compact 273.It Pa altq/ 274C include files for alternate queueing 275.El 276.It Pa net80211/ 277C include files for 802.11 wireless networking; 278see 279.Xr net80211 4 280.It Pa netinet/ 281C include files for Internet standard protocols; 282see 283.Xr inet 4 284.It Pa netinet6/ 285C include files for Internet protocol version 6; 286see 287.Xr inet6 4 288.It Pa netipsec/ 289kernel key-management service; 290see 291.Xr ipsec 4 292.It Pa netsmb/ 293SMB/CIFS requester 294.It Pa nfs/ 295C include files for NFS (Network File System) version 2 and 3 (legacy) 296.It Pa openssl/ 297OpenSSL (Cryptography/SSL toolkit) headers 298.It Pa protocols/ 299C include files for Berkeley service protocols 300.It Pa rpc/ 301remote procedure calls; 302see 303.Xr rpc 3 304.It Pa rpcsvc/ 305definition of RPC service structures; see 306.Xr rpc 3 307.It Pa security/ 308PAM; see 309.Xr pam 8 310.It Pa sys/ 311system C include files (kernel data structures) 312.\" .It Pa tcl/ 313.\" Tcl language; 314.\" see 315.\" .Xr Tcl n 316.\" .Bl -tag -width "kerberos5/" -compact 317.\" .It Pa generic/ 318.\" ??? 319.\" .It Pa unix/ 320.\" ??? 321.\" .El 322.It Pa ufs/ 323C include files for UFS (The U-word File System) 324.Bl -tag -width "kerberos5/" -compact 325.It Pa ffs/ 326Fast file system 327.It Pa ufs/ 328UFS file system 329.El 330.It Pa vm/ 331virtual memory; 332see 333.Xr vmstat 8 334.El 335.Pp 336.It Pa lib/ 337shared and archive 338.Xr ar 1 Ns -type 339libraries 340.Bl -tag -width Fl -compact 341.It Pa aout/ 342a.out archive libraries 343.It Pa compat/ 344shared libraries for compatibility 345.Bl -tag -width Fl -compact 346.It Pa aout/ 347a.out backward compatibility libraries 348.El 349.It Pa debug/ 350standalone debug data for the kernel and base system libraries and binaries 351.It Pa dtrace/ 352DTrace library scripts 353.It Pa engines/ 354OpenSSL (Cryptography/SSL toolkit) dynamically loadable engines 355.El 356.Pp 357.It Pa libdata/ 358miscellaneous utility data files 359.Bl -tag -width Fl -compact 360.It Pa gcc/ 361.Xr gcc 1 362configuration data 363.It Pa ldscripts/ 364linker scripts; 365see 366.Xr ld 1 367.El 368.Pp 369.It Pa libexec/ 370system daemons & system utilities (executed by other programs) 371.Bl -tag -width Fl -compact 372.It Pa aout/ 373utilities to manipulate a.out executables 374.It Pa elf/ 375utilities to manipulate ELF executables 376.It Pa lpr/ 377utilities and filters for LP print system; 378see 379.Xr lpr 1 380.It Pa sendmail/ 381the 382.Xr sendmail 8 383binary; 384see 385.Xr mailwrapper 8 386.It Pa sm.bin/ 387restricted shell for 388.Xr sendmail 8 ; 389see 390.Xr smrsh 8 391.El 392.Pp 393.It Pa local/ 394local executables, libraries, etc. 395Also used as the default destination for the 396.Xr ports 7 397framework. 398Within 399.Pa local/ , 400the general layout sketched out by 401.Nm 402for 403.Pa /usr 404should be used. 405Exceptions are the 406.Pa man 407directory 408.Po directly under 409.Pa local/ 410rather than under 411.Pa local/share/ Ns Pc , 412ports documentation 413.Po in 414.Pa share/doc/<port>/ Ns Pc , 415and 416.Pa /usr/local/etc 417.Po mimics 418.Pa /etc Ns Pc . 419.It Pa obj/ 420architecture-specific target tree produced by building the 421.Pa /usr/src 422tree 423.It Pa ports/ 424.Xr ports 7 , 425the 426.Fx 427ports collection. 428.It Pa sbin/ 429system daemons & system utilities (executed by users) 430.It Pa share/ 431architecture-independent files 432.Pp 433.Bl -tag -width "calendar/" -compact 434.It Pa calendar/ 435a variety of pre-fab calendar files; 436see 437.Xr calendar 1 438.It Pa dict/ 439word lists; 440see 441.Xr look 1 442.Pp 443.Bl -tag -width Fl -compact 444.It Pa freebsd 445.Fx Ns -specific 446terms, proper names, and jargon 447.It Pa web2 448words from Webster's 2nd International 449.El 450.Pp 451.It Pa doc/ 452miscellaneous documentation; 453source for most of the printed 454.Bx 455manuals (available 456from the 457.Tn USENIX 458association) 459.Bl -tag -width Fl -compact 460.It Pa FAQ/ 461Frequently Asked Questions 462.It Pa IPv6/ 463implementation notes for IPv6 464.It Pa es/ 465Spanish translations of documents in /usr/share/doc 466.It Pa handbook/ 467.Fx 468Handbook 469.It Pa ja/ 470Japanese translations of documents in /usr/share/doc 471.It Pa legal/ 472License files for vendor supplied firmwares 473.It Pa ncurses/ 474HTML documents pertaining to ncurses; 475see 476.Xr ncurses 3 477.It Pa ntp/ 478HTML documents pertaining to the Network Time Protocol 479.It Pa ru/ 480Russian translations of documents in /usr/share/doc 481.It Pa tutorials/ 482.Fx 483tutorials 484.It Pa zh/ 485Chinese translations of documents in /usr/share/doc 486.El 487.Pp 488.It Pa examples/ 489various examples for users and programmers 490.It Pa firmware/ 491firmware images loaded by userland programs 492.It Pa games/ 493ASCII text files used by various games 494.It Pa keys/ 495known trusted and revoked keys. 496.Bl -tag -width "pkg/" -compact 497.It Pa pkg/ 498fingerprints for 499.Xr pkg 7 500and 501.Xr pkg 8 502.El 503.Pp 504.It Pa locale/ 505localization files; 506see 507.Xr setlocale 3 508.It Pa man/ 509manual pages 510.It Pa misc/ 511miscellaneous system-wide ASCII text files 512.Bl -tag -width Fl -compact 513.It Pa fonts/ 514??? 515.It Pa termcap 516terminal characteristics database; 517see 518.Xr termcap 5 519.El 520.It Pa mk/ 521templates for make; 522see 523.Xr make 1 524.It Pa nls/ 525national language support files; 526see 527.Xr mklocale 1 528.It Pa security/ 529data files for security policies such as 530.Xr mac_lomac 4 531.It Pa sendmail/ 532.Xr sendmail 8 533configuration files 534.It Pa skel/ 535example 536.Pa .\& 537(dot) files for new accounts 538.It Pa snmp/ 539MIBs, example files and tree definitions for the SNMP daemon. 540.Bl -tag -width Fl -compact 541.It Pa defs/ 542tree definition files for use with 543.Xr gensnmptree 1 544.It Pa mibs/ 545MIB files 546.El 547.It Pa syscons/ 548files used by syscons; 549see 550.Xr syscons 4 551.Bl -tag -width "scrnmaps/" -compact 552.It Pa fonts/ 553console fonts; 554see 555.Xr vidcontrol 1 556and 557.Xr vidfont 1 558.It Pa keymaps/ 559console keyboard maps; 560see 561.Xr kbdcontrol 1 562and 563.Xr kbdmap 1 564.It Pa scrnmaps/ 565console screen maps 566.El 567.It Pa tabset/ 568tab description files for a variety of terminals; used in 569the termcap file; 570see 571.Xr termcap 5 572.It Pa vi/ 573localization support and utilities for 574.Xr vi 1 575.It Pa vt/ 576files used by vt; 577see 578.Xr vt 4 579.Bl -tag -width "scrnmaps/" -compact 580.It Pa fonts/ 581console fonts; 582see 583.Xr vidcontrol 1 584and 585.Xr vidfont 1 586.It Pa keymaps/ 587console keyboard maps; 588see 589.Xr kbdcontrol 1 590and 591.Xr kbdmap 1 592.\" .It Pa scrnmaps/ 593.\" console screen maps 594.El 595.It Pa zoneinfo/ 596timezone configuration information; 597see 598.Xr tzfile 5 599.El 600.It Pa src/ 601.Bx , 602third-party, and/or local source files 603.Pp 604.Bl -tag -width "kerberos5/" -compact 605.It Pa bin/ 606source code for files in /bin 607.It Pa cddl/ 608utilities covered by the Common Development and Distribution License 609.It Pa contrib/ 610source code for contributed software 611.It Pa crypto/ 612source code for contributed cryptography software 613.It Pa etc/ 614source code for files in 615.Pa /etc 616.It Pa gnu/ 617utilities covered by the GNU General Public License 618.It Pa include/ 619source code for files in 620.Pa /usr/include 621.It Pa kerberos5/ 622build infrastructure for kerberos version 5 623.It Pa lib/ 624source code for files in 625.Pa /lib 626and 627.Pa /usr/lib 628.It Pa libexec/ 629source code for files in 630.Pa /usr/libexec 631.It Pa release/ 632files required to produce a 633.Fx 634release 635.It Pa rescue/ 636source code for files in 637.Pa /rescue 638.It Pa sbin/ 639source code for files in 640.Pa /sbin 641.It Pa secure/ 642build directory for files in 643.Pa /usr/src/crypto 644.It Pa share/ 645source for files in 646.Pa /usr/share 647.It Pa sys/ 648kernel source code 649.Bl -tag -width "opencrypto/" -compact 650.It Pa amd64/ 651AMD64 architecture support 652.It Pa arm/ 653ARM architecture support 654.It Pa arm64/ 655ARMv8 architecture support 656.It Pa boot/ 657bootloader code 658.It Pa cam/ 659.Xr cam 4 660and 661.Xr ctl 4 662.It Pa cddl/ 663CDDL-licensed optional sources, including ZFS 664and DTrace 665.It Pa ddb/ 666.Xr ddb 4 667.It Pa fs/ 668most filesystems 669.It Pa dev/ 670device drivers 671.It Pa geom/ 672.Xr geom 4 673.It Pa i386/ 674i386 (32 bit) architecture support 675.It Pa kern/ 676main part of the kernel 677.It Pa mips/ 678MIPS architecture support 679.It Pa net80211/ 680.Xr net80211 4 681.It Pa netgraph/ 682.Xr netgraph 4 683.It Pa netinet/ 684.Xr inet 4 685.It Pa netinet6/ 686.Xr inet6 4 687.It Pa netipsec/ 688.Xr ipsec 4 689.It Pa netpfil/ 690.Xr ipfw 4 691and 692.Xr pf 4 693.It Pa opencrypto/ 694.Xr crypto 7 695.It Pa powerpc/ 696PowerPC/POWER architecture support 697.It Pa riscv/ 698RISC-V architecture support 699.It Pa security/ 700.Xr audit 4 701and 702.Xr mac 4 703.It Pa sparc64/ 704SPARC64 architecture support 705.It Pa sys/ 706kernel headers 707.It Pa ufs/ 708Unix File System 709.It Pa x86/ 710code shared by AMD64 and i386 architectures 711.El 712.It Pa targets/ 713support for experimental DIRDEPS_BUILD 714.It Pa tests/ 715source code for files in 716.Pa /usr/tests 717.It Pa tools/ 718tools used for maintenance and testing of 719.Fx 720.It Pa usr.bin/ 721source code for files in 722.Pa /usr/bin 723.It Pa usr.sbin/ 724source code for files in 725.Pa /usr/sbin 726.El 727.Pp 728.It Pa tests/ 729The 730.Fx 731test suite. 732See 733.Xr tests 7 734for more details. 735.El 736.It Pa /var/ 737multi-purpose log, temporary, transient, and spool files 738.Pp 739.Bl -tag -width "preserve/" -compact 740.It Pa account/ 741system accounting files 742.Pp 743.Bl -tag -width Fl -compact 744.It Pa acct 745execution accounting file; 746see 747.Xr acct 5 748.El 749.Pp 750.It Pa at/ 751timed command scheduling files; 752see 753.Xr \&at 1 754.Bl -tag -width "preserve/" -compact 755.It Pa jobs/ 756directory containing job files 757.It Pa spool/ 758directory containing output spool files 759.El 760.Pp 761.It Pa backups/ 762miscellaneous backup files 763.It Pa cache/ 764miscellaneous cached files 765.Bl -tag -width "pkg/" -compact 766.It Pa pkg/ 767cached packages for 768.Xr pkg 8 769.El 770.Pp 771.It Pa crash/ 772default directory to store kernel crash dumps; see 773.Xr crash 8 774and 775.Xr savecore 8 776.It Pa cron/ 777files used by cron; 778see 779.Xr cron 8 780.Bl -tag -width "preserve/" -compact 781.It Pa tabs/ 782crontab files; 783see 784.Xr crontab 5 785.El 786.Pp 787.It Pa db/ 788miscellaneous automatically generated system-specific database files 789.It Pa empty/ 790empty directory for use by programs that need a specifically empty directory. 791Used for instance by 792.Xr sshd 8 793for privilege separation. 794.It Pa games/ 795miscellaneous game status and score files 796.It Pa heimdal/ 797kerberos server databases; see 798.Xr kdc 8 799.It Pa log/ 800miscellaneous system log files 801.Pp 802.Bl -tag -width Fl -compact 803.It Pa utx.lastlogin 804last login log; 805see 806.Xr getutxent 3 807.It Pa utx.log 808login/logout log; 809see 810.Xr getutxent 3 811.El 812.Pp 813.It Pa mail/ 814user mailbox files 815.It Pa msgs/ 816system messages database; 817see 818.Xr msgs 1 819.It Pa preserve/ 820temporary home of files preserved after an accidental death 821of an editor; 822see 823.Xr \&ex 1 824.It Pa quotas/ 825file system quota information files 826.It Pa run/ 827system information files describing various info about 828system since it was booted 829.Pp 830.Bl -tag -width Fl -compact 831.It Pa ppp/ 832writable by the 833.Dq network 834group for command connection sockets; see 835.Xr ppp 8 836.It Pa utx.active 837database of current users; 838see 839.Xr getutxent 3 840.El 841.Pp 842.It Pa rwho/ 843rwho data files; 844see 845.Xr rwhod 8 , 846.Xr rwho 1 , 847and 848.Xr ruptime 1 849.It Pa spool/ 850miscellaneous printer and mail system spooling directories 851.Pp 852.Bl -tag -width Fl -compact 853.It Pa clientmqueue/ 854undelivered submission mail queue; 855see 856.Xr sendmail 8 857.It Pa ftp/ 858commonly ~ftp; the anonymous ftp root directory 859.It Pa mqueue/ 860undelivered mail queue; 861see 862.Xr sendmail 8 863.It Pa output/ 864line printer spooling directories 865.El 866.Pp 867.It Pa tmp/ 868temporary files that are kept between system reboots 869.Bl -tag -width Fl -compact 870.It Pa vi.recover/ 871the directory where recovery files are stored 872.El 873.It Pa yp/ 874the NIS maps 875.El 876.El 877.Sh NOTES 878This manual page documents the default 879.Fx 880file system layout, but 881the actual hierarchy on a given system is defined at the system 882administrator's discretion. 883A well-maintained installation will include a customized version of 884this document. 885.Sh SEE ALSO 886.Xr apropos 1 , 887.Xr find 1 , 888.Xr finger 1 , 889.Xr grep 1 , 890.Xr ls 1 , 891.Xr whatis 1 , 892.Xr whereis 1 , 893.Xr which 1 , 894.Xr fd 4 , 895.Xr devfs 5 , 896.Xr fsck 8 897.Sh HISTORY 898A 899.Nm 900manual page appeared in 901.At v7 . 902