DEV Community

Adam La Rosa
Adam La Rosa

Posted on

The OpenBSD /etc Directory

One of the many reasons I like OpenBSD so much is the documentation. While one might know that configuration files are located in the /etc directory, what might be more confusing is what all these files do. In the /etc directory of a OpenBSD 6.6 machine I have looks as such.

X11            examples       hosts          login.conf     mtree          pf.os          rmt            ssh
acme           fbtab          hotplug        magic          mygate         ppp            rpc            ssl
amd            firmware       iked           mail           myname         protocols      rpki           syslog.conf
authpf         fonts          installurl     mail.rc        netstart       pwd.db         services       termcap
changelist     fstab          isakmpd        mailer.conf    newsyslog.conf random.seed    shells         ttys
daily          ftpusers       ksh.kshrc      master.passwd  npppd          rc             signify        weekly
disktab        gettytab       ldap           moduli         ntpd.conf      rc.conf        skel
doas.conf      group          localtime      monthly        passwd         rc.d           soii.key
dumpdates      hostname.rl0   locate.rc      motd           pf.conf        resolv.conf    spwd.db

The file "hostname.rl0" for example. If you want to learn what the "hostname" file does all one needs to do is enter "man hostname" at the command line.

HOSTNAME(1)                 General Commands Manual                HOSTNAME(1)

NAME
     hostname - set or print name of current host system

SYNOPSIS
     hostname [-s] [name-of-host]

DESCRIPTION
     The hostname utility is used to set or print the name of the current
     host.  If no argument is given, the name of the current host is printed.

     The host name can be set by the superuser either by specifying
     name-of-host, or by supplying a myname(5) file, which is used at system
     boot time by netstart(8) to initialize the hostname.

Furthermore, the "rl0" device that "hostname" is connected to also has it's own manual page, "rl"

RL(4)                        Device Drivers Manual                       RL(4)

NAME
     rl - Realtek 8129/8139 10/100 Ethernet device

SYNOPSIS
     rl* at pci?
     rl* at cardbus?
     rlphy* at mii?

DESCRIPTION
     The rl driver provides support for PCI Ethernet adapters and embedded
     controllers based on the Realtek 8129 and 8139 Fast Ethernet controller
     chips.  This includes, among others, the following cards:

Using the manual pages, one can set up an network device to either broadcast or receive network traffic.

Top comments (0)