You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by Harikrishna Patnala <ha...@citrix.com> on 2013/05/02 13:30:52 UTC

Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

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

Review request for cloudstack and Abhinandan Prateek.


Description
-------

CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host 
Fixed by updating the patch files that has
 entries to copy scipts on xenserver. Here we added
 Add-To-VCPUs-Params-Live.sh

Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
If DMC is not enabled then static max and min are set to SO.


This addresses bug CLOUDSTACK-2085.


Diffs
-----

  plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java 46ae35a 
  plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java 96a90a6 
  plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java 7392cb1 
  scripts/vm/hypervisor/xenserver/xcpserver/patch b7961bb 
  scripts/vm/hypervisor/xenserver/xenserver56/patch 36dba3d 
  scripts/vm/hypervisor/xenserver/xenserver56fp1/patch d20e60f 
  scripts/vm/hypervisor/xenserver/xenserver60/patch c9125f4 

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


Testing
-------

Tested: tried scaling up a vm and checked on xenserver for the new values. 


Thanks,

Harikrishna Patnala


Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

Posted by Abhinandan Prateek <ap...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/10903/#review20179
-----------------------------------------------------------

Ship it!


Ship It!

- Abhinandan Prateek


On May 2, 2013, 11:30 a.m., Harikrishna Patnala wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/10903/
> -----------------------------------------------------------
> 
> (Updated May 2, 2013, 11:30 a.m.)
> 
> 
> Review request for cloudstack and Abhinandan Prateek.
> 
> 
> Description
> -------
> 
> CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host 
> Fixed by updating the patch files that has
>  entries to copy scipts on xenserver. Here we added
>  Add-To-VCPUs-Params-Live.sh
> 
> Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
> If DMC is not enabled then static max and min are set to SO.
> 
> 
> This addresses bug CLOUDSTACK-2085.
> 
> 
> Diffs
> -----
> 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java 46ae35a 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java 96a90a6 
>   plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java 7392cb1 
>   scripts/vm/hypervisor/xenserver/xcpserver/patch b7961bb 
>   scripts/vm/hypervisor/xenserver/xenserver56/patch 36dba3d 
>   scripts/vm/hypervisor/xenserver/xenserver56fp1/patch d20e60f 
>   scripts/vm/hypervisor/xenserver/xenserver60/patch c9125f4 
> 
> Diff: https://reviews.apache.org/r/10903/diff/
> 
> 
> Testing
> -------
> 
> Tested: tried scaling up a vm and checked on xenserver for the new values. 
> 
> 
> Thanks,
> 
> Harikrishna Patnala
> 
>


Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

Posted by Nitin Mehta <Ni...@citrix.com>.
Shipped with commit ffe90c00599917bfbe5e22e369fd248358074600

From: Nitin Mehta <ni...@citrix.com>>
Reply-To: Nitin Mehta <ni...@citrix.com>>
Date: Wednesday 15 May 2013 3:49 PM
To: Abhinandan Prateek <ap...@apache.org>>, Nitin Mehta <ni...@citrix.com>>
Cc: "cloudstack-dev@incubator.apache.org<ma...@incubator.apache.org>" <cl...@incubator.apache.org>>, Harikrishna Patnala <ha...@citrix.com>>
Subject: Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

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


Ship it!

Ship It!


- Nitin


On May 15th, 2013, 10:06 a.m., Harikrishna Patnala wrote:

Review request for cloudstack, Abhinandan Prateek and Nitin Mehta.
By Harikrishna Patnala.

Updated May 15, 2013, 10:06 a.m.

Description

CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host
Fixed by updating the patch files that has
 entries to copy scipts on xenserver. Here we added
 Add-To-VCPUs-Params-Live.sh

Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
If DMC is not enabled then static max and min are set to SO.


Testing

Tested: tried scaling up a vm and checked on xenserver for the new values.


Bugs: CLOUDSTACK-2085
Diffs

  *   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java (46ae35a)
  *   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java (96a90a6)
  *   plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java (7392cb1)
  *   scripts/vm/hypervisor/xenserver/Add-To-VCPUs-Params-Live.sh (0fadcd8)
  *   scripts/vm/hypervisor/xenserver/add_to_vcpus_params_live.sh (PRE-CREATION)
  *   scripts/vm/hypervisor/xenserver/vmops (30b5300)
  *   scripts/vm/hypervisor/xenserver/xcpserver/patch (b7961bb)
  *   scripts/vm/hypervisor/xenserver/xenserver56/patch (36dba3d)
  *   scripts/vm/hypervisor/xenserver/xenserver56fp1/patch (d20e60f)
  *   scripts/vm/hypervisor/xenserver/xenserver60/patch (c9125f4)

View Diff<https://reviews.apache.org/r/10903/diff/>


Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

Posted by Nitin Mehta <ni...@citrix.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/10903/#review20569
-----------------------------------------------------------

Ship it!


Ship It!

- Nitin Mehta


On May 15, 2013, 10:06 a.m., Harikrishna Patnala wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/10903/
> -----------------------------------------------------------
> 
> (Updated May 15, 2013, 10:06 a.m.)
> 
> 
> Review request for cloudstack, Abhinandan Prateek and Nitin Mehta.
> 
> 
> Description
> -------
> 
> CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host 
> Fixed by updating the patch files that has
>  entries to copy scipts on xenserver. Here we added
>  Add-To-VCPUs-Params-Live.sh
> 
> Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
> If DMC is not enabled then static max and min are set to SO.
> 
> 
> This addresses bug CLOUDSTACK-2085.
> 
> 
> Diffs
> -----
> 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java 46ae35a 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java 96a90a6 
>   plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java 7392cb1 
>   scripts/vm/hypervisor/xenserver/Add-To-VCPUs-Params-Live.sh 0fadcd8 
>   scripts/vm/hypervisor/xenserver/add_to_vcpus_params_live.sh PRE-CREATION 
>   scripts/vm/hypervisor/xenserver/vmops 30b5300 
>   scripts/vm/hypervisor/xenserver/xcpserver/patch b7961bb 
>   scripts/vm/hypervisor/xenserver/xenserver56/patch 36dba3d 
>   scripts/vm/hypervisor/xenserver/xenserver56fp1/patch d20e60f 
>   scripts/vm/hypervisor/xenserver/xenserver60/patch c9125f4 
> 
> Diff: https://reviews.apache.org/r/10903/diff/
> 
> 
> Testing
> -------
> 
> Tested: tried scaling up a vm and checked on xenserver for the new values. 
> 
> 
> Thanks,
> 
> Harikrishna Patnala
> 
>


Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

Posted by Prasanna Santhanam <ts...@apache.org>.

> On May 19, 2013, 1:05 p.m., Prasanna Santhanam wrote:
> > plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java, line 144
> > <https://reviews.apache.org/r/10903/diff/2/?file=288093#file288093line144>
> >
> >     The if-else logic should be the other way round here. When DynamicMemoryControl (dmc) is allowed on your Xenserver (restrict_dmc=false) you'd expect to set the dynamicMin and dynamicMax of your guest. You've done it the right way in CitrixResourceBase but not here. I've fixed this in master for now. Please take a look.
> >     
> >     In effect, you restrict scaling when scaling is in fact allowed.
> >     
> >     Also in the else block - you set the staticMax and staticMin to hardcoded values. While I agree with the staticMin, the staticMax is determined by the memory available on the host. You should ideally set that to what is given by the ServiceOffering, provided all the capacity managers allowed it to get to the ServerResource.
> >     
> >     Lastly, XCP supports DMC since 0.5, can you consider moving all this isDmcRestricted() logic into CitrixResourceBase so XCP can take advantage of it?
> >
> 
> Harikrishna Patnala wrote:
>     If else logic is correct. During the deployment of VM if(restrict_dmc = false) which implies if DMC is not restricted then we can scale the VM so we set static memory limit to the VM. In CitrixResourceBase while scaling the VM, we check if(restrict_dmc = true) which implies if host restricts DMC then we throw an excpetion saying host doesnt not support memory scaling.
>     
>     Inorder to scale the vm we have to set static max and min to a limit, so that after wards we can scale the vm memory within that limit.(we cannot change static max and min dynamically). But hardcoding the values is also not the right way. I have submitted another patch that removes the hardcoding these values and setting the values according the memory constraints provided by the xenserver.
>     
>
> 
> Prasanna Santhanam wrote:
>     This is what it looks like before my fix in 7ea2c950. The log as you've said shows that DMC is disabled when restrict_dmc is true. But the VM doesn't scale within static-min and static-max. It scales between dynamic-min and dynamic-max in Xen. The dynamic ranges are set earlier in the method. static-min is used only during boot time to define the memory overhead required for the OS to boot.
>     
>     
>     Please see: http://wiki.xen.org/wiki/XCP_FAQ_Dynamic_Memory_Control
>     
>              if (hostParams.get("restrict_dmc").equalsIgnoreCase("false")) {
>                 record.memoryStaticMax = 8589934592L; //8GB
>                 record.memoryStaticMin = 134217728L; //128MB
>              } else {
>                  s_logger.warn("Host "+ _host.uuid + " does not support Dynamic Memory Control, so we cannot scale up the vm");
>                 record.memoryStaticMax = vmSpec.getMaxRam();
>                 record.memoryStaticMin = vmSpec.getMinRam();
>              }
>

To ensure that this works, can you also please look at the integration test?
test/integration/smoke/test_scale_vm.py

It's been failing consistently:
http://jenkins.buildacloud.org/job/test-smoke-matrix/lastCompletedBuild/suite=test_scale_vm/testReport/


- Prasanna


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


On May 15, 2013, 10:06 a.m., Harikrishna Patnala wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/10903/
> -----------------------------------------------------------
> 
> (Updated May 15, 2013, 10:06 a.m.)
> 
> 
> Review request for cloudstack, Abhinandan Prateek and Nitin Mehta.
> 
> 
> Description
> -------
> 
> CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host 
> Fixed by updating the patch files that has
>  entries to copy scipts on xenserver. Here we added
>  Add-To-VCPUs-Params-Live.sh
> 
> Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
> If DMC is not enabled then static max and min are set to SO.
> 
> 
> This addresses bug CLOUDSTACK-2085.
> 
> 
> Diffs
> -----
> 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java 46ae35a 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java 96a90a6 
>   plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java 7392cb1 
>   scripts/vm/hypervisor/xenserver/Add-To-VCPUs-Params-Live.sh 0fadcd8 
>   scripts/vm/hypervisor/xenserver/add_to_vcpus_params_live.sh PRE-CREATION 
>   scripts/vm/hypervisor/xenserver/vmops 30b5300 
>   scripts/vm/hypervisor/xenserver/xcpserver/patch b7961bb 
>   scripts/vm/hypervisor/xenserver/xenserver56/patch 36dba3d 
>   scripts/vm/hypervisor/xenserver/xenserver56fp1/patch d20e60f 
>   scripts/vm/hypervisor/xenserver/xenserver60/patch c9125f4 
> 
> Diff: https://reviews.apache.org/r/10903/diff/
> 
> 
> Testing
> -------
> 
> Tested: tried scaling up a vm and checked on xenserver for the new values. 
> 
> 
> Thanks,
> 
> Harikrishna Patnala
> 
>


Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

Posted by Harikrishna Patnala <ha...@citrix.com>.

> On May 19, 2013, 1:05 p.m., Prasanna Santhanam wrote:
> > plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java, line 144
> > <https://reviews.apache.org/r/10903/diff/2/?file=288093#file288093line144>
> >
> >     The if-else logic should be the other way round here. When DynamicMemoryControl (dmc) is allowed on your Xenserver (restrict_dmc=false) you'd expect to set the dynamicMin and dynamicMax of your guest. You've done it the right way in CitrixResourceBase but not here. I've fixed this in master for now. Please take a look.
> >     
> >     In effect, you restrict scaling when scaling is in fact allowed.
> >     
> >     Also in the else block - you set the staticMax and staticMin to hardcoded values. While I agree with the staticMin, the staticMax is determined by the memory available on the host. You should ideally set that to what is given by the ServiceOffering, provided all the capacity managers allowed it to get to the ServerResource.
> >     
> >     Lastly, XCP supports DMC since 0.5, can you consider moving all this isDmcRestricted() logic into CitrixResourceBase so XCP can take advantage of it?
> >
> 
> Harikrishna Patnala wrote:
>     If else logic is correct. During the deployment of VM if(restrict_dmc = false) which implies if DMC is not restricted then we can scale the VM so we set static memory limit to the VM. In CitrixResourceBase while scaling the VM, we check if(restrict_dmc = true) which implies if host restricts DMC then we throw an excpetion saying host doesnt not support memory scaling.
>     
>     Inorder to scale the vm we have to set static max and min to a limit, so that after wards we can scale the vm memory within that limit.(we cannot change static max and min dynamically). But hardcoding the values is also not the right way. I have submitted another patch that removes the hardcoding these values and setting the values according the memory constraints provided by the xenserver.
>     
>
> 
> Prasanna Santhanam wrote:
>     This is what it looks like before my fix in 7ea2c950. The log as you've said shows that DMC is disabled when restrict_dmc is true. But the VM doesn't scale within static-min and static-max. It scales between dynamic-min and dynamic-max in Xen. The dynamic ranges are set earlier in the method. static-min is used only during boot time to define the memory overhead required for the OS to boot.
>     
>     
>     Please see: http://wiki.xen.org/wiki/XCP_FAQ_Dynamic_Memory_Control
>     
>              if (hostParams.get("restrict_dmc").equalsIgnoreCase("false")) {
>                 record.memoryStaticMax = 8589934592L; //8GB
>                 record.memoryStaticMin = 134217728L; //128MB
>              } else {
>                  s_logger.warn("Host "+ _host.uuid + " does not support Dynamic Memory Control, so we cannot scale up the vm");
>                 record.memoryStaticMax = vmSpec.getMaxRam();
>                 record.memoryStaticMin = vmSpec.getMinRam();
>              }
>
> 
> Prasanna Santhanam wrote:
>     To ensure that this works, can you also please look at the integration test?
>     test/integration/smoke/test_scale_vm.py
>     
>     It's been failing consistently:
>     http://jenkins.buildacloud.org/job/test-smoke-matrix/lastCompletedBuild/suite=test_scale_vm/testReport/
>     
>

Yes, in order to scale the vm's memory we need to change the dynamic min and dynamic max. These two values should be in between static max and min.
But if host restricts DMC (i.e., restrict_dmc =  true) that means we cannot scale the VM. In this case memory constraints are different on the HOST.
static_min <= dynamic_min = dynamic_max = static_max. As per your fix this constraint fails.
if (hostParams.get("restrict_dmc").equalsIgnoreCase("false")) {
            record.memoryStaticMax = vmSpec.getMaxRam();
            record.memoryStaticMin = vmSpec.getMinRam();
         } else {
             s_logger.warn("Host "+ _host.uuid + " does not support Dynamic Memory Control, so we cannot scale up the vm");
            record.memoryStaticMax = 8589934592L; //8GB
            record.memoryStaticMin = 134217728L; //128MB
         }
  The vm deployment fails with memory constraint violation.

As per your fix we cannot scale vm on host(DMC enabled host) since static max and min will be what is there in the service offering.
and vm deployment itself fails on host(DMC disabled host) because of memory constraint violation.

 


- Harikrishna


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


On May 15, 2013, 10:06 a.m., Harikrishna Patnala wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/10903/
> -----------------------------------------------------------
> 
> (Updated May 15, 2013, 10:06 a.m.)
> 
> 
> Review request for cloudstack, Abhinandan Prateek and Nitin Mehta.
> 
> 
> Description
> -------
> 
> CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host 
> Fixed by updating the patch files that has
>  entries to copy scipts on xenserver. Here we added
>  Add-To-VCPUs-Params-Live.sh
> 
> Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
> If DMC is not enabled then static max and min are set to SO.
> 
> 
> This addresses bug CLOUDSTACK-2085.
> 
> 
> Diffs
> -----
> 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java 46ae35a 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java 96a90a6 
>   plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java 7392cb1 
>   scripts/vm/hypervisor/xenserver/Add-To-VCPUs-Params-Live.sh 0fadcd8 
>   scripts/vm/hypervisor/xenserver/add_to_vcpus_params_live.sh PRE-CREATION 
>   scripts/vm/hypervisor/xenserver/vmops 30b5300 
>   scripts/vm/hypervisor/xenserver/xcpserver/patch b7961bb 
>   scripts/vm/hypervisor/xenserver/xenserver56/patch 36dba3d 
>   scripts/vm/hypervisor/xenserver/xenserver56fp1/patch d20e60f 
>   scripts/vm/hypervisor/xenserver/xenserver60/patch c9125f4 
> 
> Diff: https://reviews.apache.org/r/10903/diff/
> 
> 
> Testing
> -------
> 
> Tested: tried scaling up a vm and checked on xenserver for the new values. 
> 
> 
> Thanks,
> 
> Harikrishna Patnala
> 
>


Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

Posted by Prasanna Santhanam <ts...@apache.org>.

> On May 19, 2013, 1:05 p.m., Prasanna Santhanam wrote:
> > plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java, line 144
> > <https://reviews.apache.org/r/10903/diff/2/?file=288093#file288093line144>
> >
> >     The if-else logic should be the other way round here. When DynamicMemoryControl (dmc) is allowed on your Xenserver (restrict_dmc=false) you'd expect to set the dynamicMin and dynamicMax of your guest. You've done it the right way in CitrixResourceBase but not here. I've fixed this in master for now. Please take a look.
> >     
> >     In effect, you restrict scaling when scaling is in fact allowed.
> >     
> >     Also in the else block - you set the staticMax and staticMin to hardcoded values. While I agree with the staticMin, the staticMax is determined by the memory available on the host. You should ideally set that to what is given by the ServiceOffering, provided all the capacity managers allowed it to get to the ServerResource.
> >     
> >     Lastly, XCP supports DMC since 0.5, can you consider moving all this isDmcRestricted() logic into CitrixResourceBase so XCP can take advantage of it?
> >
> 
> Harikrishna Patnala wrote:
>     If else logic is correct. During the deployment of VM if(restrict_dmc = false) which implies if DMC is not restricted then we can scale the VM so we set static memory limit to the VM. In CitrixResourceBase while scaling the VM, we check if(restrict_dmc = true) which implies if host restricts DMC then we throw an excpetion saying host doesnt not support memory scaling.
>     
>     Inorder to scale the vm we have to set static max and min to a limit, so that after wards we can scale the vm memory within that limit.(we cannot change static max and min dynamically). But hardcoding the values is also not the right way. I have submitted another patch that removes the hardcoding these values and setting the values according the memory constraints provided by the xenserver.
>     
>
> 
> Prasanna Santhanam wrote:
>     This is what it looks like before my fix in 7ea2c950. The log as you've said shows that DMC is disabled when restrict_dmc is true. But the VM doesn't scale within static-min and static-max. It scales between dynamic-min and dynamic-max in Xen. The dynamic ranges are set earlier in the method. static-min is used only during boot time to define the memory overhead required for the OS to boot.
>     
>     
>     Please see: http://wiki.xen.org/wiki/XCP_FAQ_Dynamic_Memory_Control
>     
>              if (hostParams.get("restrict_dmc").equalsIgnoreCase("false")) {
>                 record.memoryStaticMax = 8589934592L; //8GB
>                 record.memoryStaticMin = 134217728L; //128MB
>              } else {
>                  s_logger.warn("Host "+ _host.uuid + " does not support Dynamic Memory Control, so we cannot scale up the vm");
>                 record.memoryStaticMax = vmSpec.getMaxRam();
>                 record.memoryStaticMin = vmSpec.getMinRam();
>              }
>
> 
> Prasanna Santhanam wrote:
>     To ensure that this works, can you also please look at the integration test?
>     test/integration/smoke/test_scale_vm.py
>     
>     It's been failing consistently:
>     http://jenkins.buildacloud.org/job/test-smoke-matrix/lastCompletedBuild/suite=test_scale_vm/testReport/
>     
>
> 
> Harikrishna Patnala wrote:
>     Yes, in order to scale the vm's memory we need to change the dynamic min and dynamic max. These two values should be in between static max and min.
>     But if host restricts DMC (i.e., restrict_dmc =  true) that means we cannot scale the VM. In this case memory constraints are different on the HOST.
>     static_min <= dynamic_min = dynamic_max = static_max. As per your fix this constraint fails.
>     if (hostParams.get("restrict_dmc").equalsIgnoreCase("false")) {
>                 record.memoryStaticMax = vmSpec.getMaxRam();
>                 record.memoryStaticMin = vmSpec.getMinRam();
>              } else {
>                  s_logger.warn("Host "+ _host.uuid + " does not support Dynamic Memory Control, so we cannot scale up the vm");
>                 record.memoryStaticMax = 8589934592L; //8GB
>                 record.memoryStaticMin = 134217728L; //128MB
>              }
>       The vm deployment fails with memory constraint violation.
>     
>     As per your fix we cannot scale vm on host(DMC enabled host) since static max and min will be what is there in the service offering.
>     and vm deployment itself fails on host(DMC disabled host) because of memory constraint violation.
>     
>

Ok - I understand what you're trying to do here:

You want to adjust the static-{min, max} limits so as to allow scaling between dynamic-{min,max}. The way it looked it seemed like having DMC enabled was changing the dynamic range between static-min and max. I've readjusted the code so it looks as expected and to suit XCP as well which allows scaling by default.

I tested the change on xenserver with both dmc=true and dmc=false and it works fine. I didn't try the scaling operations itself because it seems like more fixes need to go in to determine the optimal range for the guest memory to scale. I've left a TODO which I presume you will be sending a patch for.


- Prasanna


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


On May 15, 2013, 10:06 a.m., Harikrishna Patnala wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/10903/
> -----------------------------------------------------------
> 
> (Updated May 15, 2013, 10:06 a.m.)
> 
> 
> Review request for cloudstack, Abhinandan Prateek and Nitin Mehta.
> 
> 
> Description
> -------
> 
> CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host 
> Fixed by updating the patch files that has
>  entries to copy scipts on xenserver. Here we added
>  Add-To-VCPUs-Params-Live.sh
> 
> Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
> If DMC is not enabled then static max and min are set to SO.
> 
> 
> This addresses bug CLOUDSTACK-2085.
> 
> 
> Diffs
> -----
> 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java 46ae35a 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java 96a90a6 
>   plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java 7392cb1 
>   scripts/vm/hypervisor/xenserver/Add-To-VCPUs-Params-Live.sh 0fadcd8 
>   scripts/vm/hypervisor/xenserver/add_to_vcpus_params_live.sh PRE-CREATION 
>   scripts/vm/hypervisor/xenserver/vmops 30b5300 
>   scripts/vm/hypervisor/xenserver/xcpserver/patch b7961bb 
>   scripts/vm/hypervisor/xenserver/xenserver56/patch 36dba3d 
>   scripts/vm/hypervisor/xenserver/xenserver56fp1/patch d20e60f 
>   scripts/vm/hypervisor/xenserver/xenserver60/patch c9125f4 
> 
> Diff: https://reviews.apache.org/r/10903/diff/
> 
> 
> Testing
> -------
> 
> Tested: tried scaling up a vm and checked on xenserver for the new values. 
> 
> 
> Thanks,
> 
> Harikrishna Patnala
> 
>


Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

Posted by Harikrishna Patnala <ha...@citrix.com>.

> On May 19, 2013, 1:05 p.m., Prasanna Santhanam wrote:
> > plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java, line 144
> > <https://reviews.apache.org/r/10903/diff/2/?file=288093#file288093line144>
> >
> >     The if-else logic should be the other way round here. When DynamicMemoryControl (dmc) is allowed on your Xenserver (restrict_dmc=false) you'd expect to set the dynamicMin and dynamicMax of your guest. You've done it the right way in CitrixResourceBase but not here. I've fixed this in master for now. Please take a look.
> >     
> >     In effect, you restrict scaling when scaling is in fact allowed.
> >     
> >     Also in the else block - you set the staticMax and staticMin to hardcoded values. While I agree with the staticMin, the staticMax is determined by the memory available on the host. You should ideally set that to what is given by the ServiceOffering, provided all the capacity managers allowed it to get to the ServerResource.
> >     
> >     Lastly, XCP supports DMC since 0.5, can you consider moving all this isDmcRestricted() logic into CitrixResourceBase so XCP can take advantage of it?
> >

If else logic is correct. During the deployment of VM if(restrict_dmc = false) which implies if DMC is not restricted then we can scale the VM so we set static memory limit to the VM. In CitrixResourceBase while scaling the VM, we check if(restrict_dmc = true) which implies if host restricts DMC then we throw an excpetion saying host doesnt not support memory scaling.

Inorder to scale the vm we have to set static max and min to a limit, so that after wards we can scale the vm memory within that limit.(we cannot change static max and min dynamically). But hardcoding the values is also not the right way. I have submitted another patch that removes the hardcoding these values and setting the values according the memory constraints provided by the xenserver.


- Harikrishna


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


On May 15, 2013, 10:06 a.m., Harikrishna Patnala wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/10903/
> -----------------------------------------------------------
> 
> (Updated May 15, 2013, 10:06 a.m.)
> 
> 
> Review request for cloudstack, Abhinandan Prateek and Nitin Mehta.
> 
> 
> Description
> -------
> 
> CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host 
> Fixed by updating the patch files that has
>  entries to copy scipts on xenserver. Here we added
>  Add-To-VCPUs-Params-Live.sh
> 
> Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
> If DMC is not enabled then static max and min are set to SO.
> 
> 
> This addresses bug CLOUDSTACK-2085.
> 
> 
> Diffs
> -----
> 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java 46ae35a 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java 96a90a6 
>   plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java 7392cb1 
>   scripts/vm/hypervisor/xenserver/Add-To-VCPUs-Params-Live.sh 0fadcd8 
>   scripts/vm/hypervisor/xenserver/add_to_vcpus_params_live.sh PRE-CREATION 
>   scripts/vm/hypervisor/xenserver/vmops 30b5300 
>   scripts/vm/hypervisor/xenserver/xcpserver/patch b7961bb 
>   scripts/vm/hypervisor/xenserver/xenserver56/patch 36dba3d 
>   scripts/vm/hypervisor/xenserver/xenserver56fp1/patch d20e60f 
>   scripts/vm/hypervisor/xenserver/xenserver60/patch c9125f4 
> 
> Diff: https://reviews.apache.org/r/10903/diff/
> 
> 
> Testing
> -------
> 
> Tested: tried scaling up a vm and checked on xenserver for the new values. 
> 
> 
> Thanks,
> 
> Harikrishna Patnala
> 
>


Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

Posted by Prasanna Santhanam <ts...@apache.org>.

> On May 19, 2013, 1:05 p.m., Prasanna Santhanam wrote:
> > plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java, line 144
> > <https://reviews.apache.org/r/10903/diff/2/?file=288093#file288093line144>
> >
> >     The if-else logic should be the other way round here. When DynamicMemoryControl (dmc) is allowed on your Xenserver (restrict_dmc=false) you'd expect to set the dynamicMin and dynamicMax of your guest. You've done it the right way in CitrixResourceBase but not here. I've fixed this in master for now. Please take a look.
> >     
> >     In effect, you restrict scaling when scaling is in fact allowed.
> >     
> >     Also in the else block - you set the staticMax and staticMin to hardcoded values. While I agree with the staticMin, the staticMax is determined by the memory available on the host. You should ideally set that to what is given by the ServiceOffering, provided all the capacity managers allowed it to get to the ServerResource.
> >     
> >     Lastly, XCP supports DMC since 0.5, can you consider moving all this isDmcRestricted() logic into CitrixResourceBase so XCP can take advantage of it?
> >
> 
> Harikrishna Patnala wrote:
>     If else logic is correct. During the deployment of VM if(restrict_dmc = false) which implies if DMC is not restricted then we can scale the VM so we set static memory limit to the VM. In CitrixResourceBase while scaling the VM, we check if(restrict_dmc = true) which implies if host restricts DMC then we throw an excpetion saying host doesnt not support memory scaling.
>     
>     Inorder to scale the vm we have to set static max and min to a limit, so that after wards we can scale the vm memory within that limit.(we cannot change static max and min dynamically). But hardcoding the values is also not the right way. I have submitted another patch that removes the hardcoding these values and setting the values according the memory constraints provided by the xenserver.
>     
>

This is what it looks like before my fix in 7ea2c950. The log as you've said shows that DMC is disabled when restrict_dmc is true. But the VM doesn't scale within static-min and static-max. It scales between dynamic-min and dynamic-max in Xen. The dynamic ranges are set earlier in the method. static-min is used only during boot time to define the memory overhead required for the OS to boot.


Please see: http://wiki.xen.org/wiki/XCP_FAQ_Dynamic_Memory_Control

         if (hostParams.get("restrict_dmc").equalsIgnoreCase("false")) {
            record.memoryStaticMax = 8589934592L; //8GB
            record.memoryStaticMin = 134217728L; //128MB
         } else {
             s_logger.warn("Host "+ _host.uuid + " does not support Dynamic Memory Control, so we cannot scale up the vm");
            record.memoryStaticMax = vmSpec.getMaxRam();
            record.memoryStaticMin = vmSpec.getMinRam();
         }


- Prasanna


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


On May 15, 2013, 10:06 a.m., Harikrishna Patnala wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/10903/
> -----------------------------------------------------------
> 
> (Updated May 15, 2013, 10:06 a.m.)
> 
> 
> Review request for cloudstack, Abhinandan Prateek and Nitin Mehta.
> 
> 
> Description
> -------
> 
> CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host 
> Fixed by updating the patch files that has
>  entries to copy scipts on xenserver. Here we added
>  Add-To-VCPUs-Params-Live.sh
> 
> Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
> If DMC is not enabled then static max and min are set to SO.
> 
> 
> This addresses bug CLOUDSTACK-2085.
> 
> 
> Diffs
> -----
> 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java 46ae35a 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java 96a90a6 
>   plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java 7392cb1 
>   scripts/vm/hypervisor/xenserver/Add-To-VCPUs-Params-Live.sh 0fadcd8 
>   scripts/vm/hypervisor/xenserver/add_to_vcpus_params_live.sh PRE-CREATION 
>   scripts/vm/hypervisor/xenserver/vmops 30b5300 
>   scripts/vm/hypervisor/xenserver/xcpserver/patch b7961bb 
>   scripts/vm/hypervisor/xenserver/xenserver56/patch 36dba3d 
>   scripts/vm/hypervisor/xenserver/xenserver56fp1/patch d20e60f 
>   scripts/vm/hypervisor/xenserver/xenserver60/patch c9125f4 
> 
> Diff: https://reviews.apache.org/r/10903/diff/
> 
> 
> Testing
> -------
> 
> Tested: tried scaling up a vm and checked on xenserver for the new values. 
> 
> 
> Thanks,
> 
> Harikrishna Patnala
> 
>


Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

Posted by Prasanna Santhanam <ts...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/10903/#review20743
-----------------------------------------------------------


Reopening this for review as the fix is incomplete and partly invalid. Reviewers please note.


plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java
<https://reviews.apache.org/r/10903/#comment42829>

    The if-else logic should be the other way round here. When DynamicMemoryControl (dmc) is allowed on your Xenserver (restrict_dmc=false) you'd expect to set the dynamicMin and dynamicMax of your guest. You've done it the right way in CitrixResourceBase but not here. I've fixed this in master for now. Please take a look.
    
    In effect, you restrict scaling when scaling is in fact allowed.
    
    Also in the else block - you set the staticMax and staticMin to hardcoded values. While I agree with the staticMin, the staticMax is determined by the memory available on the host. You should ideally set that to what is given by the ServiceOffering, provided all the capacity managers allowed it to get to the ServerResource.
    
    Lastly, XCP supports DMC since 0.5, can you consider moving all this isDmcRestricted() logic into CitrixResourceBase so XCP can take advantage of it?
    



scripts/vm/hypervisor/xenserver/add_to_vcpus_params_live.sh
<https://reviews.apache.org/r/10903/#comment42830>

    disable -x by default



scripts/vm/hypervisor/xenserver/add_to_vcpus_params_live.sh
<https://reviews.apache.org/r/10903/#comment42831>

    Use the $(expr) syntax instead of backticks.
    See http://wiki.bash-hackers.org/syntax/expansion/cmdsubst


- Prasanna Santhanam


On May 15, 2013, 10:06 a.m., Harikrishna Patnala wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/10903/
> -----------------------------------------------------------
> 
> (Updated May 15, 2013, 10:06 a.m.)
> 
> 
> Review request for cloudstack, Abhinandan Prateek and Nitin Mehta.
> 
> 
> Description
> -------
> 
> CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host 
> Fixed by updating the patch files that has
>  entries to copy scipts on xenserver. Here we added
>  Add-To-VCPUs-Params-Live.sh
> 
> Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
> If DMC is not enabled then static max and min are set to SO.
> 
> 
> This addresses bug CLOUDSTACK-2085.
> 
> 
> Diffs
> -----
> 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java 46ae35a 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java 96a90a6 
>   plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java 7392cb1 
>   scripts/vm/hypervisor/xenserver/Add-To-VCPUs-Params-Live.sh 0fadcd8 
>   scripts/vm/hypervisor/xenserver/add_to_vcpus_params_live.sh PRE-CREATION 
>   scripts/vm/hypervisor/xenserver/vmops 30b5300 
>   scripts/vm/hypervisor/xenserver/xcpserver/patch b7961bb 
>   scripts/vm/hypervisor/xenserver/xenserver56/patch 36dba3d 
>   scripts/vm/hypervisor/xenserver/xenserver56fp1/patch d20e60f 
>   scripts/vm/hypervisor/xenserver/xenserver60/patch c9125f4 
> 
> Diff: https://reviews.apache.org/r/10903/diff/
> 
> 
> Testing
> -------
> 
> Tested: tried scaling up a vm and checked on xenserver for the new values. 
> 
> 
> Thanks,
> 
> Harikrishna Patnala
> 
>


Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

Posted by ASF Subversion and Git Services <as...@urd.zones.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/10903/#review20757
-----------------------------------------------------------


Commit 8da7ec05f1c7dae0aab827ae0568e120111c6579 in branch refs/heads/master from Prasanna Santhanam <ts...@apache.org>
[ https://git-wip-us.apache.org/repos/asf?p=cloudstack.git;h=8da7ec0 ]

CLOUDSTACK-2085: DMC enable guest scaling

When dmc is enabled allow cloudstack to scale the VM between dynamic
ranges. This requires a further commit where there is enough memory
available between dynamic-max and static-max for the VM to scale under
memory pressure. See the TODO in Xenserver56FP1Resource.java

Signed-off-by: Prasanna Santhanam <ts...@apache.org>


- ASF Subversion and Git Services


On May 15, 2013, 10:06 a.m., Harikrishna Patnala wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/10903/
> -----------------------------------------------------------
> 
> (Updated May 15, 2013, 10:06 a.m.)
> 
> 
> Review request for cloudstack, Abhinandan Prateek and Nitin Mehta.
> 
> 
> Description
> -------
> 
> CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host 
> Fixed by updating the patch files that has
>  entries to copy scipts on xenserver. Here we added
>  Add-To-VCPUs-Params-Live.sh
> 
> Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
> If DMC is not enabled then static max and min are set to SO.
> 
> 
> This addresses bug CLOUDSTACK-2085.
> 
> 
> Diffs
> -----
> 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java 46ae35a 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java 96a90a6 
>   plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java 7392cb1 
>   scripts/vm/hypervisor/xenserver/Add-To-VCPUs-Params-Live.sh 0fadcd8 
>   scripts/vm/hypervisor/xenserver/add_to_vcpus_params_live.sh PRE-CREATION 
>   scripts/vm/hypervisor/xenserver/vmops 30b5300 
>   scripts/vm/hypervisor/xenserver/xcpserver/patch b7961bb 
>   scripts/vm/hypervisor/xenserver/xenserver56/patch 36dba3d 
>   scripts/vm/hypervisor/xenserver/xenserver56fp1/patch d20e60f 
>   scripts/vm/hypervisor/xenserver/xenserver60/patch c9125f4 
> 
> Diff: https://reviews.apache.org/r/10903/diff/
> 
> 
> Testing
> -------
> 
> Tested: tried scaling up a vm and checked on xenserver for the new values. 
> 
> 
> Thanks,
> 
> Harikrishna Patnala
> 
>


Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

Posted by Harikrishna Patnala <ha...@citrix.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/10903/
-----------------------------------------------------------

(Updated May 15, 2013, 10:06 a.m.)


Review request for cloudstack, Abhinandan Prateek and Nitin Mehta.


Description
-------

CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host 
Fixed by updating the patch files that has
 entries to copy scipts on xenserver. Here we added
 Add-To-VCPUs-Params-Live.sh

Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
If DMC is not enabled then static max and min are set to SO.


This addresses bug CLOUDSTACK-2085.


Diffs
-----

  plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java 46ae35a 
  plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java 96a90a6 
  plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java 7392cb1 
  scripts/vm/hypervisor/xenserver/Add-To-VCPUs-Params-Live.sh 0fadcd8 
  scripts/vm/hypervisor/xenserver/add_to_vcpus_params_live.sh PRE-CREATION 
  scripts/vm/hypervisor/xenserver/vmops 30b5300 
  scripts/vm/hypervisor/xenserver/xcpserver/patch b7961bb 
  scripts/vm/hypervisor/xenserver/xenserver56/patch 36dba3d 
  scripts/vm/hypervisor/xenserver/xenserver56fp1/patch d20e60f 
  scripts/vm/hypervisor/xenserver/xenserver60/patch c9125f4 

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


Testing
-------

Tested: tried scaling up a vm and checked on xenserver for the new values. 


Thanks,

Harikrishna Patnala


Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

Posted by Harikrishna Patnala <ha...@citrix.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/10903/
-----------------------------------------------------------

(Updated May 6, 2013, 10:01 a.m.)


Review request for cloudstack and Abhinandan Prateek.


Changes
-------

updated patch


Description
-------

CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host 
Fixed by updating the patch files that has
 entries to copy scipts on xenserver. Here we added
 Add-To-VCPUs-Params-Live.sh

Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
If DMC is not enabled then static max and min are set to SO.


This addresses bug CLOUDSTACK-2085.


Diffs (updated)
-----

  plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java 46ae35a 
  plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java 96a90a6 
  plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java 7392cb1 
  scripts/vm/hypervisor/xenserver/Add-To-VCPUs-Params-Live.sh 0fadcd8 
  scripts/vm/hypervisor/xenserver/add_to_vcpus_params_live.sh PRE-CREATION 
  scripts/vm/hypervisor/xenserver/vmops 30b5300 
  scripts/vm/hypervisor/xenserver/xcpserver/patch b7961bb 
  scripts/vm/hypervisor/xenserver/xenserver56/patch 36dba3d 
  scripts/vm/hypervisor/xenserver/xenserver56fp1/patch d20e60f 
  scripts/vm/hypervisor/xenserver/xenserver60/patch c9125f4 

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


Testing
-------

Tested: tried scaling up a vm and checked on xenserver for the new values. 


Thanks,

Harikrishna Patnala


Re: Review Request: Fix for CLOUDSTACK-2085 VM weight on xen remain same as before vmscaleup

Posted by Abhinandan Prateek <ap...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/10903/#review20180
-----------------------------------------------------------


Rename the plugin file to all lowercase and resubmit. 

- Abhinandan Prateek


On May 2, 2013, 11:30 a.m., Harikrishna Patnala wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/10903/
> -----------------------------------------------------------
> 
> (Updated May 2, 2013, 11:30 a.m.)
> 
> 
> Review request for cloudstack and Abhinandan Prateek.
> 
> 
> Description
> -------
> 
> CLOUDSTACK-2085: VM weight on xen remain same as before vmscaleup ;because "Add-To-VCPUs-Params-Live.sh" is not getting copied on xs host 
> Fixed by updating the patch files that has
>  entries to copy scipts on xenserver. Here we added
>  Add-To-VCPUs-Params-Live.sh
> 
> Added a check on Host params whether host restricts Dynamic memory control(DMC) to able to allow scale up VM.
> If DMC is not enabled then static max and min are set to SO.
> 
> 
> This addresses bug CLOUDSTACK-2085.
> 
> 
> Diffs
> -----
> 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java 46ae35a 
>   plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XenServer56FP1Resource.java 96a90a6 
>   plugins/hypervisors/xen/test/com/cloud/hypervisor/xen/resource/CitrixResourceBaseTest.java 7392cb1 
>   scripts/vm/hypervisor/xenserver/xcpserver/patch b7961bb 
>   scripts/vm/hypervisor/xenserver/xenserver56/patch 36dba3d 
>   scripts/vm/hypervisor/xenserver/xenserver56fp1/patch d20e60f 
>   scripts/vm/hypervisor/xenserver/xenserver60/patch c9125f4 
> 
> Diff: https://reviews.apache.org/r/10903/diff/
> 
> 
> Testing
> -------
> 
> Tested: tried scaling up a vm and checked on xenserver for the new values. 
> 
> 
> Thanks,
> 
> Harikrishna Patnala
> 
>