Manual page with centralised documentation.
[virt-p2v.git] / virt-p2v.1.html
1 <?xml version="1.0" ?>
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml">
4 <head>
5 <title>virt-p2v - P2V migration tool</title>
6 <link rel="stylesheet" href="virt-p2v.1.css" type="text/css" />
7 <meta http-equiv="content-type" content="text/html; charset=utf-8" />
8 <link rev="made" href="mailto:root@localhost" />
9 </head>
10
11 <body>
12
13 <p><a name="__index__"></a></p>
14 <!-- INDEX BEGIN -->
15
16 <ul>
17
18         <li><a href="#name">NAME</a></li>
19         <li><a href="#summary">SUMMARY</a></li>
20         <li><a href="#description">DESCRIPTION</a></li>
21         <li><a href="#standard_usage">STANDARD USAGE</a></li>
22         <ul>
23
24                 <li><a href="#booting_p2v_guest_on_virtualization_host">BOOTING P2V GUEST ON VIRTUALIZATION HOST</a></li>
25         </ul>
26
27         <li><a href="#getting_a_shell">GETTING A SHELL</a></li>
28         <ul>
29
30                 <li><a href="#log_file">LOG FILE</a></li>
31         </ul>
32
33         <li><a href="#server_requirements">SERVER REQUIREMENTS</a></li>
34         <li><a href="#building_a_custom_live_cd">BUILDING A CUSTOM LIVE CD</a></li>
35         <ul>
36
37                 <li><a href="#editing_defaults_in_the_virtp2v_script">EDITING DEFAULTS IN THE <code>virt-p2v</code> SCRIPT</a></li>
38                 <li><a href="#iso_attachments">ISO ATTACHMENTS</a></li>
39         </ul>
40
41         <li><a href="#booting_from_a_usb_key_instead_of_a_cd">BOOTING FROM A USB KEY INSTEAD OF A CD</a></li>
42         <li><a href="#testing_an_iso_under_qemu_or_kvm">TESTING AN ISO UNDER QEMU OR KVM</a></li>
43         <li><a href="#see_also">SEE ALSO</a></li>
44         <li><a href="#authors">AUTHORS</a></li>
45         <li><a href="#copyright">COPYRIGHT</a></li>
46         <li><a href="#reporting_bugs">REPORTING BUGS</a></li>
47 </ul>
48 <!-- INDEX END -->
49
50 <hr />
51 <p>
52 </p>
53 <h1><a name="name">NAME</a></h1>
54 <p>virt-p2v - P2V (physical to virtual machine) migration tool</p>
55 <p>
56 </p>
57 <hr />
58 <h1><a name="summary">SUMMARY</a></h1>
59 <p>virt-p2v</p>
60 <p>
61 </p>
62 <hr />
63 <h1><a name="description">DESCRIPTION</a></h1>
64 <p>virt-p2v is a live CD for migrating physical machines to virtual
65 machine guests.</p>
66 <p>In the simplest mode of operation, you take a pre-built live CD ISO
67 from the main website (<a href="http://et.redhat.com/~rjones/virt-p2v/">http://et.redhat.com/~rjones/virt-p2v/</a>) and
68 burn it to a CD-R.  Then insert the CD-R into the physical machine
69 which must be migrated, reboot, and follow the on-screen instructions.
70 See <strong>STANDARD USAGE</strong> section below.</p>
71 <p>You may also build a customized live CD.  Typically this will contain
72 things like server details specific to your organization, so that the
73 live CD can run mostly or completely automatically.  See <strong>BUILDING A
74 CUSTOM LIVE CD</strong> section below.</p>
75 <p>In both cases, files and disk images are transferred from the physical
76 machine over the network to the virtualization host machine over ssh.
77 Therefore <code>sshd</code> must be running on the virtualization host, and must
78 be accessible to that host.  See <strong>SERVER REQUIREMENTS</strong> section below.</p>
79 <p>The <code>virt-p2v</code> script must only be run from the live CD.  It isn't
80 designed to run outside this environment and could do Bad Things to
81 your machine if you try it.  The script contains some checks to try to
82 stop you from doing this.</p>
83 <p>Virt-p2v does not modify the physical machine, its disks,
84 configuration etc.</p>
85 <p>
86 </p>
87 <hr />
88 <h1><a name="standard_usage">STANDARD USAGE</a></h1>
89 <p>After booting the live CD-R, you are presented with a series of
90 questions.  This section explains each question.</p>
91 <dl>
92 <dt><strong><a name="item_remote_host">Remote host</a></strong>
93
94 <dd>
95 <p>Enter the name or IP address of the virtualization host.  This is the
96 host running Xen (or any other virtualization system supported by
97 libvirt, eg. QEMU).  This host should be accessible on the network and
98 running an SSH daemon (<code>sshd</code>).</p>
99 </dd>
100 </li>
101 <dt><strong><a name="item_remote_port">Remote port</a></strong>
102
103 <dd>
104 <p>This is the port name or number of the SSH server on the remote host.
105 The default is <code>22</code> which is the standard SSH port.</p>
106 </dd>
107 </li>
108 <dt><strong><a name="item_remote_directory">Remote directory</a></strong>
109
110 <dd>
111 <p>Enter the directory on the remote host where disk <code>image(s)</code> and
112 configuration <code>file(s)</code> must reside.</p>
113 </dd>
114 <dd>
115 <p>Note that if the remote host is running SELinux then you may not be
116 able to start a Xen guest unless its disk <code>image(s)</code> are located in the
117 default directory, <code>/var/lib/xen/images</code>.</p>
118 </dd>
119 </li>
120 <dt><strong><a name="item_remote_username">Remote username</a></strong>
121
122 <dd>
123 <p>Enter the remote SSH username to use to log in to the remote host.</p>
124 </dd>
125 <dd>
126 <p>If you use the default username of <code>root</code> then you should ensure that
127 remote root logins are enabled on the remote host
128 (ie. <code>PermitRootLogin yes</code> in <code>/etc/ssh/sshd_config</code>).</p>
129 </dd>
130 </li>
131 <dt><strong><a name="item_network_configuration">Network configuration</a></strong>
132
133 <dd>
134 <p>Choose the way that the live CD configures network access.  The
135 current options are:</p>
136 </dd>
137 <dl>
138 <dt><strong><a name="item_automatic_configuration">Automatic configuration</a></strong>
139
140 <dd>
141 <p>In this mode, the live CD attempts to reuse the network configuration
142 from the physical machine's root filesystem.  You should probably try
143 this method even though occasionally it does not work.</p>
144 </dd>
145 </li>
146 <dt><strong><a name="item_configure_from_the_shell">Configure from the shell</a></strong>
147
148 <dd>
149 <p>In this mode you will be dropped into a command shell and you will
150 need to issue the correct sequence of <code>/sbin/ifconfig</code> commands in
151 order to configure the network interface.</p>
152 </dd>
153 <dd>
154 <p>A typical sequence of commands which should bring up the network
155 interface would be:</p>
156 </dd>
157 <dd>
158 <pre>
159  /sbin/ifconfig eth0 AA.BB.CC.DD
160  /sbin/route add default gw GG.HH.II.JJ eth0</pre>
161 </dd>
162 <dd>
163 <p>where <code>AA.BB.CC.DD</code> is the IP address and <code>GG.HH.II.JJ</code> is the
164 gateway.</p>
165 </dd>
166 </li>
167 </dl>
168 <dt><strong><a name="item_devices">Devices</a></strong>
169
170 <dd>
171 <p>This question lists out all local block devices (hard disk drives and
172 similar) and asks you to choose which will be sent to the remote host.
173 You must send at least one block device.</p>
174 </dd>
175 </li>
176 <dt><strong><a name="item_root_device">Root device</a></strong>
177
178 <dd>
179 <p>This question lists out possible root filesystems and asks you to
180 choose the right one.  Choose the filesystem which would normally be
181 mounted as <code>/</code> on the system.</p>
182 </dd>
183 <dd>
184 <p>Virt-p2v performs some autodetection and is in most cases able to work
185 out which filesystems are possible root filesystems.  It displays what
186 it thinks is on each filesystem, but leaves it up to the user to make
187 a final decision.</p>
188 </dd>
189 <dd>
190 <p>The root filesystem is critical because it contains <code>/etc/fstab</code>.
191 This is used during P2V both to determine how other filesystems are
192 normally mounted on the machine, and because this file and others
193 under <code>/etc</code> may need to be modified during P2V conversion.</p>
194 </dd>
195 <dd>
196 <p>If the machine has more than one root filesystem (typically because
197 the machine is dual-booted with another operating system), then you
198 must choose only one of them to perform the P2V conversion on.</p>
199 </dd>
200 </li>
201 <dt><strong><a name="item_hypervisor">Hypervisor</a></strong>
202
203 <dd>
204 <p>This question asks you to choose the hypervisor / virtualization
205 system in use on the remote host.</p>
206 </dd>
207 <dd>
208 <p>If you select <em>Xen</em>, <em>QEMU</em> or <em>KVM</em> then virt-p2v will produce a
209 configuration file which is customized for the selected system.  If
210 you select <em>Other</em> then virt-p2v will produce a generic configuration
211 file which will probably require hand-modification to work.</p>
212 </dd>
213 <dd>
214 <p>See also <a href="http://libvirt.org/format.html">http://libvirt.org/format.html</a>.</p>
215 </dd>
216 </li>
217 <dt><strong><a name="item_machine_architecture">Machine architecture</a></strong>
218
219 <dd>
220 <p>This question asks you to choose the machine architecture.  Virt-p2v
221 can normally detect this, so you should leave it as <em>Auto-detect</em>.</p>
222 </dd>
223 </li>
224 <dt><strong><a name="item_memory">Memory</a></strong>
225
226 <dd>
227 <p>This question asks you to choose the amount of memory (RAM) in
228 megabytes assigned to the virtual machine.</p>
229 </dd>
230 <dd>
231 <p>If the entry is left blank, then virt-p2v will try to autodetect how
232 much RAM is present in the physical machine and use that, and this is
233 probably a good choice for most simple migrations.</p>
234 </dd>
235 </li>
236 <dt><strong><a name="item_virtual_cpus">Virtual CPUs</a></strong>
237
238 <dd>
239 <p>This question asks you to choose the number of virtual CPUs assigned
240 to the virtual machine.  Choosing <code>1</code> causes the virtual machine to
241 be uniprocessor, and choosing some number greater than 1 causes the
242 virtual machine to be SMP.</p>
243 </dd>
244 <dd>
245 <p>If the entry is left blank, then virt-p2v will try to autodetect how
246 many CPU cores are present in the physical machine and use that, and
247 this is probably a good choice for most simple migrations.</p>
248 </dd>
249 </li>
250 <dt><strong><a name="item_mac_address">MAC address</a></strong>
251
252 <dd>
253 <p>Here you should enter a MAC address for the virtual machine's emulated
254 network card.  MAC addresses are written as <code>aa:bb:cc:dd:ee:ff</code> where
255 <code>aa</code>, <code>bb</code> etc are hexadecimal octets.</p>
256 </dd>
257 <dd>
258 <p>Leaving it blank will cause virt-p2v to choose a random MAC address
259 within the <code>00:16:3e:..</code> space reserved for Xen guests.  These MAC
260 addresses are not tested for uniqueness so there is a very small
261 chance that they could coincide, which would leave a guest unable to
262 access the virtual network.</p>
263 </dd>
264 </li>
265 <dt><strong><a name="item_verify_and_proceed">Verify and proceed</a></strong>
266
267 <dd>
268 <p>In this step you are asked to verify the settings above.  If any are
269 incorrect, use the <em>Back</em> button to navigate back to the setting.  If
270 all settings are correct, use the <em>OK</em> button to begin the P2V
271 conversion.</p>
272 </dd>
273 </li>
274 <dt><strong><a name="item_network_autoconfiguration">Network autoconfiguration</a></strong>
275
276 <dd>
277 <p>If you selected network autoconfiguration above then virt-p2v tries to
278 autoconfigure the network and ping the remote host.  It then asks
279 <em>Did automatic network configuration work?</em></p>
280 </dd>
281 <dd>
282 <p>You should answer <code>y</code> here if it worked.</p>
283 </dd>
284 <dd>
285 <p>Answering <code>n</code> will drop you into a command shell.</p>
286 </dd>
287 <dd>
288 <p>You can also switch to another virtual console if you need to perform
289 additional tests.  See section <strong>GETTING A SHELL</strong> below.</p>
290 </dd>
291 </li>
292 <dt><strong><a name="item_ssh_connection">SSH connection</a></strong>
293
294 <dd>
295 <p>Unless you have set up an SSH key, or the SSH server on the remote
296 host allows passwordless logins, then for each file that has to be
297 transferred to the remote host you will need to confirm the identity
298 of the remote host and/or enter a password.</p>
299 </dd>
300 <dd>
301 <p>To understand more about this, please see the <em>ssh(1)</em> manual page.</p>
302 </dd>
303 </li>
304 </dl>
305 <p>
306 </p>
307 <h2><a name="booting_p2v_guest_on_virtualization_host">BOOTING P2V GUEST ON VIRTUALIZATION HOST</a></h2>
308 <p>Once the P2V conversion has been completed, and assuming it was
309 successful, you will find a configuration file and one or more disk
310 images on the remote host.</p>
311 <p>The files will be located in the directory selected, usually
312 <code>/var/lib/xen/images</code>.  The names of the files are made up of:</p>
313 <p><code>p2v-hostname-YYYYMMDDHHMM.conf</code> or
314 <code>p2v-hostname-YYYYMMDDHHMM-hdX.img</code></p>
315 <p>To simply start up the guest, use the following commands as root:</p>
316 <pre>
317  virsh define p2v-foo-2008MMDDHHMM.conf
318  virsh start foo</pre>
319 <p>For QEMU/KVM do:</p>
320 <pre>
321  virsh -c qemu:///system define p2v-foo-2008MMDDHHMM.conf
322  virsh -c qemu:///system start foo</pre>
323 <p>For other hypervisors you will need to edit the configuration file and
324 read <a href="http://libvirt.org/uri.html">http://libvirt.org/uri.html</a>.</p>
325 <p>
326 </p>
327 <hr />
328 <h1><a name="getting_a_shell">GETTING A SHELL</a></h1>
329 <p>During all stages of P2V questions and conversion you can get a root
330 shell on the physical machine.  Use <em>ALT</em> <em>F2</em> keys to switch to the
331 second virtual console, then log in as <em>root</em> with no password.</p>
332 <p>
333 </p>
334 <h2><a name="log_file">LOG FILE</a></h2>
335 <p>Virt-p2v writes a detailed log file to <code>/tmp/virt-p2v.log</code>.  (Note
336 that this <code>/tmp</code> directory is a ramdisk on the live CD, not the same
337 as the <code>/tmp</code> directory of the physical machine, and more importantly
338 it disappears when the machine is rebooted).</p>
339 <p>If you are reporting a bug, please always supply this file.</p>
340 <p>
341 </p>
342 <hr />
343 <h1><a name="server_requirements">SERVER REQUIREMENTS</a></h1>
344 <p>The virtualization host (remote host) must be running an SSH daemon
345 (<code>sshd</code>), accessible from the physical machine which is being
346 migrated.</p>
347 <p>Previous versions of virt-p2v could use a special virt-p2v server.
348 However this capability has been removed since there was practically
349 no benefit.</p>
350 <p>
351 </p>
352 <hr />
353 <h1><a name="building_a_custom_live_cd">BUILDING A CUSTOM LIVE CD</a></h1>
354 <p>To build a custom live CD you must download the source for virt-p2v
355 from <a href="http://et.redhat.com/~rjones/virt-p2v/">http://et.redhat.com/~rjones/virt-p2v/</a> or from the Mercurial
356 source repository (see website for details).</p>
357 <p>Please read the <code>README</code> file to find the dependencies which are all
358 in Fedora &amp;gt; 8 or EPEL &amp;gt; 5.</p>
359 <p>The steps to creating a custom live CD are:</p>
360 <ol>
361 <li><strong><a name="item_edit_virt_2dp2v_and_adjust_defaults">Edit <code>virt-p2v</code> and adjust defaults</a></strong>
362
363 <p>Find the section ``TO MAKE A CUSTOM virt-p2v SCRIPT ...'' which is near
364 to the top of this file.  Edit the defaults in this section as
365 detailed below.</p>
366 </li>
367 <li><strong><a name="item_virt_2dp2v__2d_2dtest_to_verify_your_changes"><code>virt-p2v --test</code> to verify your changes</a></strong>
368
369 <p>This command should not print anything at all.  If it prints any
370 message, then you will need to fix the error by going back to the
371 first step.</p>
372 </li>
373 <li><strong><a name="item_make_build_or_make_update_to_build_a_custom_live_c"><code>make build</code> or <code>make update</code> to build a custom live CD</a></strong>
374
375 <p><code>make build</code> will create a complete ISO from scratch.  <code>make update</code>
376 can be used to build a ``quick'' developer ISO by updating an existing
377 ISO image.  See section <strong>ISO ATTACHMENTS</strong> below for more details.</p>
378 </li>
379 <li><strong><a name="item_burn_the_iso_to_a_cd_2dr_and_test">Burn the ISO to a CD-R and test</a></strong>
380
381 </ol>
382 <p>
383 </p>
384 <h2><a name="editing_defaults_in_the_virtp2v_script">EDITING DEFAULTS IN THE <code>virt-p2v</code> SCRIPT</a></h2>
385 <p>For each default, setting it to <code>None</code> will ask the user.  All of the
386 defaults are set to <code>None</code> in the standard, uncustomized virt-p2v
387 script, and so the standard script asks all the questions.</p>
388 <p>You may edit <code>virt-p2v</code> and change the defaults, in which case the
389 user will not be questioned.  In this way you can make the script
390 partially or fully automated.</p>
391 <p><em>Note about OCaml code:</em>  <code>None</code> and <code>Some foo</code> are similar to the
392 concept of a NULL pointer versus non-NULL pointer in other languages.
393 This a variant type defined as:</p>
394 <p>type &#945; option = None | Some of &#945;</p>
395 <dl>
396 <dt><strong><a name="item_greeting"><code>greeting</code></a></strong>
397
398 <dd>
399 <p>If this is <code>true</code> then we wait for a keypress after boot and at a
400 couple of other stages.  If set to <code>false</code> then we try not to wait
401 for any keypresses (so more automated live CDs are possible).</p>
402 </dd>
403 </li>
404 <dt><strong><a name="item_remote_host"><code>remote_host</code></a></strong>
405
406 <dd>
407 <p>Set this to <code>Some &quot;hostname&quot;</code> or <code>Some &quot;IP-address&quot;</code> to
408 provide the name of the remote host.</p>
409 </dd>
410 </li>
411 <dt><strong><a name="item_remote_port"><code>remote_port</code></a></strong>
412
413 <dd>
414 <p>Set this to <code>Some port</code> (eg. <code>Some 22</code>) to provide the port number
415 of the remote host's SSH daemon.</p>
416 </dd>
417 </li>
418 <dt><strong><a name="item_remote_directory"><code>remote_directory</code></a></strong>
419
420 <dd>
421 <p>Set this to <code>Some &quot;path&quot;</code> (eg. <code>Some &quot;/var/lib/xen/images&quot;</code>) to
422 provide the directory where we update P2V converted images and
423 configuration files.</p>
424 </dd>
425 </li>
426 <dt><strong><a name="item_remote_username"><code>remote_username</code></a></strong>
427
428 <dd>
429 <p>Set this to <code>Some &quot;username&quot;</code> (eg. <code>Some &quot;root&quot;</code>) to provide the SSH
430 username to use on the remote system.</p>
431 </dd>
432 </li>
433 <dt><strong><a name="item_devices_to_send"><code>devices_to_send</code></a></strong>
434
435 <dd>
436 <p>Set this to a list of block devices to send to the remote system.
437 For example, <code>Some [&quot;sda&quot;; &quot;sdb&quot;]</code>.</p>
438 </dd>
439 </li>
440 <dt><strong><a name="item_root_filesystem"><code>root_filesystem</code></a></strong>
441
442 <dd>
443 <p>Set this to the name of the root filesystem.</p>
444 </dd>
445 <dd>
446 <p>For a disk partition (eg. <code>/dev/sda1</code>), use:</p>
447 </dd>
448 <dd>
449 <pre>
450  Some (Part (&quot;sda&quot;, &quot;1&quot;))</pre>
451 </dd>
452 <dd>
453 <p>For a logical volume (eg. <code>/dev/VolGroup00/LogVol00</code>), use:</p>
454 </dd>
455 <dd>
456 <pre>
457  Some (LV (&quot;VolGroup00&quot;, &quot;LogVol00&quot;))</pre>
458 </dd>
459 </li>
460 <dt><strong><a name="item_network"><code>network</code></a></strong>
461
462 <dd>
463 <p>Set this to the choice for network setup.  Use either <code>Some Auto</code> or
464 <code>Some Shell</code> for auto-configuration or shell (manual) configuration
465 respectively.</p>
466 </dd>
467 </li>
468 <dt><strong><a name="item_hypervisor"><code>hypervisor</code></a></strong>
469
470 <dd>
471 <p>Set this to the choice of hypervisor or virtualization system.  The
472 choices are: <code>Some Xen</code>, <code>Some QEMU</code> or <code>Some KVM</code>.</p>
473 </dd>
474 </li>
475 <dt><strong><a name="item_architecture"><code>architecture</code></a></strong>
476
477 <dd>
478 <p>Set this to the architecture.  The choices are:
479 <code>Some I386</code> (i386 and up, 32 bit),
480 <code>Some X86_64</code> (AMD and Intel x86-64, 64 bit),
481 <code>Some IA64</code> (Intel IA64),
482 <code>Some PPC</code> (PowerPC, 32 bit),
483 <code>Some PPC64</code> (PowerPC, 64 bit),
484 <code>Some SPARC</code> (Sun SPARC, 32 bit),
485 <code>Some SPARC64</code> (Sun SPARC, 64 bit),
486 <code>OtherArch &quot;foo&quot;</code> (a hypothetical architecture called <em>foo</em>), or
487 <code>UnknownArch</code> to auto-detect the architecture.</p>
488 </dd>
489 </li>
490 <dt><strong><a name="item_memory"><code>memory</code></a></strong>
491
492 <dd>
493 <p>Set this to the size of memory in megabytes, eg. <code>Some 256</code>.  If you
494 set this to <code>Some 0</code> then virt-p2v will try to autodetect the amount
495 of RAM installed on the physical machine.</p>
496 </dd>
497 </li>
498 <dt><strong><a name="item_vcpus"><code>vcpus</code></a></strong>
499
500 <dd>
501 <p>Set this to the number of virtual CPUs, eg. <code>Some 1</code>.  If you set
502 this to <code>Some 0</code> then virt-p2v will try to autodetect the number of
503 CPU cores on the physical machine.</p>
504 </dd>
505 </li>
506 <dt><strong><a name="item_mac_address"><code>mac_address</code></a></strong>
507
508 <dd>
509 <p>Set this to the MAC address for the virtual network card, eg. <code>Some
510 &quot;aa:bb:cc:dd:ee:ff&quot;</code>.  If you set this to <code>Some &quot;&quot;</code> then virt-p2v
511 will choose a random MAC address within the <code>00:16:3e:..</code> space
512 reserved for Xen guests.  These MAC addresses are not tested for
513 uniqueness so there is a very small chance that they could coincide,
514 which would leave a guest unable to access the virtual network.</p>
515 </dd>
516 </li>
517 </dl>
518 <p>
519 </p>
520 <h2><a name="iso_attachments">ISO ATTACHMENTS</a></h2>
521 <p>Rebuilding a custom ISO is time-consuming.  You can make a ``quick''
522 developer ISO by updating an existing ISO image with a new custom
523 <code>virt-p2v</code> script.  This is useful for testing purposes.</p>
524 <p>From the source directory, assuming that you have downloaded or
525 built an existing <code>virt-p2v-*.iso</code>, you can just do:</p>
526 <pre>
527  make update</pre>
528 <p>or the equivalent manual command:</p>
529 <pre>
530  ./iso-attach virt-p2v-VERSION.iso virt-p2v</pre>
531 <p>
532 </p>
533 <hr />
534 <h1><a name="booting_from_a_usb_key_instead_of_a_cd">BOOTING FROM A USB KEY INSTEAD OF A CD</a></h1>
535 <p>If you wish to boot from a USB keydrive, use the livecd-iso-to-disk
536 tool:</p>
537 <pre>
538  livecd-iso-to-disk virt-p2v-$VERSION.iso /dev/sdX1</pre>
539 <p>(Replace /dev/sdX1 with the actual USB device).</p>
540 <p>In my experience I also had to set up a suitable MBR:</p>
541 <pre>
542  cat /usr/lib/syslinux/mbr.bin &gt; /dev/sdX</pre>
543 <p>
544 </p>
545 <hr />
546 <h1><a name="testing_an_iso_under_qemu_or_kvm">TESTING AN ISO UNDER QEMU OR KVM</a></h1>
547 <p>If you have a virtual guest running under QEMU or KVM then
548 you can test the P2V conversion process on the guest.</p>
549 <p>(Technically this is a V2V -- virtual to virtual -- conversion).</p>
550 <p>From the source directory do:</p>
551 <pre>
552  make boot HDA=qemuimage.img</pre>
553 <p>where <code>qemuimage.img</code> is the name of the QEMU/KVM image.</p>
554 <p>You can also supply an <code>HDB</code> parameter to specify a second disk.</p>
555 <p>
556 </p>
557 <hr />
558 <h1><a name="see_also">SEE ALSO</a></h1>
559 <p><em>virsh(1)</em>,
560 <a href="http://www.libvirt.org/ocaml/">http://www.libvirt.org/ocaml/</a>,
561 <a href="http://www.libvirt.org/">http://www.libvirt.org/</a>,
562 <a href="http://et.redhat.com/~rjones/">http://et.redhat.com/~rjones/</a>,
563 <a href="http://caml.inria.fr/">http://caml.inria.fr/</a></p>
564 <p>
565 </p>
566 <hr />
567 <h1><a name="authors">AUTHORS</a></h1>
568 <p>Richard W.M. Jones &lt;rjones @ redhat . com&gt;</p>
569 <p>
570 </p>
571 <hr />
572 <h1><a name="copyright">COPYRIGHT</a></h1>
573 <p>(C) Copyright 2007-2008 Red Hat Inc., Richard W.M. Jones
574 <a href="http://libvirt.org/">http://libvirt.org/</a></p>
575 <p>This program is free software; you can redistribute it and/or modify
576 it under the terms of the GNU General Public License as published by
577 the Free Software Foundation; either version 2 of the License, or
578 (at your option) any later version.</p>
579 <p>This program is distributed in the hope that it will be useful,
580 but WITHOUT ANY WARRANTY; without even the implied warranty of
581 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
582 GNU General Public License for more details.</p>
583 <p>You should have received a copy of the GNU General Public License
584 along with this program; if not, write to the Free Software
585 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.</p>
586 <p>
587 </p>
588 <hr />
589 <h1><a name="reporting_bugs">REPORTING BUGS</a></h1>
590 <p>Bugs can be viewed on the Red Hat Bugzilla page:
591 <a href="https://bugzilla.redhat.com/">https://bugzilla.redhat.com/</a>.</p>
592 <p>If you find a bug in virt-p2v, please follow these steps to report it:</p>
593 <ol>
594 <li><strong><a name="item_check_for_existing_bug_reports">Check for existing bug reports</a></strong>
595
596 <p>Go to <a href="https://bugzilla.redhat.com/">https://bugzilla.redhat.com/</a> and search for similar bugs.
597 Someone may already have reported the same bug, and they may even
598 have fixed it.</p>
599 </li>
600 <li><strong><a name="item_capture_debug_and_error_messages">Capture debug and error messages</a></strong>
601
602 <p>At the point where you get the error or unexpected behaviour,
603 go to the second virtual console (<em>ALT</em> <em>F2</em>) and look at
604 the logfile <code>/tmp/virt-p2v.log</code>.  Please make sure that
605 this file is attached to your bug report.</p>
606 </li>
607 <li><strong><a name="item_get_version_of_virt_2dp2v">Get version of virt-p2v</a></strong>
608
609 <p>The version is in the name of the ISO.  If you have built a custom
610 virt-p2v ISO, please describe any changes that you have made.</p>
611 </li>
612 <li><strong><a name="item_submit_a_bug_report_2e">Submit a bug report.</a></strong>
613
614 <p>Go to <a href="https://bugzilla.redhat.com/">https://bugzilla.redhat.com/</a> and enter a new bug.
615 Please describe the problem in as much detail as possible.</p>
616 <p>Remember to include the version number (step 3) and to
617 attach the log file (step 2).</p>
618 </li>
619 <li><strong><a name="item_assign_the_bug_to_rjones__40_redhat_2ecom">Assign the bug to rjones @ redhat.com</a></strong>
620
621 <p>Assign or reassign the bug to <strong>rjones @ redhat.com</strong> (without the
622 spaces).  You can also send me an email with the bug number if you
623 want a faster response.</p>
624 </li>
625 </ol>
626
627 </body>
628
629 </html>