X-Git-Url: http://git.annexia.org/?p=libguestfs.git;a=blobdiff_plain;f=src%2Fguestfs.pod;h=db0ab36a8ab0d49b29fcb2f74603b66d3c7c9e8a;hp=7ff313d1d6e6fb0d202e4efafa091ea187dc9abe;hb=fac15924f59a076c903d453d20305e00e1ae258a;hpb=84763d7fca3668c62ee3fe53d0e00a5a672f687b;ds=sidebyside diff --git a/src/guestfs.pod b/src/guestfs.pod index 7ff313d..db0ab36 100644 --- a/src/guestfs.pod +++ b/src/guestfs.pod @@ -802,6 +802,9 @@ can make this very puzzling if you are trying to debug a problem. =item Mount option C<-o sync> should not be the default. +I L no longer adds any options starting +from libguestfs 1.13.16. This section only applies to older versions. + If you use L, then C<-o sync,noatime> are added implicitly. However C<-o sync> does not add any reliability benefit, but does have a very large performance impact. @@ -952,6 +955,29 @@ For example: Note that libguestfs also calls qemu with the -help and -version options in order to determine features. +Wrappers can also be used to edit the options passed to qemu. In the +following example, the C<-machine ...> option (C<-machine> and the +following argument) are removed from the command line and replaced +with C<-machine pc,accel=tcg>. The while loop iterates over the +options until it finds the right one to remove, putting the remaining +options into the C array. + + #!/bin/bash - + + i=0 + while [ $# -gt 0 ]; do + case "$1" in + -machine) + shift 2;; + *) + args[i]="$1" + (( i++ )) + shift ;; + esac + done + + exec qemu-kvm -machine pc,accel=tcg "${args[@]}" + =head2 ATTACHING TO RUNNING DAEMONS I This is B and has a tendency to eat @@ -2893,7 +2919,7 @@ Source code to the C library. =item C -Command line tools written in Perl (L and many others). +Command line tools written in Perl (L and many others). =item C @@ -3161,6 +3187,8 @@ L, L, L, L, +L, +L, L, L, L,