Bug 909456

Summary: virt-v2v fails to install kernel if yum repo's baseurl is not a fqdn
Product: [Community] Virtualization Tools Reporter: kelvin
Component: virt-v2vAssignee: Matthew Booth <mbooth>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: rbalakri, rjones
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-09-10 12:45:01 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
virt-v2v log messages none

Description kelvin 2013-02-08 20:23:23 UTC
Created attachment 695228 [details]
virt-v2v log messages

virt-v2v cannot find kernel if yum repo file uses baseurl with shortname (i.e. hostname -s)

Version-Release number of selected component (if applicable):
[root@server4 ~]# virt-v2v --version
0.8.7


How reproducible:
always

Steps to Reproduce:
1. install minimal Xen VM on other host.
lvcreate -L 5G -n nobootloaderDisk0 filer01volgroup00
virt-install --bridge=br0 --nographics --paravirt --file=/dev/filer01volgroup00/nobootloaderDisk0 --location=http://home/distros/centos/5/os/x86_64 --os-type=linux --os-variant=rhel5.4 --name=nobootloader --ram=512 --vcpus=1

2. Inside Xen VM, alter repo file to point to local mirror, using shortname
sed -e 's,^mirrorlist,#mirrorlist,g' -e 's,#baseurl=http://mirror.centos.org/centos,baseurl=http://home/distros/centos,' -i.bak /etc/yum.repos.d/CentOS-Base.repo

3. shutdown Xen VM

4. perform virt-v2v.
virt-v2v -ic xen+ssh://root@server2 -op vm_pool --bridge br0 nobootloader
  

Actual results:
virt-v2v fails to find kernel.  
see attachment for virt-v2v output.

Expected results:
virt-v2v uses /etc/resolv.conf domainname to resolve a mirror host

Additional info:

Starting the Xen vm up again and changing the yum repo baseurl to a fqdn makes the virt-v2v succeed.

Comment 1 Richard W.M. Jones 2014-09-10 12:45:01 UTC
virt-v2v no longer installs kernels.  You have to install the kernel
first in the guest.  So in one sense this bug is "fixed".