Add compilation/linking example to guestfs(3) man page.
[libguestfs.git] / src / guestfs.pod
index 7f810f3..a566b71 100644 (file)
@@ -16,6 +16,10 @@ guestfs - Library for accessing and modifying virtual machine images
  guestfs_sync (handle);
  guestfs_close (handle);
 
+ cc prog.c -o prog -lguestfs
+or:
+ cc prog.c -o prog `pkg-config libguestfs --cflags --libs`
+
 =head1 DESCRIPTION
 
 Libguestfs is a library for accessing and modifying guest disk images.
@@ -33,7 +37,8 @@ schemes, qcow, qcow2, vmdk.
 
 Libguestfs provides ways to enumerate guest storage (eg. partitions,
 LVs, what filesystem is in each LV, etc.).  It can also run commands
-in the context of the guest.  Also you can access filesystems over FTP.
+in the context of the guest.  Also you can access filesystems over
+FUSE.
 
 Libguestfs is a library that can be linked with C and C++ management
 programs (or management programs written in OCaml, Perl, Python, Ruby,
@@ -449,10 +454,10 @@ Where we can help is in resolving the case insensitivity of paths.
 For this, call C<guestfs_case_sensitive_path>.
 
 Libguestfs also provides some help for decoding Windows Registry
-"hive" files, through the library C<libhivex> which is part of
-libguestfs.  You have to locate and download the hive file(s)
-yourself, and then pass them to C<libhivex> functions.  See also the
-programs L<hivexml(1)>, L<hivexget(1)> and L<virt-win-reg(1)> for more
+"hive" files, through the library C<hivex> which is part of the
+libguestfs project.  You have to locate and download the hive file(s)
+yourself, and then pass them to C<hivex> functions.  See also the
+programs L<hivexml(1)>, L<hivexsh(1)> and L<virt-win-reg(1)> for more
 help on this issue.
 
 =head2 USING LIBGUESTFS WITH OTHER PROGRAMMING LANGUAGES
@@ -588,6 +593,29 @@ C<guestfish -c command> to run commands.
 
 =back
 
+=head2 PROTOCOL LIMITS
+
+Internally libguestfs uses a message-based protocol to pass API calls
+and their responses to and from a small "appliance" (see L</INTERNALS>
+for plenty more detail about this).  The maximum message size used by
+the protocol is slightly less than 4 MB.  For some API calls you may
+need to be aware of this limit.  The API calls which may be affected
+are individually documented, with a link back to this section of the
+documentation.
+
+A simple call such as C<guestfs_cat> returns its result (the file
+data) in a simple string.  Because this string is at some point
+internally encoded as a message, the maximum size that it can return
+is slightly under 4 MB.  If the requested file is larger than this
+then you will get an error.
+
+In order to transfer large files into and out of the guest filesystem,
+you need to use particular calls that support this.  The sections
+L</UPLOADING> and L</DOWNLOADING> document how to do this.
+
+You might also consider mounting the disk image using our FUSE
+filesystem support (L<guestmount(1)>).
+
 =head1 CONNECTION MANAGEMENT
 
 =head2 guestfs_h *
@@ -783,7 +811,7 @@ need the compile time check as well):
    dl = dlopen (NULL, RTLD_LAZY);
    if (!dl) {
      fprintf (stderr, "dlopen: %s\n", dlerror ());
-     exit (1);
+     exit (EXIT_FAILURE);
    }
    has_function = dlsym (dl, "guestfs_dd") != NULL;
    dlclose (dl);
@@ -1302,8 +1330,21 @@ enough.
 =head1 SEE ALSO
 
 L<guestfish(1)>,
+L<guestmount(1)>,
+L<virt-cat(1)>,
+L<virt-df(1)>,
+L<virt-edit(1)>,
+L<virt-inspector(1)>,
+L<virt-list-filesystems(1)>,
+L<virt-list-partitions(1)>,
+L<virt-ls(1)>,
+L<virt-make-fs(1)>,
+L<virt-rescue(1)>,
+L<virt-tar(1)>,
+L<virt-win-reg(1)>,
 L<qemu(1)>,
 L<febootstrap(1)>,
+L<hivex(3)>,
 L<http://libguestfs.org/>.
 
 Tools with a similar purpose: