I just posted a new libguestfs tool called
virt-tar, a sort of general purpose archiving, backup, upload and snooping tool for virtual machines.
You can use this to extract or archive directories from a guest, like this:
# virt-tar -zx someguest /home home.tar.gz
which takes a copy of
/home in the VM called someguest and saves it to a local file
Or upload to a guest, like this:
# virt-tar -zu someguest /tmp libguestfs-1.0.73.tar.gz
which would unpack the tarball into
/tmp/libguestfs-1.0.73/ inside the guest called someguest. You can’t use the upload feature on live guests.
All of the above functionality is already available through guestfish, but having a separate tool to do it makes it easier to remember for the simpler cases.