So I have identified a couple of places in the code where these tests are 
failing for me.  Again let me reiterate that I am building using Cygwin on a 
Windows 7 system.  Up until today this has not been a problem but when I 
brought in the OVM3 features I ran into FILE separator issues.....

C:\workspaces\Cloudstack\WS1\cloudstack\plugins\hypervisors\ovm3\src\main\java\com\cloud\hypervisor\ovm3\objects\Xen.java

Line 437: String[] st = diskPath.split(File.separatorChar == '\\' ? "\\\\" : 
File.separator);

On my build environment this return a String array of size 1.   The path I 
getting back from the getVMDiskDetailFromMap call looks like 
file:/OVS/Repositories/f12842ebf5ed3fe78da1eb0e17f5ede8/VirtualDisks/722eb520-dcf5-4113-8f45-22d67c9a2f3c.raw
 and the \ character isn't present at all.  When I make the regex string to be 
'/' my test now works.

C:\workspaces\Cloudstack\WS1\cloudstack\plugins\hypervisors\ovm3\src\main\java\com\cloud\hypervisor\ovm3\resources

Line 553: if (!fp.getName().equals(file)) {

Again this has to do with the file separator character.  

/OVS/Repositories/f12842ebf5ed3fe78da1eb0e17f5ede8/VirtualDisks/15710eca-1ea7-47f0-8bde-e6bd0066fec8.raw
 != 
/OVS/Repositories\f12842ebf5ed3fe78da1eb0e17f5ede8\VirtualDisks\15710eca-1ea7-47f0-8bde-e6bd0066fec8.raw

  Notice how the file separators change in the middle of the second string.

Roger


-----Original Message-----
From: Roger Crerie [mailto:roger.cre...@hds.com] 
Sent: Thursday, March 26, 2015 2:43 PM
To: dev@cloudstack.apache.org
Cc: Funs Kessen
Subject: RE: OVM3 test failures

Just to clear up a few more things.  I am building in Cygwin on a windows 
system.  I through in some more debugging and found that the split command 
isn't doing what is expected......

2015-03-26 14:47:12 DEBUG Ovm3HypervisorResource:208 - executeRequest called: 
class com.cloud.agent.api.StopCommand
2015-03-26 14:47:12 DEBUG ConnectionTest:72 - getresult call: list_vms - []
2015-03-26 14:47:12 DEBUG Xen:437 - diskPath = 
file:/OVS/Repositories/f12842ebf5ed3fe78da1eb0e17f5ede8/VirtualDisks/722eb520-dcf5-4113-8f45-22d67c9a2f3c.raw
2015-03-26 14:47:12 DEBUG Xen:439 - st Size = 1 st = [Ljava.lang.String;@2e01787
2015-03-26 14:47:12 DEBUG Ovm3HypervisorResource:559 - Stop i-2-3-VM failed 
java.lang.ArrayIndexOutOfBoundsException: 3

The code actually hard codes the number 3 in the code so as to return the 3 
string from the split array. As you can see from my debug output the split 
command isn't getting 3+ string in the array but rather just 1 (st Size = 1).

Roger


-----Original Message-----
From: Roger Crerie [mailto:roger.cre...@hds.com] 
Sent: Thursday, March 26, 2015 2:33 PM
To: dev@cloudstack.apache.org
Cc: Funs Kessen
Subject: RE: OVM3 test failures

From what I am seeing in the surefire reports though it looks like I am running 
into an ArrayIndexOutOfBoundsException.

2015-03-26 13:40:48 DEBUG Ovm3HypervisorResource:345 - configure ovm-1 with 
params: {agentusername=oracle, public.network.device=xenbr0, 
xenserver.heartbeat.interval=60, private.network.device=xenbr0, 
agentpassword=unknown, Hypervisor.Version=4.1.3OVM, secondary.storage.vm=false, 
Host.OS=Oracle VM Server, ovm3pool=true, ipaddress=192.168.1.64, 
password=unknown, username=root, pool=a9c1219d-817d-4242-b23e-2607801c79d5, 
ismaster=false, storage.network.device=xenbr0, ovm3.heartbeat.timeout=120, 
Host.OS.Version=5.7, xenserver.nics.max=7, agentVersion=3.2.1-183, 
router.aggregation.command.each.timeout=3, pod=1, istest=true, 
max.template.iso.size=50, host=ovm-1, 
com.cloud.network.Networks.RouterPrivateIpStrategy=DcGlobal, agentport=8899, 
Host.OS.Kernel.Version=2.6.39-300.22.2.el5uek, migratewait=3600, 
storage.network.device1=xenbr0, ovm3.heartbeat.interval=1, ip=192.168.1.64, 
ovm3cluster=false, guid=19e5f1e7-22f4-3b6d-8d41-c82f89c65295, 
ovm3vip=192.168.1.230, hasmaster=true, cluster=1, guest.network.device=xenbr0, 
zone=1, xenserver.heartbeat.timeout=120}
2015-03-26 13:40:48 DEBUG ConnectionTest:67 - methodresponse call: 
check_dom0_ip - [192.168.1.230]
2015-03-26 13:40:48 DEBUG Ovm3HypervisorSupport:587 - ovm-1 is a master, 
already has vip 192.168.1.230
2015-03-26 13:40:48 DEBUG ConnectionTest:67 - methodresponse call: 
discover_network - []
2015-03-26 13:40:48 DEBUG Ovm3HypervisorNetwork:75 - already have control0
2015-03-26 13:40:48 DEBUG ConnectionTest:67 - methodresponse call: 
ovs_ip_config - [control0, static, 169.254.0.1, 255.255.0.0]
2015-03-26 13:40:48 DEBUG ConnectionTest:67 - methodresponse call: 
ovs_control_interface - [control0, 169.254.0.0/16]
2015-03-26 13:40:48 DEBUG ConnectionTest:67 - methodresponse call: 
discover_hardware - []
2015-03-26 13:40:48 DEBUG ConnectionTest:67 - methodresponse call: 
discover_server - []
2015-03-26 13:40:48 DEBUG ConnectionTest:67 - methodresponse call: 
update_server_roles - [xen,utility]
2015-03-26 13:40:48 DEBUG Ovm3StoragePool:164 - Host ovm-1 owned by us
2015-03-26 13:40:48 DEBUG Ovm3HypervisorResource:208 - executeRequest called: 
class com.cloud.agent.api.StopCommand
2015-03-26 13:40:48 DEBUG ConnectionTest:72 - getresult call: list_vms - []
2015-03-26 13:40:48 DEBUG Ovm3HypervisorResource:559 - Stop i-2-3-VM failed 
java.lang.ArrayIndexOutOfBoundsException: 3
        at 
com.cloud.hypervisor.ovm3.objects.Xen$Vm.getVmDiskPoolId(Xen.java:438)
        at 
com.cloud.hypervisor.ovm3.objects.Xen$Vm.getVmRootDiskPoolId(Xen.java:423)
        at 
com.cloud.hypervisor.ovm3.resources.Ovm3HypervisorResource.execute(Ovm3HypervisorResource.java:537)
        at 
com.cloud.hypervisor.ovm3.resources.Ovm3HypervisorResource.executeRequest(Ovm3HypervisorResource.java:285)
        at 
com.cloud.hypervisor.ovm3.resources.Ovm3HypervisorResourceTest.stopVmTest(Ovm3HypervisorResourceTest.java:198)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:606)
        at 
org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)
        at 
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
        at 
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)
        at 
org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
        at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271)
        at 
org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70)
        at 
org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)
        at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238)
        at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63)
        at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236)
        at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53)
        at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229)
        at org.junit.runners.ParentRunner.run(ParentRunner.java:309)
        at 
org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:283)
        at 
org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:173)
        at 
org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153)
        at 
org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:128)
        at 
org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:203)
        at 
org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:155)
        at 
org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)


-----Original Message-----
From: Daan Hoogland [mailto:daan.hoogl...@gmail.com] 
Sent: Thursday, March 26, 2015 2:23 PM
To: dev
Cc: Funs Kessen
Subject: Re: OVM3 test failures

Roger, I've been browsing through your output and can't find an obvious root 
cause. I am cc'ing the author of the ovm3. In the meanwhile i'll be compiling 
master and run the dbdeploy target. What do you mean by 'ovm install command'? 
typo?

On Thu, Mar 26, 2015 at 7:03 PM, Roger Crerie <roger.cre...@hds.com> wrote:
> Thanks for the quick reply. Please find attached a text of the build 
> errors I am getting for OVM3
>
> Roger
>
> -----Original Message-----
> From: Daan Hoogland [mailto:daan.hoogl...@gmail.com]
> Sent: Thursday, March 26, 2015 1:28 PM
> To: dev
> Subject: Re: OVM3 test failures
>
> H Roger,
>
> I hope you are missing something but can't say for sure. The jenkins master 
> build [1] seems not to have your problem. So please expand on your problems.
>
> [1] http://jenkins.buildacloud.org/job/master-slowbuild/
>
> On Thu, Mar 26, 2015 at 6:18 PM, Roger Crerie <roger.cre...@hds.com> wrote:
>> I just updated my source from the master repository.  I am now seeing 
>> failures with cloud-plugin-hypervisor-ovm3.  The failures are having to do 
>> with the tests that OVM3 are running.  I ran the ovm install command to 
>> clear the old databse ....
>> mvn -P developer -pl developer -Ddeploydb
>>
>> But when I go to build cloudstack now I fail with 6 separate tests in OVM3.  
>> Am I missing something?
>>
>> Roger
>
>
>
> --
> Daan



--
Daan

Reply via email to