Hi

It looks like image name changes during image capture process. The capture 
starts with one image name and finishes with a different image name:


start:

VCL IMAGE Creation Started: centos5image-LinuxCentOS62KVMv399-v0

finish:

VCL IMAGE Creation Completed: centos5-LinuxCentOS62KVMv3-99-v0

Imagename in 'vcl.image' table and 'vcl.imagerevision' table is different. Once 
I update the name in 'vcl.imagerevision' table to match the name in 
'vcl.image', I can reload newly captured image fine.


I.e.:

SELECT imagename FROM imagerevision where imageid=99 and production=1 
centos5-LinuxCentOS62KVMv3-99-v0 SELECT name FROM image where id=99 
centos5image-LinuxCentOS62KVMv399-v0

I'm attaching image capture log file.


I've tried to trace where the image name changes, but cannot find it in the 
code (libvirt.pm).




--
Thank you,

Dmitri Chebotarov
Virtual Computing Lab Systems Engineer, TSD - Ent Servers & Messaging
223 Aquia Building, Ffx, MSN: 1B5
Phone: (703) 993-6175
Fax: (703) 993-3404


On Thursday, June 7, 2012 at 17:15 , Dmitri Chebotarov wrote:

> Hi 
> 
> Have anyone else tried Libvirt support in VCL 2.3? 
> 
> I'm getting this error, not sure if it's specific to my configuration (# svn 
> up At revision 1347799)
> 
> During base image capture VCL creates two files per VM in "Virtual Disk Path" 
> folder (I'm using qcow2 disk format): 
> 
> qemu-img convert "/var/lib/libvirt/images/Linux_CentOS_62.img" -O qcow2 
> "/var/lib/libvirt/images/baseImages/centos5image-linuxkvm898-v0.qcow2"
> two files created:
> 
> centos5image-linuxkvm898-v0.qcow2
> centos5-linuxkvm8-98-v0.xml
> 
> The content of centos5-linuxkvm8-98-v0.xml is:
> 
> # cat centos5-linuxkvm8-98-v0.xml HASH(0x154d9a50)
> 
> When I try to reload a computer with new image, VCL is trying to use .xml 
> file as disk image and reload fails. 
> 
> Once I delete .xml and rename image file, it works fine:
> 
> rm -f centos5-linuxkvm8-98-v0.xml 
> mv centos5image-linuxkvm898-v0.qcow2 centos5-linuxkvm8-98-v0.qcow2
> 
> 
> Llog file:
> 
> |27378|484:476|reload|utils.pm:insertloadlog(3701)|inserted computer=98, 
> loadimageblade, sandbox-vcl-20 must be reloaded with centos5-linuxkvm8-98-v0 
> 2012-06-07 16:42:46|27378|484:476|reload|new.pm:reload_image(616)|calling 
> VCL::Module::Provisioning::libvirt->does_image_exist() 2012-06-07 
> 16:42:46|27378|484:476|reload|OS.pm:find_files(2801)|attempting to find files 
> on BC1-12, base directory path: '/var/lib/libvirt/images/baseImages/', 
> pattern: centos5-linuxkvm8-98-v0.*, command: /usr/bin/find 
> "/var/lib/libvirt/images/baseImages/" -type f -iname 
> "centos5-linuxkvm8-98-v0.*" 2012-06-07 
> 16:42:46|27378|484:476|reload|OS.pm:find_files(2829)|files found: 1, base 
> directory: '/var/lib/libvirt/images/baseImages/', pattern: 
> 'centos5-linuxkvm8-98-v0.*' |27378|484:476|reload| command: '/usr/bin/find 
> "/var/lib/libvirt/images/baseImages/" -type f -iname 
> "centos5-linuxkvm8-98-v0.*"', output: |27378|484:476|reload| 
> /var/lib/libvirt/images/baseImages/centos5-linuxkvm8-98-v0.xml 2012-06-07 
> 16:42:46|2
7378|484:476|reload|libvirt.pm:get_master_image_file_path(1011)|found master 
image file on BC1-12: 
/var/lib/libvirt/images/baseImages/centos5-linuxkvm8-98-v0.xml 2012-06-07 
16:42:46|27378|484:476|reload|Module.pm:new(203)|VCL::Module::Semaphore object 
created, address: 2179cfe0 2012-06-07 
16:42:46|27378|484:476|reload|Module.pm:code_loop_timeout(879)|attempting to 
open lockfile, maximum of 7200 seconds 2012-06-07 
16:42:46|27378|484:476|reload|Semaphore.pm:open_lockfile(175)|opened and 
obtained an exclusive lock on file: 
/tmp/master-centos5-linuxkvm8-98-v0.semaphore 2012-06-07 
16:42:46|27378|484:476|reload|Semaphore.pm:open_lockfile(182)|wrote to file: 
/tmp/master-centos5-linuxkvm8-98-v0.semaphore, contents: |27378|484:476|reload| 
'27378 vcld 484:476 reload sandbox-vcl-20>BC1-12 centos5-linuxkvm8-98-v0 
vclreload' 2012-06-07 
16:42:46|27378|484:476|reload|Module.pm:code_loop_timeout(899)|attempting to 
open lockfile, code returned true 2012-06-07 
16:42:46|27378|484:476|reload|Module.pm:g
et_semaphore(977)|created 'master:centos5-linuxkvm8-98-v0' Semaphore object, 
memory address: 2179cfe0 2012-06-07 
16:42:46|27378|484:476|reload|utils.pm:run_ssh_command(4928)|executing SSH 
command on BC1-12: |27378|484:476|reload| /usr/bin/ssh -i /etc/vcl/vcl.key -o 
StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o 
ConnectionAttempts=1 -o ConnectTimeout=3 -l root -p 22 -x BC1-12 'stat 
\/var\/lib\/libvirt\/images\/baseImages\/centos5\-linuxkvm8\-98\-v0\.xml' 2>&1 
2012-06-07 
16:42:46|27378|484:476|reload|utils.pm:run_ssh_command(5046)|run_ssh_command 
output: |27378|484:476|reload| File: 
`/var/lib/libvirt/images/baseImages/centos5-linuxkvm8-98-v0.xml' 
|27378|484:476|reload| Size: 16 Blocks: 0 IO Block: 65536 regular file 
|27378|484:476|reload| Device: 1bh/27d Inode: 24549393 Links: 1 
|27378|484:476|reload| Access: (0644/-rw-r--r--) Uid: ( 0/ root) Gid: ( 0/ 
root) |27378|484:476|reload| Access: 2012-06-07 16:45:02.507151000 -0400 
|27378|484:476|reload| Modify: 2012-06-07 16:45:0
2.507153000 -0400 |27378|484:476|reload| Change: 2012-06-07 16:45:02.507153000 
-0400 2012-06-07 
16:42:46|27378|484:476|reload|utils.pm:run_ssh_command(5060)|SSH command 
executed on BC1-12, returning (0, "File: `/var/lib/libvirt/images...") 
2012-06-07 
16:42:46|27378|484:476|reload|Linux.pm:file_exists(1335)|'/var/lib/libvirt/images/baseImages/centos5-linuxkvm8-98-v0.xml'
 exists on BC1-12, files: 1, directories: 0, links: 0 2012-06-07 
16:42:46|27378|484:476|reload|libvirt.pm:does_image_exist(478)|centos5-linuxkvm8-98-v0
 image exists on BC1-12: 
/var/lib/libvirt/images/baseImages/centos5-linuxkvm8-98-v0.xml
> 
> --
> Thank you,
> 
> Dmitri Chebotarov
> Virtual Computing Lab Systems Engineer, TSD - Ent Servers & Messaging
> 223 Aquia Building, Ffx, MSN: 1B5
> Phone: (703) 993-6175
> Fax: (703) 993-3404
> 
> 
> On Thursday, June 7, 2012 at 14:18 , Dmitri Chebotarov wrote:
> 
> > 
> > Hi
> > 
> > 
> > 
> > Has anyone tried KVM support in 2.3?
> > 
> > I got it working to a point where I can capture a Linux image and able to 
> > reload a VM computer with new KVM-based image via 'Manage Computers'.
> > The VM is available and I confirmed that VM is 'running' on KVM host. 
> > 
> > However when I make reservation of the KVM image, VCL tries to load the 
> > image using xCAT, not libvirt. 
> > 
> > The image is listed with type 46, which is Bare Metal RedHat. 
> > Do I need to add new OSid / OSinstalltype for libvirt?
> > 
> > --
> > Thank you,
> > 
> > Dmitri Chebotarov
> > Virtual Computing Lab Systems Engineer, TSD - Ent Servers & Messaging
> > 223 Aquia Building, Ffx, MSN: 1B5
> > Phone: (703) 993-6175
> > Fax: (703) 993-3404
> > 
> 

Reply via email to