virt-v2v-copy-to-local(1)

πŸ“¦ version 1.44.2, in ubuntu jammy

πŸ’– virt-v2v-copy-to-local πŸ’–

okay bestie, welcome to the virt-v2v-copy-to-local(1) page β€” it lives in the Virtualization Support corner of the manual-verse, and it's basically the "grab ur friend's stuff and bring it home" tool. πŸŽ€


✨ NAME ✨

virt-v2v-copy-to-local β€” copy a remote guest to the local machine. like, literally just copy. it does NOT do the conversion, ok? we'll get to that. πŸ‘‘


🌸 SYNOPSIS 🌸

virt-v2v-copy-to-local -ic LIBVIRT_URI GUEST

virt-v2v-copy-to-local -ic xen+ssh://root@xen.example.com xen_guest

πŸ¦‹ DESCRIPTION πŸ¦‹

so virt-v2v-copy-to-local copies a guest from a remote hypervisor onto the local machine, getting it all prepped for conversion by virt-v2v(1). and heads up: this tool alone does not do the virt-v2v conversion. it's the opening act, not the headliner. πŸ’…

πŸ’­ When to use this tool

ngl, this tool is not usually necessary. but there are a few special cases (list incoming πŸ‘‡) where you might genuinely need it.

if ur situation doesn't fit one of these special cases, then ignore this tool and go read virt-v2v(1) instead. fr fr, the virt-v2v-copy-to-local process is slower than just using virt-v2v directly, because it has to copy the unused parts of the guest disk too. so much wasted copying, it's giving extra. 😭

  • you have a Xen guest using host block devices. virt-v2v cannot convert such guests directly.

see virt-v2v-input-xen(1).

βš™οΈ How this tool works

ok so the whole pipeline, step by step, no cap:

this tool uses libvirt to get the libvirt XML (metadata) of the remote guest β€” essentially the same thing as running virsh dumpxml guest. 🫢

then it uses that XML to locate the remote guest disks, which get copied over using a hypervisor-specific method. for remote Xen hypervisors, it uses ssh. πŸ”₯

then it modifies the libvirt XML so it points at the local copies of the guest disks instead. glow-up, but for XML. ✨

the libvirt XML gets output to a file called guest.xml (where guest is the name of the guest). the disk(s) get output to file(s) called guest-disk1, guest-disk2 and so on. so organized. so demure. πŸŽ€

after copying the guest locally, you can convert it using:

virt-v2v -i libvirtxml guest.xml [-o options ...]

virt-v2v finds the local copies of the disks by looking in the XML. iykyk. πŸ‘‘


🌈 EXAMPLES 🌈

🧚 Copy and convert from Xen hypervisor that uses host block devices

for the full instructions, go see virt-v2v-input-xen(1).

virt-v2v-copy-to-local -ic xen+ssh://root@xen.example.com xen_guest
virt-v2v -i libvirtxml xen_guest.xml -o local -os /var/tmp
rm xen_guest.xml xen_guest-disk*

look at that cleanup at the end. so satisfying. πŸ’–


πŸ’… OPTIONS πŸ’…

  • --help β€” display help. ur little helper, always there. πŸ₯Ί
  • -ic libvirtURI β€” specify a libvirt connection URI. this is the "where are we getting it from" flag.
  • -ip file β€” instead of asking for password(s) interactively, pass the password through a file. note the file should contain the whole password, with no trailing newline, and for security the file should have mode 0600 so that others cannot read it. protect ur secrets bestie. πŸ”’
currently this option does not have any effect on xen+ssh transfers, but that is a bug. yeah, we know. πŸ’€
  • -q, --quiet β€” this disables progress bars and other unnecessary output. silence. serenity. πŸ§˜β€β™€οΈ
  • -v, --verbose β€” enable verbose messages for debugging. for when u need to know everything. πŸ™ˆ
  • -V, --version β€” display version number and exit. short and iconic. ⭐

πŸ‘€ SEE ALSO πŸ‘€

virt-v2v(1), virsh(1), http://libguestfs.org/, https://libvirt.org/uri.html, https://libvirt.org/remote.html.

go read those too, they're part of the lore. πŸ“š


🫢 AUTHORS 🫢

Richard W.M. Jones http://people.redhat.com/~rjones/


Copyright (C) 2009-2020 Red Hat Inc.


πŸ“œ LICENSE πŸ“œ

this program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

this program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. see the GNU General Public License for more details.

you should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.


πŸ› BUGS πŸ›

to get a list of bugs against libguestfs, use this link: https://bugzilla.redhat.com/buglist.cgi?component=libguestfs&product=Virtualization+Tools

to report a new bug against libguestfs, use this link: https://bugzilla.redhat.com/enter_bug.cgi?component=libguestfs&product=Virtualization+Tools

when reporting a bug, please supply (this is the vibe check, don't skip it πŸ‘‡):

  • the version of libguestfs.
  • where you got libguestfs (eg. which Linux distro, compiled from source, etc)
  • describe the bug accurately and give a way to reproduce it.
  • run libguestfs-test-tool(1) and paste the complete, unedited output into the bug report.

and that's the whole page bestie!! go forth and copy those guests πŸ’–

this has been virt-v2v-copy-to-local(1) from virt-v2v-1.44.2, dated 2021-12-25 β€” mwah, slay, periodt. πŸ‘‘βœ¨πŸŽ€

πŸ“¦ where this page comes from