I traced this to a problem with ListTemplateCommand() that is returning what I 
assumed is a cached value 
10.48.15.22:/home/nfs/secondary/template/tmpl/1/1/34b74283-916e-4562-82fd-082b387b51c5.vhd,
 the new secondary storage has a new template now: 
template/tmpl/1/1/170c3425-6078-479e-8843-3f8fdc02aaf3.vhd.

I am not sure at what stage this happened, and rather than debug this further, 
I just reinstalled it from scratch and fixed the issue.
-Soheil
________________________________________
From: Soheil Eizadi [seiz...@infoblox.com]
Sent: Tuesday, September 24, 2013 6:10 PM
To: dev@cloudstack.apache.org
Subject: RE: Problem creating VirtualRouter on XenServer 6.2 due to problem 
with copy_vhd_from_secondarystorage.sh

The error with copy_vhd_from_secondarystorage.sh is due to a problem with 
secondary storage, vhd_util returning a negative number to a query as the file 
does not exist. I am not sure why 34b74283-916e-4562-82fd-082b387b51c5.vhd 
versus 170c3425-6078-479e-8843-3f8fdc02aaf3.vhd is referenced, that is the next 
step to chase down.
-Soheil

[root@cloudstackxenserver1 bin]# ./vhd-util query -v -n 
10.48.15.22:/home/nfs/secondary/template/tmpl/1/1/34b74283-916e-4562-82fd-082b387b51c5.vhd
error opening 
10.48.15.22:/home/nfs/secondary/template/tmpl/1/1/34b74283-916e-4562-82fd-082b387b51c5.vhd:
 -2

root@nfs-server-10-48-15-21:/opt/storage/secondary# find
.
./template
./template/tmpl
./template/tmpl/1
./template/tmpl/1/1
./template/tmpl/1/1/170c3425-6078-479e-8843-3f8fdc02aaf3.vhd
./template/tmpl/1/1/template.properties
./template/tmpl/1/5
./template/tmpl/1/5/0911ae22-350f-38f5-ad3e-423e7e5d6539.vhd
./template/tmpl/1/5/template.properties
./template/tmpl/2
./volumes
./snapshots

________________________________________
From: Soheil Eizadi [seiz...@infoblox.com]
Sent: Tuesday, September 24, 2013 5:11 PM
To: dev@cloudstack.apache.org
Subject: Problem creating VirtualRouter on XenServer 6.2 due to problem with 
copy_vhd_from_secondarystorage.sh

Environment:
- 4.3 master (synced with master 08/28/2013 08:43 AM)
- XenServer 6.2

I have a problem creating a Virtual Router on XenServer 6.2, here are the 
symptoms, vmops.log and SMlog don't tell you much, but when I run the copy 
command native I get an error like the copy_vhd_from_secondarystorage.sh shell 
is not compatible with XenServer 6.2. I cleared the XenServer host tag to make 
sure the latest scripts were downloaded from my build. If someone thinks this 
problem is fixed on the top of the trunk, I can do another pull, otherwise I 
guess I need chase this some more in my enviroment?
-Soheil

[root@cloudstackxenserver1 log]# 
/opt/xensource/bin/copy_vhd_from_secondarystorage.sh 
10.48.15.22:/home/nfs/secondary/template/tmpl/1/1/34b74283-916e-4562-82fd-082b387b51c5.vhd
 1cca28ee-886a-6d52-5461-662b33f1d8d8 cloud-0230b187-29c2-4060-826c-7f697cceea35
Syntax error: Unknown switch: -22MiB
For usage run: 'xe help'
9#can not create vdi in sr 1cca28ee-886a-6d52-5461-662b33f1d8d8

vmops.log:

INFO  [o.a.c.n.e.InfobloxElement] (Job-Executor-5:ctx-e6414bc5) 
InfobloxDeviceElement Host Record created for VM r-9-VM
WARN  [c.c.h.x.r.XenServerStorageProcessor] (DirectAgent-382:null) 
destoryVDIbyNameLabel failed due to there are 0 VDIs with name 
cloud-0230b187-29c2-4060-826c-7f697cceea35
WARN  [c.c.h.x.r.XenServerStorageProcessor] (DirectAgent-382:null) can not 
create vdi in sr 1cca28ee-886a-6d52-5461-662b33f1d8d8
.....

SMlog:
Sep 24 16:39:41 cloudstackxenserver1 SM: [28919] #### VMOPS enter  
copy_vhd_from_secondarystorage ####
Sep 24 16:39:41 cloudstackxenserver1 SM: [28919] ['bash', 
'/opt/xensource/bin/copy_vhd_from_secondarystorage.sh', 
'10.48.15.22:/home/nfs/secondary/template/tmpl/1/1/34b74283-916e-4562-82fd-082b387b51c5.vhd',
 '1cca28ee-886a-6d52-5461-662b33f1d8d8', 
'cloud-0230b187-29c2-4060-826c-7f697cceea35']
Sep 24 16:39:41 cloudstackxenserver1 SM: [28919]   pread SUCCESS
Sep 24 16:39:41 cloudstackxenserver1 SM: [28919] #### VMOPS exit  
copy_vhd_from_secondarystorage ####
Sep 24 16:39:42 cloudstackxenserver1 SM: [28955] #### VMOPS enter  
kill_copy_process ####
Sep 24 16:39:42 cloudstackxenserver1 SM: [28955] ['bash', 
'/opt/xensource/bin/kill_copy_process.sh', 
'34b74283-916e-4562-82fd-082b387b51c5.vhd']
Sep 24 16:39:42 cloudstackxenserver1 SM: [28955]   pread SUCCESS
Sep 24 16:39:42 cloudstackxenserver1 SM: [28955] #### VMOPS exit  
kill_copy_process ####

Reply via email to