Re: [Libguestfs] virt-df error, help
On Thu, Dec 04, 2014 at 04:53:21PM +0800, cuimingwen@incito.com.cn wrote:
Hello, Richard, I run command as example: " virt-df -d `virsh domuuid 5`" some errors show : libguestfs: warning: supermin-helper -f checksum returned a short string libguestfs: error: cannot find any suitable libguestfs supermin, fixed or old-style appliance on LIBGUESTFS_PATH (search path: /usr/lib/guestfs)
when I run this command as root , the result is correct , but I must run the command as not-root, so , how can I do ?, please help , thanks!
Enable debugging: http://libguestfs.org/guestfs-faq.1.html#debugging-libguestfs Provide the complete output when debugging is enabled, sending it to the mailing list (mailto:libguestfs@redhat.com) Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-df lists disk usage of guests without needing to install any software inside the virtual machine. Supports Linux and Windows. http://people.redhat.com/~rjones/virt-df/
thanks for your reply, When I set the debug mode and run "libguestfs-test-tool" the result is: virtTest@06MYRC5:~$ libguestfs-test-tool ************************************************************ * IMPORTANT NOTICE * * When reporting bugs, include the COMPLETE, UNEDITED * output below in your bug report. * ************************************************************ libguestfs: trace: set_verbose true libguestfs: trace: set_verbose = 0 libguestfs: trace: set_verbose true libguestfs: trace: set_verbose = 0 LIBGUESTFS_DEBUG=1 LIBGUESTFS_TRACE=1 PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games SELinux: sh: 1: getenforce: not found libguestfs: trace: add_drive_scratch 104857600 libguestfs: trace: get_tmpdir libguestfs: trace: get_tmpdir = "/tmp" libguestfs: trace: add_drive "/tmp/libguestfsIyeuW7/scratch.1" "format:raw" "cachemode:unsafe" libguestfs: trace: add_drive = 0 libguestfs: trace: add_drive_scratch = 0 libguestfs: trace: get_append libguestfs: trace: get_append = "NULL" guestfs_get_append: (null) libguestfs: trace: get_backend libguestfs: trace: get_backend = "direct" guestfs_get_backend: direct libguestfs: trace: get_autosync libguestfs: trace: get_autosync = 1 guestfs_get_autosync: 1 libguestfs: trace: get_cachedir libguestfs: trace: get_cachedir = "/var/tmp" guestfs_get_cachedir: /var/tmp libguestfs: trace: get_direct libguestfs: trace: get_direct = 0 guestfs_get_direct: 0 libguestfs: trace: get_hv libguestfs: trace: get_hv = "/usr/bin/qemu-system-x86_64" guestfs_get_hv: /usr/bin/qemu-system-x86_64 libguestfs: trace: get_memsize libguestfs: trace: get_memsize = 500 guestfs_get_memsize: 500 libguestfs: trace: get_network libguestfs: trace: get_network = 0 guestfs_get_network: 0 libguestfs: trace: get_path libguestfs: trace: get_path = "/usr/lib/guestfs" guestfs_get_path: /usr/lib/guestfs libguestfs: trace: get_pgroup libguestfs: trace: get_pgroup = 0 guestfs_get_pgroup: 0 libguestfs: trace: get_program libguestfs: trace: get_program = "libguestfs-test-tool" guestfs_get_program: libguestfs-test-tool libguestfs: trace: get_recovery_proc libguestfs: trace: get_recovery_proc = 1 guestfs_get_recovery_proc: 1 libguestfs: trace: get_selinux libguestfs: trace: get_selinux = 0 guestfs_get_selinux: 0 libguestfs: trace: get_smp libguestfs: trace: get_smp = 1 guestfs_get_smp: 1 libguestfs: trace: get_tmpdir libguestfs: trace: get_tmpdir = "/tmp" guestfs_get_tmpdir: /tmp libguestfs: trace: get_trace libguestfs: trace: get_trace = 1 guestfs_get_trace: 1 libguestfs: trace: get_verbose libguestfs: trace: get_verbose = 1 guestfs_get_verbose: 1 host_cpu: x86_64 Launching appliance, timeout set to 600 seconds. libguestfs: trace: launch libguestfs: trace: version libguestfs: trace: version = <struct guestfs_version *> libguestfs: trace: get_backend libguestfs: trace: get_backend = "direct" libguestfs: launch: program=libguestfs-test-tool libguestfs: launch: version=1.24.5 libguestfs: launch: backend registered: unix libguestfs: launch: backend registered: uml libguestfs: launch: backend registered: libvirt libguestfs: launch: backend registered: direct libguestfs: launch: backend=direct libguestfs: launch: tmpdir=/tmp/libguestfsIyeuW7 libguestfs: launch: umask=0002 libguestfs: launch: euid=1000 libguestfs: command: run: /usr/bin/supermin-helper libguestfs: command: run: \ --verbose libguestfs: command: run: \ -f checksum libguestfs: command: run: \ --host-cpu x86_64 libguestfs: command: run: \ /usr/lib/guestfs/supermin.d supermin helper [00000ms] whitelist = (not specified) supermin helper [00000ms] host_cpu = x86_64 supermin helper [00000ms] dtb_wildcard = (not specified) supermin helper [00000ms] inputs: supermin helper [00000ms] inputs[0] = /usr/lib/guestfs/supermin.d supermin helper [00000ms] outputs: supermin helper [00000ms] kernel = (none) supermin helper [00000ms] dtb = (none) supermin helper [00000ms] initrd = (none) supermin helper [00000ms] appliance = (none) libguestfs: checksum of existing appliance: libguestfs: warning: supermin-helper -f checksum returned a short string libguestfs: error: cannot find any suitable libguestfs supermin, fixed or old-style appliance on LIBGUESTFS_PATH (search path: /usr/lib/guestfs) libguestfs: trace: launch = -1 (error) libguestfs-test-tool: failed to launch appliance libguestfs: trace: close libguestfs: closing guestfs handle 0x6ac130 (state 0) libguestfs: command: run: rm libguestfs: command: run: \ -rf /tmp/libguestfsIyeuW7 when I run " virt-df -d `virsh domuuid 5`“ , the result is : virtTest@06MYRC5:~$ virt-df -d `virsh domuuid 5` libguestfs: trace: set_verbose true libguestfs: trace: set_verbose = 0 libguestfs: create: flags = 0, handle = 0x15ee130, program = virt-df libguestfs: trace: add_domain "572e2069-1d61-4e0a-9a7d-fc9e726c22cb" "readonly:true" "allowuuid:true" "readonlydisk:read" libguestfs: opening libvirt handle: URI = NULL, auth = virConnectAuthPtrDefault, flags = 1 libguestfs: successfully opened libvirt handle: conn = 0x15ee5c0 libguestfs: trace: internal_set_libvirt_selinux_norelabel_disks false libguestfs: trace: internal_set_libvirt_selinux_norelabel_disks = 0 libguestfs: disk[0]: filename: /var/lib/nova/instances/572e2069-1d61-4e0a-9a7d-fc9e726c22cb/disk libguestfs: trace: add_drive "/var/lib/nova/instances/572e2069-1d61-4e0a-9a7d-fc9e726c22cb/disk" "readonly:true" "format:qcow2" libguestfs: trace: add_drive = 0 libguestfs: trace: add_domain = 1 libguestfs: trace: launch libguestfs: trace: get_tmpdir libguestfs: trace: get_tmpdir = "/tmp" libguestfs: trace: version libguestfs: trace: version = <struct guestfs_version *> libguestfs: trace: get_backend libguestfs: trace: get_backend = "direct" libguestfs: launch: program=virt-df libguestfs: launch: version=1.24.5 libguestfs: launch: backend registered: unix libguestfs: launch: backend registered: uml libguestfs: launch: backend registered: libvirt libguestfs: launch: backend registered: direct libguestfs: launch: backend=direct libguestfs: launch: tmpdir=/tmp/libguestfsLdtNb8 libguestfs: launch: umask=0002 libguestfs: launch: euid=1000 libguestfs: command: run: /usr/bin/supermin-helper libguestfs: command: run: \ --verbose libguestfs: command: run: \ -f checksum libguestfs: command: run: \ --host-cpu x86_64 libguestfs: command: run: \ /usr/lib/guestfs/supermin.d supermin helper [00000ms] whitelist = (not specified) supermin helper [00000ms] host_cpu = x86_64 supermin helper [00000ms] dtb_wildcard = (not specified) supermin helper [00000ms] inputs: supermin helper [00000ms] inputs[0] = /usr/lib/guestfs/supermin.d supermin helper [00000ms] outputs: supermin helper [00000ms] kernel = (none) supermin helper [00000ms] dtb = (none) supermin helper [00000ms] initrd = (none) supermin helper [00000ms] appliance = (none) libguestfs: checksum of existing appliance: libguestfs: warning: supermin-helper -f checksum returned a short string libguestfs: error: cannot find any suitable libguestfs supermin, fixed or old-style appliance on LIBGUESTFS_PATH (search path: /usr/lib/guestfs) libguestfs: trace: launch = -1 (error) libguestfs: trace: close libguestfs: closing guestfs handle 0x15ee130 (state 0) libguestfs: command: run: rm libguestfs: command: run: \ -rf /tmp/libguestfsLdtNb8 From: Richard W.M. Jones Date: 2014-12-04 18:02 To: cuimingwen@incito.com.cn CC: libguestfs Subject: Re: virt-df error, help On Thu, Dec 04, 2014 at 04:53:21PM +0800, cuimingwen@incito.com.cn wrote:
Hello, Richard, I run command as example: " virt-df -d `virsh domuuid 5`" some errors show : libguestfs: warning: supermin-helper -f checksum returned a short string libguestfs: error: cannot find any suitable libguestfs supermin, fixed or old-style appliance on LIBGUESTFS_PATH (search path: /usr/lib/guestfs)
when I run this command as root , the result is correct , but I must run the command as not-root, so , how can I do ?, please help , thanks!
Enable debugging: http://libguestfs.org/guestfs-faq.1.html#debugging-libguestfs Provide the complete output when debugging is enabled, sending it to the mailing list (mailto:libguestfs@redhat.com) Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-df lists disk usage of guests without needing to install any software inside the virtual machine. Supports Linux and Windows. http://people.redhat.com/~rjones/virt-df/
On Fri, Dec 05, 2014 at 09:11:40AM +0800, cuimingwen@incito.com.cn wrote:
thanks for your reply, When I set the debug mode and run "libguestfs-test-tool" the result is: [...] libguestfs: launch: version=1.24.5
I'll assume this is an old Ubuntu version, in which case you need to run: sudo update-guestfs-appliance See: http://libguestfs.org/guestfs-faq.1.html#libguestfs:-error:-cannot-find-any-... This is not required in newer versions of libguestfs. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-top is 'top' for virtual machines. Tiny program with many powerful monitoring features, net stats, disk stats, logging, etc. http://people.redhat.com/~rjones/virt-top
Thanks again, but when I run the command "sudo update-guestfs-appliance" the result is "unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/syslinux_3%3a4.05+dfsg-6+deb8u1_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/sysv-rc_2.88dsf-41ubuntu6_all.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/sysvinit-utils_2.88dsf-41ubuntu6_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/tar_1.27.1-1_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/tzdata_2014i-0ubuntu0.14.04_all.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/ucf_3.0027+nmu1_all.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/udev_204-5ubuntu20.9_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/upstart_1.12.1-0ubuntu4.2_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/util-linux_2.20.1-5.1ubuntu20.3_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/vim-common_2%3a7.4.052-1ubuntu3_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/vim-tiny_2%3a7.4.052-1ubuntu3_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/watershed_7_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/xkb-data_2.10.1-1ubuntu1_all.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/xz-utils_5.1.1alpha+20120614-2ubuntu2_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/zerofree_1.0.2-1ubuntu1_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/zfs-fuse_0.7.0-10.1_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/zlib1g_1%3a1.2.8.dfsg-1ubuntu1_amd64.deb ... 9081 files and directories writing supermin.d/base.img ... writing supermin.d/hostfiles ..." but when I run "virt-df -d `virsh domuuid 5` " the errors are also still , incito@M06MYPY9:~$ virt-df -d `virsh domuuid 5` libguestfs: warning: supermin-helper -f checksum returned a short string libguestfs: error: cannot find any suitable libguestfs supermin, fixed or old-style appliance on LIBGUESTFS_PATH (search path: /usr/lib/guestfs) incito@M06MYPY9:~$ But I find another solution, I use “sudo virt-df -d `virsh domuuid 5`" , and set the user without password (/etc/sudoers) to run the command . From: Richard W.M. Jones Date: 2014-12-05 16:51 To: cuimingwen@incito.com.cn CC: libguestfs Subject: Re: Re: virt-df error, help On Fri, Dec 05, 2014 at 09:11:40AM +0800, cuimingwen@incito.com.cn wrote:
thanks for your reply, When I set the debug mode and run "libguestfs-test-tool" the result is: [...] libguestfs: launch: version=1.24.5
I'll assume this is an old Ubuntu version, in which case you need to run: sudo update-guestfs-appliance See: http://libguestfs.org/guestfs-faq.1.html#libguestfs:-error:-cannot-find-any-... This is not required in newer versions of libguestfs. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-top is 'top' for virtual machines. Tiny program with many powerful monitoring features, net stats, disk stats, logging, etc. http://people.redhat.com/~rjones/virt-top
On Sun, Dec 07, 2014 at 07:57:06AM +0800, cuimingwen@incito.com.cn wrote:
Thanks again, but when I run the command "sudo update-guestfs-appliance"
the result is "unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/syslinux_3%3a4.05+dfsg-6+deb8u1_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/sysv-rc_2.88dsf-41ubuntu6_all.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/sysvinit-utils_2.88dsf-41ubuntu6_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/tar_1.27.1-1_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/tzdata_2014i-0ubuntu0.14.04_all.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/ucf_3.0027+nmu1_all.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/udev_204-5ubuntu20.9_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/upstart_1.12.1-0ubuntu4.2_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/util-linux_2.20.1-5.1ubuntu20.3_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/vim-common_2%3a7.4.052-1ubuntu3_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/vim-tiny_2%3a7.4.052-1ubuntu3_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/watershed_7_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/xkb-data_2.10.1-1ubuntu1_all.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/xz-utils_5.1.1alpha+20120614-2ubuntu2_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/zerofree_1.0.2-1ubuntu1_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/zfs-fuse_0.7.0-10.1_amd64.deb ... unpacking /tmp/superminef3fb7da4d1971287149691a8361ae0d.tmp/zlib1g_1%3a1.2.8.dfsg-1ubuntu1_amd64.deb ... 9081 files and directories writing supermin.d/base.img ... writing supermin.d/hostfiles ..."
but when I run "virt-df -d `virsh domuuid 5` " the errors are also still , incito@M06MYPY9:~$ virt-df -d `virsh domuuid 5` libguestfs: warning: supermin-helper -f checksum returned a short string libguestfs: error: cannot find any suitable libguestfs supermin, fixed or old-style appliance on LIBGUESTFS_PATH (search path: /usr/lib/guestfs) incito@M06MYPY9:~$
Maybe not enough disk space on /tmp or /var/tmp? What host OS are you using? Where did you get libguestfs from? What versions of libguestfs & supermin are installed? If possible, update to libguestfs >= 1.26. The appliance building code was completely rewritten and is far more robust. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-df lists disk usage of guests without needing to install any software inside the virtual machine. Supports Linux and Windows. http://people.redhat.com/~rjones/virt-df/
participants (2)
-
cuimingwen@incito.com.cn -
Richard W.M. Jones