]> git.proxmox.com Git - systemd.git/blame - man/modules-load.d.5
Imported Upstream version 219
[systemd.git] / man / modules-load.d.5
CommitLineData
14228c0d 1'\" t
e735f4d4 2.TH "MODULES\-LOAD\&.D" "5" "" "systemd 219" "modules-load.d"
14228c0d
MB
3.\" -----------------------------------------------------------------
4.\" * Define some portability stuff
5.\" -----------------------------------------------------------------
6.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
7.\" http://bugs.debian.org/507673
8.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
9.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
10.ie \n(.g .ds Aq \(aq
11.el .ds Aq '
12.\" -----------------------------------------------------------------
13.\" * set default formatting
14.\" -----------------------------------------------------------------
15.\" disable hyphenation
16.nh
17.\" disable justification (adjust text to left margin only)
18.ad l
19.\" -----------------------------------------------------------------
20.\" * MAIN CONTENT STARTS HERE *
21.\" -----------------------------------------------------------------
22.SH "NAME"
23modules-load.d \- Configure kernel modules to load at boot
24.SH "SYNOPSIS"
25.PP
26/etc/modules\-load\&.d/*\&.conf
27.PP
28/run/modules\-load\&.d/*\&.conf
29.PP
30/usr/lib/modules\-load\&.d/*\&.conf
31.SH "DESCRIPTION"
32.PP
33\fBsystemd-modules-load.service\fR(8)
34reads files from the above directories which contain kernel modules to load during boot in a static list\&. Each configuration file is named in the style of
35/etc/modules\-load\&.d/\fIprogram\fR\&.conf\&. Note that it is usually a better idea to rely on the automatic module loading by PCI IDs, USB IDs, DMI IDs or similar triggers encoded in the kernel modules themselves instead of static configuration like this\&. In fact, most modern kernel modules are prepared for automatic loading already\&.
36.SH "CONFIGURATION FORMAT"
37.PP
38The configuration files should simply contain a list of kernel module names to load, separated by newlines\&. Empty lines and lines whose first non\-whitespace character is # or ; are ignored\&.
f47781d8 39.SH "CONFIGURATION DIRECTORIES AND PRECEDENCE"
14228c0d 40.PP
f47781d8
MP
41Configuration files are read from directories in
42/etc/,
43/run/, and
44/usr/lib/, in order of precedence\&. Each configuration file in these configuration directories shall be named in the style of
45\fIfilename\fR\&.conf\&. Files in
14228c0d
MB
46/etc/
47override files with the same name in
f47781d8 48/run/
14228c0d 49and
f47781d8 50/usr/lib/\&. Files in
14228c0d
MB
51/run/
52override files with the same name in
f47781d8
MP
53/usr/lib/\&.
54.PP
55Packages should install their configuration files in
56/usr/lib/\&. Files in
14228c0d 57/etc/
f47781d8 58are reserved for the local administrator, who may use this logic to override the configuration files installed by vendor packages\&. All configuration files are sorted by their filename in lexicographic order, regardless of which of the directories they reside in\&. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence\&. It is recommended to prefix all filenames with a two\-digit number and a dash, to simplify the ordering of the files\&.
14228c0d
MB
59.PP
60If the administrator wants to disable a configuration file supplied by the vendor, the recommended way is to place a symlink to
61/dev/null
f47781d8
MP
62in the configuration directory in
63/etc/, with the same filename as the vendor configuration file\&.
14228c0d
MB
64.SH "EXAMPLE"
65.PP
66\fBExample\ \&1.\ \&/etc/modules-load.d/virtio-net.conf example:\fR
67.sp
68.if n \{\
69.RS 4
70.\}
71.nf
72# Load virtio\-net\&.ko at boot
73virtio\-net
74.fi
75.if n \{\
76.RE
77.\}
78.SH "SEE ALSO"
79.PP
80\fBsystemd\fR(1),
81\fBsystemd-modules-load.service\fR(8),
82\fBsystemd-delta\fR(1),
83\fBmodprobe\fR(8)