cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sate...@apache.org
Subject [02/50] git commit: updated refs/heads/vmware-storage-motion to 004e74d
Date Wed, 29 May 2013 09:54:03 GMT
CLOUDSTACK-2683: DevCloud systemVMs fail to launch

DevCloud is a XCP Kronos based xen. For this we use the XcpOssResource
whose memory limits were not set explicitly. Instead the base
CitrixResourceBase would set the limits. static_min was set to 128MB
failing the cpvm and ssvm start fails whose offerings have 100MB set to
the max limits.

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


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/5b902c70
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/5b902c70
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/5b902c70

Branch: refs/heads/vmware-storage-motion
Commit: 5b902c700513423921da48161acd7f8cff8a0b56
Parents: dc822a8
Author: Prasanna Santhanam <tsp@apache.org>
Authored: Sun May 26 14:46:27 2013 +0530
Committer: Prasanna Santhanam <tsp@apache.org>
Committed: Sun May 26 14:49:52 2013 +0530

----------------------------------------------------------------------
 .../hypervisor/xen/resource/XcpOssResource.java    |   30 ++++++++------
 1 files changed, 17 insertions(+), 13 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/5b902c70/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XcpOssResource.java
----------------------------------------------------------------------
diff --git a/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XcpOssResource.java
b/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XcpOssResource.java
index 357b433..870049c 100644
--- a/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XcpOssResource.java
+++ b/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XcpOssResource.java
@@ -17,17 +17,6 @@
 
 package com.cloud.hypervisor.xen.resource;
 
-import java.io.File;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import javax.ejb.Local;
-
-import org.apache.log4j.Logger;
-import org.apache.xmlrpc.XmlRpcException;
-
 import com.cloud.agent.api.Answer;
 import com.cloud.agent.api.Command;
 import com.cloud.agent.api.NetworkUsageAnswer;
@@ -46,14 +35,24 @@ import com.cloud.utils.script.Script;
 import com.cloud.vm.VirtualMachine;
 import com.xensource.xenapi.Connection;
 import com.xensource.xenapi.Types;
+import com.xensource.xenapi.Types.XenAPIException;
 import com.xensource.xenapi.VBD;
 import com.xensource.xenapi.VDI;
 import com.xensource.xenapi.VM;
-import com.xensource.xenapi.Types.XenAPIException;
+import org.apache.log4j.Logger;
+import org.apache.xmlrpc.XmlRpcException;
+
+import javax.ejb.Local;
+import java.io.File;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Set;
 
 @Local(value=ServerResource.class)
 public class XcpOssResource extends CitrixResourceBase {
-	 private final static Logger s_logger = Logger.getLogger(XcpServerResource.class);
+    private final static Logger s_logger = Logger.getLogger(XcpOssResource.class);
+    private static final long mem_32m = 33554432L;
+
     @Override
     protected List<File> getPatchFiles() {
         List<File> files = new ArrayList<File>();
@@ -167,4 +166,9 @@ public class XcpOssResource extends CitrixResourceBase {
     	}
     	return answer;
     }
+
+    @Override
+    protected void setMemory(Connection conn, VM vm, long minMemsize, long maxMemsize) throws
XmlRpcException, XenAPIException {
+        vm.setMemoryLimits(conn, mem_32m, maxMemsize, minMemsize, maxMemsize);
+    }
 }


Mime
View raw message