On Sun, May 13, 2012 at 11:55:34AM +0800, Nok wrote:
Hi
I`ve been trying this guestfs_mount_local api for quite a few days,
but still can`t get over it.
Now it seems to have enter the fuse loop but have some problems with
'mount',
and stops at guestfs_mount_local_run(g).
Here`s corresponding code in the test program:
……
if(guestfs_mount_local(g,"/mnt/libg")==-1)
exit(EXIT_FAILURE);
else
guestfs_mount_local_run(g);
……
Below is a part of the debug dump information,
……
version = 1.17.40.Root device: /dev/vda1 (this is test output)
libguestfs: guestfs__mount_local: fuse_mount /mnt/libg
libguestfs: guestfs__mount_local: fuse_new
libguestfs: guestfs__mount_local: leaving fuse_mount_local
libguestfs: guestfs__mount_local_run: entering fuse_loop
libguestfs: send_to_daemon: 56 bytes: 00 00 00 34 | 20 00 f5 f5 | 00
00 00 04 | 00 00 00 35 | 00 00 00 00 | ...
guestfsd: main_loop: proc 11 (lvs) took 0.04 seconds
guestfsd: main_loop: new request, len 0x34
guestfsd: error: lstat_stub: you must call 'mount' first to mount
the root filesystem
Are you actually mounting any filesystem before calling
guestfs_mount_local?
I just realized that I didn`t mount the /dev/sda to guestfs
appliance mount point