summaryrefslogtreecommitdiffstats
path: root/test-tool/test-tool.c
diff options
context:
space:
mode:
authorRichard Jones <rjones@redhat.com>2010-02-09 18:00:24 +0000
committerRichard Jones <rjones@redhat.com>2010-02-10 10:46:23 +0000
commitf93cbe5756cf052cce8049087afdcf714a3fc70c (patch)
treec8caeeeb48f4293aa3aa7781fa3ae013b146728a /test-tool/test-tool.c
parent245ac5673700f54479e9408e8659cb68f80c344a (diff)
downloadlibguestfs-f93cbe5756cf052cce8049087afdcf714a3fc70c.tar.gz
libguestfs-f93cbe5756cf052cce8049087afdcf714a3fc70c.tar.xz
libguestfs-f93cbe5756cf052cce8049087afdcf714a3fc70c.zip
Use mount-options instead of mount to avoid implicit -o sync.
guestfs_mount adds -o sync implicitly. This causes a very large performance problem for write-intensive programs (eg. virt-v2v). Document this as a "gotcha". Change the tests, guestfish, Sys::Guestfs::Lib, guestmount to use mount-options instead. (Note that this gotcha does not affect mount-ro). The source of the performance problem was first identified by Matthew Booth.
Diffstat (limited to 'test-tool/test-tool.c')
-rw-r--r--test-tool/test-tool.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/test-tool/test-tool.c b/test-tool/test-tool.c
index 39139e58..cc47c018 100644
--- a/test-tool/test-tool.c
+++ b/test-tool/test-tool.c
@@ -229,7 +229,7 @@ main (int argc, char *argv[])
exit (EXIT_FAILURE);
}
- if (guestfs_mount (g, "/dev/sda1", "/") == -1) {
+ if (guestfs_mount_options (g, "", "/dev/sda1", "/") == -1) {
fprintf (stderr,
_("libguestfs-test-tool: failed to mount /dev/sda1 on /\n"));
exit (EXIT_FAILURE);