]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - usr.sbin/bhyveload/bhyveload.8
sysctl(9): Fix a few mandoc related issues
[FreeBSD/FreeBSD.git] / usr.sbin / bhyveload / bhyveload.8
1 .\"
2 .\" Copyright (c) 2012 NetApp Inc
3 .\" All rights reserved.
4 .\"
5 .\" Redistribution and use in source and binary forms, with or without
6 .\" modification, are permitted provided that the following conditions
7 .\" are met:
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 the
12 .\"    documentation and/or other materials provided with the distribution.
13 .\"
14 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
15 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
18 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 .\" SUCH DAMAGE.
25 .\"
26 .\" $FreeBSD$
27 .\"
28 .Dd June 24, 2016
29 .Dt BHYVELOAD 8
30 .Os
31 .Sh NAME
32 .Nm bhyveload
33 .Nd load a
34 .Fx
35 guest inside a bhyve virtual machine
36 .Sh SYNOPSIS
37 .Nm
38 .Op Fl C
39 .Op Fl S
40 .Op Fl c Ar cons-dev
41 .Op Fl d Ar disk-path
42 .Op Fl e Ar name=value
43 .Op Fl h Ar host-path
44 .Op Fl l Ar os-loader
45 .Op Fl m Ar memsize Ns Op Ar K|k|M|m|G|g|T|t
46 .Ar vmname
47 .Sh DESCRIPTION
48 .Nm
49 is used to load a
50 .Fx
51 guest inside a
52 .Xr bhyve 4
53 virtual machine.
54 .Pp
55 .Nm
56 is based on
57 .Xr loader 8
58 and will present an interface identical to the
59 .Fx
60 loader on the user's terminal.
61 This behavior can be changed by specifying a different OS loader.
62 .Pp
63 The virtual machine is identified as
64 .Ar vmname
65 and will be created if it does not already exist.
66 .Sh OPTIONS
67 The following options are available:
68 .Bl -tag -width indent
69 .It Fl c Ar cons-dev
70 .Ar cons-dev
71 is a
72 .Xr tty 4
73 device to use for
74 .Nm
75 terminal I/O.
76 .Pp
77 The text string "stdio" is also accepted and selects the use of
78 unbuffered standard I/O. This is the default value.
79 .It Fl d Ar disk-path
80 The
81 .Ar disk-path
82 is the pathname of the guest's boot disk image.
83 .It Fl e Ar name=value
84 Set the
85 .Fx
86 loader environment variable
87 .Ar name
88 to
89 .Ar value .
90 .Pp
91 The option may be used more than once to set more than one environment
92 variable.
93 .It Fl h Ar host-path
94 The
95 .Ar host-path
96 is the directory at the top of the guest's boot filesystem.
97 .It Fl l Ar os-loader
98 Specify a different OS loader.
99 By default
100 .Nm
101 will use
102 .Pa /boot/userboot.so ,
103 which presents a standard
104 .Fx
105 loader.
106 .It Fl m Ar memsize Ns Op Ar K|k|M|m|G|g|T|t
107 .Ar memsize
108 is the amount of memory allocated to the guest.
109 .Pp
110 The
111 .Ar memsize
112 argument may be suffixed with one of
113 .Cm K ,
114 .Cm M ,
115 .Cm G
116 or
117 .Cm T
118 (either upper or lower case) to indicate a multiple of
119 Kilobytes, Megabytes, Gigabytes or Terabytes
120 respectively.
121 .Pp
122 .Ar memsize
123 defaults to 256M.
124 .It Fl C
125 Include guest memory in the core file when
126 .Nm
127 dumps core.
128 This is intended for debugging an OS loader as it allows inspection of
129 the guest memory.
130 .It Fl S
131 Wire guest memory.
132 .El
133 .Sh EXAMPLES
134 To create a virtual machine named
135 .Ar freebsd-vm
136 that boots off the ISO image
137 .Pa /freebsd/release.iso
138 and has 1GB memory allocated to it:
139 .Pp
140 .Dl "bhyveload -m 1G -d /freebsd/release.iso freebsd-vm"
141 .Pp
142 To create a virtual machine named
143 .Ar test-vm
144 with 256MB of memory allocated, the guest root filesystem under the host
145 directory
146 .Pa /user/images/test
147 and terminal I/O sent to the
148 .Xr nmdm 4
149 device
150 .Pa /dev/nmdm1B
151 .Pp
152 .Dl "bhyveload -m 256MB -h /usr/images/test -c /dev/nmdm1B test-vm"
153 .Sh SEE ALSO
154 .Xr bhyve 4 ,
155 .Xr nmdm 4 ,
156 .Xr vmm 4 ,
157 .Xr bhyve 8 ,
158 .Xr loader 8
159 .Sh HISTORY
160 .Nm
161 first appeared in
162 .Fx 10.0 ,
163 and was developed at NetApp Inc.
164 .Sh AUTHORS
165 .Nm
166 was developed by
167 .An -nosplit
168 .An Neel Natu Aq Mt neel@FreeBSD.org
169 at NetApp Inc with a lot of help from
170 .An Doug Rabson Aq Mt dfr@FreeBSD.org .
171 .Sh BUGS
172 .Nm
173 can only load
174 .Fx
175 as a guest.