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.
Bug 1977228 - Failed to open LUKS encrypted disk on rhel9
Summary: Failed to open LUKS encrypted disk on rhel9
Keywords:
Status: CLOSED DUPLICATE of bug 1977214
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: libguestfs
Version: 9.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: beta
: ---
Assignee: Virtualization Maintenance
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-06-29 09:06 UTC by Xiaodai Wang
Modified: 2021-06-30 02:28 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-06-30 02:28:31 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Xiaodai Wang 2021-06-29 09:06:20 UTC
Description of problem:
Failed to open LUKS encrypted disk on rhel9

Version-Release number of selected component (if applicable):
virt-v2v-1.45.1-1.el9.1.x86_64
libguestfs-1.45.6-7.el9.x86_64
qemu-kvm-6.0.0-6.el9.x86_64


How reproducible:
100%

Steps to Reproduce:
1. Convert a guest which has luks encryption disks.
# virt-v2v -i libvirt -ic vpx://root.x.x/data/x.x.x.x/?no_verify=1 -o null esx6.7-rhel7.8-swap_luks-non_os_3luks-xxx -it vddk -io vddk-libdir=/root/vddk_libdir/latest -io vddk-thumbprint=xxx  -ip /root/v2v_vpx_passwd
2. Type correct password.


Actual results:
libguestfs: trace: v2v: luks_uuid "/dev/sda3"
command: blkid returned 0^M
command: blkid: stdout:^M
crypto_LUKS^M
guestfsd: => vfs_type (0xc6) took 0.01 secs^M
guestfsd: <= luks_uuid (0x1fb) request length 56 bytes^M
commandrvf: stdout=n stderr=y flags=0x0^M
commandrvf: udevadm --debug settle -E /dev/sda3^M
SELinux enabled state cached to: disabled^M
No filesystem is currently mounted on /sys/fs/cgroup.^M
Failed to determine unit we run in, ignoring: No data available^M
commandrvf: stdout=y stderr=y flags=0x0^M
commandrvf: cryptsetup luksUUID /dev/sda3^M
libguestfs: trace: v2v: luks_uuid = "37990053-c744-4f9e-ba7b-1944d18ac3db"
libguestfs: trace: v2v: cryptsetup_open "/dev/sda3" "***" "cryptsda3"
guestfsd: => luks_uuid (0x1fb) took 0.01 secs^M
guestfsd: <= cryptsetup_open (0x1fc) request length 96 bytes^M
commandrvf: stdout=n stderr=y flags=0x0^M
commandrvf: udevadm --debug settle -E /dev/sda3^M
SELinux enabled state cached to: disabled^M
No filesystem is currently mounted on /sys/fs/cgroup.^M
Failed to determine unit we run in, ignoring: No data available^M
command: blkid '-c' '/dev/null' '-o' 'value' '-s' 'TYPE' '/dev/sda3'^M
command: blkid returned 0^M
command: blkid: stdout:^M
crypto_LUKS^M
command: cryptsetup '-d' '/tmp/crypt9878fa.key' 'open' '/dev/sda3' 'cryptsda3' '--type' 'luks'^M
command: cryptsetup returned 1^M
command: cryptsetup: stderr:^M
Cannot open keyslot (using hash sha256).^M
ocaml_exn: 'cryptsetup_open' raised 'Failure' exception^M
guestfsd: error: cryptsetup exited with status 1: Cannot open keyslot (using hash sha256).^M
guestfsd: => cryptsetup_open (0x1fc) took 0.02 secs^M
libguestfs: trace: v2v: cryptsetup_open = -1 (error)
/usr/bin/virt-v2v: could not find key to open LUKS encrypted /dev/sda3.

Try using --key on the command line.

Original error: cryptsetup_open: cryptsetup exited with status 1: Cannot open keyslot (using hash sha256). (0)

Expected results:
v2v should run success.

Additional info:
The issue cannot be reproduced by libguestfs-1.45.6-6.el9.x86_64

Comment 1 Richard W.M. Jones 2021-06-29 14:44:36 UTC
This is likely to be a duplicate of:
https://bugzilla.redhat.com/show_bug.cgi?id=1977214

Comment 2 Xiaodai Wang 2021-06-30 02:27:58 UTC
Yes, I verified it with libguestfs-1.45.6-9.el9.x86_64 and it works well.

Comment 3 Xiaodai Wang 2021-06-30 02:28:31 UTC

*** This bug has been marked as a duplicate of bug 1977214 ***


Note You need to log in before you can comment on or make changes to this bug.