mkinitrd.8: Remove some trailing whitespace.
[dragonfly.git] / sbin / mkinitrd / mkinitrd.8
CommitLineData
ae14c9db
AH
1.\"
2.\" Copyright (c) 2010 The DragonFly Project. 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.\"
8.\" 1. Redistributions of source code must retain the above copyright
9.\" notice, this list of conditions and the following disclaimer.
10.\" 2. Redistributions in binary form must reproduce the above copyright
11.\" notice, this list of conditions and the following disclaimer in
12.\" the documentation and/or other materials provided with the
13.\" distribution.
14.\" 3. Neither the name of The DragonFly Project nor the names of its
15.\" contributors may be used to endorse or promote products derived
16.\" from this software without specific, prior written permission.
17.\"
18.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
19.\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
20.\" LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
21.\" FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
22.\" COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
23.\" INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING,
24.\" BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25.\" LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
26.\" AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
27.\" OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
28.\" OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
29.\" SUCH DAMAGE.
30.\"
31.Dd July 1, 2010
32.Os
33.Dt MKINITRD 8
34.Sh NAME
35.Nm mkinitrd
36.Nd build an initial ramdisk image for use as early userland
37.Sh SYNOPSIS
38.Nm
39.\".Op Ar options ...
40.\".Ar target ...
41.Sh DESCRIPTION
42The
43.Nm
44script builds a ramdisk (md) image based on the UFS filesystem containing
45only the most basic tools, such as a minimal
46.Xr init 8 ,
8cb4cb97 47.Xr sh 1
ae14c9db
AH
48as well as many
49.Xr mount 8
50utilities.
51.Pp
8cb4cb97 52It will also copy the contents of
ae14c9db
AH
53.Pa /usr/share/initrd
54onto the ramdisk, maintaining the same hierarchy.
55.Pp
56On completion, the final image will be copied to
57.Pa /boot/initrd.img ,
58ready to be used as an early userland.
59.Pp
60The
61.Nm
62script will check for
63.Pa /etc/defaults/mkinitrd.conf
64and
65.Pa /etc/mkinitrd.conf
66and include the configuration from these files in the given order, allowing
67the user to override or add to the following variables:
68.Bd -literal -offset indent
69BUILD_DIR
70INITRD_SIZE
71BIN_TOOLS
72SBIN_TOOLS
73INITRD_DIRS
74CONTENT_DIRS
75.Ed
76.Pp
77Adding the following lines to
78.Pa /boot/loader.conf
79will enable the use of the created initrd image:
80.Bd -literal -offset indent
81initrd.img_load="YES"
82initrd.img_type="md_image"
83vfs.root.mountfrom="ufs:md0s0"
84.Ed
ae14c9db
AH
85.Sh SEE ALSO
86.Xr md 4 ,
87.Xr loader.conf 5