after install libguestfs_xfs,  all results are:

[using guestfish]
guestfish -N fs:xfs -m /dev/sda1 statvfs /
bsize: 4096
frsize: 4096
blocks: 24713
bfree: 23391
bavail: 23391
files: 51136
ffree: 51133
favail: 51133
fsid: 2049
flag: 4096
namemax: 255

[using virt-rescure]
virt-rescue -a test1.img
><rescue> mount /dev/sda1 /sysroot
><rescue> stat -f /sysroot
  File: "/sysroot" 
    ID: 80100000000 Namelen: 255     Type: xfs
Block size: 4096       Fundamental block size: 4096
Blocks: Total: 24713      Free: 23391      Available: 23391
Inodes: Total: 51136      Free: 51133

the free numbers are the same. but the "virt-df" output is not changed.

Thanks,
Chen




ÔÚ 2018-01-07 20:22:28£¬"Richard W.M. Jones" <rjones@redhat.com> дµÀ£º >On Sun, Jan 07, 2018 at 08:11:58PM +0800, ³Â·« wrote: >> Sorry for the late reply. when I used your method to execute command: >> $guestfish -N fs:xfs -m /dev/sda1 statvfs / >> libguestfs: error: mkfs: xfs: /dev/sda1: mkfs.xfs: No such file or directory >> guestfish: error creating prepared disk image 'fs:xfs' on 'test1.img': failed to create filesystem (xfs): mkfs: xfs: /dev/sda1: mkfs.xfs: No such file or directory > >You need to install ¡®libguestfs-xfs¡¯. > >Rich. > >-- >Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones >Read my programming and virtualization blog: http://rwmj.wordpress.com >virt-p2v converts physical machines to virtual machines. Boot with a >live CD or over the network (PXE) and turn machines into KVM guests. >http://libguestfs.org/virt-v2v