xref: /netbsd-src/usr.sbin/mdsetimage/mdsetimage.8 (revision bdc22b2e01993381dcefeff2bc9b56ca75a4235c)
1.\"	$NetBSD: mdsetimage.8,v 1.12 2016/09/21 16:25:41 christos Exp $
2.\"
3.\" Copyright (c) 1996 Christopher G. Demetriou
4.\" All rights reserved.
5.\"
6.\" Redistribution and use in source and binary forms, with or without
7.\" modification, are permitted provided that the following conditions
8.\" are met:
9.\" 1. Redistributions of source code must retain the above copyright
10.\"    notice, this list of conditions and the following disclaimer.
11.\" 2. Redistributions in binary form must reproduce the above copyright
12.\"    notice, this list of conditions and the following disclaimer in the
13.\"    documentation and/or other materials provided with the distribution.
14.\" 3. The name of the author may not be used to endorse or promote products
15.\"    derived from this software without specific prior written permission.
16.\"
17.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
18.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
19.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
20.\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
21.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
22.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
26.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27.\"
28.\" <<Id: LICENSE_GC,v 1.1 2001/10/01 23:24:05 cgd Exp>>
29.\"
30.Dd September 21, 2016
31.Dt MDSETIMAGE 8
32.Os
33.Sh NAME
34.Nm mdsetimage
35.Nd set kernel RAM disk image
36.Sh SYNOPSIS
37.Nm
38.Op Fl svx
39.Op Fl b Ar bfdname
40.Op Fl I Ar image_symbol
41.Op Fl S Ar size_symbol
42.Op Fl T Ar address
43.Ar kernel
44.Ar image
45.Sh DESCRIPTION
46The
47.Nm
48command copies the disk image specified by
49.Ar image
50into the memory disk storage area in
51.Ar kernel .
52The file system present in
53.Ar image
54will typically be used by the kernel
55as the root file system.
56.Pp
57To recognize kernel executable format, the
58.Fl b
59flag specifies BFD name of kernel.
60.Pp
61The
62.Fl I
63and
64.Fl S
65flags specify the symbol names of image and size of memory disk
66drivers respectively.
67.Pp
68For a.out kernels only, the
69.Fl T
70flag specifies the starting address of kernel text.
71This flag is ignored for other kernel executable formats.
72.Pp
73If the
74.Fl s
75flags is given,
76.Nm
77will write back the actual disk image size back into
78.Ar kernel .
79.Pp
80If the
81.Fl v
82flag is given,
83.Nm
84will print out status information as
85it is copying the image.
86.Pp
87If the
88.Fl x
89flag is given,
90.Nm
91will extract the disk image from
92.Ar kernel
93into the file
94.Ar image .
95This is the opposite of the default behavior.
96.Sh SEE ALSO
97.Xr md 4 ,
98.Xr mdconfig 8
99