RC.CONF(5)

NAME
rc.conf - system startup configuration file

DESCRIPTION
The rc.conf file specifies which services are enabled during system startup by the startup script /etc/rc. The rc.conf file is a shell script that is sourced by /etc/rc if it exists, meaning that rc.conf must contain valid shell commands.

Listed below are the rc.conf variables that may be set, the values to which each may be set, a brief description of what each variable does, and a reference to relevant manual pages.

Most variables are one of two types: enabling variables or flags variables. Enabling variables, such as inetd, are generally named after the program or the system they enable, and are set to "YES" or "NO". Flags variables, such as inetd_flags have the same name with "_flags" appended, and determine what arguments are passed to the program if it is enabled.

If a variable that /etc/rc expects to be set is not set, or the value is not one of the allowed values, a warning will be printed.

  Basic network configuration:

hostname
    Name of host. If empty or not set, then the contents of /etc/myname (if it exists) are used.

domainname
    NIS (YP) domain of host. If empty or not set, then the contents of /etc/defaultdomain (if it exists) are used.

defaultroute
    Default network route. If empty or not set, then the contents of /etc/mygate (if it exists) are used.

  Boottime file-system and swap configuration:

critical_filesystems
    File systems mounted very early in the system boot, except for the /usr and /var file-systems.

critfs_require_network
    YES or NO. Set the critfs_require_network variable to YES if the network must be configured before critical filesystems can be mounted. This should be set to NO if you are using the DHCP client, because the DHCP client needs to store its lease database in the /var/db directory.

no_swap
    Set the no_swap variable to YES if you have configured your system with no swap on purpose. If not set, or set to anything other than YES, and no swap devices are configured, the system will warn you.

  One-time actions to perform or programs to run on boot-up:

lkm YES or NO. Runs /etc/rc.lkm.

savecore
    YES or NO. Runs the savecore(8) utility. Passes savecore_flags.

update_motd
    YES or NO. Updates the NetBSD version string in the /etc/motd file to reflect the version of the running kernel. See motd(5).

  System security setting:

securelevel
    A number. The system securelevel is set to the specified value early in the boot process, before any external logins, or other programs that run users job, are started. If set to nothing, the default action is taken, as described init(8), which contains definative information about the system securelevel.

  Networking startup:

ipfilter
    YES or NO. Runs ipf(8) to load in packet filter specifications from /etc/ipf.conf at network boot time, before any interfaces are configured. See ipf(5).

auto_ifconfig
    YES or NO. Sets the net_interfaces variable (see below) to the output of ifconfig(8) with the -l flag and suppresses warnings about interfaces in this list that do not have an ifconfig file or variable.

net_interfaces
    The list of network interfaces to be configured at boot time. For each interface "xxn", the system first looks for ifconfig parameters in /etc/ifconfig.xxn and then in the variable ifconfig_xxn. The contents of the file or the variable are handed to ifconfig after the interface name. If auto_ifconfig is set to "NO" and neither the file nor the variable is found, a warning is printed.

ifaliases_*
    List of ‘address netmask’ pairs to configure additional network addresses for the given configured interface “*” (e.g. ifaliases_le0). If netmask is “-”, then use the default netmask for the interface.

flushroutes
    YES or NO. Flushes the route table on networking startup. Useful when coming up to multiuser mode after going down to single-user mode.

dhclient
    YES or NO. Set to YES to configure some or all network interfaces using the DHCP client. If you set dhclient to YES, you must either set critfs_require_network to NO or direct the DHCP client to store the leases file on the root filesystem by modifying the dhclient_flags variable. You must not provide ifconfig information or ifaliases information for any interface that is to be configured using the DHCP client. Interface aliases can be set up in the DHCP client configuration file if needed - see dhclient.conf(5) for details.

dhclient_flags
    Flags to pass to the DHCP client. See dhclient(8) for complete documentation. If you wish to configure all broadcast network interfaces using the DHCP client, you can leave this blank. To configure only specific interfaces, name the interfaces to be configured on the command line.

    If you must run the DHCP client before mounting critical filesystems, then you should specify an alternate location for the DHCP client's lease file in the dhclient_flags variable - for example, "-lf /tmp/dhclient.leases".

ntpdate
    YES or NO. Runs ntpdate(8) to set the system time from one of the hosts in ntpdate_hosts. If ntpdate_hosts is empty, it will attempt to find a list of hosts in /etc/ntp.conf.

ppp_peers
    If ppp_peers is not empty, then /etc/netstart will check each word in ppp_peers for a coresponding ppp configuration file in /etc/ppp/peers and will call pppd(8) with the “call peer” option.

  Daemons required by other daemons:

inetd
    YES or NO. Runs the inetd(8) daemon to start network server processes (as listed in /etc/inetd.conf) as necessary. Passes inetd_flags. The -l flag turns on libwrap connection logging.

portmap
    YES or NO. The portmap(8) daemon is required for any rpc(3) services. These include NFS, NIS, bootparamd(8), rstatd(8), rusersd(8), and rwalld(8).

  Commonly used daemons:

update
    YES or NO. Runs update(8) and passes update_flags.

syslogd
    YES or NO. Runs syslogd(8) and passes syslogd_flags.

named
    YES or NO. Runs named(8) and passes named_flags.

timed
    YES or NO. Runs timed(8) and passes timed_flags. The -M option allows timed(8) to be a master time source as well as a slave. If you are also running xntpd(8), only one machine running both should have the -M flag given to timed(8).

xntpd
    YES or NO. Runs xntpd(8) and passes xntpd_flags.

sendmail
    YES or NO. Runs sendmail(8) and passes sendmail_flags.

lpd YES or NO. Runs lpd(8) and passes lpd_flags. The -l flag will turn on extra logging.

  Routing daemons:

routed
    YES or NO. Runs routed(8), the RIP routing protocol daemon. Passes routed_flags. This should be NO if gated is YES.

gated
    YES or NO. Runs gated(8), the multiprotocol routing daemon. Passes gated_flags. This should be NO if routed is YES. gated(8) is not included with NetBSD.

mrouted
    YES or NO. Runs mrouted(8), the DVMRP multicast routing protocol daemon. Passes mrouted_flags.

  Daemons used to boot other hosts over a network:

rarpd
    YES or NO. Runs rarpd(8), the reverse ARP daemon, often used to boot NetBSD and Sun workstations. Passes rarpd_flags.

bootparamd
    YES or NO. Runs bootparamd(8), the boot parameter server, with bootparamd_flags as options. Used to boot NetBSD and SunOS 4.x systems.

dhcpd
    YES or NO. Runs dhcpd(8), the Dynamic Host Configuration Protocol (DHCP) daemon, for assigning IP addresses to hosts and passing boot information. Passes dhcpd_flags.

rbootd
    YES or NO. Runs rbootd(8), the HP boot protocol daemon; used for booting HP workstations. Passes rbootd_flags.

mopd
    YES or NO. Runs mopd(8), the DEC MOP protocol daemon; used for booting VAX and other DEC machines. Passes mopd_flags.

  NIS (YP) daemons:

ypbind
    YES or NO. Runs ypbind(8), which lets NIS (YP) clients use information from a NIS server. Passes ypbind_flags.

ypserv
    YES or NO. Runs ypserv(8), the NIS (YP) server for distributing information from certain files in /etc. Passes ypserv_flags. The -d flag causes it to use DNS for lookups in /etc/hosts that fail.

yppasswdd
    YES or NO. Runs yppasswdd(8), which allows remote NIS users to update password on master server. Passes yppasswdd_flags.

  NFS daemons and parameters:

nfs_client
    YES or NO. Runs nfsiod(8) to increase performance of an NFS client host. Passes nfsiod_flags.

nfs_server
    YES or NO. Sets up a host to be a NFS server by running mountd(8) and nfsd(8), and passing mountd_flags and nfsd_flags to them, respectively.

lockd
    YES or NO. Runs rpc.lockd(8) if either nfs_server or nfs_client is (or both are) set to YES. Passes lockd_flags.

statd
    YES or NO. Runs rpc.statd(8), a status monitoring daemon used when rpc.lockd(8) is running, if either nfs_server or nfs_client is (or both are) set to YES. Passes statd_flags.

amd YES or NO. Runs amd(8), the automounter daemon, which automatically mounts NFS file systems whenever a file or directory within that filesystem is accessed. Passes amd_flags.

amd_dir
    The amd(8) mount directory. Used only if amd is set to YES.

amd_master
    The amd(8) automounter master map. Used only if amd is set to YES.

  X Window System daemons:

xfs YES or NO. Runs the xfs(1) X11 font server, which supplies local X font files to X terminals.

xdm YES or NO. Runs the xdm(1) X display manager. These X daemons are available only with the optional X distribution of NetBSD.

  Other daemons:

apmd
    YES or NO. Runs apmd(8) and passes apmd_flags.

rwhod
    YES or NO. Runs rwhod(8) to support the rwho(1) and ruptime(1) commands.

kerberos
    YES or NO. Runs the kerberos server kerberos(8) and the kerberos admininstration server, kadmind(8). This should only be run on the kerberos master server. Both servers implement version IV of the Kerberos protocol, not the newer Kerberos version 5. The kerberos server is only available with the USA distribution of NetBSD.

screenblank
    YES or NO. Runs screenblank(1) and passes screenblank_flags.

FILES
/etc/rc.conf

SEE ALSO
boot(8), rc(8)

HISTORY
The rc.conf file appeared in NetBSD 1.3.