Skip to content

Commit 4809d91

Browse files
koushik-daschaturvedia
authored andcommitted
CLOUDSTACK-5993: Cloud agent fails to start on 32-bit system vms (cpvm and ssvm) created with 4GB RAM offering
Capped the max heap size of the JVM at 2600M for 32-bit system VMs. For 64-bit, existing logic works fine. (cherry picked from commit 1ae0200) Signed-off-by: Animesh Chaturvedi <animesh@apache.org>
1 parent 9961a8e commit 4809d91

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

systemvm/scripts/_run.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,4 +61,11 @@ then
6161
maxmem=$eightypcnt
6262
fi
6363

64+
if [ "$(uname -m | grep '64')" == "" ]; then
65+
let "maxmem32bit=2600"
66+
if [ $maxmem -gt $maxmem32bit ]; then
67+
maxmem=$maxmem32bit
68+
fi
69+
fi
70+
6471
java -Djavax.net.ssl.trustStore=./certs/realhostip.keystore -Dlog.home=$LOGHOME -mx${maxmem}m -cp $CP com.cloud.agent.AgentShell $keyvalues $@

0 commit comments

Comments
 (0)