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 1151725 - virt-v2v: warning: /files/boot/grub/device.map/hd0 references unknown device "sda" when convert a guest with ide bus
Summary: virt-v2v: warning: /files/boot/grub/device.map/hd0 references unknown device ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: libguestfs
Version: 7.1
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: ---
Assignee: Richard W.M. Jones
QA Contact: Virtualization Bugs
URL:
Whiteboard: V2V
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-10-11 07:53 UTC by zhoujunqin
Modified: 2015-03-05 13:46 UTC (History)
6 users (show)

Fixed In Version: libguestfs-1.28.1-1.12.el7
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-03-05 13:46:07 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:0303 0 normal SHIPPED_LIVE libguestfs bug fix and enhancement update 2015-03-05 17:34:44 UTC

Description zhoujunqin 2014-10-11 07:53:00 UTC
Description of problem:
virt-v2v: warning: /files/boot/grub/device.map/hd0 references unknown  device "sda"  when convert a guest with ide bus

Version-Release number of selected component (if applicable):
libguestfs-1.27.62-1.1.el7.x86_64
virt-v2v-1.27.62-1.1.el7.x86_64
libvirt-1.2.8-5.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Prepare a guest with ide bus:
# virsh dumpxml rhel6.5-2 |grep -A5 disk

    <disk type='file' device='disk'>
      <driver name='qemu' type='qcow2'/>
      <source file='/var/lib/libvirt/images/rhel6.5-2.qcow2'/>
      <target dev='hda' bus='ide'/>
      <address type='drive' controller='0' bus='0' target='0' unit='0'/>
    </disk>

Before conversion,check /boot/grub/device.map:
# cat /boot/grub/device.map
# this device map was generated by anaconda
(hd0)     /dev/sda

2. Use virt-v2v convert guest "rhel6.5-2" to rhevm server, warning shows like:
virt-v2v: warning: /files/boot/grub/device.map/hd0 references unknown
device "sda".  You may have to fix this entry manually after conversion.
virt-v2v: warning: /files/etc/sysconfig/grub/boot references unknown device
"sda".  You may have to fix this entry manually after conversion.

# virt-v2v -o rhev -os 10.66.90.115:/vol/v2v_auto/auto_export rhel6.5-2  --network rhevm -on rhel6-juzhou2  -of qcow2
[   0.0] Opening the source -i libvirt rhel6.5-2
[   0.0] Creating an overlay to protect the source from being modified
[   0.0] Opening the overlay
[   3.0] Initializing the target -o rhev -os 10.66.90.115:/vol/v2v_auto/auto_export
virt-v2v: warning: cannot write files to the NFS server as 36:36, even
though we appear to be running as root. This probably means the NFS client
or idmapd is not configured properly.

You will have to chown the files that virt-v2v creates after the run,
otherwise RHEV-M will not be able to import the VM.
[   3.0] Inspecting the overlay
[   6.0] Checking for sufficient free disk space in the guest
[   6.0] Estimating space required on target for each disk
[   6.0] Converting Red Hat Enterprise Linux Server release 6.6 (Santiago) to run on KVM
virt-v2v: warning: The display driver was updated to 'qxl', but X11 does
not seem to be installed in the guest.  X may not function correctly.
virt-v2v: warning: /files/boot/grub/device.map/hd0 references unknown
device "sda".  You may have to fix this entry manually after conversion.
virt-v2v: warning: /files/etc/sysconfig/grub/boot references unknown device
"sda".  You may have to fix this entry manually after conversion.
This guest has virtio drivers installed.
[  28.0] Mapping filesystem data to avoid copying unused and blank areas
[  30.0] Closing the overlay
[  30.0] Copying disk 1/1 to /tmp/v2v.L9G5gT/46adae8a-63c1-40f8-b25a-f02deb1a5160/images/89e1fa86-a7c7-4bc4-be38-831a98d3253e/59be4437-c5ff-43d8-a76f-98b87d69778c (qcow2)
    (100.00/100%)
[  46.0] Creating output metadata
[  46.0] Finishing off

3. Login rhevm server and import guest then start guest check:
# cat /boot/grub/device.map
# this device map was generated by anaconda
(hd0)     /dev/sda

Actual results:
As described.

Expected results:
No such warning shows in Step2.

Additional info:
Since i used a guest without x-window, so the following warning message is accepted i think:
virt-v2v: warning: The display driver was updated to 'qxl', but X11 does
not seem to be installed in the guest.  X may not function correctly.

Comment 4 zhoujunqin 2014-11-19 02:36:21 UTC
I can reproduce this issue with package:
libguestfs-1.28.1-1.11.el7.x86_64
virt-v2v-1.28.1-1.11.el7.x86_64

Then try to verify with new build:
libguestfs-1.28.1-1.12.el7.x86_64
virt-v2v-1.28.1-1.12.el7.x86_64

Steps:
1. Prepare a guest with ide bus as Comment 0.

2. Use virt-v2v convert guest "rhel6.5-2" to rhevm server:
#  virt-v2v -o rhev -os 10.66.90.115:/vol/v2v_auto/nfs_export rhel6.5-2  --network rhevm -on juzhou-1151725  -of qcow2 
[   0.0] Opening the source -i libvirt rhel6.5-2
[   0.0] Creating an overlay to protect the source from being modified
[   0.0] Opening the overlay
[   2.0] Initializing the target -o rhev -os 10.66.90.115:/vol/v2v_auto/nfs_export
virt-v2v: warning: cannot write files to the NFS server as 36:36, even 
though we appear to be running as root. This probably means the NFS client 
or idmapd is not configured properly.

You will have to chown the files that virt-v2v creates after the run, 
otherwise RHEV-M will not be able to import the VM.
[   2.0] Inspecting the overlay
[   9.0] Checking for sufficient free disk space in the guest
[   9.0] Estimating space required on target for each disk
[   9.0] Converting Red Hat Enterprise Linux Server release 6.5 (Santiago) to run on KVM
virt-v2v: This guest has virtio drivers installed.
[  43.0] Mapping filesystem data to avoid copying unused and blank areas
[  44.0] Closing the overlay
[  44.0] Copying disk 1/1 to /tmp/v2v.9uEYqP/594d0565-f687-4ab9-abb7-460daeb837a3/images/898a1271-2321-441e-8d8e-917525ec0d51/83320b8f-665e-4172-91f8-ef36e474dad2 (qcow2)
    (100.00/100%)
[ 112.0] Creating output metadata
[ 112.0] Finishing off

Result: Conversion finished without warning message "virt-v2v: warning: /files/boot/grub/device.map/hd0 references unknown device "sda" showing.

3. Import guest on rhevm server.
Result: guest can boot up with no error.
# cat /boot/grub/device.map
# this device map was generated by anaconda
(hd0)     /dev/vda

So move this bug from ON_QA to VERIFIED.

Comment 6 errata-xmlrpc 2015-03-05 13:46:07 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2015-0303.html


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