Review Request 19036: CLOUDSTACK-6092: Storage OverProvisioning as a Per Primary Basis

2014-03-11 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/19036/
---

Review request for cloudstack, Devdeep Singh, Likitha Shetty, Rajesh Battala, 
and Sateesh Chodapuneedi.


Bugs: CLOUDSTACK-6092
https://issues.apache.org/jira/browse/CLOUDSTACK-6092


Repository: cloudstack-git


Description
---

The feature allows CloudStack admins to define over-provisioning for individual 
primary data storages. This will eliminate the tight dependency over the global 
parameter to leverage underlying overprovisioning.
admin can update an existing primary store by setting overprovisioning in the 
per primary setting.
This value will override the value at the global level. To fall back to the 
global value, null value can be passed.
Added overprovisioning as a part of Storage Pool response.
Currently limited to NFS and VMFS data stores.
Appropriate logs added to inform about capacity calculations.
Upgraded setup will migrate the data from data_center_details table to 
storage_pool_details
FS : 
https://cwiki.apache.org/confluence/display/CLOUDSTACK/Storage+OverProvisioning+as+Per+Primary+Basis


Diffs
-

  api/src/org/apache/cloudstack/api/response/StoragePoolResponse.java 03a4f34 
  engine/components-api/src/com/cloud/capacity/CapacityManager.java bd1a610 
  server/src/com/cloud/api/query/dao/StoragePoolJoinDaoImpl.java 274bf1c 
  server/src/com/cloud/capacity/StorageCapacityListener.java 4322ecf 
  server/src/com/cloud/storage/StorageManagerImpl.java 52c2e7e 
  setup/db/db/schema-430to440.sql ee4cf21 
  test/integration/smoke/test_over_provisioning.py PRE-CREATION 

Diff: https://reviews.apache.org/r/19036/diff/


Testing
---

Build passes successfully.
Rat build for the new file passes.
Patch applies cleanly.

The following scenarios tested:
setting and resetting of the overprovision factor.
setting the factor to null
adding new data stores
capacity calculations

New Marvin test: test_over_provisioning.py added


Thanks,

Saksham Srivastava



RE: [PROPOSAL] Storage OverProvisioning as Per Primary Basis

2014-03-11 Thread Saksham Srivastava
Hi,
Created review request at https://reviews.apache.org/r/19036/
Tested the common scenarios and added Marvin test for the same.

Thanks,
Saksham

-Original Message-
From: Saksham Srivastava [mailto:saksham.srivast...@citrix.com] 
Sent: Monday, February 17, 2014 4:56 PM
To: dev@cloudstack.apache.org
Subject: RE: [PROPOSAL] Storage OverProvisioning as Per Primary Basis

Koushik/Mike,
Thanks for comments.

The current behavior is that we calculate the totalOverProvCapacity 
(storage.overprovisioning.factor * total storage capacity) for the destination 
PS.
When volume is being migrated across PS, the destination PS must have a higher 
totalOverProvCapacity than the expected total allocated space.

This feature will be on same lines as the current behavior except that now the 
storage.overprovisioning.factor will be a configurable parameter for the PS.

I will include this information with more detailed capacity computation along 
with more explanation on upgrade scenarios as soon as cwiki comes up.

As Mike pointed out, we can have Primary Storages at 3 levels : Local Storage 
(HOST), Cluster Storage(CLUSTER) ,  ZWPS (ZONE).
Storage scope was introduced for enhancing Granularity for configuration 
parameters in 4.2, so it would be good to use the same as an individual 
per-primary setting instead of multi scopes.

Thanks,
Saksham

-Original Message-
From: Mike Tutkowski [mailto:mike.tutkow...@solidfire.com]
Sent: Saturday, February 15, 2014 4:25 AM
To: dev@cloudstack.apache.org
Subject: Re: [PROPOSAL] Storage OverProvisioning as Per Primary Basis

Just a reminder here that primary storage can also be at the zone level as of 
4.2.


On Fri, Feb 14, 2014 at 4:44 AM, Koushik Das  wrote:

> Please add more details for upgrade scenario. Also can you give some 
> examples as to how the capacity computation is done for operations 
> where the volume gets migrated from one PS to another having different 
> over provisioning factors.
>
> Is there any value add if you give this also at cluster scope?
>
> -Koushik
>
> On 14-Feb-2014, at 2:13 PM, Saksham Srivastava < 
> saksham.srivast...@citrix.com> wrote:
>
> > Hi,
> >
> > CloudStack currently leverages storage overcommit/overprovisioning 
> > by
> specifying global setting storage.overprovisioning.factor
> > I would like to extend the granularity of global params to make 
> > storage
> overprovisioning as a per primary store basis.
> > Also it would allow admin to make more intuitive choice for
> overprovision factor depending upon the actual storage used.
> >
> > Bug Reference : 
> > https://issues.apache.org/jira/browse/CLOUDSTACK-6092
> > Related : https://issues.apache.org/jira/browse/CLOUDSTACK-5806
> > FS :
> https://cwiki.apache.org/confluence/display/CLOUDSTACK/Storage+OverPro
> visioning+as+Per+Primary+Basis
> >
> > Thanks,
> > Saksham
> >
>
>


--
*Mike Tutkowski*
*Senior CloudStack Developer, SolidFire Inc.*
e: mike.tutkow...@solidfire.com
o: 303.746.7302
Advancing the way the world uses the
cloud<http://solidfire.com/solution/overview/?video=play>
*(tm)*


RE: Affinity Groups and Project

2014-03-12 Thread Saksham Srivastava
Can you provide more logs, you can upload them on pastebin.

Thanks,
Saksham

-Original Message-
From: zcsu [mailto:szc...@hotmail.com] 
Sent: Wednesday, March 12, 2014 3:15 PM
To: dev@cloudstack.apache.org
Subject: Affinity Groups and Project

Question: Whether Project can not support Affinity Groups?
Environment: CS4.2 + Xenserver6.2
   Advance Zone
Step:
1.  I set a host as dedicated host to an account, affinity groups will 
auto create a affinity groups with type ExplicitDedication .
 2. Then I create a Project and add the account has dedicated host.
 
when I try creat a VM in Project view, I can select affinity groups has been 
auto created. but created VM will failed with error "Entity AffinityGroup 
[dc4751ao-d2cb-463e-8351-384b9422313] and entity acct 
[3f526aid-d9ab-40ec-a6a5-9b61c84cb1el-PrjAcct-CPSM-1] belong to different 
accounts"
 
Note: I also try to create new affinity groups in project ,the same error 
happend.
 
So  Project can not use Affinity Groups? If is yes, why affinity group display 
in project view?
 
Anybody can answer, very thanks!
 
 
 
 
  


Re: Review Request 14124: CLOUDSTACK-4622 : If a VM from guest network is added to network tier of VPC then IP reservation allows the CIDR to be a superset of Network CIDR for that VPC tier

2014-03-12 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/14124/
---

(Updated March 12, 2014, 2:23 p.m.)


Review request for cloudstack, Jayapal Reddy and Sateesh Chodapuneedi.


Changes
---

Adding the output of marvin tests.


Bugs: CLOUDSTACK-4622
https://issues.apache.org/jira/browse/CLOUDSTACK-4622


Repository: cloudstack-git


Description
---

Add a new utility method for comparing 2 CIDRs.
The method takes in 2 cidrs, cidrA and cidrB and returns true if cidrA's IP 
range is equal or a subset of cidrB's IP range.


Diffs (updated)
-

  utils/src/com/cloud/utils/net/NetUtils.java 6350986 
  utils/test/com/cloud/utils/net/NetUtilsTest.java 3183826 

Diff: https://reviews.apache.org/r/14124/diff/


Testing (updated)
---

Added unit test for the utility.
Tested locally.
Build is successful.
Patch applies cleanly.
No FindBug issues.

Results of marvin test: test_vpc.py
Test list VPC APIs ... ok
Test restart VPC having no networks ... ok
Test restart VPC having networks ... ok
Test delete VPC having no networks ... ok
Test delete VPC having networks ... ok
Test list VPC APIs for different user roles ... ok
Test Restart VPC when there are multiple networks associated ... ok
Test vpc deletion after account deletion ... ok
Test to create vpc and verify VPC state, VR and SourceNatIP ... ok
Test creation of multiple VPCs with non-overlapping CIDRs ... ok
Test deployment of vm in a VPC without network domain ... ok
Test deployment of vm in a VPC with network domain ... ok
Test deployment of vm in a VPC with network domain ... ok
Test vm deploy in network by a user where VPC was created without 
account/domain ID ... ok
Test deployment of vm in a network in a domain admin account where VPC is 
created without account/domain ID ... ok
Test deployment of vm in a network by root admin for user. ... ok
Test deployment of vm in a network by domain admin for user. ... ok
Test creation of network by domain admin for user from different domain ... ok
Test creation of VPC without mandatory parameters ... ok
Test to verify updation of vpc name and display text ... ok

few tests from: test_vpc_network.py
Test create network in VPC ... ok
Test create network in VPC ... SKIP: Netscaler not configured: skipping test
Test create network in VPC mismatched services (Should fail) ... ok
Test create multiple networks with LB service (Should fail) ... ok
Test create network with external LB devices ... ok
Test create network with redundant router capability ... SKIP: skipped - RvR 
didn't support VPC currently
Test create network services not supported by VPC (Should fail) ... ok
Test create network without sourceNAT service in VPC (should fail) ... ok
Test create network with shared network offering ... ok
Test create network with conserve mode ON ... ok
Test create network with conserve mode ON ... ok
Test network gc after shutdown of vms in the network ... ok
Test network rules after starting a VpcVr that was shutdown after network.gc 
... ok
Test Stop all the Vms that are part of the a Network ... ok
Test create network outside cidr range of VPC ... ok
Test create network outside cidr range of VPC ... ok
Test create network inside cidr range of VPC ... ok
Test create network overlapping cidr range of VPC ... ok
Test create network from different account in VPC ... ok
Test update Network that is NOT part of a VPC to a nw offering that has 
services that are provided by VPCVR and vice versa ... ok


Thanks,

Saksham Srivastava



Re: Review Request 14124: CLOUDSTACK-4622 : If a VM from guest network is added to network tier of VPC then IP reservation allows the CIDR to be a superset of Network CIDR for that VPC tier

2014-03-12 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/14124/
---

(Updated March 12, 2014, 2:25 p.m.)


Review request for cloudstack, Jayapal Reddy and Sateesh Chodapuneedi.


Bugs: CLOUDSTACK-4622
https://issues.apache.org/jira/browse/CLOUDSTACK-4622


Repository: cloudstack-git


Description
---

Add a new utility method for comparing 2 CIDRs.
The method takes in 2 cidrs, cidrA and cidrB and returns true if cidrA's IP 
range is equal or a subset of cidrB's IP range.


Diffs
-

  utils/src/com/cloud/utils/net/NetUtils.java 6350986 
  utils/test/com/cloud/utils/net/NetUtilsTest.java 3183826 

Diff: https://reviews.apache.org/r/14124/diff/


Testing
---

Added unit test for the utility.
Tested locally.
Build is successful.
Patch applies cleanly.
No FindBug issues.

Results of marvin test: test_vpc.py
Test list VPC APIs ... ok
Test restart VPC having no networks ... ok
Test restart VPC having networks ... ok
Test delete VPC having no networks ... ok
Test delete VPC having networks ... ok
Test list VPC APIs for different user roles ... ok
Test Restart VPC when there are multiple networks associated ... ok
Test vpc deletion after account deletion ... ok
Test to create vpc and verify VPC state, VR and SourceNatIP ... ok
Test creation of multiple VPCs with non-overlapping CIDRs ... ok
Test deployment of vm in a VPC without network domain ... ok
Test deployment of vm in a VPC with network domain ... ok
Test deployment of vm in a VPC with network domain ... ok
Test vm deploy in network by a user where VPC was created without 
account/domain ID ... ok
Test deployment of vm in a network in a domain admin account where VPC is 
created without account/domain ID ... ok
Test deployment of vm in a network by root admin for user. ... ok
Test deployment of vm in a network by domain admin for user. ... ok
Test creation of network by domain admin for user from different domain ... ok
Test creation of VPC without mandatory parameters ... ok
Test to verify updation of vpc name and display text ... ok

few tests from: test_vpc_network.py
Test create network in VPC ... ok
Test create network in VPC ... SKIP: Netscaler not configured: skipping test
Test create network in VPC mismatched services (Should fail) ... ok
Test create multiple networks with LB service (Should fail) ... ok
Test create network with external LB devices ... ok
Test create network with redundant router capability ... SKIP: skipped - RvR 
didn't support VPC currently
Test create network services not supported by VPC (Should fail) ... ok
Test create network without sourceNAT service in VPC (should fail) ... ok
Test create network with shared network offering ... ok
Test create network with conserve mode ON ... ok
Test create network with conserve mode ON ... ok
Test network gc after shutdown of vms in the network ... ok
Test network rules after starting a VpcVr that was shutdown after network.gc 
... ok
Test Stop all the Vms that are part of the a Network ... ok
Test create network outside cidr range of VPC ... ok
Test create network outside cidr range of VPC ... ok
Test create network inside cidr range of VPC ... ok
Test create network overlapping cidr range of VPC ... ok
Test create network from different account in VPC ... ok
Test update Network that is NOT part of a VPC to a nw offering that has 
services that are provided by VPCVR and vice versa ... ok


Thanks,

Saksham Srivastava



RE: Affinity Groups and Project

2014-03-12 Thread Saksham Srivastava
The bug tracking URL is https://issues.apache.org/jira/browse/CLOUDSTACK/
You can log the ticket here.

-Original Message-
From: zcsu [mailto:szc...@hotmail.com] 
Sent: Thursday, March 13, 2014 7:29 AM
To: dev@cloudstack.apache.org; Prachi Damle
Subject: RE: Affinity Groups and Project

Thanks Prachi very much.
 Would you hint me how to log a ticket to change the display result for project 
view? Thanks again.
 
> From: prachi.da...@citrix.com
> To: dev@cloudstack.apache.org
> Subject: RE: Affinity Groups and Project
> Date: Wed, 12 Mar 2014 23:34:29 +
> 
> Yes Affinity Groups feature does not support projects. This is 
> mentioned in the FS for that feature, check the FAQ part 
> https://cwiki.apache.org/confluence/display/CLOUDSTACK/FS+-+Affinity-A
> nti-affinity+groups
> 
> 
> You should probably log a ticket to change the display result for project 
> view.
> 
> Thanks,
> Prachi
> 
> -Original Message-
> From: Saksham Srivastava [mailto:saksham.srivast...@citrix.com]
> Sent: Wednesday, March 12, 2014 3:07 AM
> To: dev@cloudstack.apache.org
> Subject: RE: Affinity Groups and Project
> 
> Can you provide more logs, you can upload them on pastebin.
> 
> Thanks,
> Saksham
> 
> -Original Message-
> From: zcsu [mailto:szc...@hotmail.com]
> Sent: Wednesday, March 12, 2014 3:15 PM
> To: dev@cloudstack.apache.org
> Subject: Affinity Groups and Project
> 
> Question: Whether Project can not support Affinity Groups?
> Environment: CS4.2 + Xenserver6.2
>Advance Zone
> Step:
> 1.  I set a host as dedicated host to an account, affinity groups 
> will auto create a affinity groups with type ExplicitDedication .
>  2. Then I create a Project and add the account has dedicated host.
>  
> when I try creat a VM in Project view, I can select affinity groups has been 
> auto created. but created VM will failed with error "Entity AffinityGroup 
> [dc4751ao-d2cb-463e-8351-384b9422313] and entity acct 
> [3f526aid-d9ab-40ec-a6a5-9b61c84cb1el-PrjAcct-CPSM-1] belong to different 
> accounts"
>  
> Note: I also try to create new affinity groups in project ,the same error 
> happend.
>  
> So  Project can not use Affinity Groups? If is yes, why affinity group 
> display in project view?
>  
> Anybody can answer, very thanks!
>  
>  
>  
>  
> 
  


Re: Review Request 17736: CLOUDSTACK-5999: Virtual Router does not start if Guest VM is rebooted from CloudStack

2014-03-13 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/17736/
---

(Updated March 13, 2014, 7:02 a.m.)


Review request for cloudstack, John Burwell and Murali Reddy.


Bugs: CLOUDSTACK-5999
https://issues.apache.org/jira/browse/CLOUDSTACK-5999


Repository: cloudstack-git


Description
---

When a guest is rebooted from CloudStack, if the virtual router managing the 
guest network of that guest is down, CloudStack will not start the virtual 
router.
However the router is started in case the guest vm is stopped and then started.
To mantain similarity between the 2 process it is necessary to start the VR in 
case it is not running.
The fix will address the same.


Diffs (updated)
-

  server/src/com/cloud/vm/UserVmManagerImpl.java be00aa8 

Diff: https://reviews.apache.org/r/17736/diff/


Testing (updated)
---

Testing:
1) vm in a single guest network :
   vm Reboot : If the VR is stopped: VR is first started and then 
the VM reboots.
   vm Reboot : If the VR is running, VM reboots as it used to.
vm Stop/Start continue to work the same.

2)  vm having nics in multi networks :
   vm Reboot : If VR in any/all network is stopped: VRs are first 
started and then the VM reboots.
   vm Reboot : If the VRs are running, VM reboots as it used to.
vm Stop/Start continue to work the same.

3) vpc :
   Tested the above scenarios for vpc also, works fine.

Patch applies cleanly.
Build passes succesfully.
FindBug is passed.
Rebased against latest master.


Thanks,

Saksham Srivastava



Re: Review Request 17736: CLOUDSTACK-5999: Virtual Router does not start if Guest VM is rebooted from CloudStack

2014-03-13 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/17736/
---

(Updated March 13, 2014, 7:31 a.m.)


Review request for cloudstack, John Burwell and Murali Reddy.


Bugs: CLOUDSTACK-5999
https://issues.apache.org/jira/browse/CLOUDSTACK-5999


Repository: cloudstack-git


Description
---

When a guest is rebooted from CloudStack, if the virtual router managing the 
guest network of that guest is down, CloudStack will not start the virtual 
router.
However the router is started in case the guest vm is stopped and then started.
To mantain similarity between the 2 process it is necessary to start the VR in 
case it is not running.
The fix will address the same.


Diffs
-

  server/src/com/cloud/vm/UserVmManagerImpl.java be00aa8 

Diff: https://reviews.apache.org/r/17736/diff/


Testing
---

Testing:
1) vm in a single guest network :
   vm Reboot : If the VR is stopped: VR is first started and then 
the VM reboots.
   vm Reboot : If the VR is running, VM reboots as it used to.
vm Stop/Start continue to work the same.

2)  vm having nics in multi networks :
   vm Reboot : If VR in any/all network is stopped: VRs are first 
started and then the VM reboots.
   vm Reboot : If the VRs are running, VM reboots as it used to.
vm Stop/Start continue to work the same.

3) vpc :
   Tested the above scenarios for vpc also, works fine.

Patch applies cleanly.
Build passes succesfully.
FindBug is passed.
Rebased against latest master.


Thanks,

Saksham Srivastava



Re: Review Request 19036: CLOUDSTACK-6092: Storage OverProvisioning as a Per Primary Basis

2014-03-14 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/19036/
---

(Updated March 14, 2014, 11:21 a.m.)


Review request for cloudstack, Devdeep Singh, Likitha Shetty, Rajesh Battala, 
and Sateesh Chodapuneedi.


Changes
---

Rebased against latest master.


Bugs: CLOUDSTACK-6092
https://issues.apache.org/jira/browse/CLOUDSTACK-6092


Repository: cloudstack-git


Description
---

The feature allows CloudStack admins to define over-provisioning for individual 
primary data storages. This will eliminate the tight dependency over the global 
parameter to leverage underlying overprovisioning.
admin can update an existing primary store by setting overprovisioning in the 
per primary setting.
This value will override the value at the global level. To fall back to the 
global value, null value can be passed.
Added overprovisioning as a part of Storage Pool response.
Currently limited to NFS and VMFS data stores.
Appropriate logs added to inform about capacity calculations.
Upgraded setup will migrate the data from data_center_details table to 
storage_pool_details
FS : 
https://cwiki.apache.org/confluence/display/CLOUDSTACK/Storage+OverProvisioning+as+Per+Primary+Basis


Diffs (updated)
-

  api/src/org/apache/cloudstack/api/response/StoragePoolResponse.java 03a4f34 
  engine/components-api/src/com/cloud/capacity/CapacityManager.java bd1a610 
  server/src/com/cloud/api/query/dao/StoragePoolJoinDaoImpl.java 274bf1c 
  server/src/com/cloud/capacity/StorageCapacityListener.java 4322ecf 
  server/src/com/cloud/storage/StorageManagerImpl.java 913dc23 
  setup/db/db/schema-430to440.sql 9d41fe9 
  test/integration/smoke/test_over_provisioning.py PRE-CREATION 

Diff: https://reviews.apache.org/r/19036/diff/


Testing
---

Build passes successfully.
Rat build for the new file passes.
Patch applies cleanly.

The following scenarios tested:
setting and resetting of the overprovision factor.
setting the factor to null
adding new data stores
capacity calculations

New Marvin test: test_over_provisioning.py added


Thanks,

Saksham Srivastava



Re: Review Request 19036: CLOUDSTACK-6092: Storage OverProvisioning as a Per Primary Basis

2014-03-14 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/19036/
---

(Updated March 14, 2014, 12:10 p.m.)


Review request for cloudstack, Devdeep Singh, Likitha Shetty, Rajesh Battala, 
and Sateesh Chodapuneedi.


Changes
---

Re-rebasing the patch.


Bugs: CLOUDSTACK-6092
https://issues.apache.org/jira/browse/CLOUDSTACK-6092


Repository: cloudstack-git


Description
---

The feature allows CloudStack admins to define over-provisioning for individual 
primary data storages. This will eliminate the tight dependency over the global 
parameter to leverage underlying overprovisioning.
admin can update an existing primary store by setting overprovisioning in the 
per primary setting.
This value will override the value at the global level. To fall back to the 
global value, null value can be passed.
Added overprovisioning as a part of Storage Pool response.
Currently limited to NFS and VMFS data stores.
Appropriate logs added to inform about capacity calculations.
Upgraded setup will migrate the data from data_center_details table to 
storage_pool_details
FS : 
https://cwiki.apache.org/confluence/display/CLOUDSTACK/Storage+OverProvisioning+as+Per+Primary+Basis


Diffs (updated)
-

  api/src/org/apache/cloudstack/api/response/StoragePoolResponse.java 03a4f34 
  engine/components-api/src/com/cloud/capacity/CapacityManager.java bd1a610 
  server/src/com/cloud/api/query/dao/StoragePoolJoinDaoImpl.java 274bf1c 
  server/src/com/cloud/capacity/StorageCapacityListener.java 4322ecf 
  server/src/com/cloud/storage/StorageManagerImpl.java 913dc23 
  setup/db/db/schema-430to440.sql 9298f72 
  test/integration/smoke/test_over_provisioning.py PRE-CREATION 

Diff: https://reviews.apache.org/r/19036/diff/


Testing
---

Build passes successfully.
Rat build for the new file passes.
Patch applies cleanly.

The following scenarios tested:
setting and resetting of the overprovision factor.
setting the factor to null
adding new data stores
capacity calculations

New Marvin test: test_over_provisioning.py added


Thanks,

Saksham Srivastava



Re: Review Request 19036: CLOUDSTACK-6092: Storage OverProvisioning as a Per Primary Basis

2014-03-14 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/19036/
---

(Updated March 14, 2014, 12:10 p.m.)


Review request for cloudstack, Devdeep Singh, Likitha Shetty, Rajesh Battala, 
and Sateesh Chodapuneedi.


Bugs: CLOUDSTACK-6092
https://issues.apache.org/jira/browse/CLOUDSTACK-6092


Repository: cloudstack-git


Description
---

The feature allows CloudStack admins to define over-provisioning for individual 
primary data storages. This will eliminate the tight dependency over the global 
parameter to leverage underlying overprovisioning.
admin can update an existing primary store by setting overprovisioning in the 
per primary setting.
This value will override the value at the global level. To fall back to the 
global value, null value can be passed.
Added overprovisioning as a part of Storage Pool response.
Currently limited to NFS and VMFS data stores.
Appropriate logs added to inform about capacity calculations.
Upgraded setup will migrate the data from data_center_details table to 
storage_pool_details
FS : 
https://cwiki.apache.org/confluence/display/CLOUDSTACK/Storage+OverProvisioning+as+Per+Primary+Basis


Diffs
-

  api/src/org/apache/cloudstack/api/response/StoragePoolResponse.java 03a4f34 
  engine/components-api/src/com/cloud/capacity/CapacityManager.java bd1a610 
  server/src/com/cloud/api/query/dao/StoragePoolJoinDaoImpl.java 274bf1c 
  server/src/com/cloud/capacity/StorageCapacityListener.java 4322ecf 
  server/src/com/cloud/storage/StorageManagerImpl.java 913dc23 
  setup/db/db/schema-430to440.sql 9298f72 
  test/integration/smoke/test_over_provisioning.py PRE-CREATION 

Diff: https://reviews.apache.org/r/19036/diff/


Testing
---

Build passes successfully.
Rat build for the new file passes.
Patch applies cleanly.

The following scenarios tested:
setting and resetting of the overprovision factor.
setting the factor to null
adding new data stores
capacity calculations

New Marvin test: test_over_provisioning.py added


Thanks,

Saksham Srivastava



Re: Review Request 17736: CLOUDSTACK-5999: Virtual Router does not start if Guest VM is rebooted from CloudStack

2014-03-14 Thread Saksham Srivastava


> On March 13, 2014, 4:46 p.m., John Burwell wrote:
> > server/src/com/cloud/vm/UserVmManagerImpl.java, line 756
> > <https://reviews.apache.org/r/17736/diff/3/?file=518208#file518208line756>
> >
> > Two queries are executed in this for loop which puts stress on the 
> > database and slows down the application.  Furthermore, this for loop 
> > appears to be performing in-memory join and filter operations.  Please 
> > refactor into a single query performed by the most appropriate DAO.

I guess I completely misunderstood the last comment by you, now it makes 
complete sense to me. Thanks for the suggestion John, I will update my patch 
with a single query.


- Saksham


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/17736/#review37061
-------


On March 13, 2014, 7:31 a.m., Saksham Srivastava wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/17736/
> ---
> 
> (Updated March 13, 2014, 7:31 a.m.)
> 
> 
> Review request for cloudstack, John Burwell and Murali Reddy.
> 
> 
> Bugs: CLOUDSTACK-5999
> https://issues.apache.org/jira/browse/CLOUDSTACK-5999
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> ---
> 
> When a guest is rebooted from CloudStack, if the virtual router managing the 
> guest network of that guest is down, CloudStack will not start the virtual 
> router.
> However the router is started in case the guest vm is stopped and then 
> started.
> To mantain similarity between the 2 process it is necessary to start the VR 
> in case it is not running.
> The fix will address the same.
> 
> 
> Diffs
> -
> 
>   server/src/com/cloud/vm/UserVmManagerImpl.java be00aa8 
> 
> Diff: https://reviews.apache.org/r/17736/diff/
> 
> 
> Testing
> ---
> 
> Testing:
> 1) vm in a single guest network :
>vm Reboot : If the VR is stopped: VR is first started and then 
> the VM reboots.
>vm Reboot : If the VR is running, VM reboots as it used to.
> vm Stop/Start continue to work the same.
> 
> 2)  vm having nics in multi networks :
>vm Reboot : If VR in any/all network is stopped: VRs are first 
> started and then the VM reboots.
>vm Reboot : If the VRs are running, VM reboots as it used to.
> vm Stop/Start continue to work the same.
> 
> 3) vpc :
>Tested the above scenarios for vpc also, works fine.
> 
> Patch applies cleanly.
> Build passes succesfully.
> FindBug is passed.
> Rebased against latest master.
> 
> 
> Thanks,
> 
> Saksham Srivastava
> 
>



Re: Review Request 17736: CLOUDSTACK-5999: Virtual Router does not start if Guest VM is rebooted from CloudStack

2014-03-14 Thread Saksham Srivastava


> On March 13, 2014, 4:55 p.m., Alena Prokharchyk wrote:
> > Also why don't start routers in parallel? First, get all the router nics in 
> > one query like John suggested, then span start process for routers in 
> > separate threads, check the status of each job using Future.

Sure I will do that.


- Saksham


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/17736/#review37066
---


On March 13, 2014, 7:31 a.m., Saksham Srivastava wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/17736/
> ---
> 
> (Updated March 13, 2014, 7:31 a.m.)
> 
> 
> Review request for cloudstack, John Burwell and Murali Reddy.
> 
> 
> Bugs: CLOUDSTACK-5999
> https://issues.apache.org/jira/browse/CLOUDSTACK-5999
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> ---
> 
> When a guest is rebooted from CloudStack, if the virtual router managing the 
> guest network of that guest is down, CloudStack will not start the virtual 
> router.
> However the router is started in case the guest vm is stopped and then 
> started.
> To mantain similarity between the 2 process it is necessary to start the VR 
> in case it is not running.
> The fix will address the same.
> 
> 
> Diffs
> -
> 
>   server/src/com/cloud/vm/UserVmManagerImpl.java be00aa8 
> 
> Diff: https://reviews.apache.org/r/17736/diff/
> 
> 
> Testing
> ---
> 
> Testing:
> 1) vm in a single guest network :
>vm Reboot : If the VR is stopped: VR is first started and then 
> the VM reboots.
>vm Reboot : If the VR is running, VM reboots as it used to.
> vm Stop/Start continue to work the same.
> 
> 2)  vm having nics in multi networks :
>vm Reboot : If VR in any/all network is stopped: VRs are first 
> started and then the VM reboots.
>vm Reboot : If the VRs are running, VM reboots as it used to.
> vm Stop/Start continue to work the same.
> 
> 3) vpc :
>    Tested the above scenarios for vpc also, works fine.
> 
> Patch applies cleanly.
> Build passes succesfully.
> FindBug is passed.
> Rebased against latest master.
> 
> 
> Thanks,
> 
> Saksham Srivastava
> 
>



Re: Review Request 18768: CLOUDSTACK-6151: Local data disk with tag goes to the wrong local storage pool

2014-04-16 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/18768/
---

(Updated April 16, 2014, 9:39 a.m.)


Review request for cloudstack and Koushik Das.


Changes
---

Resolving merge conflicts.


Bugs: CLOUDSTACK-6151
https://issues.apache.org/jira/browse/CLOUDSTACK-6151


Repository: cloudstack-git


Description (updated)
---

Updating the patch for 4.4 becuase of merge conflicts.


Diffs (updated)
-

  
engine/schema/resources/META-INF/cloudstack/core/spring-engine-schema-core-daos-context.xml
 489b37d 
  
engine/schema/src/org/apache/cloudstack/storage/datastore/db/PrimaryDataStoreDao.java
 2c4369d 
  
engine/schema/src/org/apache/cloudstack/storage/datastore/db/PrimaryDataStoreDaoImpl.java
 57afa16 
  
engine/storage/src/org/apache/cloudstack/storage/allocator/LocalStoragePoolAllocator.java
 678b2a3 
  server/test/resources/createNetworkOffering.xml 6ae1978 

Diff: https://reviews.apache.org/r/18768/diff/


Testing (updated)
---

Tested the folowing scenarios:
attaching local volume with tags
attaching local volume without tags
attaching local volume with different tags
attaching shared volume

Build passes successfully.
Patch applies cleanly.


Thanks,

Saksham Srivastava



Re: Review Request 18768: CLOUDSTACK-6151: Local data disk with tag goes to the wrong local storage pool

2014-04-16 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/18768/
---

(Updated April 16, 2014, 10:14 a.m.)


Review request for cloudstack and Koushik Das.


Bugs: CLOUDSTACK-6151
https://issues.apache.org/jira/browse/CLOUDSTACK-6151


Repository: cloudstack-git


Description (updated)
---

Updating the patch for 4.4 and master because of merge conflicts.


Diffs
-

  
engine/schema/resources/META-INF/cloudstack/core/spring-engine-schema-core-daos-context.xml
 489b37d 
  
engine/schema/src/org/apache/cloudstack/storage/datastore/db/PrimaryDataStoreDao.java
 2c4369d 
  
engine/schema/src/org/apache/cloudstack/storage/datastore/db/PrimaryDataStoreDaoImpl.java
 57afa16 
  
engine/storage/src/org/apache/cloudstack/storage/allocator/LocalStoragePoolAllocator.java
 678b2a3 
  server/test/resources/createNetworkOffering.xml 6ae1978 

Diff: https://reviews.apache.org/r/18768/diff/


Testing
---

Tested the folowing scenarios:
attaching local volume with tags
attaching local volume without tags
attaching local volume with different tags
attaching shared volume

Build passes successfully.
Patch applies cleanly.


Thanks,

Saksham Srivastava



RE: [ANNOUNCE] New PMC Menber: Alena Prokharchyk

2014-04-22 Thread Saksham Srivastava
Congratulations Alena !

-Original Message-
From: Daan Hoogland [mailto:daan.hoogl...@gmail.com] 
Sent: Wednesday, April 23, 2014 1:21 AM
To: dev
Subject: [ANNOUNCE] New PMC Menber: Alena Prokharchyk

The Project Management Committee (PMC) for Apache CloudStack has asked Alena 
Prokharchyk to join the PMC and we are pleased to announce that he has accepted.

Join me in congratulating Alena!


-The CloudStack PMC


RE: [cloudmonkey] Problem listing virtualmachines by account

2014-04-30 Thread Saksham Srivastava
Nux,

You have to specify the account name not the uuid.
#list virtualmachines account= 
domainid=730c8a4a-a44f-11e3-bae5-f6145f6a2f37 listall=true


Thanks,
Saksham

-Original Message-
From: Nux! [mailto:n...@li.nux.ro] 
Sent: Wednesday, April 30, 2014 5:48 PM
To: dev@cloudstack.apache.org
Subject: [cloudmonkey] Problem listing virtualmachines by account

Hi,

How can I list the VMs of a certain account?
Apparently cloudmonkey allows listing VMs per account (a pretty D'OH feature), 
but I can't get it to work. All I get is this:

mycloudmonkey > list virtualmachines
account=e7905355-2e13-4ea7-b6d8-e23ad214f20f
domainid=730c8a4a-a44f-11e3-bae5-f6145f6a2f37
431: could not find account e7905355-2e13-4ea7-b6d8-e23ad214f20f in domain 
730c8a4a-a44f-11e3-bae5-f6145f6a2f37

What am I missing?

Lucian

--
Sent from the Delta quadrant using Borg technology!

Nux!
www.nux.ro


Review Request 21156: CLOUDSTACK-6575: Deploy VM failed with NPE while using custom compute offering

2014-05-10 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/21156/
---

Review request for cloudstack, Devdeep Singh and Rajesh Battala.


Bugs: CLOUDSTACK-6575
https://issues.apache.org/jira/browse/CLOUDSTACK-6575


Repository: cloudstack-git


Description
---

Deploy VM failed with NPE while using custom compute offering:
Steps to reproduce:
1. Install and configure Adv zone.
2. Create Compute offering with Custom option enabled.
3. Deploy VM using Default Cent OS template using Custom option enabled Compute 
offering.

Root Cause:
In schema-410to420.sql ALTER TABLE `cloud`.`disk_offering` ADD COLUMN 
`customized_iops` tinyint(1) unsigned COMMENT 'Should customized IOPS be 
displayed to the end user'; 

The default value of customized_iops is null and ServiceOfferingVO construtor 
calls the super constructor in DiskOfferingVO passing null to boolean value, 
hence the NPE.

Fix: Change Boolean to boolean with appropriate conversions.


Diffs
-

  engine/schema/src/com/cloud/service/ServiceOfferingVO.java 3be0aaa 

Diff: https://reviews.apache.org/r/21156/diff/


Testing
---

Deployed vm with customized_iops as null in disk_offering table.
Deployed vm with customized_iops as not null in disk_offering table.
Both the deployments pass.
Build passes successfully.


Thanks,

Saksham Srivastava



RE: [ACS44] Cherry pick for CLOUDSTACK-6575

2014-05-11 Thread Saksham Srivastava
Resending it as the original mail was not delivered.

Thanks,
Saksham

From: Saksham Srivastava
Sent: Thursday, May 8, 2014 1:26 PM
To: dev@cloudstack.apache.org
Subject: [ACS44] Cherry pick for CLOUDSTACK-6575


Hi Daan/Hugo,



Can you please cherry-pick following to 4.4:



Commit hash:  84135cd302ab5fb944a28e73b394d02a8d1c17e2



CLOUDSTACK-6575: Deploy VM failed with NPE while using custom compute offering



Contained in branches: 4.4-forward, master



Thanks,

Saksham



Review Request 21375: CLOUDSTACK-6654: Configkey parameters are not validated

2014-05-13 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/21375/
---

Review request for cloudstack, Abhinandan Prateek and Devdeep Singh.


Bugs: CLOUDSTACK-6654
https://issues.apache.org/jira/browse/CLOUDSTACK-6654


Repository: cloudstack-git


Description
---

ConfigKey variables values are not validated. So anything  like -5.6 or “abc”  
as the value of cpu/memory/storage overprovision factors can be set. Similarly 
for all of the variables in ConfigKey.
We have a verification mechanism but it is never executed. The code is 
unreachable in the preset 4.4

In ConfigurationManagerImpl.java: validateConfigurationValue()
 
Config c = Config.getConfig(name);
 if (c == null) {
s_logger.warn("Did not find configuration " + name + " in Config.java. Perhaps 
moved to ConfigDepot?");
-return null;
}
Since for the ConfigKey parameters ‘c’ is always null, we return null and do 
not further validate.

Fix is to make sure type is validated by using  _configDepot.get(name)

Note: Configkey does not have a range flag. Each range param has to be 
considered as per case basis.
Added comments for the same.


Diffs
-

  server/src/com/cloud/configuration/ConfigurationManagerImpl.java 231b5e1 

Diff: https://reviews.apache.org/r/21375/diff/


Testing
---

Tested both Configkey variables as well as old Config parameters.
ConfigKey values are now validated before setting them in db.

The following status message appears when cpu.overprovisioning.factor is set to 
incorrect value.
There was an error trying to parse the float value for: 
cpu.overprovisioning.factor

Build passes.
Findbug is clean.


Thanks,

Saksham Srivastava



RE: CLOUDSTACK-6092 in 4.4 ?

2014-05-13 Thread Saksham Srivastava
Yes ,
This is available in 4.4.
Refer the  Functional Specification for what is supported in 4.4 and the future 
scope.
https://cwiki.apache.org/confluence/display/CLOUDSTACK/Storage+OverProvisioning+as+Per+Primary+Basis

There is a related ticket CLOUDSTACK-5806 which is still in discussion, so I 
have kept this ticket is still in progress.

Thanks,
Saksham



-Original Message-
From: Pierre-Luc Dion [mailto:pd...@cloudops.com] 
Sent: Wednesday, May 14, 2014 3:49 AM
To: dev@cloudstack.apache.org
Subject: CLOUDSTACK-6092 in 4.4 ?

does this new Feature will be in 4.4 ?

in JIRA status is currently : In Progress

Thanks

Pierre-Luc Dion


RE: [REQUEST] permission to assign task in jira

2014-05-14 Thread Saksham Srivastava
Sebastien, I think there is an issue with our Jira permissions.
People are not able to assign bugs to themselves.
I am also facing the same issue. The Assignee field in the tickets cannot be 
edited by many of us.

Thanks,
Saksham

-Original Message-
From: sebgoa [mailto:run...@gmail.com] 
Sent: Wednesday, May 14, 2014 12:40 PM
To: dev@cloudstack.apache.org
Subject: Re: [REQUEST] permission to assign task in jira


On May 13, 2014, at 4:38 PM, Gaurav Aradhye  wrote:

> Hi,
> 
> Can anyone please give me permission to "assign task" in jira? My jira 
> id is gauravaradhye.
> 

We don't assign task in this project, folks pick up the tickets themselves

> Regards,
> Gaurav



Cannot assign bugs on ASF Cloudstack Jira

2014-05-15 Thread Saksham Srivastava
Hi,

I tried assigning 4.4 bug to myself on https://issues.apache.org/jira
But the UI option to change the assignee seems disabled.

Anyone else having the same issue ?

Thanks,
Saksham


[ACS44] Cherry pick for CLOUDSTACK-6575

2014-05-15 Thread Saksham Srivastava
Hi Daan/Hugo,



Can you please cherry-pick following to 4.4:



Commit hash:  84135cd302ab5fb944a28e73b394d02a8d1c17e2



CLOUDSTACK-6575: Deploy VM failed with NPE while using custom compute offering



Contained in branches: 4.4-forward, master



Thanks,

Saksham



RE: [ANNOUNCE] Saksham Srivastava as committer

2014-05-29 Thread Saksham Srivastava
Thanks everyone !!

Regards,
Saksham

-Original Message-
From: Gaurav Aradhye [mailto:gaurav.arad...@clogeny.com] 
Sent: Friday, May 30, 2014 9:35 AM
To: dev@cloudstack.apache.org
Subject: Re: [ANNOUNCE] Saksham Srivastava as committer

Congrats Saksham!

Regards,
Gaurav


On Fri, May 30, 2014 at 9:28 AM, Sanjeev Neelarapu < 
sanjeev.neelar...@citrix.com> wrote:

> Congrats Saksham !!
>
> -Original Message-
> From: Vaibhav Gupta [mailto:vaibhav.gu...@citrix.com]
> Sent: Thursday, May 29, 2014 6:03 PM
> To: dev@cloudstack.apache.org
> Subject: RE: [ANNOUNCE] Saksham Srivastava as committer
>
> Congratulations Saksham..
>
> Thanks,
> Vaibhav
>
> -Original Message-
> From: Sanjay Tripathi [mailto:sanjay.tripa...@citrix.com]
> Sent: 29 May 2014 15:39
> To: dev@cloudstack.apache.org
> Subject: RE: [ANNOUNCE] Saksham Srivastava as committer
>
> Congratulations Saksham.
>
> --Sanjay
>
> -Original Message-
> From: sebgoa [mailto:run...@gmail.com]
> Sent: Thursday, May 29, 2014 12:18 PM
> To: dev@cloudstack.apache.org
> Subject: [ANNOUNCE] Saksham Srivastava as committer
>
> The Project Management Committee (PMC) for Apache CloudStack has asked 
> Saksham Srivastava to become a committer and we are pleased to 
> announce that he has accepted.
>
> Being a committer allows many contributors to contribute more 
> autonomously. For developers, it makes it easier to submit changes and 
> eliminates the need to have contributions reviewed via the patch 
> submission process. Whether contributions are development-related or 
> otherwise, it is a recognition of a contributor's participation in the 
> project and commitment to the project and the Apache Way.
>
> Please join me in congratulating Saksham,
>
>
> -Sebastien, on behalf of the CloudStack PMC
>


RE: Unable to upload SSL certificate

2014-06-04 Thread Saksham Srivastava
Adding Syed,

I debugged the issue and here are my findings:

The api is failing at CertServiceimpl: parseCertificate()

return (Certificate) certPem.readObject();

readObject method is failing.

I tried to use the certificate used in the test 
runUploadSslCertSelfSignedWithPassword and other tests in CertServiceTest.java
The following is the api call:

http://10.x.x.x:8096/client/api?command=uploadSslCert&certificate=-BEGIN+CERTIFICATE-%0AMIIDBjCCAe4CCQD5Q6qF5dVV0jANBgkqhkiG9w0BAQUFADBFMQswCQYDVQQGEwJB%0AVTETMBEGA1UECAwKU29tZS1TdGF0ZTEhMB8GA1UECgwYSW50ZXJuZXQgV2lkZ2l0%0AcyBQdHkgTHRkMB4XDTEzMTAyMTEzNTgwNFoXDTE0MTAyMTEzNTgwNFowRTELMAkG%0AA1UEBhMCQVUxEzARBgNVBAgMClNvbWUtU3RhdGUxITAfBgNVBAoMGEludGVybmV0%0AIFdpZGdpdHMgUHR5IEx0ZDCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB%0AAN%2F7lJtiEs68IC1ZPxY9NA34z9T4AU4LPS%2FkbQtuxx4X72XOBy%2By0cB%2FqdMD7JNV%0Ah8Mq4URDljhSDyVPdH%2F%2BjQr%2B7kWx2gNe2R%2FDCnd%2FmeVwwU30JJvpGVZXt%2BMTef5N%0AQAbSfDMsuT4FaUY80InbDd24HelrjwunPdY9wwKXO6zL2fLjyDRediiydxcx18Vb%0ADq1cm7DRi4mNkmA3RwBQMhxGp3VsfXJ4Hy2WTRCCCxWHZphAh3EUJGK3idum6%2F7j%0AHbAwpM%2Ft1kNWN8PZiYDZ1HbccgjmqB7Cub10BfB9g1RByiQ%2FC87o5cKtQha3uuXR%0AiBcHISoDydQrgxKgUpiqEF0CAwEAATANBgkqhkiG9w0BAQUFAAOCAQEASvulIaVb%0Azh8z2TysE6RFoYTAYIRXghFrmqCUyyQmUVTvs6vN8iaSXr%2BWMQJcpgXewWcFrDhr%0AmIcyRCvF91ZYb7q6lMZFSpE6u%2FSUGIEtxGUDAfbkbQdKYmrMcbggUUIvSzgUFisO%0AKr0H9PEO4AWtCCrtOJFc7jgu03Sv06wDxn9ghkyiBRnVkbAhoKfKnI179yKruJWR%0AA3ieEj0eFoUbeSH8hDkToj4ynpkAvEGoHjHG9j%2B8FJxy%2FPTjkyVPl1ykTs%2B2Jc1B%0ASnx8f2afdTenPWyyBm3wFuRZjEAJJLUO0kxM7E8hAwhGsr%2BXYanwcr1oA1dz6M3f%0Acq26lpjTH5ITwQ%3D%3D%0A-END+CERTIFICATE-%0A&privatekey=-BEGIN+RSA+PRIVATE+KEY-%0AProc-Type%3A+4%2CENCRYPTED%0ADEK-Info%3A+DES-EDE3-CBC%2CCCA6E4CB4C4039DD%0A%0ATaVCJtB0dE9xTZbX7GOaGJwwGHVAMjU1GbRIHf0jODdP%2BquZvbjklNqsw8Ozlia9%0Aq%2FG%2BUqtRJGlIPPLpce0YCrTo0P3eixZdMs0%2BhioAEJ4OLtL0SAC6b8q%2FgB6HRfAx%0ABvNg%2BumTqeF9YB68Tcuv%2F2g4VGKiaePQACyOzMdf7lGY7ojxoJCYZa1mfKb7jWrg%0AFLwmTtLLhNjb6CnOKo3klIef3A6zdutpgxF1gARzdRyXg4qCA3boYnwEptTOlJFu%0AovxbhDG9iuYYr4gXYSs1pLYptEC8J6iWpG%2Fqzkwfr4l5Cfg5uF00bbxQE5%2BWeRaj%0AYFicvXjB%2FkcoFZuCL7M%2FYRXYxkJ%2FEZ19xI9HZNBQ4L738StkSBKL4OhpF%2FqgYZ2y%0AZLRV6XT4AijUA0Ef7YTuUsTL7Qt9drj09gCtAzXTA7gpZBn5SqT9kWhuwSzY302l%0AKF8DIC6A52igk2QKPLbleM%2FV8eCu6n%2BJ4uF%2B0GwVRROuG7ThxAQiUlJKhoEYrndL%0AnzT7jHVLftjilhVWFu2On62bRf5t1QZuob%2B1AdK0ukvEIVsYnN4bnlAkc99Wi6C0%0AZJd9qW5L4A9XAC2gcjr3m0Rzw3RO%2Bk17faR8YfmTuJvGyBf5fnrSFoNkrninXQXp%0Ask0ajRi4PJ4XTswLyxjWRSt3egNsZBSKnVCibca%2FQoDEdZHSKXo2FlYiUYx8JHQX%0ASPUsLl9OQKC1W8%2F%2BReryqBLHCkiGEsvT8gVaXga0uhVaqe%2BPaVur2tbOHl4yCysC%0A%2BZlnKwsC84LQsUvpENdCh%2BD7E1I1Rao9IJMR6q9azKq8Ck63cOJ1fA9xSnxJGoCA%0AIlGLttlXrR32EtzYwEnlqf1nI%2FIqNQrAXQKrP5VPzHsgMFu5uD4OEZa92Q5cVTsz%0Aap%2F1UEqiJVYUt6nuA%2BaqOUlyjC0oNtYL%2FVO4DbHTFcHa8SI2cPSS6ebPMWPGHjUm%0Al9bWa6Q9iyplCYS6hinAVsAaLVjPi1Eu9Pc8rxFCmoiJYJju5NZuGI5UBK64dqcX%0AT6trWl0kB8QY63JtnrZaoStoSPImV5KVseUKDV8TM3Y76h1nLV3MSmAD1ivk9oKs%0AVKeVrDhZBWUq9Dqre%2F%2BlVGO0a2wo5VTR8hfpf8QkODPLeyNZNdfGKzkkFLuXa8V5%0AELhLQJ3FnbEU3NEvMwikV9MhP%2FELPTkZwJr%2FNKv%2B9JLs9eXtwz29I%2FQ8byQVrCCs%0AhAuDl0zHGRnqdpdSImeS2EXGx631zGMwSe8fhKelni5h6hXrXz52asr0k30BxWjf%0AWUn1uTInwVjWGy9B5j3mZlVDotFbvVAZgtR0IoFwihPl4VZd9oS13l%2BhMfrTy1YZ%0A8xFNg8ZqUQ0lSmKfOVqSBT0lP8tM8LuGxgY4cWluhsAQxR5Nl7wkundnqjcwEDDu%0AJz2rD54St1EZYGLDJZSfC7mpG2PgodsdeopQCTyFhHWa8s3caZ40GFOwaR%2B%2F5%2BYF%0A1oRvkR1Yr4qIS7KbX4xsaFfAA5b8QfLA74L05PAgDwKofam2GFAlAKHOcI6mexPq%0AaySON9MNdnXBNxs16mBJLzCX5ljQb0ilJildVEI3aVmABptM4ehEiw%3D%3D%0A-END+RSA+PRIVATE+KEY-%0A&password=test

and the api fails with "Invalid Certificate format. Expected X509 certificate"

Since all the tests pass, I am assuming a problem with the api encoding format.
Can someone point to a working api call for the same.

Thanks,
Saksham


-Original Message-
From: Sujaya Maiyya (Intern) [mailto:sujaya.mai...@citrix.com] 
Sent: Tuesday, June 3, 2014 2:36 PM
To: dev@cloudstack.apache.org
Cc: Vijay Venkatachalam
Subject: Unable to upload SSL certificate

Hi,
  I am trying to upload an SSL certificate to Cloudstack using uploadSslCert 
API since 4.3 version does not have UI support for the same. And I am getting 
following exception:
Invalid Certificate format. Expected X509 certificate

The certificate, private key and certificate-chain are URL encoded and sent to 
the Cloudstack using a GET on 8096 port. On debugging, it was found that some 
characters were missing from certificate after it was decoded from the URL 
which is the cause of the exception.

I am unable to figure out the reason, so can you please throw some light on why 
are some characters missing after decoding the certificate from the URL?

Thank you,
Sujaya



RE: Unable to upload SSL certificate

2014-06-05 Thread Saksham Srivastava
Syed,

The certificate in the mentioned call is already UTF-8 encoded of the raw 
plain-text certificate.
To make the api work I had to doubly encode the cert and key .

I guess it will be good to have this mentioned in the FS/docs as there is no UI 
for this and also a sample api call can help a lot.

Thanks,
Saksham 

-Original Message-
From: Syed Ahmed [mailto:sah...@cloudops.com] 
Sent: Thursday, June 5, 2014 6:23 AM
To: Saksham Srivastava
Cc: Vijay Venkatachalam; dev@cloudstack.apache.org
Subject: Re: Unable to upload SSL certificate

Can you try to encode the certificate before passing it as the param?

-Syed

On Wed 04 Jun 2014 09:01:19 AM EDT, Saksham Srivastava wrote:
> Adding Syed,
>
> I debugged the issue and here are my findings:
>
> The api is failing at CertServiceimpl: parseCertificate()
>
> return (Certificate) certPem.readObject();
>
> readObject method is failing.
>
> I tried to use the certificate used in the test 
> runUploadSslCertSelfSignedWithPassword and other tests in 
> CertServiceTest.java The following is the api call:
>
> http://10.x.x.x:8096/client/api?command=uploadSslCert&certificate=
> -BEGIN+CERTIFICATE-%0AMIIDBjCCAe4CCQD5Q6qF5dVV0jANBgkqhkiG9w0BAQUF
> ADBFMQswCQYDVQQGEwJB%0AVTETMBEGA1UECAwKU29tZS1TdGF0ZTEhMB8GA1UECgwYSW5
> 0ZXJuZXQgV2lkZ2l0%0AcyBQdHkgTHRkMB4XDTEzMTAyMTEzNTgwNFoXDTE0MTAyMTEzNT
> gwNFowRTELMAkG%0AA1UEBhMCQVUxEzARBgNVBAgMClNvbWUtU3RhdGUxITAfBgNVBAoMG
> EludGVybmV0%0AIFdpZGdpdHMgUHR5IEx0ZDCCASIwDQYJKoZIhvcNAQEBBQADggEPADCC
> AQoCggEB%0AAN%2F7lJtiEs68IC1ZPxY9NA34z9T4AU4LPS%2FkbQtuxx4X72XOBy%2By0
> cB%2FqdMD7JNV%0Ah8Mq4URDljhSDyVPdH%2F%2BjQr%2B7kWx2gNe2R%2FDCnd%2FmeVw
> wU30JJvpGVZXt%2BMTef5N%0AQAbSfDMsuT4FaUY80InbDd24HelrjwunPdY9wwKXO6zL2
> fLjyDRediiydxcx18Vb%0ADq1cm7DRi4mNkmA3RwBQMhxGp3VsfXJ4Hy2WTRCCCxWHZphA
> h3EUJGK3idum6%2F7j%0AHbAwpM%2Ft1kNWN8PZiYDZ1HbccgjmqB7Cub10BfB9g1RByiQ
> %2FC87o5cKtQha3uuXR%0AiBcHISoDydQrgxKgUpiqEF0CAwEAATANBgkqhkiG9w0BAQUF
> AAOCAQEASvulIaVb%0Azh8z2TysE6RFoYTAYIRXghFrmqCUyyQmUVTvs6vN8iaSXr%2BWM
> QJcpgXewWcFrDhr%0AmIcyRCvF91ZYb7q6lMZFSpE6u%2FSUGIEtxGUDAfbkbQdKYmrMcb
> ggUUIvSzgUFisO%0A
Kr0H9PEO4AWtCCrtOJFc7jgu03Sv06wDxn9ghkyiBRnVkbAhoKfKnI179yKruJWR%0AA3ieEj0eFoUbeSH8hDkToj4ynpkAvEGoHjHG9j%2B8FJxy%2FPTjkyVPl1ykTs%2B2Jc1B%0ASnx8f2afdTenPWyyBm3wFuRZjEAJJLUO0kxM7E8hAwhGsr%2BXYanwcr1oA1dz6M3f%0Acq26lpjTH5ITwQ%3D%3D%0A-END+CERTIFICATE-%0A&privatekey=-BEGIN+RSA+PRIVATE+KEY-%0AProc-Type%3A+4%2CENCRYPTED%0ADEK-Info%3A+DES-EDE3-CBC%2CCCA6E4CB4C4039DD%0A%0ATaVCJtB0dE9xTZbX7GOaGJwwGHVAMjU1GbRIHf0jODdP%2BquZvbjklNqsw8Ozlia9%0Aq%2FG%2BUqtRJGlIPPLpce0YCrTo0P3eixZdMs0%2BhioAEJ4OLtL0SAC6b8q%2FgB6HRfAx%0ABvNg%2BumTqeF9YB68Tcuv%2F2g4VGKiaePQACyOzMdf7lGY7ojxoJCYZa1mfKb7jWrg%0AFLwmTtLLhNjb6CnOKo3klIef3A6zdutpgxF1gARzdRyXg4qCA3boYnwEptTOlJFu%0AovxbhDG9iuYYr4gXYSs1pLYptEC8J6iWpG%2Fqzkwfr4l5Cfg5uF00bbxQE5%2BWeRaj%0AYFicvXjB%2FkcoFZuCL7M%2FYRXYxkJ%2FEZ19xI9HZNBQ4L738StkSBKL4OhpF%2FqgYZ2y%0AZLRV6XT4AijUA0Ef7YTuUsTL7Qt9drj09gCtAzXTA7gpZBn5SqT9kWhuwSzY302l%0AKF8DIC6A52igk2QKPLbleM%2FV8eCu6n%2BJ4uF%2B0GwVRROuG7ThxAQiUlJKhoEYrndL%0AnzT7jHVLftjilhVWFu2On62bRf5t1QZuob%2B1AdK0ukvEI
VsYnN4bnlAkc99Wi6C0%0AZJd9qW5L4A9XAC2gcjr3m0Rzw3RO%2Bk17faR8YfmTuJvGyBf5fnrSFoNkrninXQXp%0Ask0ajRi4PJ4XTswLyxjWRSt3egNsZBSKnVCibca%2FQoDEdZHSKXo2FlYiUYx8JHQX%0ASPUsLl9OQKC1W8%2F%2BReryqBLHCkiGEsvT8gVaXga0uhVaqe%2BPaVur2tbOHl4yCysC%0A%2BZlnKwsC84LQsUvpENdCh%2BD7E1I1Rao9IJMR6q9azKq8Ck63cOJ1fA9xSnxJGoCA%0AIlGLttlXrR32EtzYwEnlqf1nI%2FIqNQrAXQKrP5VPzHsgMFu5uD4OEZa92Q5cVTsz%0Aap%2F1UEqiJVYUt6nuA%2BaqOUlyjC0oNtYL%2FVO4DbHTFcHa8SI2cPSS6ebPMWPGHjUm%0Al9bWa6Q9iyplCYS6hinAVsAaLVjPi1Eu9Pc8rxFCmoiJYJju5NZuGI5UBK64dqcX%0AT6trWl0kB8QY63JtnrZaoStoSPImV5KVseUKDV8TM3Y76h1nLV3MSmAD1ivk9oKs%0AVKeVrDhZBWUq9Dqre%2F%2BlVGO0a2wo5VTR8hfpf8QkODPLeyNZNdfGKzkkFLuXa8V5%0AELhLQJ3FnbEU3NEvMwikV9MhP%2FELPTkZwJr%2FNKv%2B9JLs9eXtwz29I%2FQ8byQVrCCs%0AhAuDl0zHGRnqdpdSImeS2EXGx631zGMwSe8fhKelni5h6hXrXz52asr0k30BxWjf%0AWUn1uTInwVjWGy9B5j3mZlVDotFbvVAZgtR0IoFwihPl4VZd9oS13l%2BhMfrTy1YZ%0A8xFNg8ZqUQ0lSmKfOVqSBT0lP8tM8LuGxgY4cWluhsAQxR5Nl7wkundnqjcwEDDu%0AJz2rD54St1EZYGLDJZSfC7mpG2PgodsdeopQCTyFhHWa8s3caZ40GFOwaR%2B%2F5%2BYF
%0A1oRvkR1Yr4qIS7KbX4xsaFfAA5b8QfLA74L05PAgDwKofam2GFAlAKHOcI6mexPq%0AaySON9MNdnXBNxs16mBJLzCX5ljQb0ilJildVEI3aVmABptM4ehEiw%3D%3D%0A-END+RSA+PRIVATE+KEY-%0A&password=test
>
> and the api fails with "Invalid Certificate format. Expected X509 certificate"
>
> Since all the tests pass, I am assuming a problem with the api encoding 
> format.
> Can someone point to a working api call for the same.
>
> Thanks,
> Saksham
>
>
> -Original Message-
> From: Sujaya Maiyya (Intern) [mailto:sujaya.mai...@citrix.com]
> Sent: Tuesday, June 3, 2014 2:36 PM
> To: dev@cloudstack.apache.org
> Cc: Vijay Venkatachalam
> Subject: Unable to upload SSL certificate
>
> Hi,
>I am tryi

RE: Unable to upload SSL certificate

2014-06-10 Thread Saksham Srivastava
Fixed the issue in CLOUDSTACK-6864
Now we should not require double encoding in the API.

Thanks,
Saksham

-Original Message-
From: Saksham Srivastava 
Sent: Thursday, June 5, 2014 7:54 PM
To: 'Syed Ahmed'
Cc: Vijay Venkatachalam; dev@cloudstack.apache.org
Subject: RE: Unable to upload SSL certificate

Syed,

The certificate in the mentioned call is already UTF-8 encoded of the raw 
plain-text certificate.
To make the api work I had to doubly encode the cert and key .

I guess it will be good to have this mentioned in the FS/docs as there is no UI 
for this and also a sample api call can help a lot.

Thanks,
Saksham 

-Original Message-
From: Syed Ahmed [mailto:sah...@cloudops.com]
Sent: Thursday, June 5, 2014 6:23 AM
To: Saksham Srivastava
Cc: Vijay Venkatachalam; dev@cloudstack.apache.org
Subject: Re: Unable to upload SSL certificate

Can you try to encode the certificate before passing it as the param?

-Syed

On Wed 04 Jun 2014 09:01:19 AM EDT, Saksham Srivastava wrote:
> Adding Syed,
>
> I debugged the issue and here are my findings:
>
> The api is failing at CertServiceimpl: parseCertificate()
>
> return (Certificate) certPem.readObject();
>
> readObject method is failing.
>
> I tried to use the certificate used in the test 
> runUploadSslCertSelfSignedWithPassword and other tests in 
> CertServiceTest.java The following is the api call:
>
> http://10.x.x.x:8096/client/api?command=uploadSslCert&certificate=
> -BEGIN+CERTIFICATE-%0AMIIDBjCCAe4CCQD5Q6qF5dVV0jANBgkqhkiG9w0BAQUF
> ADBFMQswCQYDVQQGEwJB%0AVTETMBEGA1UECAwKU29tZS1TdGF0ZTEhMB8GA1UECgwYSW5
> 0ZXJuZXQgV2lkZ2l0%0AcyBQdHkgTHRkMB4XDTEzMTAyMTEzNTgwNFoXDTE0MTAyMTEzNT
> gwNFowRTELMAkG%0AA1UEBhMCQVUxEzARBgNVBAgMClNvbWUtU3RhdGUxITAfBgNVBAoMG
> EludGVybmV0%0AIFdpZGdpdHMgUHR5IEx0ZDCCASIwDQYJKoZIhvcNAQEBBQADggEPADCC
> AQoCggEB%0AAN%2F7lJtiEs68IC1ZPxY9NA34z9T4AU4LPS%2FkbQtuxx4X72XOBy%2By0
> cB%2FqdMD7JNV%0Ah8Mq4URDljhSDyVPdH%2F%2BjQr%2B7kWx2gNe2R%2FDCnd%2FmeVw
> wU30JJvpGVZXt%2BMTef5N%0AQAbSfDMsuT4FaUY80InbDd24HelrjwunPdY9wwKXO6zL2
> fLjyDRediiydxcx18Vb%0ADq1cm7DRi4mNkmA3RwBQMhxGp3VsfXJ4Hy2WTRCCCxWHZphA
> h3EUJGK3idum6%2F7j%0AHbAwpM%2Ft1kNWN8PZiYDZ1HbccgjmqB7Cub10BfB9g1RByiQ
> %2FC87o5cKtQha3uuXR%0AiBcHISoDydQrgxKgUpiqEF0CAwEAATANBgkqhkiG9w0BAQUF
> AAOCAQEASvulIaVb%0Azh8z2TysE6RFoYTAYIRXghFrmqCUyyQmUVTvs6vN8iaSXr%2BWM
> QJcpgXewWcFrDhr%0AmIcyRCvF91ZYb7q6lMZFSpE6u%2FSUGIEtxGUDAfbkbQdKYmrMcb
> ggUUIvSzgUFisO%0A
Kr0H9PEO4AWtCCrtOJFc7jgu03Sv06wDxn9ghkyiBRnVkbAhoKfKnI179yKruJWR%0AA3ieEj0eFoUbeSH8hDkToj4ynpkAvEGoHjHG9j%2B8FJxy%2FPTjkyVPl1ykTs%2B2Jc1B%0ASnx8f2afdTenPWyyBm3wFuRZjEAJJLUO0kxM7E8hAwhGsr%2BXYanwcr1oA1dz6M3f%0Acq26lpjTH5ITwQ%3D%3D%0A-END+CERTIFICATE-%0A&privatekey=-BEGIN+RSA+PRIVATE+KEY-%0AProc-Type%3A+4%2CENCRYPTED%0ADEK-Info%3A+DES-EDE3-CBC%2CCCA6E4CB4C4039DD%0A%0ATaVCJtB0dE9xTZbX7GOaGJwwGHVAMjU1GbRIHf0jODdP%2BquZvbjklNqsw8Ozlia9%0Aq%2FG%2BUqtRJGlIPPLpce0YCrTo0P3eixZdMs0%2BhioAEJ4OLtL0SAC6b8q%2FgB6HRfAx%0ABvNg%2BumTqeF9YB68Tcuv%2F2g4VGKiaePQACyOzMdf7lGY7ojxoJCYZa1mfKb7jWrg%0AFLwmTtLLhNjb6CnOKo3klIef3A6zdutpgxF1gARzdRyXg4qCA3boYnwEptTOlJFu%0AovxbhDG9iuYYr4gXYSs1pLYptEC8J6iWpG%2Fqzkwfr4l5Cfg5uF00bbxQE5%2BWeRaj%0AYFicvXjB%2FkcoFZuCL7M%2FYRXYxkJ%2FEZ19xI9HZNBQ4L738StkSBKL4OhpF%2FqgYZ2y%0AZLRV6XT4AijUA0Ef7YTuUsTL7Qt9drj09gCtAzXTA7gpZBn5SqT9kWhuwSzY302l%0AKF8DIC6A52igk2QKPLbleM%2FV8eCu6n%2BJ4uF%2B0GwVRROuG7ThxAQiUlJKhoEYrndL%0AnzT7jHVLftjilhVWFu2On62bRf5t1QZuob%2B1AdK0ukvEI
VsYnN4bnlAkc99Wi6C0%0AZJd9qW5L4A9XAC2gcjr3m0Rzw3RO%2Bk17faR8YfmTuJvGyBf5fnrSFoNkrninXQXp%0Ask0ajRi4PJ4XTswLyxjWRSt3egNsZBSKnVCibca%2FQoDEdZHSKXo2FlYiUYx8JHQX%0ASPUsLl9OQKC1W8%2F%2BReryqBLHCkiGEsvT8gVaXga0uhVaqe%2BPaVur2tbOHl4yCysC%0A%2BZlnKwsC84LQsUvpENdCh%2BD7E1I1Rao9IJMR6q9azKq8Ck63cOJ1fA9xSnxJGoCA%0AIlGLttlXrR32EtzYwEnlqf1nI%2FIqNQrAXQKrP5VPzHsgMFu5uD4OEZa92Q5cVTsz%0Aap%2F1UEqiJVYUt6nuA%2BaqOUlyjC0oNtYL%2FVO4DbHTFcHa8SI2cPSS6ebPMWPGHjUm%0Al9bWa6Q9iyplCYS6hinAVsAaLVjPi1Eu9Pc8rxFCmoiJYJju5NZuGI5UBK64dqcX%0AT6trWl0kB8QY63JtnrZaoStoSPImV5KVseUKDV8TM3Y76h1nLV3MSmAD1ivk9oKs%0AVKeVrDhZBWUq9Dqre%2F%2BlVGO0a2wo5VTR8hfpf8QkODPLeyNZNdfGKzkkFLuXa8V5%0AELhLQJ3FnbEU3NEvMwikV9MhP%2FELPTkZwJr%2FNKv%2B9JLs9eXtwz29I%2FQ8byQVrCCs%0AhAuDl0zHGRnqdpdSImeS2EXGx631zGMwSe8fhKelni5h6hXrXz52asr0k30BxWjf%0AWUn1uTInwVjWGy9B5j3mZlVDotFbvVAZgtR0IoFwihPl4VZd9oS13l%2BhMfrTy1YZ%0A8xFNg8ZqUQ0lSmKfOVqSBT0lP8tM8LuGxgY4cWluhsAQxR5Nl7wkundnqjcwEDDu%0AJz2rD54St1EZYGLDJZSfC7mpG2PgodsdeopQCTyFhHWa8s3caZ40GFOwaR%2B%2F5%2BYF
%0A1oRvkR1Yr4qIS7KbX4xsaFfAA5b8QfLA74L05PAgDwKofam2GFAlAKHOcI6mexPq%0AaySON9MNdnXBNxs16mBJLzCX5ljQb0ilJildVEI3aVmABptM4ehEiw%3D%3D%0A-END+RSA+PRIVATE+KEY-%0A&password=test
>
> and the api fails with "Invalid Certificate format. Expected X509 certificate"
>
> Since all the tests pass, I am assuming a problem with the api encoding 
> format.
> Can someone point to a working api call for the same.
>
> Thanks,
> Sa

[ACS44] Cherry pick request

2014-06-11 Thread Saksham Srivastava
Hi Daan,

Request you to cherry-pick the following commits to 4.4:

c5ee5ad5c828d9f0b128e3d7280a30dcf717e045   -   CLOUDSTACK-6864
5bcd017de6f421a6125406120b39fb8602276dc7   -CLOUDSTACK-6654
f14f36170e94c0184ade28a50226b17d25ecf57c-CLOUDSTACK-6812

Thanks,
Saksham


RE: [ANNOUNCE] Saksham Srivastava as committer

2014-06-17 Thread Saksham Srivastava
Thanks again :)

-Original Message-
From: Radhika Puthiyetath [mailto:radhika.puthiyet...@citrix.com] 
Sent: Tuesday, June 17, 2014 10:43 PM
To: dev@cloudstack.apache.org
Subject: RE: [ANNOUNCE] Saksham Srivastava as committer

I am too late to wish you on ML. Congrats

Welcome aboard, and don't forget to drive the BLR Meetup group..:-)

-Original Message-
From: sebgoa [mailto:run...@gmail.com] 
Sent: Wednesday, May 28, 2014 11:48 PM
To: dev@cloudstack.apache.org
Subject: [ANNOUNCE] Saksham Srivastava as committer

The Project Management Committee (PMC) for Apache CloudStack has asked Saksham 
Srivastava to become a committer and we are pleased to announce that he has 
accepted.

Being a committer allows many contributors to contribute more autonomously. For 
developers, it makes it easier to submit changes and eliminates the need to 
have contributions reviewed via the patch submission process. Whether 
contributions are development-related or otherwise, it is a recognition of a 
contributor's participation in the project and commitment to the project and 
the Apache Way.

Please join me in congratulating Saksham,


-Sebastien, on behalf of the CloudStack PMC


RE: "Reset VM" and it's gone - how do I get rid of this button??

2014-06-18 Thread Saksham Srivastava
Some changes came as part of this : 
https://issues.apache.org/jira/browse/CLOUDSTACK-6272

May give you some pointers. Brian/Jessica can be of help.

Thanks,
Saksham

-Original Message-
From: Nux! [mailto:n...@li.nux.ro] 
Sent: Wednesday, June 18, 2014 4:27 PM
To: dev@cloudstack.apache.org
Subject: "Reset VM" and it's gone - how do I get rid of this button??

Hi,

A colleague just wiped out a VM because he thought that buttong reboots the 
virtual machine...

Is there any way I can butcher the UI and remove that button or at least rename 
it to "Reinstall VM" or similar?

--
Sent from the Delta quadrant using Borg technology!

Nux!
www.nux.ro



RE: 431: Unable to execute API command listnics due to invalid value

2014-06-23 Thread Saksham Srivastava
Works on  ACS 4.4 (Make sure you are passing the correct vm id):

#list nics virtualmachineid=d6c6b69c-d162-4fe8-a5cc-fd09ea32d525
count = 1
nic:
id = 8f15c1a0-d6b2-4eae-849e-1496747b22d9
deviceid = 0
gateway = 10.0.64.1
ipaddress = 10.0.65.178
isdefault = True
macaddress = 02:00:6e:f1:00:01
netmask = 255.255.240.0
networkid = e6e9ba59-2779-469b-9a1a-82dccd55d7f3
virtualmachineid = d6c6b69c-d162-4fe8-a5cc-fd09ea32d525


-Saksham

-Original Message-
From: Nux! [mailto:n...@li.nux.ro] 
Sent: Monday, June 23, 2014 1:58 PM
To: dev@cloudstack.apache.org
Subject: [cloudmonkey] 431: Unable to execute API command listnics due to 
invalid value

Hi,

I'm trying to list the nics of my virtualmachines (searching for some IP 
address) and for many of them I get this error:

"cloudmonkey list nics virtualmachineid=913303d6-6243-4b1a-8acb-254086d123b3
431: Unable to execute API command listnics due to invalid value. Invalid 
parameter virtualmachineid value=913303d6-6243-4b1a-8acb-254086d123b3 due to 
incorrect long value format, or entity does not exist or due to incorrect 
parameter annotation for the field in api cmd class."

The management server log shows:

Object entity uuid = 913303d6-6243-4b1a-8acb-254086d123b3 does not exist in the 
database.
Unable to execute API command listnics due to invalid value. Invalid parameter 
virtualmachineid value=913303d6-6243-4b1a-8acb-254086d123b3 due to incorrect 
long value format, or entity does not exist or due to incorrect parameter 
annotation for the field in api cmd class.

The UI however lists the said VM and its nics (and IPs) just fine. Anyone knows 
what could be going on?

This is ACS 4.3 KVM.

Lucian

--
Sent from the Delta quadrant using Borg technology!

Nux!
www.nux.ro



RE: [ANNOUNCE] Santhosh Edukulla as a committer...

2014-06-30 Thread Saksham Srivastava
Congrats Santhosh.

-Original Message-
From: Alex Huang [mailto:alex.hu...@citrix.com] 
Sent: Monday, June 30, 2014 9:55 PM
To: dev@cloudstack.apache.org
Subject: [ANNOUNCE] Santhosh Edukulla as a committer...

Hi All,

The Project Management Committee (PMC) for Apache CloudStack has asked Santhosh 
Edukulla to become a committer and we are pleased to announce that he has 
accepted.

Being a committer allows many contributors to contribute more autonomously. For 
developers, it makes it easier to submit changes and eliminates the need to 
have contributions reviewed via the patch submission process. Whether 
contributions are development-related or otherwise, it is a recognition of a 
contributor's participation in the project and commitment to the project and 
the Apache Way.

Please join me in congratulating Santhosh!

--Alex, on behalf of the CloudStack PMC


RE: Regarding UI for SSL termination/offloading feature

2014-07-03 Thread Saksham Srivastava
We also have few gaps in the FS.
There is no reference API in the FS which makes it difficult to use the feature 
given that there is no UI still.
Will update the FS in a couple of days.

Thanks,
Saksham 

-Original Message-
From: Rajesh Battala [mailto:rajesh.batt...@citrix.com] 
Sent: Friday, July 4, 2014 10:48 AM
To: dev@cloudstack.apache.org; Syed Ahmed
Subject: RE: Regarding UI for SSL termination/offloading feature

Sayed,
There is a bug I found in feature, I have fixed it and pushed to master. 
CLOUDSTACK-7037 - Unable to add new vm/service to existing LB rule of SSL 
protocol

Thanks
Rajesh Battala

-Original Message-
From: Rajesh Battala [mailto:rajesh.batt...@citrix.com]
Sent: Friday, July 4, 2014 8:09 AM
To: Syed Ahmed
Cc: dev@cloudstack.apache.org
Subject: RE: Regarding UI for SSL termination/offloading feature

Please do that. It will be great help to community so that no need to re-invent 
the UI for this feature.
I can test the UI part.

Thanks
Rajesh Battala

-Original Message-
From: Syed Ahmed [mailto:sah...@cloudops.com]
Sent: Thursday, July 3, 2014 11:26 PM
To: Rajesh Battala
Cc: dev@cloudstack.apache.org
Subject: Re: Regarding UI for SSL termination/offloading feature

Hey Rajesh,

I had the UI in my dev branch but could not send that for review as I got busy 
with other work. I will dig that code up and send the request sometime next 
week.

Thanks,
-Syed

On Wed 02 Jul 2014 03:23:20 AM EDT, Rajesh Battala wrote:
> Hi Syed,
>
> In FS, there are screenshots regarding the UI support for certificates 
> management for accounts.
>
> But in deployment(master) am not able to see any such UI.
>
> Is this a model or you have missed committing the changes.
>
> Thanks
>
> Rajesh Battala
>




RE: [ANNOUNCE] New PMC member: Animesh Chaturvedi

2013-10-22 Thread Saksham Srivastava
Congrats Animesh.

-Original Message-
From: chip.child...@sungard.com [mailto:chip.child...@sungard.com] On Behalf Of 
Chip Childers
Sent: Tuesday, October 22, 2013 12:31 AM
To: 
Subject: [ANNOUNCE] New PMC member: Animesh Chaturvedi

The Project Management Committee (PMC) for Apache CloudStack has asked Animesh 
Chaturvedi to join the PMC and we are pleased to announce that they have 
accepted.

Join me in congratulating Animesh!

-The CloudStack PMC


RE: Issue building Deb packages from source

2013-11-29 Thread Saksham Srivastava
Can you try replacing -Dnonoss with -Dnoredist

Thanks,
Saksham

-Original Message-
From: Vosbury, David [mailto:david.vosb...@systemsmadesimple.com] 
Sent: Friday, November 29, 2013 5:31 PM
To: dev@cloudstack.apache.org
Subject: Issue building Deb packages from source



 Original Message 
Subject: Issue building Deb packages from source
From: "Vosbury, David" 
To: d...@cloudsrack.apache.org
CC:

I'm not sure if this is a question for the users or the Dev list so I'm posting 
to both.

I'm new to building CloudStack from source. I'm having some difficulty creating 
my Deb packages. I'm trying to compile with the nonoss options. I've been going 
through the documentation for building from source and I'm using the nonoss 
option to get the vmware support. When following the build docs I get 
successful compiles when running mvn clean install -Dnonoss and when doing mvn 
-P deps -Dnonoss (although I do get a message at the end of the compile that it 
couldn't find the deps profile, but the compile shows successful). When I try 
to compile to my deb packages I get an error message at the end and It also 
doesn't look like the nonoss modules build. It looks like a default oss build. 
Here is the error messages I get back when trying to compile the debs. Please 
help as I have an upcoming deadline to get this CloudStack install up and 
running and this is really holding me up. It seems like maybe I need to change 
something in the configuration for the deb build, but I'm not sure where to do 
that. It also seems like the deb build is failing with the aws api module 
build. Is there a way to remove that from the build if that is the issue? I 
don't need aws support at this time. Is there an option I need to add when 
doing the deb build to get the nonoss modules to build? Anyway, here's the 
error message.



[INFO] --- maven-compiler-plugin:2.5.1:compile (default-compile) @ cloud-awsapi 

---

[INFO] Compiling 1296 source files to 
/home/dvosbury/apache-cloudstack-4.2.0-src  
  /awsapi/target/classes

[INFO] -

[ERROR] COMPILATION ERROR :

[INFO] -

[ERROR] error: error reading 
/home/dvosbury/.m2/repository/org/apache/axis2/mex/ 
   
1.5.4/mex-1.5.4-impl.jar; error in opening zip file

[ERROR] error: error reading 
/home/dvosbury/.m2/repository/org/apache/axis2/axis 
   
2-mtompolicy/1.5.4/axis2-mtompolicy-1.5.4.jar; error in opening zip file

[ERROR] error: error reading 
/home/dvosbury/.m2/repository/org/apache/ws/commons 
   
/axiom/axiom-dom/1.2.10/axiom-dom-1.2.10.jar; error in opening zip file

[ERROR] error: error reading 
/home/dvosbury/.m2/repository/org/opensaml/opensaml 
   
1/1.1/opensaml1-1.1.jar; error in opening zip file

[ERROR] error: error reading 
/home/dvosbury/.m2/repository/commons-lang/commons- 
   
lang/2.3/commons-lang-2.3.jar; error in opening zip file

[INFO] 5 errors

[INFO] -

[INFO] 

[INFO] Reactor Summary:

[INFO]

[INFO] Apache CloudStack . SUCCESS [1.890s]

[INFO] Apache CloudStack Utils ... SUCCESS [10.227s]

[INFO] Apache CloudStack API . SUCCESS [10.884s]

[INFO] Apache CloudStack Framework ... SUCCESS [0.072s]

[INFO] Apache CloudStack Framework - REST  SUCCESS [2.908s]

[INFO] Apache CloudStack Framework - IPC . SUCCESS [4.501s]

[INFO] Apache CloudStack Cloud Engine  SUCCESS [0.062s]

[INFO] Apache CloudStack Cloud Engine API  SUCCESS [5.064s]

[INFO] Apache CloudStack Cloud Engine Internal Components API  SUCCESS [1.810s]

[INFO] Apache CloudStack Cloud Engine Schema Component ... SUCCESS [9.314s]

[INFO] Apache CloudStack Core  SUCCESS [7.708s]

[INFO] Apache CloudStack Agents .. SUCCESS [5.966s]

[INFO] Apache CloudStack Framework - Jobs  SUCCESS [1.623s]

[INFO] Apache CloudStack Framework - Event Notification .. SUCCESS [1.682s]

[INFO] Apache CloudStack Server .. SUCCESS [18.616s]

[INFO] Apache CloudStack Usage Server  SUCCESS [5.502s

https://reviews.apache.org/ down ??

2013-12-06 Thread Saksham Srivastava
Is anyone else also having the same problem?

Thanks,
Saksham



RE: https://reviews.apache.org/ down ??

2013-12-06 Thread Saksham Srivastava
Can someone kindly look into this.

Thanks,
Saksham

-Original Message-
From: Syed Ahmed [mailto:sah...@cloudops.com] 
Sent: Friday, December 06, 2013 3:07 PM
To: dev@cloudstack.apache.org
Cc: Saksham Srivastava
Subject: Re: https://reviews.apache.org/ down ??

Me too. I get a 502 proxy error.


On Fri 06 Dec 2013 04:32:19 AM EST, Saksham Srivastava wrote:
> Is anyone else also having the same problem?
>
> Thanks,
> Saksham
>
>




RE: https://reviews.apache.org/ down ??

2013-12-06 Thread Saksham Srivastava
Also raised https://issues.apache.org/jira/browse/INFRA-7076


-Original Message-
From: Radhika Puthiyetath [mailto:radhika.puthiyet...@citrix.com] 
Sent: Friday, December 06, 2013 3:41 PM
To: dev@cloudstack.apache.org
Cc: Syed Ahmed
Subject: RE: https://reviews.apache.org/ down ??

http://monitoring.apache.org/status/ shows Red. They should fix this soon.

-Original Message-
From: Hugo Trippaers [mailto:trip...@gmail.com] 
Sent: Friday, December 06, 2013 3:34 PM
To: dev@cloudstack.apache.org
Cc: Syed Ahmed; dev@cloudstack.apache.org
Subject: Re: https://reviews.apache.org/ down ??

Saksham,

This is apache infrastructure, so not much we can do directly. Did you check if 
apache infra is aware of the problem?

Cheers,

Hugo

Sent from my iPhone

> On 6 dec. 2013, at 09:56, Saksham Srivastava  
> wrote:
> 
> Can someone kindly look into this.
> 
> Thanks,
> Saksham
> 
> -Original Message-
> From: Syed Ahmed [mailto:sah...@cloudops.com] 
> Sent: Friday, December 06, 2013 3:07 PM
> To: dev@cloudstack.apache.org
> Cc: Saksham Srivastava
> Subject: Re: https://reviews.apache.org/ down ??
> 
> Me too. I get a 502 proxy error.
> 
> 
>> On Fri 06 Dec 2013 04:32:19 AM EST, Saksham Srivastava wrote:
>> Is anyone else also having the same problem?
>> 
>> Thanks,
>> Saksham
> 
> 


RE: https://reviews.apache.org/ down ??

2013-12-06 Thread Saksham Srivastava
The issue is fixed now:
=

 [ 
https://issues.apache.org/jira/browse/INFRA-7076?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

jan iversen closed INFRA-7076.
--

Resolution: Fixed
  Assignee: jan iversen

/dev/sda1 was "inconsistent", a manual fsck on the console solved the problem.

Site is up and running.

syslog has not been examined.

> Apache review board is inaccessible
> ---
>
> Key: INFRA-7076
> URL: https://issues.apache.org/jira/browse/INFRA-7076
> Project: Infrastructure
>  Issue Type: Bug
>  Components: ReviewBoard
>    Reporter: Saksham Srivastava
>Assignee: jan iversen
>Priority: Critical
>
> https://reviews.apache.org/ is showing proxy server error.



--
This message was sent by Atlassian JIRA
(v6.1#6144)

-Original Message-
From: Hugo Trippaers [mailto:trip...@gmail.com] 
Sent: Friday, December 06, 2013 4:00 PM
To: dev@cloudstack.apache.org
Cc: dev@cloudstack.apache.org; Syed Ahmed
Subject: Re: https://reviews.apache.org/ down ??

Great!

Cheers,
Hugo

Sent from my iPhone

> On 6 dec. 2013, at 10:17, Saksham Srivastava  
> wrote:
> 
> Also raised https://issues.apache.org/jira/browse/INFRA-7076
> 
> 
> -Original Message-
> From: Radhika Puthiyetath [mailto:radhika.puthiyet...@citrix.com] 
> Sent: Friday, December 06, 2013 3:41 PM
> To: dev@cloudstack.apache.org
> Cc: Syed Ahmed
> Subject: RE: https://reviews.apache.org/ down ??
> 
> http://monitoring.apache.org/status/ shows Red. They should fix this soon.
> 
> -Original Message-
> From: Hugo Trippaers [mailto:trip...@gmail.com] 
> Sent: Friday, December 06, 2013 3:34 PM
> To: dev@cloudstack.apache.org
> Cc: Syed Ahmed; dev@cloudstack.apache.org
> Subject: Re: https://reviews.apache.org/ down ??
> 
> Saksham,
> 
> This is apache infrastructure, so not much we can do directly. Did you check 
> if apache infra is aware of the problem?
> 
> Cheers,
> 
> Hugo
> 
> Sent from my iPhone
> 
>> On 6 dec. 2013, at 09:56, Saksham Srivastava  
>> wrote:
>> 
>> Can someone kindly look into this.
>> 
>> Thanks,
>> Saksham
>> 
>> -Original Message-
>> From: Syed Ahmed [mailto:sah...@cloudops.com] 
>> Sent: Friday, December 06, 2013 3:07 PM
>> To: dev@cloudstack.apache.org
>> Cc: Saksham Srivastava
>> Subject: Re: https://reviews.apache.org/ down ??
>> 
>> Me too. I get a 502 proxy error.
>> 
>> 
>>> On Fri 06 Dec 2013 04:32:19 AM EST, Saksham Srivastava wrote:
>>> Is anyone else also having the same problem?
>>> 
>>> Thanks,
>>> Saksham
>> 
>> 


Re: Review Request 14124: CLOUDSTACK-4622 : If a VM from guest network is added to network tier of VPC then IP reservation allows the CIDR to be a superset of Network CIDR for that VPC tier

2013-12-09 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/14124/
---

(Updated Dec. 9, 2013, 11:30 a.m.)


Review request for cloudstack and Sateesh Chodapuneedi.


Changes
---

Updating a three month old patch as it was not applying cleanly on master.


Bugs: CLOUDSTACK-4622
https://issues.apache.org/jira/browse/CLOUDSTACK-4622


Repository: cloudstack-git


Description
---

Add a new utility method for comparing 2 CIDRs.
The method takes in 2 cidrs, cidrA and cidrB and returns true if cidrA's IP 
range is equal or a subset of cidrB's IP range.


Diffs (updated)
-

  server/src/com/cloud/network/NetworkServiceImpl.java 6855587 
  utils/src/com/cloud/utils/net/NetUtils.java c0c792f 
  utils/test/com/cloud/utils/net/NetUtilsTest.java c7407bf 

Diff: https://reviews.apache.org/r/14124/diff/


Testing
---

Added unit test for the utility.
Tested locally.
Build is successful.
Patch applies cleanly.


Thanks,

Saksham Srivastava



Faulty method isNetworkAWithinNetworkB ?

2013-12-13 Thread Saksham Srivastava
Hi,

I encountered a method isNetworkAWithinNetworkB(cidrA, cidrB) in NetUtils.java 
which should return true if cidrA is a subset of cidrB.
The method returns flawed output in many scenarios. After unittesting it I 
found :

isNetworkAWithinNetworkB("10.1.1.0/24", "10.1.1.0/25") returns true
isNetworkAWithinNetworkB("10.1.1.0/25", "10.1.1.0/24") returns true
isNetworkAWithinNetworkB("10.1.1.0/23", "10.1.1.0/22") returns true
isNetworkAWithinNetworkB("10.1.1.0/22", "10.1.1.0/23") returns true

Due to this I am able to create VPC tiers with cidr 10.1.0.0/24 even when the 
VPC super cidr has been defined as 10.1.1.0/25
IMO the simpler/cleaner way to compare cidrs should be to compare the 
respective IP ranges. I have an old patch [1] in RB which uses the IP ranges to 
compare 2 cidrs.
We could leverage that to replace isNetworkAWithinNetworkB() or in case of any 
other suggestions please share.

Thanks,
Saksham

[1] https://reviews.apache.org/r/14124/diff/#index_header



Review Request 16361: CLOUDSTACK-5535: Do not allow addNetwork to create NIC across VPC tiers and Isolated Networks

2013-12-18 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16361/
---

Review request for cloudstack and Alena Prokharchyk.


Bugs: CLOUDSTACK-5535
https://issues.apache.org/jira/browse/CLOUDSTACK-5535


Repository: cloudstack-git


Description
---

addNetworkToVM allows adding any network to VM.
Ideally a VM running in isolated Guest Network should not be able to add a VPC 
tier.
A VM running in VPC tier should not be allowed to add another tier
A VM running in VPC tier should not be allowed to add another isolated guest 
network


Diffs
-

  server/src/com/cloud/vm/UserVmManagerImpl.java 3ad49d8 

Diff: https://reviews.apache.org/r/16361/diff/


Testing
---

VM having a nic in isolated guest network cannot add a VPC tier.
VM having a nic in one VPC tier cannot add another VPC tier.
VM having a nic in a VPC tier cannot add a isolated guest network.


Thanks,

Saksham Srivastava



Re: Review Request 14124: CLOUDSTACK-4622 : If a VM from guest network is added to network tier of VPC then IP reservation allows the CIDR to be a superset of Network CIDR for that VPC tier

2013-12-24 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/14124/
---

(Updated Dec. 24, 2013, 9:18 a.m.)


Review request for cloudstack and Sateesh Chodapuneedi.


Changes
---

Modified isNetworkAWithinNetworkB to compare IP ranges.


Bugs: CLOUDSTACK-4622
https://issues.apache.org/jira/browse/CLOUDSTACK-4622


Repository: cloudstack-git


Description
---

Add a new utility method for comparing 2 CIDRs.
The method takes in 2 cidrs, cidrA and cidrB and returns true if cidrA's IP 
range is equal or a subset of cidrB's IP range.


Diffs (updated)
-

  utils/src/com/cloud/utils/net/NetUtils.java f6f6285 
  utils/test/com/cloud/utils/net/NetUtilsTest.java c7407bf 

Diff: https://reviews.apache.org/r/14124/diff/


Testing
---

Added unit test for the utility.
Tested locally.
Build is successful.
Patch applies cleanly.


Thanks,

Saksham Srivastava



Re: Review Request 14124: CLOUDSTACK-4622 : If a VM from guest network is added to network tier of VPC then IP reservation allows the CIDR to be a superset of Network CIDR for that VPC tier

2013-12-24 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/14124/
---

(Updated Dec. 24, 2013, 9:20 a.m.)


Review request for cloudstack, Jayapal Reddy and Sateesh Chodapuneedi.


Bugs: CLOUDSTACK-4622
https://issues.apache.org/jira/browse/CLOUDSTACK-4622


Repository: cloudstack-git


Description
---

Add a new utility method for comparing 2 CIDRs.
The method takes in 2 cidrs, cidrA and cidrB and returns true if cidrA's IP 
range is equal or a subset of cidrB's IP range.


Diffs
-

  utils/src/com/cloud/utils/net/NetUtils.java f6f6285 
  utils/test/com/cloud/utils/net/NetUtilsTest.java c7407bf 

Diff: https://reviews.apache.org/r/14124/diff/


Testing
---

Added unit test for the utility.
Tested locally.
Build is successful.
Patch applies cleanly.


Thanks,

Saksham Srivastava



RE: Faulty method isNetworkAWithinNetworkB ?

2013-12-24 Thread Saksham Srivastava
Thanks Jayapal for reviewing.

I have updated the patch.
Now isNetworkAWithinNetworkB method uses IP ranges of cidrs  for comparison.
Also updated the unittests for the same.

Thanks,
Saksham

-Original Message-
From: Jayapal Reddy Uradi [mailto:jayapalreddy.ur...@citrix.com] 
Sent: Monday, December 23, 2013 6:03 PM
To: 
Subject: Re: Faulty method isNetworkAWithinNetworkB ?

Hi Saksham,

Always the higher suffix cidr will be in lower suffix cidr.
10.1.1.0/24 will have 256 addresses and 10.1.1.0/25 will have 128 addresses[1].

/25 will be completely in /24 but not wise versa. 

The below are incorrect.
> isNetworkAWithinNetworkB("10.1.1.0/24", "10.1.1.0/25") returns true 
> isNetworkAWithinNetworkB("10.1.1.0/22", "10.1.1.0/23") returns true

I think you can change isNetworkAWithinNetworkB method to compare respective ip 
ranges for cidrs.

What about changing method name isNetworkACompletelyWithinNetworkB() ?

[1]https://www.dan.me.uk/ipsubnets?ip=10.1.1.0


Thanks,
Jayapal

On 13-Dec-2013, at 4:49 PM, Saksham Srivastava  
wrote:

> Hi,
> 
> I encountered a method isNetworkAWithinNetworkB(cidrA, cidrB) in 
> NetUtils.java which should return true if cidrA is a subset of cidrB.
> The method returns flawed output in many scenarios. After unittesting it I 
> found :
> 
> isNetworkAWithinNetworkB("10.1.1.0/24", "10.1.1.0/25") returns true 
> isNetworkAWithinNetworkB("10.1.1.0/25", "10.1.1.0/24") returns true 
> isNetworkAWithinNetworkB("10.1.1.0/23", "10.1.1.0/22") returns true 
> isNetworkAWithinNetworkB("10.1.1.0/22", "10.1.1.0/23") returns true
> 
> Due to this I am able to create VPC tiers with cidr 10.1.0.0/24 even 
> when the VPC super cidr has been defined as 10.1.1.0/25 IMO the 
> simpler/cleaner way to compare cidrs should be to compare the respective IP 
> ranges. I have an old patch [1] in RB which uses the IP ranges to compare 2 
> cidrs.
> We could leverage that to replace isNetworkAWithinNetworkB() or in case of 
> any other suggestions please share.
> 
> Thanks,
> Saksham
> 
> [1] https://reviews.apache.org/r/14124/diff/#index_header
> 



Re: Review Request 16456: prepended the description of storage.overprovisioning.factor with NFS only as this feature works only with NFS

2013-12-24 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16456/#review30853
---


Rajani, storage.overprovisioning.factor works for VMFS also.
Please have a look at https://issues.apache.org/jira/browse/CLOUDSTACK-5061

- Saksham Srivastava


On Dec. 24, 2013, 1:20 p.m., Rajani Karuturi wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16456/
> ---
> 
> (Updated Dec. 24, 2013, 1:20 p.m.)
> 
> 
> Review request for cloudstack, Abhinandan Prateek and Jayapal Reddy.
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> ---
> 
> prepended the description of storage.overprovisioning.factor with NFS 
> only as this feature works only with NFS
> 
> 
> Diffs
> -
> 
>   engine/components-api/src/com/cloud/capacity/CapacityManager.java 0cda826 
>   setup/db/db/schema-421to430.sql 574f510 
> 
> Diff: https://reviews.apache.org/r/16456/diff/
> 
> 
> Testing
> ---
> 
> manually tested
> 
> 
> Thanks,
> 
> Rajani Karuturi
> 
>



Re: Review Request 14124: CLOUDSTACK-4622 : If a VM from guest network is added to network tier of VPC then IP reservation allows the CIDR to be a superset of Network CIDR for that VPC tier

2013-12-30 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/14124/
---

(Updated Dec. 30, 2013, 3:22 p.m.)


Review request for cloudstack, Jayapal Reddy and Sateesh Chodapuneedi.


Bugs: CLOUDSTACK-4622
https://issues.apache.org/jira/browse/CLOUDSTACK-4622


Repository: cloudstack-git


Description
---

Add a new utility method for comparing 2 CIDRs.
The method takes in 2 cidrs, cidrA and cidrB and returns true if cidrA's IP 
range is equal or a subset of cidrB's IP range.


Diffs (updated)
-

  utils/src/com/cloud/utils/net/NetUtils.java a315b93 
  utils/test/com/cloud/utils/net/NetUtilsTest.java 3cfc98f 

Diff: https://reviews.apache.org/r/14124/diff/


Testing
---

Added unit test for the utility.
Tested locally.
Build is successful.
Patch applies cleanly.


Thanks,

Saksham Srivastava



RE: ACS4.2 db goes for a toss if no netmask is specified while creating a virtual Network

2013-12-30 Thread Saksham Srivastava
In general, if you do not specify a  gateway and netmask, the values will be 
taken from the zone level settings.
Check listZones to see your configuration.

Thanks,
Saksham

-Original Message-
From: Vinod Nair [mailto:vinodn...@juniper.net] 
Sent: Tuesday, December 31, 2013 6:29 AM
To: dev@cloudstack.apache.org
Subject: RE: ACS4.2 db goes for a toss if no netmask is specified while 
creating a virtual Network

Hi 

Root cause is that ACS is allowing to create a VN without a net mask value, 
Whereas list networks command is checking for if cidr value is present or not 
for a network while iterating all networks. If it finds a network without cidr 
it throws Exception and  returns empty

Thanks
Vinod

-Original Message-
From: Vinod Nair [mailto:vinodn...@juniper.net] 
Sent: Monday, December 30, 2013 11:26 AM
To: dev@cloudstack.apache.org
Subject: ACS4.2 db goes for a toss if no netmask is specified while creating a 
virtual Network

Hi

I have ACS4.2 , If I try creating a virtual network without specifying  a 
netmask, the database goes for a toss..  only way to recover is to delete  the 
entry from the  database manually  or set the CIDR manually as it is set as 
NULL. Is there a fix available for this issue.



# cloudmonkey
? Apache CloudStack ?? cloudmonkey 5.0.0. Type help or ? to list commands.

> list networks
: None


select * from networks where id=207;
+-+--+--+--+--+---+---+-+--+--+-+-++--+-+-+---++--+--+---++--++--++--+-+-+---++-+--+--+-++
| id  | name | uuid | display_text | 
traffic_type | broadcast_domain_type | broadcast_uri | gateway | cidr | mode | 
network_offering_id | physical_network_id | data_center_id | guru_name| 
state   | related | domain_id | account_id | dns1 | dns2 | guru_data | 
set_fields | acl_type | network_domain | reservation_id   | 
guest_type | restart_required | created | removed | 
specify_ip_ranges | vpc_id | ip6_gateway | ip6_cidr | network_cidr | 
display_network | network_acl_id |
+-+--+--+--+--+---+---+-+--+--+-+-++--+-+-+---++--+--+---++--++--++--+-+-+---++-+--+--+-++
| 207 | Vn1  | d1e6ae13-d750-4682-948c-c6545d6c9ace | vn1  | Guest  
  | Lswitch   | NULL  | NULL| NULL | Dhcp | 
 15 | 200 |  1 | ContrailGuru | Implemented |   
  207 | 1 |  2 | NULL | NULL | NULL  |  0 | Account 
 | NULL   | e7f881be-c9d8-4ff1-8fce-26d207426b45 | Isolated   | 
   0 | 2013-12-30 16:10:46 | NULL| 0 |   NULL | NULL
| NULL | NULL |   1 |   NULL |
+-+--+--+--+--+---+---+-+--+--+-+-++--+-+-+---++--+--+---++--++--++--+-+-+---++-+--+--+-++
1 row in set (0.00 sec)



Thanks
Vinod




Review Request 16540: CLOUDSTACK-5692: cleanup API response for primary/secondary storages

2013-12-31 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16540/
---

Review request for cloudstack and Devdeep Singh.


Bugs: CLOUDSTACK-5692
https://issues.apache.org/jira/browse/CLOUDSTACK-5692


Repository: cloudstack-git


Description
---

Cleanup the API response while listing primary/secondary stores while using 
cifs.


Diffs
-

  server/src/com/cloud/api/query/dao/ImageStoreJoinDaoImpl.java 8022871 
  server/src/com/cloud/api/query/dao/StoragePoolJoinDaoImpl.java 4d2aac2 

Diff: https://reviews.apache.org/r/16540/diff/


Testing
---

Tested locally.


Thanks,

Saksham Srivastava



RE: ACS 4.2: list networks returns empty, if a VN is created without net mask

2014-01-03 Thread Saksham Srivastava
This could be a bug, go ahead a file an issue.

Thanks,
Saksham

-Original Message-
From: Vinod Nair [mailto:vinodn...@juniper.net] 
Sent: Friday, January 03, 2014 5:53 AM
To: dev@cloudstack.apache.org
Subject: ACS 4.2: list networks returns empty, if a VN is created without net 
mask 

Hi Saksham 

The issue here is if we specify the gateway without specifying the net-mask , 
the networks table gets updated with the VN name , but in db  both gateway cidr 
are empty .  list network bails out because if this.


> list zones
count = 1
zone:
name = default
id = 9b5dd877-1fb1-4499-8fec-2baea16ce973
allocationstate = Enabled
dhcpprovider = VirtualRouter
dns1 = 10.84.5.100
dns2 =
domain = ROOT
guestcidraddress = 10.1.0.0/24
internaldns1 = 10.84.5.100
internaldns2 =
ip6dns1 =
ip6dns2 =
localstorageenabled = False
networktype = Advanced
securitygroupsenabled = False
zonetoken = 63b953cc-1dbf-3a03-8aea-ce96319173cc


mysql> select id,name,cidr,gateway  from networks;
+-+--++-+
| id  | name | cidr   | gateway |
+-+--++-+
| 200 | NULL | NULL   | NULL|
| 201 | NULL | NULL   | NULL|
| 202 | NULL | 169.254.0.0/16 | 169.254.0.1 |
| 203 | NULL | NULL   | NULL|
| 204 | VN1  | 10.1.1.0/24| 10.1.1.254  |
| 205 | VN2  | NULL   | NULL|
+-+--++-+



Thanks
Vinod
-Original Message-
From: Saksham Srivastava [mailto:saksham.srivast...@citrix.com] 
Sent: Monday, December 30, 2013 10:21 PM
To: dev@cloudstack.apache.org
Subject: RE: ACS4.2 db goes for a toss if no netmask is specified while 
creating a virtual Network

In general, if you do not specify a  gateway and netmask, the values will be 
taken from the zone level settings.
Check listZones to see your configuration.

Thanks,
Saksham

-Original Message-
From: Vinod Nair [mailto:vinodn...@juniper.net] 
Sent: Tuesday, December 31, 2013 6:29 AM
To: dev@cloudstack.apache.org
Subject: RE: ACS4.2 db goes for a toss if no netmask is specified while 
creating a virtual Network

Hi 

Root cause is that ACS is allowing to create a VN without a net mask value, 
Whereas list networks command is checking for if cidr value is present or not 
for a network while iterating all networks. If it finds a network without cidr 
it throws Exception and  returns empty

Thanks
Vinod

-Original Message-
From: Vinod Nair [mailto:vinodn...@juniper.net] 
Sent: Monday, December 30, 2013 11:26 AM
To: dev@cloudstack.apache.org
Subject: ACS4.2 db goes for a toss if no netmask is specified while creating a 
virtual Network

Hi

I have ACS4.2 , If I try creating a virtual network without specifying  a 
netmask, the database goes for a toss..  only way to recover is to delete  the 
entry from the  database manually  or set the CIDR manually as it is set as 
NULL. Is there a fix available for this issue.



# cloudmonkey
? Apache CloudStack ?? cloudmonkey 5.0.0. Type help or ? to list commands.

> list networks
: None


select * from networks where id=207;
+-+--+--+--+--+---+---+-+--+--+-+-++--+-+-+---++--+--+---++--++--++--+-+-+---++-+--+--+-++
| id  | name | uuid | display_text | 
traffic_type | broadcast_domain_type | broadcast_uri | gateway | cidr | mode | 
network_offering_id | physical_network_id | data_center_id | guru_name| 
state   | related | domain_id | account_id | dns1 | dns2 | guru_data | 
set_fields | acl_type | network_domain | reservation_id   | 
guest_type | restart_required | created | removed | 
specify_ip_ranges | vpc_id | ip6_gateway | ip6_cidr | network_cidr | 
display_network | network_acl_id |
+-+--+--+--+--+---+---+-+--+--+-+-++--+-+-+---++--+--+---++--++--++--+-+-+---++-+--+--+-++
| 207 | Vn1  | d1e6ae13-d750-4682-948c-c6545d6c9ace | vn1  | Guest  
  | Lswitch   | NULL  | NULL| NULL | Dhcp | 
 15 | 200 |  1 | Con

Re: Review Request 14124: CLOUDSTACK-4622 : If a VM from guest network is added to network tier of VPC then IP reservation allows the CIDR to be a superset of Network CIDR for that VPC tier

2014-01-07 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/14124/
---

(Updated Jan. 7, 2014, 11:58 a.m.)


Review request for cloudstack, Jayapal Reddy and Sateesh Chodapuneedi.


Changes
---

Updating patch, resolving conflicts and adding more unit-tests.


Bugs: CLOUDSTACK-4622
https://issues.apache.org/jira/browse/CLOUDSTACK-4622


Repository: cloudstack-git


Description
---

Add a new utility method for comparing 2 CIDRs.
The method takes in 2 cidrs, cidrA and cidrB and returns true if cidrA's IP 
range is equal or a subset of cidrB's IP range.


Diffs (updated)
-

  utils/src/com/cloud/utils/net/NetUtils.java 266a5d1 
  utils/test/com/cloud/utils/net/NetUtilsTest.java b049516 

Diff: https://reviews.apache.org/r/14124/diff/


Testing
---

Added unit test for the utility.
Tested locally.
Build is successful.
Patch applies cleanly.


Thanks,

Saksham Srivastava



Re: Review Request 16361: CLOUDSTACK-5535: Do not allow addNetwork to create NIC across VPC tiers and Isolated Networks

2014-01-09 Thread Saksham Srivastava


> On Jan. 9, 2014, 12:39 a.m., Alena Prokharchyk wrote:
> > One more check is needed: don't let to add vm to VPC network if its already 
> > a part of another VPC network.

This check is already in place unless I am missing something:
if (existingNetwork.getVpcId() != null && network.getGuestType() != 
Network.GuestType.Shared) {
// If the vm is already in VPC and we try to add a new Non shared network (eg. 
VPC or Isolated Network), 
// then throw exception
}


- Saksham


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16361/#review31417
---


On Dec. 19, 2013, 5:25 a.m., Saksham Srivastava wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16361/
> ---
> 
> (Updated Dec. 19, 2013, 5:25 a.m.)
> 
> 
> Review request for cloudstack and Alena Prokharchyk.
> 
> 
> Bugs: CLOUDSTACK-5535
> https://issues.apache.org/jira/browse/CLOUDSTACK-5535
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> ---
> 
> addNetworkToVM allows adding any network to VM.
> Ideally a VM running in isolated Guest Network should not be able to add a 
> VPC tier.
> A VM running in VPC tier should not be allowed to add another tier
> A VM running in VPC tier should not be allowed to add another isolated guest 
> network
> 
> 
> Diffs
> -
> 
>   server/src/com/cloud/vm/UserVmManagerImpl.java 3ad49d8 
> 
> Diff: https://reviews.apache.org/r/16361/diff/
> 
> 
> Testing
> ---
> 
> VM having a nic in isolated guest network cannot add a VPC tier.
> VM having a nic in one VPC tier cannot add another VPC tier.
> VM having a nic in a VPC tier cannot add a isolated guest network.
> 
> 
> Thanks,
> 
> Saksham Srivastava
> 
>



RE: [ANNOUNCE] Rajani Karuturi as committer

2014-07-22 Thread Saksham Srivastava
Congrats Rajani.

-Original Message-
From: Prasanna Santhanam [mailto:t...@apache.org] 
Sent: Tuesday, July 22, 2014 11:53 AM
To: CloudStack Dev
Subject: [ANNOUNCE] Rajani Karuturi as committer

The Project Management Committee (PMC) for Apache CloudStack has asked Rajani 
Karuturi to become a committer and we are pleased to announce that she has 
accepted. Being a committer allows many contributors to contribute more 
autonomously. For developers, it makes it easier to submit changes and 
eliminates the need to have contributions reviewed via the patch submission 
process. Whether contributions are development-related or otherwise, it is a 
recognition of a contributor's participation in the project and commitment to 
the project and the Apache Way.

Please join me in congratulating Rajani

--
Prasanna., on behalf of the CloudStack PMC


Powered by BigRock.com



[DB-CHANGE] Infrastructure tab fails to load with db exception

2014-08-06 Thread Saksham Srivastava
I remember we used to follow the practice of informing others in case db 
changes are committed, but we do not do it anymore.
In case you are on dev setup on master branch post the following commit :
commit b9d834e83854009483f6d061f9996e5ffaa9b883
Author: Nitin Mehta 
Date:   Tue Aug 5 17:29:34 2014 -0700
CLOUDSTACK-4200: listSystemVMs API and listRouters API should return hypervisor 
property since dynamic scaling is not enabled for all the hypervisors and that 
action can be showed only for the hypervisors t

Update your database with :

DROP VIEW IF EXISTS `cloud`.`domain_router_view`;
CREATE VIEW `cloud`.`domain_router_view` AS
select
vm_instance.id id,
vm_instance.name name,
account.id account_id,
account.uuid account_uuid,
account.account_name account_name,
account.type account_type,
domain.id domain_id,
domain.uuid domain_uuid,
domain.name domain_name,
domain.path domain_path,
projects.id project_id,
projects.uuid project_uuid,
projects.name project_name,
vm_instance.uuid uuid,
vm_instance.created created,
vm_instance.state state,
vm_instance.removed removed,
vm_instance.pod_id pod_id,
vm_instance.instance_name instance_name,
host_pod_ref.uuid pod_uuid,
data_center.id data_center_id,
data_center.uuid data_center_uuid,
data_center.name data_center_name,
data_center.networktype data_center_type,
data_center.dns1 dns1,
data_center.dns2 dns2,
data_center.ip6_dns1 ip6_dns1,
data_center.ip6_dns2 ip6_dns2,
host.id host_id,
host.uuid host_uuid,
host.name host_name,
   host.hypervisor_type,
host.cluster_id cluster_id,
vm_template.id template_id,
vm_template.uuid template_uuid,
service_offering.id service_offering_id,
disk_offering.uuid service_offering_uuid,
disk_offering.name service_offering_name,
nics.id nic_id,
nics.uuid nic_uuid,
nics.network_id network_id,
nics.ip4_address ip_address,
nics.ip6_address ip6_address,
nics.ip6_gateway ip6_gateway,
nics.ip6_cidr ip6_cidr,
nics.default_nic is_default_nic,
nics.gateway gateway,
nics.netmask netmask,
nics.mac_address mac_address,
nics.broadcast_uri broadcast_uri,
nics.isolation_uri isolation_uri,
vpc.id vpc_id,
vpc.uuid vpc_uuid,
networks.uuid network_uuid,
networks.name network_name,
networks.network_domain network_domain,
networks.traffic_type traffic_type,
networks.guest_type guest_type,
async_job.id job_id,
async_job.uuid job_uuid,
async_job.job_status job_status,
async_job.account_id job_account_id,
domain_router.template_version template_version,
domain_router.scripts_version scripts_version,
domain_router.is_redundant_router is_redundant_router,
domain_router.redundant_state redundant_state,
domain_router.stop_pending stop_pending,
domain_router.role role
from
`cloud`.`domain_router`
   inner join
`cloud`.`vm_instance` ON vm_instance.id = domain_router.id
inner join
`cloud`.`account` ON vm_instance.account_id = account.id
inner join
`cloud`.`domain` ON vm_instance.domain_id = domain.id
left join
`cloud`.`host_pod_ref` ON vm_instance.pod_id = host_pod_ref.id
left join
`cloud`.`projects` ON projects.project_account_id = account.id
left join
`cloud`.`data_center` ON vm_instance.data_center_id = data_center.id
left join
`cloud`.`host` ON vm_instance.host_id = host.id
left join
`cloud`.`vm_template` ON vm_instance.vm_template_id = vm_template.id
left join
   `cloud`.`service_offering` ON vm_instance.service_offering_id = 
service_offering.id
left join
`cloud`.`disk_offering` ON vm_instance.service_offering_id = 
disk_offering.id
left join
`cloud`.`nics` ON vm_instance.id = nics.instance_id and nics.removed is 
null
left join
`cloud`.`networks` ON nics.network_id = networks.id
left join
`cloud`.`vpc` ON domain_router.vpc_id = vpc.id and vpc.removed is null
left join
`cloud`.`async_job` ON async_job.instance_id = vm_instance.id
and async_job.instance_type = 'DomainRouter'
and async_job.job_status = 0;



Thanks,
Saksham


RE: [DB-CHANGE] Infrastructure tab fails to load with db exception

2014-08-08 Thread Saksham Srivastava
Agree, we should be using the same tag.
https://cwiki.apache.org/confluence/display/CLOUDSTACK/mail+tags+to+use+to+help+each+other

-Original Message-
From: Mike Tutkowski [mailto:mike.tutkow...@solidfire.com] 
Sent: Thursday, August 7, 2014 11:29 PM
To: dev@cloudstack.apache.org
Cc: Alena Prokharchyk
Subject: Re: [DB-CHANGE] Infrastructure tab fails to load with db exception

That is true. It was not my intent to address that problem, though. I was 
simply commenting on the question of whether we should continue to use the 
[DB-CHANGE] e-mail tag (I believe we should).


On Wed, Aug 6, 2014 at 10:04 PM, Rajani Karuturi  wrote:

> Don’t you think we are overlooking the actual problem of handle 
> migrations on the development branch?
>
> ~Rajani
>
>
>
> On 07-Aug-2014, at 12:21 am, Mike Tutkowski 
> 
> wrote:
>
> > Yep, I agree.
> >
> > I guess my point was that a manually created e-mail should still be
> issued
> > by the developer.
> >
> > On Wednesday, August 6, 2014, Alena Prokharchyk < 
> > alena.prokharc...@citrix.com> wrote:
> >
> >> I doubt we can fully automate this one, Mike, for the case when 
> >> data migration/modification is involved (.java file is modified in 
> >> this
> case).
> >> Only for the changes to .sql files we can automate the 
> >> instructions. For data modification, the developer who’s made the 
> >> changes, still needs to provide the instructions on the dev list.
> >>
> >> -Alena.
> >>
> >>  From: Mike Tutkowski  >> >
> >> Date: Wednesday, August 6, 2014 at 11:33 AM
> >> To: "dev@cloudstack.apache.org
> >> " < 
> >> dev@cloudstack.apache.org 
> >> >
> >> Cc: Alena Prokharchyk  >> >,
> Koushik
> >> Das  >> >
> >> Subject: Re: [DB-CHANGE] Infrastructure tab fails to load with db 
> >> exception
> >>
> >> What about the details for updating your DB?
> >>
> >> If we just receive a general e-mail notification, then each dev 
> >> will independently have to examine the DB changes to come up with a
> workaround
> >> to keep his/her current env running properly after a code update.
> >>
> >> On Wednesday, August 6, 2014, Nitin Mehta  >> > wrote:
> >>
> >>> Agreed. Added that information in the bug.
> >>>
> >>> On 06/08/14 11:08 AM, "Alena Prokharchyk" <
> alena.prokharc...@citrix.com>
> >>> wrote:
> >>>
> >>>> Thank you, Nitin. I think we should add one more item to the 
> >>>> things
> that
> >>>> the script checks: modifications to the older upgrade paths 
> >>>> shouldn¹t
> be
> >>>> allowed. If we already released 4.4, db upgrade changes should be
> >>> accepted
> >>>> only to 4.4-4.5 scripts. If someone makes the changes to, say 
> >>>> 4.3-4.4,
> >>> the
> >>>> mailing list should be notified, and the changes have to be reverted.
> >>>>
> >>>> -Alena.
> >>>>
> >>>> On 8/6/14, 11:03 AM, "Nitin Mehta"  wrote:
> >>>>
> >>>>> This should be automated. We can't rely on the good intentions 
> >>>>> of
> dev.
> >>>>> All we need is a script which checks changes in the schema/java
> Upgrade
> >>>>> files and to sends a notification to the dev list.
> >>>>> Filed a bug for this -
> >>>>> https://issues.apache.org/jira/browse/CLOUDSTACK-7273
> >>>>>
> >>>>>
> >>>>> Thanks,
> >>>>> -Nitin
> >>>>>
> >>>>> On 06/08/14 5:28 AM, "Koushik Das"  wrote:
> >>>>>
> >>>>>> Thanks Saksham. This fixed the initial issue. But I noticed a 
> >>>>>> new
> one,
> >>>>>> after destroying the last VR if you select the infra view it 
> >>>>>> again results in exception. Not sure if anything else needs to be 
> >>>>>> fixed.
> >>>>>>
> >>>>>> -Original Message-
> >>>>>> From: Saksham Srivastava [mailto:saksham.srivast...@citrix.com]
> >>>>>> Sent: Wednesday, 6 August 2014 3:37 PM
> >>>>>> To: dev@cloudstack.apache.org
> >>>>>> Subject: [DB-CHANGE] Infrastructure tab fails to load with db
>

RE: Cluster/Host dedication logic

2014-09-30 Thread Saksham Srivastava
Logan you are correct. We currently have a limitation on placing system vms and 
VRs on dedicated resources. They do not strictly adhere to dedication.
It would be good if you could please file Jira tickets regarding the proposed 
enhancements so that we can track it.

Thanks,
Saksham

-Original Message-
From: Logan Barfield [mailto:lbarfi...@tqhosting.com] 
Sent: Monday, September 29, 2014 11:35 PM
To: dev@cloudstack.apache.org
Subject: Cluster/Host dedication logic

I was doing some testing with the explicit and implicit dedication features, 
and was just wondering about the logic behind it.

From a service provider perspective this feature seems most useful for 
dedicating certain resources to a domain or account.  In other words, a client 
pays for a single host/cluster of hosts, and all their instances are isolated 
on those hosts.

Right now if a host/cluster is explicitly dedicated system VMs will ignore that 
dedication and deploy on the dedicated hosts anyway.  This isn't ideal because 
the system VMs consume resources dedicated (and being paid for) by a single 
client.  That being said the system VMs have to get deployed somewhere, so this 
is probably the best solution overall.

To get around this issue a host can be implicitly dedicated.  In this case only 
VMs specifically deployed by the dedicated user will be provisioned on their 
resources.  This prevents unwanted resource consumption on the dedicated 
infrastructure.  However, this causes the opposite problem with virtual 
routers.  The dedicated client's virtual router is deployed on shared 
resources, instead of their dedicated infrastructure.  This isn't ideal, 
because a customer paying for dedicated resources can be negatively impacted by 
an issue with the shared hosts (e.g., host running their VR goes down causing 
network outages).

Would it be hard to change the implicit dedication logic to allow the virtual 
router owned by an account to reside on their implicitly dedicated resources, 
or even to prefer those resources?  This would ensure that a client paying for 
dedicated resources would only be affected by outages on their own hardware.  
If a console proxy or secondary storage VM goes down they would still be 
affected, but that's a much less urgent/immediately visible problem than losing 
a virtual router.

I know the implicit dedication manager views virtual routers as being owned by 
the "system" right now, but since they are tied to a specific account I don't 
think this change would be too hard to implement.

Is my logic sound on this, or is there something I'm not considering?


Thank You,

Logan Barfield
Tranquil Hosting


RE: Reserved Guest VM CIDR Question

2014-10-06 Thread Saksham Srivastava
Logan,

The reason why reservation is not enabled in create stage is the case of 
External network devices. 
When using external devices like NetScaler, CloudStack will not have a 'real' 
cidr unless the network has been implemented.
So a cidr like /24 used at time of create may turn to /20 when the network has 
been implemented and then it make no sense for reservation in initial stage.
What I will suggest is to create a network offering with 'Persistent' as true.
So your network will be implemented when you create it and VR will be up. Once 
the network has been implemented you can apply reservation.


Thanks,
Saksham


-Original Message-
From: Logan Barfield [mailto:lbarfi...@tqhosting.com] 
Sent: Tuesday, October 7, 2014 12:27 AM
To: dev@cloudstack.apache.org
Subject: Reserved Guest VM CIDR Question

We have decided internally to set up a CIDR reservation with all new accounts 
to give us the ability to easily attach dedicated hosts to existing VM networks.

We were thinking it would be easier to set up the reservation before deploying 
VMs.  Setting up reservation after the fact can get complicated if a VM happens 
to be outside the intended reservation range.

The issue we're having is that reservation is not allowed until the network is 
in the "Implemented" state (i.e. after the first VM is deployed).

Why is reservation not allowed upon initial network creation?  If we try to 
apply reservation after the first VM is online the command will fail 
occasionally because the first VM is deployed outside the CIDR range.

Example:

Guest Net: 10.1.1.0/24
Reserved CIDR: 10.1.1.0/25

- Attempt reservation before deploying a VM: Fails due to network not being 
"Implemented"
- Attempt reservation after many VMs are deployed: Fails due to VMs being 
outside Reserved CIDR (e.g., 10.1.1.150), and requires a lot of work to change 
the VM's IP
- Attempt reservation after first VM is deployed: Either succeeds, or fails if 
the first VMs IP is outside of the reserved CIDR.

How can we fix this without hacking work arounds into the deployment logic?
 (ex: Check network for 10.1.1.10, if it doesn't exist deploy the VM on that 
IP, if it already exists deploy it wherever.)

Thank You,

Logan Barfield
Tranquil Hosting


Re: Review Request 13560: CLOUDSTACK-4021 : Update the test test_explicit_dedication.py according to new changes to dedicated resources

2014-12-18 Thread Saksham Srivastava


> On Dec. 1, 2014, 3:33 a.m., Pierre-Luc Dion wrote:
> > Is this still valid? could it be possible to resubmit a new patch from 
> > master that remove conflict? 
> > 
> > thanks

Yes this is still valid.
https://reviews.apache.org/r/29201/diff/ will address the issue.
Closing the current review request.


- Saksham


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/13560/#review63331
---


On Jan. 17, 2014, 11:06 a.m., Saksham Srivastava wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/13560/
> ---
> 
> (Updated Jan. 17, 2014, 11:06 a.m.)
> 
> 
> Review request for cloudstack, Devdeep Singh, Girish Shilamkar, Prachi Damle, 
> and Rayees Namathponnan.
> 
> 
> Bugs: CLOUDSTACK-4021
> https://issues.apache.org/jira/browse/CLOUDSTACK-4021
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> ---
> 
> test_explicit_dedication.py need to modified according to the new changes to 
> dedicate resources feature.
> Now dedicate a host first and use the created affinity group to deploy vm.
> 
> 
> Diffs
> -
> 
>   test/integration/component/test_explicit_dedication.py 7aefc21 
>   tools/marvin/marvin/integration/lib/common.py 550de1a 
> 
> Diff: https://reviews.apache.org/r/13560/diff/
> 
> 
> Testing
> ---
> 
> test runs successfully whenever an empty host is found.
> 
> 
> Thanks,
> 
> Saksham Srivastava
> 
>



RE: [ANNOUNCE] New Committer: Sanjay Tripathi

2014-01-09 Thread Saksham Srivastava
Congrats Sanjay.

-Original Message-
From: David Nalley [mailto:da...@gnsa.us] 
Sent: Friday, January 10, 2014 4:23 AM
To: dev@cloudstack.apache.org
Subject: [ANNOUNCE] New Committer: Sanjay Tripathi

The Project Management Committee (PMC) for Apache CloudStack has asked Sanjay 
Tripathi to become a committer and we are pleased to announce that they have 
accepted.

Being a committer allows many contributors to contribute more autonomously. For 
developers, it makes it easier to submit changes and eliminates the need to 
have contributions reviewed via the patch submission process. Whether 
contributions are development-related or otherwise, it is a recognition of a 
contributor's participation in the project and commitment to the project and 
the Apache Way.

Please join me in congratulating Sanjay!

--David,
on behalf of the Apache CloudStack PMC


Review Request 16779: CLOUDSTACK-5535: Disallow cross-tier and isolated networks to be added by addNetwork

2014-01-10 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16779/
---

Review request for cloudstack and Alena Prokharchyk.


Bugs: CLOUDSTACK-5535
https://issues.apache.org/jira/browse/CLOUDSTACK-5535


Repository: cloudstack-git


Description
---

Patch for master branch for https://reviews.apache.org/r/16361/


Diffs
-

  server/src/com/cloud/vm/UserVmManagerImpl.java 5601118 

Diff: https://reviews.apache.org/r/16779/diff/


Testing
---


Thanks,

Saksham Srivastava



Re: Review Request 16361: CLOUDSTACK-5535: Do not allow addNetwork to create NIC across VPC tiers and Isolated Networks

2014-01-13 Thread Saksham Srivastava


> On Jan. 9, 2014, 6:22 p.m., Alena Prokharchyk wrote:
> > Saksham,
> > 
> > The patch fails on 4.3 branch with the error:
> > 
> > Applying: CLOUDSTACK-5535 : Do not allow addNetwork to create NIC across 
> > VPC tiers and Isolated Networks
> > error: patch failed: server/src/com/cloud/vm/UserVmManagerImpl.java:973
> > error: server/src/com/cloud/vm/UserVmManagerImpl.java: patch does not apply
> > Patch failed at 0001 CLOUDSTACK-5535 : Do not allow addNetwork to create 
> > NIC across VPC tiers and Isolated Networks
> > The copy of the patch that failed is found in:
> >/Users/alena/repos/dr/cloudstack/.git/rebase-apply/patch
> > 
> > 
> > Please fix and submit again. Also submit a separate patch for the master 
> > branch, as there are changes in code style that might affect the 
> > cherry-pick.
> 
> Marcus Sorensen wrote:
> Please dont submit again! :-) See my comments on CLOUDSTACK-5535

Discarding as per comments from Marcus and Animesh on the bug.


- Saksham


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16361/#review31444
---


On Dec. 19, 2013, 5:25 a.m., Saksham Srivastava wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16361/
> ---
> 
> (Updated Dec. 19, 2013, 5:25 a.m.)
> 
> 
> Review request for cloudstack and Alena Prokharchyk.
> 
> 
> Bugs: CLOUDSTACK-5535
> https://issues.apache.org/jira/browse/CLOUDSTACK-5535
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> ---
> 
> addNetworkToVM allows adding any network to VM.
> Ideally a VM running in isolated Guest Network should not be able to add a 
> VPC tier.
> A VM running in VPC tier should not be allowed to add another tier
> A VM running in VPC tier should not be allowed to add another isolated guest 
> network
> 
> 
> Diffs
> -
> 
>   server/src/com/cloud/vm/UserVmManagerImpl.java 3ad49d8 
> 
> Diff: https://reviews.apache.org/r/16361/diff/
> 
> 
> Testing
> ---
> 
> VM having a nic in isolated guest network cannot add a VPC tier.
> VM having a nic in one VPC tier cannot add another VPC tier.
> VM having a nic in a VPC tier cannot add a isolated guest network.
> 
> 
> Thanks,
> 
> Saksham Srivastava
> 
>



Re: Review Request 16540: CLOUDSTACK-5692: cleanup API response for primary/secondary storages

2014-01-16 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16540/
---

(Updated Jan. 16, 2014, 1:52 p.m.)


Review request for cloudstack and Devdeep Singh.


Bugs: CLOUDSTACK-5692
https://issues.apache.org/jira/browse/CLOUDSTACK-5692


Repository: cloudstack-git


Description (updated)
---

Cleanup the API response while listing primary/secondary stores while using 
cifs.
Cleanup logs and remove passwords.


Diffs (updated)
-

  core/src/com/cloud/agent/transport/Request.java cbeb112 
  
plugins/hypervisors/hyperv/src/com/cloud/hypervisor/hyperv/resource/HypervDirectConnectResource.java
 1edfea3 
  server/src/com/cloud/api/query/dao/ImageStoreJoinDaoImpl.java 8022871 
  server/src/com/cloud/api/query/dao/StoragePoolJoinDaoImpl.java 4d2aac2 

Diff: https://reviews.apache.org/r/16540/diff/


Testing (updated)
---

Tested locally.

The api response for list doesnot contain passwords:

"listimagestoresresponse" : { "count":1 ,"imagestore" : [  
{"id":"182cfbfd-6343-4f35-804c-6b388fbf6a18","zoneid":"1ae705a4-c9bc-4977-9260-ce128d7fd3d8","zonename":"zone1","name":"secondary1","url":"cifs://10.102.192.151/SMB-Share/saksham/secondary?user=administrator&domain=blr","protocol":"cifs","providername":"NFS","scope":"ZONE","details":[]}
 ] } }

The logs also do not contain passwords :

2014-01-16 18:48:53,288 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] 
(Job-Executor-2:ctx-24ee5b9d ctx-b4e28b06) Complete async job-62, jobStatus: 
SUCCEEDED, resultCode: 0, result: 
org.apache.cloudstack.api.response.StoragePoolResponse/storagepool/{"id":"c59cc1c9-8d16-3090-95e7-d5c54839cf2c","zoneid":"1ae705a4-c9bc-4977-9260-ce128d7fd3d8","zonename":"zone1","podid":"bd328cfc-692e-4c8c-8d32-e2a34abaaa37","podname":"pod1","name":"primary1","ipaddress":"10.102.192.150","path":"/SMB-Share/saksham/primary?user\u003dadministrator\u0026domain\u003dblr","created":"2014-01-07T16:28:35+0530","type":"NetworkFilesystem","clusterid":"fc1df888-0e90-45c2-8555-5d4ed61c7bc3","clustername":"cluster1","disksizetotal":500105736192,"disksizeallocated":0,"tags":"sggss","state":"Up","scope":"CLUSTER","jobid":"dfbd2072-48dc-457d-a417-312a74c517f9","jobstatus":0}


Thanks,

Saksham Srivastava



Re: Review Request 13560: CLOUDSTACK-4021 : Update the test test_explicit_dedication.py according to new changes to dedicated resources

2014-01-17 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/13560/
---

(Updated Jan. 17, 2014, 11:06 a.m.)


Review request for cloudstack, Devdeep Singh, Girish Shilamkar, Prachi Damle, 
and Rayees Namathponnan.


Changes
---

Resubmitting an old patch by removing merge conflicts.


Bugs: CLOUDSTACK-4021
https://issues.apache.org/jira/browse/CLOUDSTACK-4021


Repository: cloudstack-git


Description
---

test_explicit_dedication.py need to modified according to the new changes to 
dedicate resources feature.
Now dedicate a host first and use the created affinity group to deploy vm.


Diffs (updated)
-

  test/integration/component/test_explicit_dedication.py 7aefc21 
  tools/marvin/marvin/integration/lib/common.py 550de1a 

Diff: https://reviews.apache.org/r/13560/diff/


Testing
---

test runs successfully whenever an empty host is found.


Thanks,

Saksham Srivastava



Review Request 17142: CLOUDSTACK-5916: associateIpAddress" leaves an IP in allocating state

2014-01-21 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/17142/
---

Review request for cloudstack and Murali Reddy.


Bugs: 5916
https://issues.apache.org/jira/browse/5916


Repository: cloudstack-git


Description
---

associateIpAddress leaves an IP in allocating state (user_ip_address table), 
although the API command is executed on incorrectly.

Steps to repro :
1) create a vpc tier.
2) Execute associateIpAddress" API on the vpc tier but do not specify the vpc 
id.
#cloudmonkey
>>associate ipaddress networkid=09ffc45f-beba-4690-8be7-425891915d44
Async job ea020246-d0e8-4e58-ac84-fccb55c3b646 failed
Error 530, Can't assign ip to the network directly when network belongs to 
VPC.Specify vpcId to associate ip address to VPC
accountid = a6ba35b3-7e76-11e3-8490-7614eba325e6
cmd = org.apache.cloudstack.api.command.user.address.AssociateIPAddrCmd
created = 2014-01-21T10:46:46+0530
jobid = ea020246-d0e8-4e58-ac84-fccb55c3b646
jobprocstatus = 0
jobresult:
errorcode = 530
errortext = Can't assign ip to the network directly when network belongs to 
VPC.Specify vpcId to associate ip address to VPC
jobresultcode = 530
jobresulttype = object
jobstatus = 2
userid = a6ba5844-7e76-11e3-8490-7614eba325e6

Expected behavior:
There should be no allocation of IP .

Actual behaviour:
The public IP remains in 'Allocating' state

The fix releases the IP incase of exception.


Diffs
-

  server/src/com/cloud/network/NetworkServiceImpl.java 056190f 

Diff: https://reviews.apache.org/r/17142/diff/


Testing
---

Tested the following scenarios:
:8096/client/api?command=associateIpAddress&networkid=09ffc45f-beba-4690-8be7-425891915d44
There is no allocation of public IP (no IP is put in Allocating state in the 
db).
 
:8096/client/api?command=associateIpAddress&networkid=09ffc45f-beba-4690-8be7-425891915d44&vpcid=1
Successfully associates the IP.

Build passes successfully.
Patch applies cleanly.


Thanks,

Saksham Srivastava



Review Request 17736: CLOUDSTACK-5999: Virtual Router does not start if Guest VM is rebooted from CloudStack

2014-02-05 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/17736/
---

Review request for cloudstack and Murali Reddy.


Bugs: CLOUDSTACK-5999
https://issues.apache.org/jira/browse/CLOUDSTACK-5999


Repository: cloudstack-git


Description
---

When a guest is rebooted from CloudStack, if the virtual router managing the 
guest network of that guest is down, CloudStack will not start the virtual 
router.
However the router is started in case the guest vm is stopped and then started.
To mantain similarity between the 2 process it is necessary to start the VR in 
case it is not running.
The fix will address the same.


Diffs
-

  server/src/com/cloud/vm/UserVmManagerImpl.java 81be19f 

Diff: https://reviews.apache.org/r/17736/diff/


Testing
---

Testing:
1) vm in a single guest network :
   vm Reboot : If the VR is stopped: VR is first started and then 
the VM reboots.
   vm Reboot : If the VR is running, VM reboots as it used to.
vm Stop/Start continue to work the same.

2)  vm having nics in multi networks :
   vm Reboot : If VR in any/all network is stopped: VRs are first 
started and then the VM reboots.
   vm Reboot : If the VRs are running, VM reboots as it used to.
vm Stop/Start continue to work the same.

3) vpc :
   Tested the above scenarios for vpc also, works fine.

Patch applies cleanly.


Thanks,

Saksham Srivastava



Re: Review Request 17736: CLOUDSTACK-5999: Virtual Router does not start if Guest VM is rebooted from CloudStack

2014-02-07 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/17736/#review33921
---



server/src/com/cloud/vm/UserVmManagerImpl.java
<https://reviews.apache.org/r/17736/#comment63715>

Thanks John for the comments.
Created single list and now using new utility to grab the domain router for 
the network.


- Saksham Srivastava


On Feb. 5, 2014, 8:46 a.m., Saksham Srivastava wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/17736/
> ---
> 
> (Updated Feb. 5, 2014, 8:46 a.m.)
> 
> 
> Review request for cloudstack and Murali Reddy.
> 
> 
> Bugs: CLOUDSTACK-5999
> https://issues.apache.org/jira/browse/CLOUDSTACK-5999
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> ---
> 
> When a guest is rebooted from CloudStack, if the virtual router managing the 
> guest network of that guest is down, CloudStack will not start the virtual 
> router.
> However the router is started in case the guest vm is stopped and then 
> started.
> To mantain similarity between the 2 process it is necessary to start the VR 
> in case it is not running.
> The fix will address the same.
> 
> 
> Diffs
> -
> 
>   server/src/com/cloud/vm/UserVmManagerImpl.java 81be19f 
> 
> Diff: https://reviews.apache.org/r/17736/diff/
> 
> 
> Testing
> ---
> 
> Testing:
> 1) vm in a single guest network :
>vm Reboot : If the VR is stopped: VR is first started and then 
> the VM reboots.
>vm Reboot : If the VR is running, VM reboots as it used to.
> vm Stop/Start continue to work the same.
> 
> 2)  vm having nics in multi networks :
>vm Reboot : If VR in any/all network is stopped: VRs are first 
> started and then the VM reboots.
>vm Reboot : If the VRs are running, VM reboots as it used to.
> vm Stop/Start continue to work the same.
> 
> 3) vpc :
>Tested the above scenarios for vpc also, works fine.
> 
> Patch applies cleanly.
> 
> 
> Thanks,
> 
> Saksham Srivastava
> 
>



Re: Review Request 17736: CLOUDSTACK-5999: Virtual Router does not start if Guest VM is rebooted from CloudStack

2014-02-07 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/17736/
---

(Updated Feb. 7, 2014, 9:26 a.m.)


Review request for cloudstack, John Burwell and Murali Reddy.


Changes
---

Updated the patch.


Bugs: CLOUDSTACK-5999
https://issues.apache.org/jira/browse/CLOUDSTACK-5999


Repository: cloudstack-git


Description
---

When a guest is rebooted from CloudStack, if the virtual router managing the 
guest network of that guest is down, CloudStack will not start the virtual 
router.
However the router is started in case the guest vm is stopped and then started.
To mantain similarity between the 2 process it is necessary to start the VR in 
case it is not running.
The fix will address the same.


Diffs (updated)
-

  server/src/com/cloud/vm/UserVmManagerImpl.java 81be19f 

Diff: https://reviews.apache.org/r/17736/diff/


Testing
---

Testing:
1) vm in a single guest network :
   vm Reboot : If the VR is stopped: VR is first started and then 
the VM reboots.
   vm Reboot : If the VR is running, VM reboots as it used to.
vm Stop/Start continue to work the same.

2)  vm having nics in multi networks :
   vm Reboot : If VR in any/all network is stopped: VRs are first 
started and then the VM reboots.
   vm Reboot : If the VRs are running, VM reboots as it used to.
vm Stop/Start continue to work the same.

3) vpc :
   Tested the above scenarios for vpc also, works fine.

Patch applies cleanly.


Thanks,

Saksham Srivastava



Review Request 17840: Patch [master] CLOUDSTACK-5999: Virtual Router does not start if Guest VM is rebooted from CloudStack

2014-02-07 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/17840/
---

Review request for cloudstack, John Burwell and Murali Reddy.


Bugs: CLOUDSTACK-5999
https://issues.apache.org/jira/browse/CLOUDSTACK-5999


Repository: cloudstack-git


Description
---

Patch for matser for bug CLOUDSTACK-5999.
The parent review request is at https://reviews.apache.org/r/17736/


Diffs
-

  server/src/com/cloud/vm/UserVmManagerImpl.java f6f20cc 

Diff: https://reviews.apache.org/r/17840/diff/


Testing
---

Patch applies cleanly.
Build passes.


Thanks,

Saksham Srivastava



[PROPOSAL] Storage OverProvisioning as Per Primary Basis

2014-02-14 Thread Saksham Srivastava
Hi,

CloudStack currently leverages storage overcommit/overprovisioning by 
specifying global setting storage.overprovisioning.factor
I would like to extend the granularity of global params to make storage 
overprovisioning as a per primary store basis.
Also it would allow admin to make more intuitive choice for overprovision 
factor depending upon the actual storage used.

Bug Reference : https://issues.apache.org/jira/browse/CLOUDSTACK-6092
Related : https://issues.apache.org/jira/browse/CLOUDSTACK-5806
FS : 
https://cwiki.apache.org/confluence/display/CLOUDSTACK/Storage+OverProvisioning+as+Per+Primary+Basis

Thanks,
Saksham



RE: [PROPOSAL] Storage OverProvisioning as Per Primary Basis

2014-02-17 Thread Saksham Srivastava
Koushik/Mike,
Thanks for comments.

The current behavior is that we calculate the totalOverProvCapacity 
(storage.overprovisioning.factor * total storage capacity) for the destination 
PS.
When volume is being migrated across PS, the destination PS must have a higher 
totalOverProvCapacity than the expected total allocated space.

This feature will be on same lines as the current behavior except that now the 
storage.overprovisioning.factor will be a configurable parameter for the PS.

I will include this information with more detailed capacity computation along 
with more explanation on upgrade scenarios as soon as cwiki comes up.

As Mike pointed out, we can have Primary Storages at 3 levels : Local Storage 
(HOST), Cluster Storage(CLUSTER) ,  ZWPS (ZONE).
Storage scope was introduced for enhancing Granularity for configuration 
parameters in 4.2, so it would be good to use the same 
as an individual per-primary setting instead of multi scopes.

Thanks,
Saksham

-Original Message-
From: Mike Tutkowski [mailto:mike.tutkow...@solidfire.com] 
Sent: Saturday, February 15, 2014 4:25 AM
To: dev@cloudstack.apache.org
Subject: Re: [PROPOSAL] Storage OverProvisioning as Per Primary Basis

Just a reminder here that primary storage can also be at the zone level as of 
4.2.


On Fri, Feb 14, 2014 at 4:44 AM, Koushik Das  wrote:

> Please add more details for upgrade scenario. Also can you give some 
> examples as to how the capacity computation is done for operations 
> where the volume gets migrated from one PS to another having different 
> over provisioning factors.
>
> Is there any value add if you give this also at cluster scope?
>
> -Koushik
>
> On 14-Feb-2014, at 2:13 PM, Saksham Srivastava < 
> saksham.srivast...@citrix.com> wrote:
>
> > Hi,
> >
> > CloudStack currently leverages storage overcommit/overprovisioning 
> > by
> specifying global setting storage.overprovisioning.factor
> > I would like to extend the granularity of global params to make 
> > storage
> overprovisioning as a per primary store basis.
> > Also it would allow admin to make more intuitive choice for
> overprovision factor depending upon the actual storage used.
> >
> > Bug Reference : 
> > https://issues.apache.org/jira/browse/CLOUDSTACK-6092
> > Related : https://issues.apache.org/jira/browse/CLOUDSTACK-5806
> > FS :
> https://cwiki.apache.org/confluence/display/CLOUDSTACK/Storage+OverPro
> visioning+as+Per+Primary+Basis
> >
> > Thanks,
> > Saksham
> >
>
>


--
*Mike Tutkowski*
*Senior CloudStack Developer, SolidFire Inc.*
e: mike.tutkow...@solidfire.com
o: 303.746.7302
Advancing the way the world uses the
cloud<http://solidfire.com/solution/overview/?video=play>
*(tm)*


Review Request 18352: CLOUDSTACK-6151: Local data disk with tag goes to the wrong local storage pool

2014-02-21 Thread Saksham Srivastava

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/18352/
---

Review request for cloudstack, Koushik Das and Prachi Damle.


Bugs: CLOUDSTACK-6151
https://issues.apache.org/jira/browse/CLOUDSTACK-6151


Repository: cloudstack-git


Description
---

Attaching a disk created from local disk offering with tags, to a VM was going 
to wrong local storage pool.
Cause : In LocalStoragePoolAlocator-
List hostPools = _poolHostDao.listByHostId(plan.getHostId());
It return pools by hostId, but nowhere were the tags being compared.

Added new method findLocalStoragePoolsByHostAndTags() that returns stoage pools 
by hostid and tags both.


Diffs
-

  
engine/schema/src/org/apache/cloudstack/storage/datastore/db/PrimaryDataStoreDao.java
 59c338e 
  
engine/schema/src/org/apache/cloudstack/storage/datastore/db/PrimaryDataStoreDaoImpl.java
 d35aa44 
  
engine/storage/src/org/apache/cloudstack/storage/allocator/LocalStoragePoolAllocator.java
 1f61e8b 

Diff: https://reviews.apache.org/r/18352/diff/


Testing
---

Tested the folowing scenarios:
attaching local volume with tags
attaching local volume without tags
attaching local volume with different tags
attaching shared volume

Build passes successfully.


Thanks,

Saksham Srivastava



Re: Review Request 18352: CLOUDSTACK-6151: Local data disk with tag goes to the wrong local storage pool

2014-02-24 Thread Saksham Srivastava


> On Feb. 24, 2014, 7:10 a.m., Koushik Das wrote:
> > engine/schema/src/org/apache/cloudstack/storage/datastore/db/PrimaryDataStoreDao.java,
> >  line 118
> > <https://reviews.apache.org/r/18352/diff/1/?file=46#file46line118>
> >
> > If you specify the host then you don't need dc, pod, cluster.

The reason why I added this was to make sure in case the hostId is passed as 
null, we could return tagged storagePools by calling 
findLocalStoragePoolsByTags.
This is more of an extra check that we should return all hosts with matching 
tags even when host is not passed. 
As suggested it may not be required as there are not other cases where one 
would call this utility.


> On Feb. 24, 2014, 7:10 a.m., Koushik Das wrote:
> > engine/schema/src/org/apache/cloudstack/storage/datastore/db/PrimaryDataStoreDaoImpl.java,
> >  line 68
> > <https://reviews.apache.org/r/18352/diff/1/?file=47#file47line68>
> >
> > I would recommend that you use the createSearchBuilder() approach 
> > instead of hardcoding the sql query. Refer to PrimaryDataStoreDaoImpl() 
> > ctor.

To return local storage pools of matching tags and matching host id requires 
join of 3 tables (storage_pools, storage_host_ref and storage_pool_details). 
Further , all the methods that search for tagged pools in this file are 
currently using the same technique of filling the base sql query with custom 
search parameters, I have also gone the same way.
But as you have mentioned I will update the patch using createSearchBuilder() 
method.


> On Feb. 24, 2014, 7:10 a.m., Koushik Das wrote:
> > engine/schema/src/org/apache/cloudstack/storage/datastore/db/PrimaryDataStoreDaoImpl.java,
> >  line 366
> > <https://reviews.apache.org/r/18352/diff/1/?file=47#file47line366>
> >
> > What is the use case for null host id? Make it long instead of Long.

This is just because I was checking for null hostIds, since the check may not 
be required, I will change it to long.


- Saksham


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/18352/#review35257
---


On Feb. 21, 2014, 11:36 a.m., Saksham Srivastava wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/18352/
> ---
> 
> (Updated Feb. 21, 2014, 11:36 a.m.)
> 
> 
> Review request for cloudstack, Koushik Das and Prachi Damle.
> 
> 
> Bugs: CLOUDSTACK-6151
> https://issues.apache.org/jira/browse/CLOUDSTACK-6151
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> ---
> 
> Attaching a disk created from local disk offering with tags, to a VM was 
> going to wrong local storage pool.
> Cause : In LocalStoragePoolAlocator-
> List hostPools = 
> _poolHostDao.listByHostId(plan.getHostId());
> It return pools by hostId, but nowhere were the tags being compared.
> 
> Added new method findLocalStoragePoolsByHostAndTags() that returns stoage 
> pools by hostid and tags both.
> 
> 
> Diffs
> -
> 
>   
> engine/schema/src/org/apache/cloudstack/storage/datastore/db/PrimaryDataStoreDao.java
>  59c338e 
>   
> engine/schema/src/org/apache/cloudstack/storage/datastore/db/PrimaryDataStoreDaoImpl.java
>  d35aa44 
>   
> engine/storage/src/org/apache/cloudstack/storage/allocator/LocalStoragePoolAllocator.java
>  1f61e8b 
> 
> Diff: https://reviews.apache.org/r/18352/diff/
> 
> 
> Testing
> ---
> 
> Tested the folowing scenarios:
> attaching local volume with tags
> attaching local volume without tags
> attaching local volume with different tags
> attaching shared volume
> 
> Build passes successfully.
> 
> 
> Thanks,
> 
> Saksham Srivastava
> 
>



<    1   2