Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
virt-edit/tar/inspector do not support encrypted system, while some other virt-* commands like virt-cat/ls work fine with encrypted system.
Version-Release number of selected component (if applicable):
libguestfs-tools-1.7.17-10.el6.x86_64
How reproducible:
Always
Steps to Reproduce:
1.Run virt-edit/tar/inspector with an encrypted VM:
virt-edit /var/lib/libvirt/images/rhel55-64-encryptsystem.img /etc/issue
virt-tar -x /var/lib/libvirt/images/rhel55-64-encryptsystem.img /home home.tar
virt-inspector /var/lib/libvirt/images/rhel55-64-encryptsystem.img
2.Run virt-cat/ls with the encrypted VM:
virt-cat -a /var/lib/libvirt/images/rhel55-64-encryptsystem.img /etc/issue
virt-ls -a /var/lib/libvirt/images/rhel55-64-encryptsystem.img /etc
Actual results:
At step1, after running the commands there will return similar messages as below:
"virt-edit: No operating system could be detected inside this disk image.
This may be because the file is not a disk image, or is not a virtual machine
image, or because the OS type is not understood by libguestfs.
If you feel this is an error, please file a bug report including as much
information about the disk image as possible."
And at step2, there will be prompt like "Enter key or passphrase ("/dev/vda2"):" to ask users to enter the passphrase, and then the virt-* commands work as expected.
Expected results:
The three virt-* commands virt-edit/tar/inspector should also work well with encrypted system.
Comment 2Richard W.M. Jones
2011-01-25 10:22:23 UTC
I agree this is a shortcoming, but it's not something we
can do for 6.1.
Setting flags for 6.2.
(Note it's an RFE, not a regression: in 6.0 we didn't support
encrypted guests at all :-)
Also "virt-df -a encrypted_image" does not show the encrypted partitions, only regular partitions were listed, but it won't report error messages.
Comment 5Richard W.M. Jones
2011-06-12 18:11:44 UTC
Upstream:
- virt-edit now supports encrypted filesystems
- virt-inspector (ie. "virt-inspector2" in RHEL) has supported it
for quite a while
- virt-tar is obsolete, replaced by virt-tar-in and virt-tar-out
which are just wrappers around guestfish and therefore support
encrypted filesystems
-> RHEL 7
Comment 6Richard W.M. Jones
2013-07-19 10:47:40 UTC
I believe this should Just Work in all recent versions
of libguestfs, including RHEL >= 6.4 and RHEL >= 7.
Note that 'virt-tar' is obsolete. Don't use it or test it.
Use 'virt-tar-in' and/or 'virt-tar-out' instead.
I try to reproduce it with libguestfs-1.21.33-1.1.el7, but
virt-tar-out, virt-ls virt-df, virt-cat, virt-inspector works well with encrypted systems, as it is a new function for these tools to support encrypted systems, is it ok to just verify it?
Comment 9Richard W.M. Jones
2013-11-18 08:37:06 UTC
Verify with libguestfs-1.22.6-15.el7
Steps to verify:
1. Install encrypted system to hvm-6.5-64-2.img
2. Run the following command:
#virt-tar-out -a ./hvm-6.5-64-2.img /home home.tar
#virt-tar-in -a ./hvm-6.5-64-2.img virsh-kvm.tar /home/
#virt-edit -a ./hvm-6.5-64-2.img /etc/issue
#virt-inspector -a ./hvm-6.5-64-2.img
#virt-cat -a ./hvm-6.5-64-2.img /etc/issue
#virt-ls -a ./hvm-6.5-64-2.img /home/
#virt-df -a ./hvm-6.5-64-2.img
These command works well with encrypted system.
This request was resolved in Red Hat Enterprise Linux 7.0.
Contact your manager or support representative in case you have further questions about the request.
Description of problem: virt-edit/tar/inspector do not support encrypted system, while some other virt-* commands like virt-cat/ls work fine with encrypted system. Version-Release number of selected component (if applicable): libguestfs-tools-1.7.17-10.el6.x86_64 How reproducible: Always Steps to Reproduce: 1.Run virt-edit/tar/inspector with an encrypted VM: virt-edit /var/lib/libvirt/images/rhel55-64-encryptsystem.img /etc/issue virt-tar -x /var/lib/libvirt/images/rhel55-64-encryptsystem.img /home home.tar virt-inspector /var/lib/libvirt/images/rhel55-64-encryptsystem.img 2.Run virt-cat/ls with the encrypted VM: virt-cat -a /var/lib/libvirt/images/rhel55-64-encryptsystem.img /etc/issue virt-ls -a /var/lib/libvirt/images/rhel55-64-encryptsystem.img /etc Actual results: At step1, after running the commands there will return similar messages as below: "virt-edit: No operating system could be detected inside this disk image. This may be because the file is not a disk image, or is not a virtual machine image, or because the OS type is not understood by libguestfs. If you feel this is an error, please file a bug report including as much information about the disk image as possible." And at step2, there will be prompt like "Enter key or passphrase ("/dev/vda2"):" to ask users to enter the passphrase, and then the virt-* commands work as expected. Expected results: The three virt-* commands virt-edit/tar/inspector should also work well with encrypted system.