Files
libguestfs/perl/examples
Richard W.M. Jones ffbf1475f7 New API: guestfs_shutdown: Cleanly shutdown the backend.
The new API splits orderly close into a two-step process:

  if (guestfs_shutdown (g) == -1) {
    /* handle the error, eg. qemu error */
  }
  guestfs_close (g);

Note that the explicit shutdown step is only necessary in the case
where you have made changes to the disk image and want to handle write
errors.  Read the documentation for further information.

This change also:

 - deprecates guestfs_kill_subprocess

 - turns guestfs_kill_subprocess into the same as guestfs_shutdown

 - changes guestfish and other tools to call shutdown + close
   where necessary (not for read-only tools)

 - updates documentation

 - updates examples
2012-07-03 21:27:29 +01:00
..
2011-09-21 15:21:58 +01:00
2011-01-31 09:34:47 +00:00
2011-11-08 14:43:07 +00:00

This directory contains various example programs which use the perl
Sys::Guestfs bindings to the libguestfs API.

As they are examples, these are licensed so they can be freely copied
and used without any restrictions.

Tips:

(1) To enable verbose messages, set environment variable LIBGUESTFS_DEBUG=1

(2) To run a program without installing the library, set PERL5LIB and
LIBGUESTFS_PATH as in this example (if run from the root directory of
the source distribution):

  LIBGUESTFS_PATH=$(pwd)/appliance \
  PERL5LIB=$(pwd)/perl/blib/lib:$(pwd)/perl/blib/arch/auto/Sys/Guestfs \
  perl/examples/foo