X-Git-Url: http://git.annexia.org/?a=blobdiff_plain;f=src%2Fguestfs.pod;h=e6a16a68fa6dfbcfd3d4a2688baa6306bc49df9f;hb=145ed04e41a3fcd3be87c11cae0085f4551f1da8;hp=ada9f1e53ba15286e02c5e28cdfcba862b7b5b05;hpb=c155330f04f933d13298d5cddab6b7f3dc9d218f;p=libguestfs.git diff --git a/src/guestfs.pod b/src/guestfs.pod index ada9f1e..e6a16a6 100644 --- a/src/guestfs.pod +++ b/src/guestfs.pod @@ -313,21 +313,36 @@ in the table below. =item B to B -Use L to copy a single file, or -L to copy directories recursively. +Use L to copy a single file, or L to copy +directories recursively. -=item B to B +To copy part of a file (offset and size) use +L. -Use L which efficiently uses L -to copy between files and devices in the guest. +=item B to B + +=item B to B + +=item B to B + +Use L, L, +or L. Example: duplicate the contents of an LV: - guestfs_dd (g, "/dev/VG/Original", "/dev/VG/Copy"); + guestfs_copy_device_to_device (g, + "/dev/VG/Original", "/dev/VG/Copy", + /* -1 marks the end of the list of optional parameters */ + -1); The destination (C) must be at least as large as the -source (C). To copy less than the whole -source device, use L. +source (C). To copy less than the whole source +device, use the optional C parameter: + + guestfs_copy_device_to_device (g, + "/dev/VG/Original", "/dev/VG/Copy", + GUESTFS_COPY_DEVICE_TO_DEVICE_SIZE, 10000, + -1); =item B to B