1 | <?xml version="1.0" encoding="UTF-8"?>
|
---|
2 | <!--
|
---|
3 | manpage, user manual, usage: VBoxManage guestcontrol
|
---|
4 | -->
|
---|
5 | <!--
|
---|
6 | Copyright (C) 2006-2023 Oracle and/or its affiliates.
|
---|
7 |
|
---|
8 | This file is part of VirtualBox base platform packages, as
|
---|
9 | available from https://www.virtualbox.org.
|
---|
10 |
|
---|
11 | This program is free software; you can redistribute it and/or
|
---|
12 | modify it under the terms of the GNU General Public License
|
---|
13 | as published by the Free Software Foundation, in version 3 of the
|
---|
14 | License.
|
---|
15 |
|
---|
16 | This program is distributed in the hope that it will be useful, but
|
---|
17 | WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
18 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
---|
19 | General Public License for more details.
|
---|
20 |
|
---|
21 | You should have received a copy of the GNU General Public License
|
---|
22 | along with this program; if not, see <https://www.gnu.org/licenses>.
|
---|
23 |
|
---|
24 | SPDX-License-Identifier: GPL-3.0-only
|
---|
25 | -->
|
---|
26 | <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
27 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd"[
|
---|
28 | <!ENTITY % all.entities SYSTEM "all-entities.ent">
|
---|
29 | %all.entities;
|
---|
30 | ]>
|
---|
31 | <refentry id="vboxmanage-guestcontrol" lang="en">
|
---|
32 | <refentryinfo>
|
---|
33 | <pubdate>$Date: 2024-09-10 11:15:32 +0000 (Tue, 10 Sep 2024) $</pubdate>
|
---|
34 | <title>VBoxManage guestcontrol</title>
|
---|
35 | </refentryinfo>
|
---|
36 |
|
---|
37 | <refmeta>
|
---|
38 | <refentrytitle>VBoxManage-guestcontrol</refentrytitle>
|
---|
39 | <manvolnum>1</manvolnum>
|
---|
40 | </refmeta>
|
---|
41 |
|
---|
42 | <refnamediv>
|
---|
43 | <refname>VBoxManage-guestcontrol</refname>
|
---|
44 | <refpurpose>control a virtual machine from the host system</refpurpose>
|
---|
45 | <refclass>&product-name;</refclass>
|
---|
46 | </refnamediv>
|
---|
47 |
|
---|
48 | <refsynopsisdiv>
|
---|
49 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-run">
|
---|
50 | <!-- The 'id' is mandatory and must start with 'synopsis-'. -->
|
---|
51 | <command>VBoxManage guestcontrol</command>
|
---|
52 | <group choice="req">
|
---|
53 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
54 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
55 | </group>
|
---|
56 | <arg choice="plain">run</arg>
|
---|
57 | <arg>--arg0=<replaceable>argument 0</replaceable></arg>
|
---|
58 | <arg>--domain=<replaceable>domainname</replaceable></arg>
|
---|
59 | <arg>--dos2unix</arg>
|
---|
60 | <arg>--exe=<replaceable>filename</replaceable></arg>
|
---|
61 | <arg>--ignore-orphaned-processes</arg>
|
---|
62 | <group>
|
---|
63 | <arg choice="plain">--no-wait-stderr</arg>
|
---|
64 | <arg choice="plain">--wait-stderr</arg>
|
---|
65 | </group>
|
---|
66 | <group>
|
---|
67 | <arg choice="plain">--no-wait-stdout</arg>
|
---|
68 | <arg choice="plain">--wait-stdout</arg>
|
---|
69 | </group>
|
---|
70 | <group>
|
---|
71 | <arg choice="plain">--passwordfile=<replaceable>password-file</replaceable></arg>
|
---|
72 | <arg choice="plain">--password=<replaceable>password</replaceable></arg>
|
---|
73 | </group>
|
---|
74 | <arg>--profile</arg>
|
---|
75 | <arg>--putenv=<replaceable>var-name</replaceable>=[<replaceable>value</replaceable>]</arg>
|
---|
76 | <arg>--quiet</arg>
|
---|
77 | <arg>--timeout=<replaceable>msec</replaceable></arg>
|
---|
78 | <arg>--unix2dos</arg>
|
---|
79 | <arg>--unquoted-args</arg>
|
---|
80 | <arg>--username=<replaceable>username</replaceable></arg>
|
---|
81 | <arg>--cwd=<replaceable>directory</replaceable></arg>
|
---|
82 | <arg>--verbose</arg>
|
---|
83 | <arg choice="req">--<arg rep="repeat"><replaceable>argument</replaceable></arg></arg>
|
---|
84 | </cmdsynopsis>
|
---|
85 |
|
---|
86 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-start">
|
---|
87 | <command>VBoxManage guestcontrol</command>
|
---|
88 | <group choice="req">
|
---|
89 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
90 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
91 | </group>
|
---|
92 | <arg choice="plain">start</arg>
|
---|
93 | <arg>--arg0=<replaceable>argument 0</replaceable></arg>
|
---|
94 | <arg>--domain=<replaceable>domainname</replaceable></arg>
|
---|
95 | <arg>--exe=<replaceable>filename</replaceable></arg>
|
---|
96 | <arg>--ignore-orphaned-processes</arg>
|
---|
97 | <group>
|
---|
98 | <arg choice="plain">--passwordfile=<replaceable>password-file</replaceable></arg>
|
---|
99 | <arg choice="plain">--password=<replaceable>password</replaceable></arg>
|
---|
100 | </group>
|
---|
101 | <arg>--profile</arg>
|
---|
102 | <arg>--putenv=<replaceable>var-name</replaceable>=[<replaceable>value</replaceable>]</arg>
|
---|
103 | <arg>--quiet</arg>
|
---|
104 | <arg>--timeout=<replaceable>msec</replaceable></arg>
|
---|
105 | <arg>--unquoted-args</arg>
|
---|
106 | <arg>--username=<replaceable>username</replaceable></arg>
|
---|
107 | <arg>--cwd=<replaceable>directory</replaceable></arg>
|
---|
108 | <arg>--verbose</arg>
|
---|
109 | <arg choice="req">--<arg rep="repeat"><replaceable>argument</replaceable></arg></arg>
|
---|
110 | </cmdsynopsis>
|
---|
111 |
|
---|
112 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-copyfrom">
|
---|
113 | <command>VBoxManage guestcontrol</command>
|
---|
114 | <group choice="req">
|
---|
115 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
116 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
117 | </group>
|
---|
118 | <arg choice="plain">copyfrom</arg>
|
---|
119 | <arg>--dereference</arg>
|
---|
120 | <arg>--domain=<replaceable>domainname</replaceable></arg>
|
---|
121 | <group>
|
---|
122 | <arg choice="plain">--passwordfile=<replaceable>password-file</replaceable></arg>
|
---|
123 | <arg choice="plain">--password=<replaceable>password</replaceable></arg>
|
---|
124 | </group>
|
---|
125 | <arg>--quiet</arg>
|
---|
126 | <arg>--no-replace</arg>
|
---|
127 | <arg>--recursive</arg>
|
---|
128 | <arg>--target-directory=<replaceable>host-destination-dir</replaceable></arg>
|
---|
129 | <arg>--update</arg>
|
---|
130 | <arg>--username=<replaceable>username</replaceable></arg>
|
---|
131 | <arg>--verbose</arg>
|
---|
132 | <arg choice="req"><replaceable>guest-source0</replaceable></arg>
|
---|
133 | <arg choice="plain"><replaceable>guest-source1</replaceable> [...]</arg>
|
---|
134 | <arg choice="req"><replaceable>host-destination</replaceable></arg>
|
---|
135 | </cmdsynopsis>
|
---|
136 |
|
---|
137 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-copyto">
|
---|
138 | <command>VBoxManage guestcontrol</command>
|
---|
139 | <group choice="req">
|
---|
140 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
141 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
142 | </group>
|
---|
143 | <arg choice="plain">copyto</arg>
|
---|
144 | <arg>--dereference</arg>
|
---|
145 | <arg>--domain=<replaceable>domainname</replaceable></arg>
|
---|
146 | <group>
|
---|
147 | <arg choice="plain">--passwordfile=<replaceable>password-file</replaceable></arg>
|
---|
148 | <arg choice="plain">--password=<replaceable>password</replaceable></arg>
|
---|
149 | </group>
|
---|
150 | <arg>--quiet</arg>
|
---|
151 | <arg>--no-replace</arg>
|
---|
152 | <arg>--recursive</arg>
|
---|
153 | <arg>--target-directory=<replaceable>guest-destination-dir</replaceable></arg>
|
---|
154 | <arg>--update</arg>
|
---|
155 | <arg>--username=<replaceable>username</replaceable></arg>
|
---|
156 | <arg>--verbose</arg>
|
---|
157 | <arg choice="req"><replaceable>host-source0</replaceable></arg>
|
---|
158 | <arg choice="plain"><replaceable>host-source1</replaceable> [...]</arg>
|
---|
159 | </cmdsynopsis>
|
---|
160 |
|
---|
161 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-mkdir">
|
---|
162 | <command>VBoxManage guestcontrol</command>
|
---|
163 | <group choice="req">
|
---|
164 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
165 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
166 | </group>
|
---|
167 | <arg choice="plain">mkdir</arg>
|
---|
168 | <arg>--domain=<replaceable>domainname</replaceable></arg>
|
---|
169 | <arg>--mode=<replaceable>mode</replaceable></arg>
|
---|
170 | <arg>--parents</arg>
|
---|
171 | <group>
|
---|
172 | <arg choice="plain">--passwordfile=<replaceable>password-file</replaceable></arg>
|
---|
173 | <arg choice="plain">--password=<replaceable>password</replaceable></arg>
|
---|
174 | </group>
|
---|
175 | <arg>--quiet</arg>
|
---|
176 | <arg>--username=<replaceable>username</replaceable></arg>
|
---|
177 | <arg>--verbose</arg>
|
---|
178 | <arg choice="req" rep="repeat"><replaceable>guest-directory</replaceable></arg>
|
---|
179 | </cmdsynopsis>
|
---|
180 |
|
---|
181 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-rmdir">
|
---|
182 | <command>VBoxManage guestcontrol</command>
|
---|
183 | <group choice="req">
|
---|
184 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
185 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
186 | </group>
|
---|
187 | <arg choice="plain">rmdir</arg>
|
---|
188 | <arg>--domain=<replaceable>domainname</replaceable></arg>
|
---|
189 | <group>
|
---|
190 | <arg choice="plain">--passwordfile=<replaceable>password-file</replaceable></arg>
|
---|
191 | <arg choice="plain">--password=<replaceable>password</replaceable></arg>
|
---|
192 | </group>
|
---|
193 | <arg>--quiet</arg>
|
---|
194 | <arg>--recursive</arg>
|
---|
195 | <arg>--username=<replaceable>username</replaceable></arg>
|
---|
196 | <arg>--verbose</arg>
|
---|
197 | <arg choice="req" rep="repeat"><replaceable>guest-directory</replaceable></arg>
|
---|
198 | </cmdsynopsis>
|
---|
199 |
|
---|
200 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-rm">
|
---|
201 | <command>VBoxManage guestcontrol</command>
|
---|
202 | <group choice="req">
|
---|
203 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
204 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
205 | </group>
|
---|
206 | <arg choice="plain">rm</arg>
|
---|
207 | <arg>--domain=<replaceable>domainname</replaceable></arg>
|
---|
208 | <arg>--force</arg>
|
---|
209 | <group>
|
---|
210 | <arg choice="plain">--passwordfile=<replaceable>password-file</replaceable></arg>
|
---|
211 | <arg choice="plain">--password=<replaceable>password</replaceable></arg>
|
---|
212 | </group>
|
---|
213 | <arg>--quiet</arg>
|
---|
214 | <arg>--username=<replaceable>username</replaceable></arg>
|
---|
215 | <arg>--verbose</arg>
|
---|
216 | <arg choice="req" rep="repeat"><replaceable>guest-directory</replaceable></arg>
|
---|
217 | </cmdsynopsis>
|
---|
218 |
|
---|
219 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-mv">
|
---|
220 | <command>VBoxManage guestcontrol</command>
|
---|
221 | <group choice="req">
|
---|
222 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
223 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
224 | </group>
|
---|
225 | <arg choice="plain">mv</arg>
|
---|
226 | <arg>--domain=<replaceable>domainname</replaceable></arg>
|
---|
227 | <group>
|
---|
228 | <arg choice="plain">--passwordfile=<replaceable>password-file</replaceable></arg>
|
---|
229 | <arg choice="plain">--password=<replaceable>password</replaceable></arg>
|
---|
230 | </group>
|
---|
231 | <arg>--quiet</arg>
|
---|
232 | <arg>--username=<replaceable>username</replaceable></arg>
|
---|
233 | <arg>--verbose</arg>
|
---|
234 | <arg choice="req" rep="repeat"><replaceable>source</replaceable></arg>
|
---|
235 | <arg choice="req"><replaceable>destination-directory</replaceable></arg>
|
---|
236 | </cmdsynopsis>
|
---|
237 |
|
---|
238 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-mktemp">
|
---|
239 | <command>VBoxManage guestcontrol</command>
|
---|
240 | <group choice="req">
|
---|
241 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
242 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
243 | </group>
|
---|
244 | <arg choice="plain">mktemp</arg>
|
---|
245 | <arg>--directory</arg>
|
---|
246 | <arg>--domain=<replaceable>domainname</replaceable></arg>
|
---|
247 | <arg>--mode=<replaceable>mode</replaceable></arg>
|
---|
248 | <group>
|
---|
249 | <arg choice="plain">--passwordfile=<replaceable>password-file</replaceable></arg>
|
---|
250 | <arg choice="plain">--password=<replaceable>password</replaceable></arg>
|
---|
251 | </group>
|
---|
252 | <arg>--quiet</arg>
|
---|
253 | <arg>--secure</arg>
|
---|
254 | <arg>--tmpdir=<replaceable>directory-name</replaceable></arg>
|
---|
255 | <arg>--username=<replaceable>username</replaceable></arg>
|
---|
256 | <arg>--verbose</arg>
|
---|
257 | <arg choice="req"><replaceable>template-name</replaceable></arg>
|
---|
258 | </cmdsynopsis>
|
---|
259 |
|
---|
260 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-mount">
|
---|
261 | <command>VBoxManage guestcontrol</command>
|
---|
262 | <group choice="req">
|
---|
263 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
264 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
265 | </group>
|
---|
266 | <arg choice="plain">mount</arg>
|
---|
267 | <group>
|
---|
268 | <arg choice="plain">--passwordfile=<replaceable>password-file</replaceable></arg>
|
---|
269 | <arg choice="plain">--password=<replaceable>password</replaceable></arg>
|
---|
270 | </group>
|
---|
271 | <arg>--username=<replaceable>username</replaceable></arg>
|
---|
272 | <arg>--verbose</arg>
|
---|
273 | </cmdsynopsis>
|
---|
274 |
|
---|
275 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-fsinfo">
|
---|
276 | <command>VBoxManage guestcontrol</command>
|
---|
277 | <group choice="req">
|
---|
278 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
279 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
280 | </group>
|
---|
281 | <arg choice="plain">fsinfo</arg>
|
---|
282 | <arg>--domain=<replaceable>domainname</replaceable></arg>
|
---|
283 | <group>
|
---|
284 | <arg choice="plain">--passwordfile=<replaceable>password-file</replaceable></arg>
|
---|
285 | <arg choice="plain">--password=<replaceable>password</replaceable></arg>
|
---|
286 | </group>
|
---|
287 | <arg>--human-readable</arg>
|
---|
288 | <arg>--quiet</arg>
|
---|
289 | <arg>--total</arg>
|
---|
290 | <arg>--username=<replaceable>username</replaceable></arg>
|
---|
291 | <arg>--verbose</arg>
|
---|
292 | <arg choice="req"><replaceable>path</replaceable></arg>
|
---|
293 | </cmdsynopsis>
|
---|
294 |
|
---|
295 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-stat">
|
---|
296 | <command>VBoxManage guestcontrol</command>
|
---|
297 | <group choice="req">
|
---|
298 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
299 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
300 | </group>
|
---|
301 | <arg choice="plain">stat</arg>
|
---|
302 | <arg>--domain=<replaceable>domainname</replaceable></arg>
|
---|
303 | <group>
|
---|
304 | <arg choice="plain">--passwordfile=<replaceable>password-file</replaceable></arg>
|
---|
305 | <arg choice="plain">--password=<replaceable>password</replaceable></arg>
|
---|
306 | </group>
|
---|
307 | <arg>--quiet</arg>
|
---|
308 | <arg>--username=<replaceable>username</replaceable></arg>
|
---|
309 | <arg>--verbose</arg>
|
---|
310 | <arg choice="req"><replaceable>filename</replaceable></arg>
|
---|
311 | </cmdsynopsis>
|
---|
312 |
|
---|
313 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-list">
|
---|
314 | <command>VBoxManage guestcontrol</command>
|
---|
315 | <group choice="req">
|
---|
316 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
317 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
318 | </group>
|
---|
319 | <arg choice="plain">list</arg>
|
---|
320 | <group choice="req">
|
---|
321 | <arg choice="plain">all</arg>
|
---|
322 | <arg choice="plain">files</arg>
|
---|
323 | <arg choice="plain">processes</arg>
|
---|
324 | <arg choice="plain">sessions</arg>
|
---|
325 | </group>
|
---|
326 | <arg>--quiet</arg>
|
---|
327 | <arg>--verbose</arg>
|
---|
328 | </cmdsynopsis>
|
---|
329 |
|
---|
330 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-closeprocess">
|
---|
331 | <command>VBoxManage guestcontrol</command>
|
---|
332 | <group choice="req">
|
---|
333 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
334 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
335 | </group>
|
---|
336 | <arg choice="plain">closeprocess</arg>
|
---|
337 | <group>
|
---|
338 | <arg choice="plain">--session-id=<replaceable>ID</replaceable></arg>
|
---|
339 | <arg choice="plain">--session-name=<replaceable>name-or-pattern</replaceable></arg>
|
---|
340 | </group>
|
---|
341 | <arg>--quiet</arg>
|
---|
342 | <arg>--verbose</arg>
|
---|
343 | <arg choice="req" rep="repeat"><replaceable>PID</replaceable></arg>
|
---|
344 | </cmdsynopsis>
|
---|
345 |
|
---|
346 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-closesession">
|
---|
347 | <command>VBoxManage guestcontrol</command>
|
---|
348 | <group choice="req">
|
---|
349 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
350 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
351 | </group>
|
---|
352 | <arg choice="plain">closesession</arg>
|
---|
353 | <group>
|
---|
354 | <arg choice="plain">--all</arg>
|
---|
355 | <arg choice="plain">--session-id=<replaceable>ID</replaceable></arg>
|
---|
356 | <arg choice="plain">--session-name=<replaceable>name-or-pattern</replaceable></arg>
|
---|
357 | </group>
|
---|
358 | <arg>--quiet</arg>
|
---|
359 | <arg>--verbose</arg>
|
---|
360 | </cmdsynopsis>
|
---|
361 |
|
---|
362 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-updatega">
|
---|
363 | <command>VBoxManage guestcontrol</command>
|
---|
364 | <group choice="req">
|
---|
365 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
366 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
367 | </group>
|
---|
368 | <arg choice="plain">updatega</arg>
|
---|
369 | <arg>--quiet</arg>
|
---|
370 | <arg>--verbose</arg>
|
---|
371 | <arg>--source=<replaceable>guest-additions.ISO</replaceable></arg>
|
---|
372 | <arg>--wait-start</arg>
|
---|
373 | <arg>--<arg rep="repeat"><replaceable>argument</replaceable></arg></arg>
|
---|
374 | </cmdsynopsis>
|
---|
375 |
|
---|
376 | <cmdsynopsis id="synopsis-vboxmanage-guestcontrol-watch">
|
---|
377 | <command>VBoxManage guestcontrol</command>
|
---|
378 | <group choice="req">
|
---|
379 | <arg choice="plain"><replaceable>uuid</replaceable></arg>
|
---|
380 | <arg choice="plain"><replaceable>vmname</replaceable></arg>
|
---|
381 | </group>
|
---|
382 | <arg choice="plain">watch</arg>
|
---|
383 | <arg>--quiet</arg>
|
---|
384 | <arg>--verbose</arg>
|
---|
385 | </cmdsynopsis>
|
---|
386 | </refsynopsisdiv>
|
---|
387 |
|
---|
388 | <refsect1 id="vboxmanage-guestcontrol-description">
|
---|
389 | <title>Description</title>
|
---|
390 | <para>
|
---|
391 | The <command>VBoxManage guestcontrol</command> command enables you
|
---|
392 | to control a guest (VM) from the host system. See
|
---|
393 | <xref linkend="guestadd-guestcontrol" />.
|
---|
394 | </para>
|
---|
395 | <refsect2 id="vboxmanage-guestcontrol-common">
|
---|
396 | <title>Common Options and Operands</title>
|
---|
397 | <para>
|
---|
398 | The following options can be used by any of the
|
---|
399 | <command>VBoxManage guestcontrol</command> subcommands:
|
---|
400 | </para>
|
---|
401 | <variablelist>
|
---|
402 | <varlistentry>
|
---|
403 | <term><option><replaceable>uuid</replaceable> | <replaceable>vmname</replaceable></option></term>
|
---|
404 | <listitem><para>
|
---|
405 | Specifies the Universally Unique Identifier (UUID) or name
|
---|
406 | of the VM.
|
---|
407 | </para></listitem>
|
---|
408 | </varlistentry>
|
---|
409 | <varlistentry>
|
---|
410 | <term><option>--quiet</option></term>
|
---|
411 | <listitem><para>
|
---|
412 | Specifies that the command produce quieter output.
|
---|
413 | </para><para>
|
---|
414 | The short form of this option is <option>-q</option>.
|
---|
415 | </para></listitem>
|
---|
416 | </varlistentry>
|
---|
417 | <varlistentry>
|
---|
418 | <term><option>--verbose</option></term>
|
---|
419 | <listitem><para>
|
---|
420 | Specifies that the command produce more detailed output.
|
---|
421 | </para><para>
|
---|
422 | The short form of this option is <option>-v</option>.
|
---|
423 | </para></listitem>
|
---|
424 | </varlistentry>
|
---|
425 | </variablelist>
|
---|
426 | <para>
|
---|
427 | Some of the <command>VBoxManage guestcontrol</command>
|
---|
428 | subcommands require that you provide guest credentials for
|
---|
429 | authentication. The subcommands are:
|
---|
430 | <command>copyfrom</command>, <command>copyto</command>,
|
---|
431 | <command>fsinfo</command>,
|
---|
432 | <command>mkdir</command>, <command>mktemp</command>,
|
---|
433 | <command>mount</command>,
|
---|
434 | <command>mv</command>, <command>rmdir</command>,
|
---|
435 | <command>rm</command>, <command>run</command>,
|
---|
436 | <command>start</command>, and <command>stat</command>.
|
---|
437 | </para>
|
---|
438 | <para>
|
---|
439 | While you cannot perform anonymous executions, a user account
|
---|
440 | password is optional and depends on the guest's OS security
|
---|
441 | policy. If a user account does not have an associated password,
|
---|
442 | specify an empty password. On OSes such as Windows, you might
|
---|
443 | need to adjust the security policy to permit user accounts with
|
---|
444 | an empty password. In addition, global domain rules might
|
---|
445 | apply and therefore cannot be changed.
|
---|
446 | </para>
|
---|
447 | <para>
|
---|
448 | The following options are used for authentication on the guest
|
---|
449 | VM:
|
---|
450 | </para>
|
---|
451 | <variablelist>
|
---|
452 | <varlistentry>
|
---|
453 | <term><option>--domain=<replaceable>domainname</replaceable></option></term>
|
---|
454 | <listitem><para>
|
---|
455 | Specifies the user domain for Windows guest VMs.
|
---|
456 | </para></listitem>
|
---|
457 | </varlistentry>
|
---|
458 | <varlistentry>
|
---|
459 | <term><option>--password=<replaceable>password</replaceable></option></term>
|
---|
460 | <listitem><para>
|
---|
461 | Specifies the password for the specified user. If you do
|
---|
462 | not specify a password on the command line or if the
|
---|
463 | password is empty, the specified user needs to have
|
---|
464 | an empty password.
|
---|
465 | </para></listitem>
|
---|
466 | </varlistentry>
|
---|
467 | <varlistentry>
|
---|
468 | <term><option>--passwordfile=<replaceable>filename</replaceable></option></term>
|
---|
469 | <listitem><para>
|
---|
470 | Specifies the absolute path to a file on the host system that
|
---|
471 | contains the password for the specified user. If the
|
---|
472 | password file is empty or if you do not specify a password
|
---|
473 | on the command line, the specified user needs to have an
|
---|
474 | empty password.
|
---|
475 | </para></listitem>
|
---|
476 | </varlistentry>
|
---|
477 | <varlistentry>
|
---|
478 | <term><option>--username=<replaceable>username</replaceable></option></term>
|
---|
479 | <listitem><para>
|
---|
480 | Specifies an existing user in the guest OS that runs the
|
---|
481 | process. If unspecified, the name of the user on the host
|
---|
482 | invoking the <command>VBoxManage</command> command will be
|
---|
483 | used as the username for the guest OS login.
|
---|
484 | </para></listitem>
|
---|
485 | </varlistentry>
|
---|
486 | </variablelist>
|
---|
487 | </refsect2>
|
---|
488 | <refsect2 id="vboxmanage-guestcontrol-process-restrictions">
|
---|
489 | <title>Guest Process Restrictions</title>
|
---|
490 | <para>
|
---|
491 | By default, you can run up to 255 guest processes simultaneously.
|
---|
492 | If attempting to start a new guest process would exceed
|
---|
493 | this limit and there are inactive guest processes then the the
|
---|
494 | oldest inactive guest process is discarded to run the new process.
|
---|
495 | You cannot retrieve the output from a discarded guest process. If
|
---|
496 | all 255 guest processes are active and running, attempting to start
|
---|
497 | a new guest process fails.
|
---|
498 | </para>
|
---|
499 | </refsect2>
|
---|
500 | <refsect2 id="vboxmanage-guestcontrol-run">
|
---|
501 | <title>Run a Command in the guest</title>
|
---|
502 | <remark role="help-copy-synopsis"/>
|
---|
503 | <para>
|
---|
504 | The <command>VBoxManage guestcontrol
|
---|
505 | <replaceable>vmname</replaceable> run</command> command enables
|
---|
506 | you to execute a program in the guest VM. Standard input,
|
---|
507 | standard output, and standard error are redirected from the VM
|
---|
508 | to the host system until the program completes.
|
---|
509 | </para>
|
---|
510 | <note>
|
---|
511 | <para>
|
---|
512 | Microsoft Windows imposes certain limitations when running
|
---|
513 | graphical user interface applications launched using
|
---|
514 | <command>VBoxManage guestcontrol run</command>. See
|
---|
515 | <xref linkend="KnownIssues" />.
|
---|
516 | </para>
|
---|
517 | </note>
|
---|
518 | <variablelist>
|
---|
519 | <varlistentry>
|
---|
520 | <term><option>--exe=<replaceable>path-to-executable</replaceable></option></term>
|
---|
521 | <listitem><para>
|
---|
522 | Specifies the absolute path of the executable program to
|
---|
523 | run in the guest VM. For example:
|
---|
524 | <filename>C:\Windows\System32\calc.exe</filename>.
|
---|
525 | </para></listitem>
|
---|
526 | </varlistentry>
|
---|
527 | <varlistentry>
|
---|
528 | <term><option>--arg0=<replaceable>alternate-executable-name</replaceable></option></term>
|
---|
529 | <listitem><para>
|
---|
530 | Specifies an alternate name (i.e. arg0 or argv[0]) for the
|
---|
531 | executable being run in the guest.
|
---|
532 | </para></listitem>
|
---|
533 | </varlistentry>
|
---|
534 | <varlistentry>
|
---|
535 | <term><option>--cwd=<replaceable>path-to-directory</replaceable></option></term>
|
---|
536 | <listitem><para>
|
---|
537 | Specifies the absolute path of a directory in which
|
---|
538 | to start the program. Optional. The directory must
|
---|
539 | exist and be accessible to the guest user. For example:
|
---|
540 | <filename>C:\Users\production\work_area</filename>.
|
---|
541 | </para><para>
|
---|
542 | The short form of this option is <option>-C</option>.
|
---|
543 | </para></listitem>
|
---|
544 | </varlistentry>
|
---|
545 | <varlistentry>
|
---|
546 | <term><option>--timeout=<replaceable>msec</replaceable></option></term>
|
---|
547 | <listitem><para>
|
---|
548 | Specifies the maximum amount of time, in milliseconds,
|
---|
549 | that the program can run. While the program runs,
|
---|
550 | <command>VBoxManage</command> receives its output.
|
---|
551 | </para><para>
|
---|
552 | If you do not specify a timeout value,
|
---|
553 | <command>VBoxManage</command> waits indefinitely for the
|
---|
554 | process to end, or for an error to occur.
|
---|
555 | </para></listitem>
|
---|
556 | </varlistentry>
|
---|
557 | <varlistentry>
|
---|
558 | <term><option>--putenv=<replaceable>NAME</replaceable>=[<replaceable>value</replaceable>]</option></term>
|
---|
559 | <listitem><para>
|
---|
560 | Sets, modifies, and unsets environment variables in the
|
---|
561 | guest VM environment.
|
---|
562 | </para><para>
|
---|
563 | When you create a guest process, it runs with the default
|
---|
564 | standard guest OS environment. Use this option to modify
|
---|
565 | environment variables in that default environment.
|
---|
566 | </para><para>
|
---|
567 | Use the
|
---|
568 | <option>--putenv=<replaceable>NAME</replaceable>=[<replaceable>value</replaceable>]</option>
|
---|
569 | option to set or modify the environment variable specified
|
---|
570 | by <replaceable>NAME</replaceable>.
|
---|
571 | </para><para>
|
---|
572 | Use the
|
---|
573 | <option>--putenv=<replaceable>NAME</replaceable>=</option>
|
---|
574 | option to unset the environment variable specified by
|
---|
575 | <replaceable>NAME</replaceable>.
|
---|
576 | </para><para>
|
---|
577 | Ensure that any environment variable name or value that
|
---|
578 | includes spaces is enclosed by quotes.
|
---|
579 | </para><para>
|
---|
580 | Specify a <option>--putenv</option> option for each
|
---|
581 | environment variable that you want to modify.
|
---|
582 | </para><para>
|
---|
583 | The short form of this option is <option>-E</option>.
|
---|
584 | </para></listitem>
|
---|
585 | </varlistentry>
|
---|
586 | <varlistentry>
|
---|
587 | <term><option>--unquoted-args</option></term>
|
---|
588 | <listitem><para>
|
---|
589 | Disables the escaped double quoting of arguments that you
|
---|
590 | pass to the program. For example,
|
---|
591 | <literal>\"fred\"</literal>.
|
---|
592 | </para></listitem>
|
---|
593 | </varlistentry>
|
---|
594 | <varlistentry>
|
---|
595 | <term><option>--ignore-orphaned-processes</option></term>
|
---|
596 | <listitem><para>
|
---|
597 | Ignores orphaned processes. Not yet implemented.
|
---|
598 | </para></listitem>
|
---|
599 | </varlistentry>
|
---|
600 | <varlistentry>
|
---|
601 | <term><option>--profile</option></term>
|
---|
602 | <listitem><para>
|
---|
603 | Uses a shell profile to specify the environment to use.
|
---|
604 | Not yet implemented.
|
---|
605 | </para></listitem>
|
---|
606 | </varlistentry>
|
---|
607 | <varlistentry>
|
---|
608 | <term><option>--no-wait-stdout</option></term>
|
---|
609 | <listitem><para>
|
---|
610 | Does not wait for the guest process to end or receive its
|
---|
611 | exit code and any failure explanation.
|
---|
612 | </para></listitem>
|
---|
613 | </varlistentry>
|
---|
614 | <varlistentry>
|
---|
615 | <term><option>--wait-stdout</option></term>
|
---|
616 | <listitem><para>
|
---|
617 | Waits for the guest process to end to receive its exit
|
---|
618 | code and any failure explanation. The
|
---|
619 | <command>VBoxManage</command> command receives the
|
---|
620 | standard output of the guest process while the process
|
---|
621 | runs.
|
---|
622 | </para></listitem>
|
---|
623 | </varlistentry>
|
---|
624 | <varlistentry>
|
---|
625 | <term><option>--no-wait-stderr</option></term>
|
---|
626 | <listitem><para>
|
---|
627 | Does not wait for the guest process to end to receive its
|
---|
628 | exit code, error messages, and flags.
|
---|
629 | </para></listitem>
|
---|
630 | </varlistentry>
|
---|
631 | <varlistentry>
|
---|
632 | <term><option>--wait-stderr</option></term>
|
---|
633 | <listitem><para>
|
---|
634 | Waits for the guest process to end to receive its exit
|
---|
635 | code, error messages, and flags. The
|
---|
636 | <command>VBoxManage</command> command receives the
|
---|
637 | standard error of the guest process while the process
|
---|
638 | runs.
|
---|
639 | </para></listitem>
|
---|
640 | </varlistentry>
|
---|
641 | <varlistentry>
|
---|
642 | <term><option>--dos2unix</option></term>
|
---|
643 | <listitem><para>
|
---|
644 | Transform DOS or Windows guest output to UNIX or Linux
|
---|
645 | output. This transformation changes CR + LF line endings
|
---|
646 | to LF. Not yet implemented.
|
---|
647 | </para></listitem>
|
---|
648 | </varlistentry>
|
---|
649 | <varlistentry>
|
---|
650 | <term><option>--unix2dos</option></term>
|
---|
651 | <listitem><para>
|
---|
652 | Transform UNIX or Linux guest output to DOS or Windows
|
---|
653 | output. This transformation changes LF line endings to CR
|
---|
654 | + LF.
|
---|
655 | </para></listitem>
|
---|
656 | </varlistentry>
|
---|
657 | <varlistentry>
|
---|
658 | <term><option>-- [<replaceable>argument</replaceable>...]</option></term>
|
---|
659 | <listitem><para>
|
---|
660 | Specifies one or more arguments to pass to the program
|
---|
661 | being run in the guest.
|
---|
662 | </para><para>
|
---|
663 | Ensure that any command argument that includes spaces is
|
---|
664 | enclosed by quotes.
|
---|
665 | </para></listitem>
|
---|
666 | </varlistentry>
|
---|
667 | </variablelist>
|
---|
668 | </refsect2>
|
---|
669 | <refsect2 id="vboxmanage-guestcontrol-start">
|
---|
670 | <title>Start a Command on the guest</title>
|
---|
671 | <remark role="help-copy-synopsis"/>
|
---|
672 | <para>
|
---|
673 | The <command>VBoxManage guestcontrol
|
---|
674 | <replaceable>vmname</replaceable> start</command> command
|
---|
675 | enables you to execute a guest program and returns after
|
---|
676 | the command has been successfully started. The invoked
|
---|
677 | command doesn't wait until all data from stdout or stderr
|
---|
678 | has been read before returning.
|
---|
679 | </para>
|
---|
680 | <note>
|
---|
681 | <para>
|
---|
682 | Microsoft Windows imposes certain limitations when running
|
---|
683 | graphical user interface applications launched using
|
---|
684 | <command>VBoxManage guestcontrol start</command>. See
|
---|
685 | <xref linkend="KnownIssues" />.
|
---|
686 | </para>
|
---|
687 | </note>
|
---|
688 | </refsect2>
|
---|
689 | <refsect2 id="vboxmanage-guestcontrol-copyfrom">
|
---|
690 | <title>Copy a file from the guest to the host.</title>
|
---|
691 | <remark role="help-copy-synopsis"/>
|
---|
692 | <para>
|
---|
693 | The <command>VBoxManage guestcontrol
|
---|
694 | <replaceable>vmname</replaceable> copyfrom</command> command
|
---|
695 | enables you to copy a file from the guest VM to the host system.
|
---|
696 | </para>
|
---|
697 | <variablelist>
|
---|
698 | <varlistentry>
|
---|
699 | <term><option>--dereference</option></term>
|
---|
700 | <listitem><para>
|
---|
701 | Enables following of symbolic links on the guest file
|
---|
702 | system.
|
---|
703 | </para></listitem>
|
---|
704 | </varlistentry>
|
---|
705 | <varlistentry>
|
---|
706 | <term><option>--no-replace</option></term>
|
---|
707 | <listitem><para>
|
---|
708 | Only copies a file if it does not exist on the host yet.
|
---|
709 | </para><para>
|
---|
710 | The short form of this option is <option>-n</option>.
|
---|
711 | </para></listitem>
|
---|
712 | </varlistentry>
|
---|
713 | <varlistentry>
|
---|
714 | <term><option>--recursive</option></term>
|
---|
715 | <listitem><para>
|
---|
716 | Recursively copies files and directories from the
|
---|
717 | specified guest directory to the host.
|
---|
718 | </para><para>
|
---|
719 | The short form of this option is <option>-R</option>.
|
---|
720 | </para></listitem>
|
---|
721 | </varlistentry>
|
---|
722 | <varlistentry>
|
---|
723 | <term><option>--target-directory=<replaceable>host-dst-dir</replaceable></option></term>
|
---|
724 | <listitem><para>
|
---|
725 | Specifies the absolute path of the destination directory
|
---|
726 | on the host system. For example,
|
---|
727 | <filename>C:\Temp</filename>.
|
---|
728 | </para></listitem>
|
---|
729 | </varlistentry>
|
---|
730 | <varlistentry>
|
---|
731 | <term><option>--update</option></term>
|
---|
732 | <listitem><para>
|
---|
733 | Only copies a file if the guest file is newer than on the host.
|
---|
734 | </para><para>
|
---|
735 | The short form of this option is <option>-u</option>.
|
---|
736 | </para></listitem>
|
---|
737 | </varlistentry>
|
---|
738 | <varlistentry>
|
---|
739 | <term><literal><replaceable>guest-source0</replaceable> [<replaceable>guest-source1</replaceable> [...]]</literal></term>
|
---|
740 | <listitem><para>
|
---|
741 | Specifies the absolute path of one or more files to copy
|
---|
742 | from the guest VM. For example,
|
---|
743 | <filename>C:\Windows\System32\calc.exe</filename>. You can
|
---|
744 | use wildcards to specify multiple files. For example,
|
---|
745 | <filename>C:\Windows\System*\*.dll</filename>.
|
---|
746 | </para></listitem>
|
---|
747 | </varlistentry>
|
---|
748 | </variablelist>
|
---|
749 | </refsect2>
|
---|
750 | <refsect2 id="vboxmanage-guestcontrol-copyto">
|
---|
751 | <title>Copy a file from the host to the guest.</title>
|
---|
752 | <remark role="help-copy-synopsis"/>
|
---|
753 | <para>
|
---|
754 | The <command>VBoxManage guestcontrol
|
---|
755 | <replaceable>vmname</replaceable> copyto</command> command
|
---|
756 | enables you to copy a file from the host system to the guest VM.
|
---|
757 | </para>
|
---|
758 | <variablelist>
|
---|
759 | <varlistentry>
|
---|
760 | <term><option>--dereference</option></term>
|
---|
761 | <listitem><para>
|
---|
762 | Enables following of symbolic links on the host system.
|
---|
763 | </para></listitem>
|
---|
764 | </varlistentry>
|
---|
765 | <varlistentry>
|
---|
766 | <term><option>--no-replace</option></term>
|
---|
767 | <listitem><para>
|
---|
768 | Only copies a file if it does not exist on the guest yet.
|
---|
769 | </para><para>
|
---|
770 | The short form of this option is <option>-n</option>.
|
---|
771 | </para></listitem>
|
---|
772 | </varlistentry>
|
---|
773 | <varlistentry>
|
---|
774 | <term><option>--recursive</option></term>
|
---|
775 | <listitem><para>
|
---|
776 | Recursively copies files and directories from the
|
---|
777 | specified host directory to the guest.
|
---|
778 | </para><para>
|
---|
779 | The short form of this option is <option>-R</option>.
|
---|
780 | </para></listitem>
|
---|
781 | </varlistentry>
|
---|
782 | <varlistentry>
|
---|
783 | <term><option>--target-directory=<replaceable>guest-dst-dir</replaceable></option></term>
|
---|
784 | <listitem><para>
|
---|
785 | Specifies the absolute path of the destination directory
|
---|
786 | on the guest. For example,
|
---|
787 | <filename>/home/myuser/fromhost</filename>.
|
---|
788 | </para></listitem>
|
---|
789 | </varlistentry>
|
---|
790 | <varlistentry>
|
---|
791 | <term><option>--update</option></term>
|
---|
792 | <listitem><para>
|
---|
793 | Only copies a file if the host file is newer than on the guest.
|
---|
794 | </para><para>
|
---|
795 | The short form of this option is <option>-u</option>.
|
---|
796 | </para></listitem>
|
---|
797 | </varlistentry>
|
---|
798 | <varlistentry>
|
---|
799 | <term><literal><replaceable>host-source0</replaceable> [<replaceable>host-source1</replaceable> [...]]</literal></term>
|
---|
800 | <listitem><para>
|
---|
801 | Specifies the absolute path of a file to
|
---|
802 | copy from the host system. For example,
|
---|
803 | <filename>C:\Windows\System32\calc.exe</filename>. You can
|
---|
804 | use wildcards to specify multiple files. For example,
|
---|
805 | <filename>C:\Windows\System*\*.dll</filename>.
|
---|
806 | </para></listitem>
|
---|
807 | </varlistentry>
|
---|
808 | </variablelist>
|
---|
809 | </refsect2>
|
---|
810 | <refsect2 id="vboxmanage-guestcontrol-fsinfo">
|
---|
811 | <title>Show guest filesystem information.</title>
|
---|
812 | <remark role="help-copy-synopsis"/>
|
---|
813 | <para>
|
---|
814 | The <command>VBoxManage guestcontrol
|
---|
815 | <replaceable>vmname</replaceable> fsinfo</command> command
|
---|
816 | enables you to show filesystem information of the guest VM.
|
---|
817 | </para>
|
---|
818 | <para>
|
---|
819 | An alternate form of this subcommand is <command>df</command>.
|
---|
820 | </para>
|
---|
821 | <variablelist>
|
---|
822 | <varlistentry>
|
---|
823 | <term><option>--human-readable</option></term>
|
---|
824 | <listitem><para>
|
---|
825 | Shows the disk sizes in a human readable form.
|
---|
826 | </para>
|
---|
827 | </listitem>
|
---|
828 | </varlistentry>
|
---|
829 | <varlistentry>
|
---|
830 | <term><option>--total</option></term>
|
---|
831 | <listitem><para>
|
---|
832 | Produces a grand total of all disk sizes.
|
---|
833 | </para>
|
---|
834 | </listitem>
|
---|
835 | </varlistentry>
|
---|
836 | <varlistentry>
|
---|
837 | <term><literal><replaceable>guest-path</replaceable> [<replaceable>guest-path</replaceable>...]</literal></term>
|
---|
838 | <listitem><para>
|
---|
839 | Specifies an absolute path to show guest filesystem
|
---|
840 | information for.
|
---|
841 | </para></listitem>
|
---|
842 | </varlistentry>
|
---|
843 | </variablelist>
|
---|
844 | </refsect2>
|
---|
845 | <refsect2 id="vboxmanage-guestcontrol-mkdir">
|
---|
846 | <title>Create a directory on the guest.</title>
|
---|
847 | <remark role="help-copy-synopsis"/>
|
---|
848 | <para>
|
---|
849 | The <command>VBoxManage guestcontrol
|
---|
850 | <replaceable>vmname</replaceable> mkdir</command> command
|
---|
851 | enables you to create one or more directories on the guest VM.
|
---|
852 | </para>
|
---|
853 | <para>
|
---|
854 | Alternate forms of this subcommand are <command>md</command>,
|
---|
855 | <command>createdir</command>, and
|
---|
856 | <command>createdirectory</command>.
|
---|
857 | </para>
|
---|
858 | <variablelist>
|
---|
859 | <varlistentry>
|
---|
860 | <term><option>--parents</option></term>
|
---|
861 | <listitem><para>
|
---|
862 | Creates any of the missing parent directories of the
|
---|
863 | specified directory.
|
---|
864 | </para><para>
|
---|
865 | For example, if you attempt to create the
|
---|
866 | <filename>D:\Foo\Bar</filename> directory and the
|
---|
867 | <filename>D:\Foo</filename> directory does not exist,
|
---|
868 | using the <option>--parents</option> creates the missing
|
---|
869 | <filename>D:\Foo</filename> directory. However, if you
|
---|
870 | attempt to create the <filename>D:\Foo\Bar</filename> and
|
---|
871 | do not specify the <option>--parents</option> option, the
|
---|
872 | command fails.
|
---|
873 | </para></listitem>
|
---|
874 | </varlistentry>
|
---|
875 | <varlistentry>
|
---|
876 | <term><option>--mode=<replaceable>mode</replaceable></option></term>
|
---|
877 | <listitem><para>
|
---|
878 | Specifies the permission mode to use for the specified
|
---|
879 | directory. If you specify the <option>--parents</option>
|
---|
880 | option, the mode is used for the associated parent
|
---|
881 | directories, as well. <replaceable>mode</replaceable> is a
|
---|
882 | four-digit octal mode such as <literal>0755</literal>.
|
---|
883 | </para></listitem>
|
---|
884 | </varlistentry>
|
---|
885 | <varlistentry>
|
---|
886 | <term><literal><replaceable>guest-dir</replaceable> [<replaceable>guest-dir</replaceable>...]</literal></term>
|
---|
887 | <listitem><para>
|
---|
888 | Specifies an absolute path of one or more directories to
|
---|
889 | create on the guest VM. For example,
|
---|
890 | <filename>D:\Foo\Bar</filename>.
|
---|
891 | </para><para>
|
---|
892 | If all of the associated parent directories do not exist
|
---|
893 | on the guest VM, you must specify the
|
---|
894 | <option>--parents</option> option.
|
---|
895 | </para><para>
|
---|
896 | You must have sufficient rights on the guest VM to create
|
---|
897 | the specified directory and its parent directories.
|
---|
898 | </para></listitem>
|
---|
899 | </varlistentry>
|
---|
900 | </variablelist>
|
---|
901 | </refsect2>
|
---|
902 | <refsect2 id="vboxmanage-guestcontrol-rmdir">
|
---|
903 | <title>Remove a directory from the guest.</title>
|
---|
904 | <remark role="help-copy-synopsis"/>
|
---|
905 | <para>
|
---|
906 | The <command>VBoxManage guestcontrol
|
---|
907 | <replaceable>vmname</replaceable> rmdir</command> command
|
---|
908 | enables you to delete the specified directory from the guest VM.
|
---|
909 | </para>
|
---|
910 | <para>
|
---|
911 | Alternate forms of this subcommand are
|
---|
912 | <command>removedir</command> and
|
---|
913 | <command>removedirectory</command>.
|
---|
914 | </para>
|
---|
915 | <variablelist>
|
---|
916 | <varlistentry>
|
---|
917 | <term><option>--recursive</option></term>
|
---|
918 | <listitem><para>
|
---|
919 | Recursively removes directories from the specified from
|
---|
920 | the guest VM.
|
---|
921 | </para><para>
|
---|
922 | The short form of this option is <option>-R</option>.
|
---|
923 | </para></listitem>
|
---|
924 | </varlistentry>
|
---|
925 | <varlistentry>
|
---|
926 | <term><literal><replaceable>guest-dir</replaceable> [<replaceable>guest-dir</replaceable>...]</literal></term>
|
---|
927 | <listitem><para>
|
---|
928 | Specifies an absolute path of one or more directories to
|
---|
929 | remove from the guest VM. You can use wildcards to specify
|
---|
930 | the directory names. For example,
|
---|
931 | <filename>D:\Foo\*Bar</filename>.
|
---|
932 | </para><para>
|
---|
933 | You must have sufficient rights on the guest VM to remove
|
---|
934 | the specified directory and its parent directories.
|
---|
935 | </para></listitem>
|
---|
936 | </varlistentry>
|
---|
937 | </variablelist>
|
---|
938 | </refsect2>
|
---|
939 | <refsect2 id="vboxmanage-guestcontrol-rm">
|
---|
940 | <title>Remove a file from the guest.</title>
|
---|
941 | <remark role="help-copy-synopsis"/>
|
---|
942 | <para>
|
---|
943 | The <command>VBoxManage guestcontrol
|
---|
944 | <replaceable>vmname</replaceable> rm</command> command enables
|
---|
945 | you to delete the specified files from the guest VM.
|
---|
946 | </para>
|
---|
947 | <para>
|
---|
948 | The alternate form of this subcommand is
|
---|
949 | <command>removefile</command>.
|
---|
950 | </para>
|
---|
951 | <variablelist>
|
---|
952 | <varlistentry>
|
---|
953 | <term><option>--force</option></term>
|
---|
954 | <listitem><para>
|
---|
955 | Forces the operation and overrides any confirmation
|
---|
956 | requests.
|
---|
957 | </para><para>
|
---|
958 | The short form of this option is <option>-f</option>.
|
---|
959 | </para></listitem>
|
---|
960 | </varlistentry>
|
---|
961 | <varlistentry>
|
---|
962 | <term><literal><replaceable>guest-file</replaceable> [<replaceable>guest-file</replaceable>...]</literal></term>
|
---|
963 | <listitem><para>
|
---|
964 | Specifies an absolute path of one or more files to remove
|
---|
965 | from the guest VM. You can use wildcards to specify the
|
---|
966 | file names. For example,
|
---|
967 | <filename>D:\Foo\Bar\text*.txt</filename>.
|
---|
968 | </para><para>
|
---|
969 | You must have sufficient rights on the guest VM to remove
|
---|
970 | the specified file.
|
---|
971 | </para></listitem>
|
---|
972 | </varlistentry>
|
---|
973 | </variablelist>
|
---|
974 | </refsect2>
|
---|
975 | <refsect2 id="vboxmanage-guestcontrol-mv">
|
---|
976 | <title>Rename a file or Directory on the guest</title>
|
---|
977 | <remark role="help-copy-synopsis"/>
|
---|
978 | <para>
|
---|
979 | The <command>VBoxManage guestcontrol
|
---|
980 | <replaceable>vmname</replaceable> mv</command> command enables
|
---|
981 | you to rename files and directories on the guest VM.
|
---|
982 | </para>
|
---|
983 | <para>
|
---|
984 | Alternate forms of this subcommand are <command>move</command>,
|
---|
985 | <command>ren</command>, and <command>rename</command>.
|
---|
986 | </para>
|
---|
987 | <variablelist>
|
---|
988 | <varlistentry>
|
---|
989 | <term><literal><replaceable>guest-source</replaceable> [<replaceable>guest-source</replaceable>...]</literal></term>
|
---|
990 | <listitem><para>
|
---|
991 | Specifies an absolute path of a file or a single directory
|
---|
992 | to move or rename on the guest VM. You can use wildcards
|
---|
993 | to specify the file names.
|
---|
994 | </para><para>
|
---|
995 | You must have sufficient rights on the guest VM to access
|
---|
996 | the specified file or directory.
|
---|
997 | </para></listitem>
|
---|
998 | </varlistentry>
|
---|
999 | <varlistentry>
|
---|
1000 | <term><replaceable>dest</replaceable></term>
|
---|
1001 | <listitem><para>
|
---|
1002 | Specifies the absolute path of the renamed file or
|
---|
1003 | directory, or the destination directory to which to move
|
---|
1004 | the files. If you move only one file,
|
---|
1005 | <replaceable>dest</replaceable> can be a file or a
|
---|
1006 | directory, otherwise <replaceable>dest</replaceable> must
|
---|
1007 | be a directory.
|
---|
1008 | </para><para>
|
---|
1009 | You must have sufficient rights on the guest VM to access
|
---|
1010 | the destination file or directory.
|
---|
1011 | </para></listitem>
|
---|
1012 | </varlistentry>
|
---|
1013 | </variablelist>
|
---|
1014 | </refsect2>
|
---|
1015 | <refsect2 id="vboxmanage-guestcontrol-mktemp">
|
---|
1016 | <title>Create a Temporary File or Directory on the guest</title>
|
---|
1017 | <remark role="help-copy-synopsis"/>
|
---|
1018 | <para>
|
---|
1019 | The <command>VBoxManage guestcontrol
|
---|
1020 | <replaceable>vmname</replaceable> mktemp</command> command
|
---|
1021 | enables you to create a temporary file or temporary directory on
|
---|
1022 | the guest VM. You can use this command to assist with the
|
---|
1023 | subsequent copying of files from the host system to the guest
|
---|
1024 | VM. By default, this command creates the file or directory in
|
---|
1025 | the guest VM's platform-specific <filename>temp</filename>
|
---|
1026 | directory.
|
---|
1027 | </para>
|
---|
1028 | <para>
|
---|
1029 | Alternate forms of this subcommand are
|
---|
1030 | <command>createtemp</command> and
|
---|
1031 | <command>createtemporary</command>.
|
---|
1032 | </para>
|
---|
1033 | <variablelist>
|
---|
1034 | <varlistentry>
|
---|
1035 | <term><option>--directory</option></term>
|
---|
1036 | <listitem><para>
|
---|
1037 | Creates a temporary directory that is specified by the
|
---|
1038 | <replaceable>template</replaceable> operand.
|
---|
1039 | </para></listitem>
|
---|
1040 | </varlistentry>
|
---|
1041 | <varlistentry>
|
---|
1042 | <term><option>--secure</option></term>
|
---|
1043 | <listitem><para>
|
---|
1044 | Enforces secure file and directory creation by setting the
|
---|
1045 | permission mode to <literal>0755</literal>. Any operation
|
---|
1046 | that cannot be performed securely fails.
|
---|
1047 | </para></listitem>
|
---|
1048 | </varlistentry>
|
---|
1049 | <varlistentry>
|
---|
1050 | <term><option>--mode=<replaceable>mode</replaceable></option></term>
|
---|
1051 | <listitem><para>
|
---|
1052 | Specifies the permission mode to use for the specified
|
---|
1053 | directory. <replaceable>mode</replaceable> is a four-digit
|
---|
1054 | octal mode such as <literal>0755</literal>.
|
---|
1055 | </para></listitem>
|
---|
1056 | </varlistentry>
|
---|
1057 | <varlistentry>
|
---|
1058 | <term><option>--tmpdir=<replaceable>directory</replaceable></option></term>
|
---|
1059 | <listitem><para>
|
---|
1060 | Specifies the absolute path of the directory on the guest
|
---|
1061 | VM in which to create the specified file or directory. If
|
---|
1062 | unspecified, <replaceable>directory</replaceable> is the
|
---|
1063 | platform-specific <filename>temp</filename> directory.
|
---|
1064 | </para></listitem>
|
---|
1065 | </varlistentry>
|
---|
1066 | <varlistentry>
|
---|
1067 | <term><replaceable>template</replaceable></term>
|
---|
1068 | <listitem><para>
|
---|
1069 | Specifies a template file name for the temporary file,
|
---|
1070 | without a directory path. The template file name must
|
---|
1071 | contain at least one sequence of three consecutive X
|
---|
1072 | characters, or must end in X.
|
---|
1073 | </para></listitem>
|
---|
1074 | </varlistentry>
|
---|
1075 | </variablelist>
|
---|
1076 | </refsect2>
|
---|
1077 | <refsect2 id="vboxmanage-guestcontrol-mount">
|
---|
1078 | <title>Shows mount points on the guest</title>
|
---|
1079 | <remark role="help-copy-synopsis"/>
|
---|
1080 | <para>
|
---|
1081 | The <command>VBoxManage guestcontrol
|
---|
1082 | <replaceable>vmname</replaceable> mount</command> command
|
---|
1083 | enables you to the current mount points on
|
---|
1084 | the guest VM. For Windows guests this shows the mapped drives.
|
---|
1085 | </para>
|
---|
1086 | </refsect2>
|
---|
1087 | <refsect2 id="vboxmanage-guestcontrol-stat">
|
---|
1088 | <title>Show a file or File System Status on the guest</title>
|
---|
1089 | <remark role="help-copy-synopsis"/>
|
---|
1090 | <para>
|
---|
1091 | The <command>VBoxManage guestcontrol
|
---|
1092 | <replaceable>vmname</replaceable> stat</command> command enables
|
---|
1093 | you to show the status of files or file systems on the guest VM.
|
---|
1094 | </para>
|
---|
1095 | <variablelist>
|
---|
1096 | <varlistentry>
|
---|
1097 | <term><literal><replaceable>file</replaceable> [<replaceable>file</replaceable> ...]</literal></term>
|
---|
1098 | <listitem><para>
|
---|
1099 | Specifies an absolute path of a file or file system on the
|
---|
1100 | guest VM. For example,
|
---|
1101 | <filename>/home/foo/a.out</filename>.
|
---|
1102 | </para><para>
|
---|
1103 | You must have sufficient rights on the guest VM to access
|
---|
1104 | the specified files or file systems.
|
---|
1105 | </para></listitem>
|
---|
1106 | </varlistentry>
|
---|
1107 | </variablelist>
|
---|
1108 | </refsect2>
|
---|
1109 | <refsect2 id="vboxmanage-guestcontrol-list">
|
---|
1110 | <title>List the Configuration and Status Information for a Guest Virtual
|
---|
1111 | Machine</title>
|
---|
1112 | <remark role="help-copy-synopsis"/>
|
---|
1113 | <para>
|
---|
1114 | The <command>VBoxManage guestcontrol
|
---|
1115 | <replaceable>vmname</replaceable> list</command> command enables
|
---|
1116 | you to list guest control configuration and status information.
|
---|
1117 | For example, the output shows open guest sessions, guest
|
---|
1118 | processes, and files.
|
---|
1119 | </para>
|
---|
1120 | <variablelist>
|
---|
1121 | <varlistentry>
|
---|
1122 | <term><literal>all</literal>|<literal>sessions</literal>|<literal>processes</literal>|<literal>files</literal></term>
|
---|
1123 | <listitem><para>
|
---|
1124 | Indicates the type of information to show.
|
---|
1125 | <literal>all</literal> shows all available data,
|
---|
1126 | <literal>sessions</literal> shows guest sessions,
|
---|
1127 | <literal>processes</literal> shows processes, and
|
---|
1128 | <literal>files</literal> shows files.
|
---|
1129 | </para></listitem>
|
---|
1130 | </varlistentry>
|
---|
1131 | </variablelist>
|
---|
1132 | </refsect2>
|
---|
1133 | <refsect2 id="vboxmanage-guestcontrol-closeprocess">
|
---|
1134 | <title>Terminate a Process in a guest Session</title>
|
---|
1135 | <remark role="help-copy-synopsis"/>
|
---|
1136 | <para>
|
---|
1137 | The <command>VBoxManage guestcontrol
|
---|
1138 | <replaceable>vmname</replaceable> closeprocess</command> command
|
---|
1139 | enables you to terminate a guest process that runs in a guest
|
---|
1140 | session. Specify the process by using a process identifier (PID)
|
---|
1141 | and the session by using the session ID or name.
|
---|
1142 | </para>
|
---|
1143 | <variablelist>
|
---|
1144 | <varlistentry>
|
---|
1145 | <term><option>--session-id=<replaceable>ID</replaceable></option></term>
|
---|
1146 | <listitem><para>
|
---|
1147 | Specifies the ID of the guest session.
|
---|
1148 | </para></listitem>
|
---|
1149 | </varlistentry>
|
---|
1150 | <varlistentry>
|
---|
1151 | <term><option>--session-name=<replaceable>name</replaceable>|<replaceable>pattern</replaceable></option></term>
|
---|
1152 | <listitem><para>
|
---|
1153 | Specifies the name of the guest session. Use a pattern
|
---|
1154 | that contains wildcards to specify multiple sessions.
|
---|
1155 | </para></listitem>
|
---|
1156 | </varlistentry>
|
---|
1157 | <varlistentry>
|
---|
1158 | <term><literal><replaceable>PID</replaceable> [<replaceable>PID</replaceable> ...]</literal></term>
|
---|
1159 | <listitem><para>
|
---|
1160 | Specifies the list of PIDs of guest processes to
|
---|
1161 | terminate.
|
---|
1162 | </para></listitem>
|
---|
1163 | </varlistentry>
|
---|
1164 | </variablelist>
|
---|
1165 | </refsect2>
|
---|
1166 | <refsect2 id="vboxmanage-guestcontrol-closesession">
|
---|
1167 | <title>Close a guest Session</title>
|
---|
1168 | <remark role="help-copy-synopsis"/>
|
---|
1169 | <para>
|
---|
1170 | The <command>VBoxManage guestcontrol
|
---|
1171 | <replaceable>vmname</replaceable> closesession</command> command
|
---|
1172 | enables you to close a guest session. Specify the guest session
|
---|
1173 | either by session ID or by name.
|
---|
1174 | </para>
|
---|
1175 | <variablelist>
|
---|
1176 | <varlistentry>
|
---|
1177 | <term><option>--session-id=<replaceable>ID</replaceable></option></term>
|
---|
1178 | <listitem><para>
|
---|
1179 | Specifies the ID of the guest session.
|
---|
1180 | </para></listitem>
|
---|
1181 | </varlistentry>
|
---|
1182 | <varlistentry>
|
---|
1183 | <term><option>--session-name=<replaceable>name</replaceable>|<replaceable>pattern</replaceable></option></term>
|
---|
1184 | <listitem><para>
|
---|
1185 | Specifies the name of the guest session. Use a pattern
|
---|
1186 | that contains wildcards to specify multiple sessions.
|
---|
1187 | </para></listitem>
|
---|
1188 | </varlistentry>
|
---|
1189 | <varlistentry>
|
---|
1190 | <term><option>--all</option></term>
|
---|
1191 | <listitem><para>
|
---|
1192 | Closes all guest sessions.
|
---|
1193 | </para></listitem>
|
---|
1194 | </varlistentry>
|
---|
1195 | </variablelist>
|
---|
1196 | </refsect2>
|
---|
1197 | <refsect2 id="vboxmanage-guestcontrol-updatega">
|
---|
1198 | <title>Update the Guest Additions Software on the guest</title>
|
---|
1199 | <remark role="help-copy-synopsis"/>
|
---|
1200 | <para>
|
---|
1201 | The <command>VBoxManage guestcontrol
|
---|
1202 | <replaceable>vmname</replaceable> updatega</command> command
|
---|
1203 | enables you to update the Guest Additions software installed in
|
---|
1204 | the specified guest VM.
|
---|
1205 | </para>
|
---|
1206 | <para>
|
---|
1207 | Alternate forms of this subcommand are
|
---|
1208 | <command>updateadditions</command> and
|
---|
1209 | <command>updateguestadditions</command>.
|
---|
1210 | </para>
|
---|
1211 | <variablelist>
|
---|
1212 | <varlistentry>
|
---|
1213 | <term><option>--source=<replaceable>new-iso-path</replaceable></option></term>
|
---|
1214 | <listitem><para>
|
---|
1215 | Specifies the absolute path of the Guest Additions update
|
---|
1216 | <filename>.ISO</filename> file on the guest VM.
|
---|
1217 | </para></listitem>
|
---|
1218 | </varlistentry>
|
---|
1219 | <varlistentry>
|
---|
1220 | <term><option>--reboot</option></term>
|
---|
1221 | <listitem><para>
|
---|
1222 | Automatically reboots the guest after a successful Guest Additions
|
---|
1223 | update.
|
---|
1224 | </para></listitem>
|
---|
1225 | </varlistentry>
|
---|
1226 | <varlistentry>
|
---|
1227 | <term><option>--timeout=<replaceable>ms</replaceable></option></term>
|
---|
1228 | <listitem><para>
|
---|
1229 | Sets the timeout (in ms) to wait for the overall Guest Additions update
|
---|
1230 | to complete. By default no timeout is being used.
|
---|
1231 | </para></listitem>
|
---|
1232 | </varlistentry>
|
---|
1233 | <varlistentry>
|
---|
1234 | <term><option>--verify</option></term>
|
---|
1235 | <listitem><para>
|
---|
1236 | Verifies whether the Guest Additions were updated successfully after
|
---|
1237 | a successful installation. A guest reboot is mandatory.
|
---|
1238 | </para></listitem>
|
---|
1239 | </varlistentry>
|
---|
1240 | <varlistentry>
|
---|
1241 | <term><option>--wait-ready</option></term>
|
---|
1242 | <listitem><para>
|
---|
1243 | Waits for the current Guest Additions being ready to handle the
|
---|
1244 | Guest Additions update.
|
---|
1245 | </para>
|
---|
1246 | </listitem>
|
---|
1247 | </varlistentry>
|
---|
1248 | <varlistentry>
|
---|
1249 | <term><option>--wait-start</option></term>
|
---|
1250 | <listitem><para>
|
---|
1251 | Starts the <command>VBoxManage</command> update process on
|
---|
1252 | the guest VM and then waits for the Guest Additions update
|
---|
1253 | to begin before terminating the
|
---|
1254 | <command>VBoxManage</command> process.
|
---|
1255 | </para><para>
|
---|
1256 | By default, the <command>VBoxManage</command> command
|
---|
1257 | waits for the Guest Additions update to complete before it
|
---|
1258 | terminates. Use this option when a running
|
---|
1259 | <command>VBoxManage</command> process affects the
|
---|
1260 | interaction between the installer and the guest OS.
|
---|
1261 | </para></listitem>
|
---|
1262 | </varlistentry>
|
---|
1263 | <varlistentry>
|
---|
1264 | <term><option>-- <replaceable>argument</replaceable> [<replaceable>argument</replaceable> ...]</option></term>
|
---|
1265 | <listitem><para>
|
---|
1266 | Specifies optional command-line arguments to pass to the
|
---|
1267 | Guest Additions updater. You might use the
|
---|
1268 | <option>--</option> option to pass the appropriate updater
|
---|
1269 | arguments to retrofit features that are not yet installed.
|
---|
1270 | </para><para>
|
---|
1271 | Ensure that any command argument that includes spaces is
|
---|
1272 | enclosed by quotes.
|
---|
1273 | </para></listitem>
|
---|
1274 | </varlistentry>
|
---|
1275 | </variablelist>
|
---|
1276 | </refsect2>
|
---|
1277 | <refsect2 id="vboxmanage-guestcontrol-waitrunlevel">
|
---|
1278 | <title>Wait for a guest run level</title>
|
---|
1279 | <para>
|
---|
1280 | The <command>VBoxManage guestcontrol
|
---|
1281 | <replaceable>vmname</replaceable> waitrunlevel</command> command
|
---|
1282 | enables you to wait for a guest run level being reached.
|
---|
1283 | </para>
|
---|
1284 | <variablelist>
|
---|
1285 | <varlistentry>
|
---|
1286 | <term><option>--timeout=<replaceable>ms</replaceable></option></term>
|
---|
1287 | <listitem><para>
|
---|
1288 | Sets the timeout (in ms) to wait for reaching the run level.
|
---|
1289 | By default no timeout is being used.
|
---|
1290 | </para></listitem>
|
---|
1291 | </varlistentry>
|
---|
1292 | <varlistentry>
|
---|
1293 | <term><option><replaceable>system</replaceable>|<replaceable>userland</replaceable>|<replaceable>desktop</replaceable></option></term>
|
---|
1294 | <listitem><para>
|
---|
1295 | Specifies the run level to wait for.
|
---|
1296 | </para></listitem>
|
---|
1297 | </varlistentry>
|
---|
1298 | </variablelist>
|
---|
1299 | </refsect2>
|
---|
1300 | <refsect2 id="vboxmanage-guestcontrol-watch">
|
---|
1301 | <title>Show Current Guest Control Activity</title>
|
---|
1302 | <remark role="help-copy-synopsis"/>
|
---|
1303 | <para>
|
---|
1304 | The <command>VBoxManage guestcontrol
|
---|
1305 | <replaceable>vmname</replaceable> watch</command> command
|
---|
1306 | enables you to show current guest control activity.
|
---|
1307 | </para>
|
---|
1308 | </refsect2>
|
---|
1309 | </refsect1>
|
---|
1310 |
|
---|
1311 | <refsect1 id="vboxmanage-guestcontrol-examples">
|
---|
1312 | <title>Examples</title>
|
---|
1313 | <remark role="help-scope" condition="GLOBAL"/>
|
---|
1314 | <para>
|
---|
1315 | The following <command>VBoxManage guestcontrol run</command>
|
---|
1316 | command executes the <command>ls -l /usr</command> command on the
|
---|
1317 | <literal>My OL VM</literal> Oracle Linux VM as the
|
---|
1318 | <literal>user1</literal> user.
|
---|
1319 | </para>
|
---|
1320 | <screen>
|
---|
1321 | $ VBoxManage --nologo guestcontrol "My OL VM" run --exe "/bin/ls" \
|
---|
1322 | --username user1 --passwordfile pw.txt --wait-stdout -- -l /usr
|
---|
1323 | </screen>
|
---|
1324 | <para>
|
---|
1325 | The <option>--exe</option> option specifies the absolute path of
|
---|
1326 | the command to run in the guest VM, <filename>/bin/ls</filename>.
|
---|
1327 | Use the <option>--</option> option to pass any arguments that
|
---|
1328 | follow it to the <command>ls</command> command.
|
---|
1329 | </para>
|
---|
1330 | <para>
|
---|
1331 | Use the <option>--username</option> option to specify the user
|
---|
1332 | name, <literal>user1</literal> and use the
|
---|
1333 | <option>--passwordfile</option> option to specify the name of a
|
---|
1334 | file that includes the password for the <literal>user1</literal>
|
---|
1335 | user, <filename>pw.txt</filename>.
|
---|
1336 | </para>
|
---|
1337 | <para>
|
---|
1338 | The <option>--wait-stdout</option> option waits for the
|
---|
1339 | <command>ls</command> guest process to complete before providing
|
---|
1340 | the exit code and the command output. The
|
---|
1341 | <option>--nologo</option> option suppresses the output of the logo
|
---|
1342 | information.
|
---|
1343 | </para>
|
---|
1344 | <para>
|
---|
1345 | The following <command>VBoxManage guestcontrol run</command>
|
---|
1346 | command executes the <command>ipconfig</command> command on the
|
---|
1347 | <literal>My Win VM</literal> Windows VM as the
|
---|
1348 | <literal>user1</literal> user. Standard input, standard output,
|
---|
1349 | and standard error are redirected from the VM to the host system
|
---|
1350 | until the program completes.
|
---|
1351 | </para>
|
---|
1352 | <screen>
|
---|
1353 | $ VBoxManage --nologo guestcontrol "My Win VM" run \
|
---|
1354 | --exe "c:\\windows\\system32\\ipconfig.exe" \
|
---|
1355 | --username user1 --passwordfile pw.txt --wait-stdout
|
---|
1356 | </screen>
|
---|
1357 | <para>
|
---|
1358 | The <option>--exe</option> specifies the absolute path of command
|
---|
1359 | to run in the guest VM,
|
---|
1360 | <filename>c:\windows\system32\ipconfig.exe</filename>. The double
|
---|
1361 | backslashes shown in this example are required only on UNIX host
|
---|
1362 | systems.
|
---|
1363 | </para>
|
---|
1364 | <para>
|
---|
1365 | Use the <option>--username</option> option to specify the user
|
---|
1366 | name, <literal>user1</literal> and use the
|
---|
1367 | <option>--passwordfile</option> option to specify the name of a
|
---|
1368 | file that includes the password for the <literal>user1</literal>
|
---|
1369 | user, <filename>pw.txt</filename>.
|
---|
1370 | </para>
|
---|
1371 | <para>
|
---|
1372 | The <option>--wait-stdout</option> option waits for the
|
---|
1373 | <command>ls</command> guest process to complete before providing
|
---|
1374 | the exit code and the command output. The
|
---|
1375 | <option>--nologo</option> option to suppress the output of the
|
---|
1376 | logo information.
|
---|
1377 | </para>
|
---|
1378 | <para>
|
---|
1379 | The following <command>VBoxManage guestcontrol start</command>
|
---|
1380 | command executes the <command>ls -l /usr</command> command on the
|
---|
1381 | <literal>My OL VM</literal> Oracle Linux VM until the program
|
---|
1382 | completes.
|
---|
1383 | </para>
|
---|
1384 | <screen>
|
---|
1385 | $ VBoxManage --nologo guestcontrol "My Win VM" start \
|
---|
1386 | --exe "c:\\windows\\system32\\ipconfig.exe" \
|
---|
1387 | --username user1 --passwordfile pw.txt
|
---|
1388 | </screen>
|
---|
1389 | <para>
|
---|
1390 | The following <command>VBoxManage guestcontrol run</command>
|
---|
1391 | command executes a <command>/usr/bin/busybox -l /usr</command>
|
---|
1392 | command on the <literal>My OL VM</literal> Oracle Linux VM as the
|
---|
1393 | <literal>user1</literal> user, explicitly using <literal>ls</literal>
|
---|
1394 | as argument 0.
|
---|
1395 | </para>
|
---|
1396 | <screen>
|
---|
1397 | $ VBoxManage --nologo guestcontrol "My OL VM" run --exe "/usr/bin/busybox" \
|
---|
1398 | --username user1 --passwordfile pw.txt --wait-stdout --arg0 ls -- -l /usr
|
---|
1399 | </screen>
|
---|
1400 | <para>
|
---|
1401 | The <option>--exe</option> option specifies the absolute path of
|
---|
1402 | the command to run in the guest VM, <filename>/usr/bin/busybox</filename>.
|
---|
1403 | Use the <option>--</option> option to pass any arguments that
|
---|
1404 | follow it to the <command>busybox</command> command.
|
---|
1405 | </para>
|
---|
1406 | <para>
|
---|
1407 | Use the <option>--username</option> option to specify the user
|
---|
1408 | name, <literal>user1</literal> and use the
|
---|
1409 | <option>--passwordfile</option> option to specify the name of a
|
---|
1410 | file that includes the password for the <literal>user1</literal>
|
---|
1411 | user, <filename>pw.txt</filename>.
|
---|
1412 | </para>
|
---|
1413 | <para>
|
---|
1414 | The <option>--wait-stdout</option> option waits for the
|
---|
1415 | <command>ls</command> guest process to complete before providing
|
---|
1416 | the exit code and the command output. The
|
---|
1417 | <option>--nologo</option> option suppresses the output of the logo
|
---|
1418 | information.
|
---|
1419 | </para>
|
---|
1420 | <para>
|
---|
1421 | The <option>--arg0</option> option explicitly specifies the argument 0
|
---|
1422 | to use for the command to execute.
|
---|
1423 | </para>
|
---|
1424 | <para>
|
---|
1425 | The default value of argument 0 (i.e. arg0 or argv[0]) is the value
|
---|
1426 | from the <option>--exe</option> option unless the <option>--arg0</option>
|
---|
1427 | option has been supplied.
|
---|
1428 | </para>
|
---|
1429 | </refsect1>
|
---|
1430 | </refentry>
|
---|