You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@usergrid.apache.org by to...@apache.org on 2014/09/29 22:52:46 UTC

[07/52] [abbrv] git commit: removed awscluster changes

removed awscluster changes


Project: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/commit/cc08a047
Tree: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/tree/cc08a047
Diff: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/diff/cc08a047

Branch: refs/heads/eventsystem
Commit: cc08a047855d404cbe601c9c8f0a344cda90d8f0
Parents: 3993f08
Author: amuramoto <am...@apigee.com>
Authored: Wed Sep 17 14:11:16 2014 -0700
Committer: amuramoto <am...@apigee.com>
Committed: Wed Sep 17 14:11:16 2014 -0700

----------------------------------------------------------------------
 .../main/dist/init_instance/init_db_server.sh   |  3 ---
 .../main/dist/init_instance/init_rest_server.sh | 20 ++++++++++----------
 .../dist/init_instance/install_elasticsearch.sh |  8 ++++----
 3 files changed, 14 insertions(+), 17 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/cc08a047/stack/awscluster/src/main/dist/init_instance/init_db_server.sh
----------------------------------------------------------------------
diff --git a/stack/awscluster/src/main/dist/init_instance/init_db_server.sh b/stack/awscluster/src/main/dist/init_instance/init_db_server.sh
index 3ffca66..b9c4f56 100644
--- a/stack/awscluster/src/main/dist/init_instance/init_db_server.sh
+++ b/stack/awscluster/src/main/dist/init_instance/init_db_server.sh
@@ -67,9 +67,6 @@ cd /usr/share/usergrid/init_instance
 cd /usr/share/usergrid/init_instance
 ./create_keyspaces.sh
 
-#Increase file descriptors for Elasticsearch
-sed -i.bak "s/#@student        -       maxlogins       4/*\t\t\-\tnofile\t\t${NOFILE}\nroot\t\t\-\tnofile\t\t10000"/ /etc/security/limits.conf
-
 # tag last so we can see in the console that the script ran to completion
 cd /usr/share/usergrid/scripts
 groovy tag_instance.groovy

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/cc08a047/stack/awscluster/src/main/dist/init_instance/init_rest_server.sh
----------------------------------------------------------------------
diff --git a/stack/awscluster/src/main/dist/init_instance/init_rest_server.sh b/stack/awscluster/src/main/dist/init_instance/init_rest_server.sh
index 5cdf10a..fdc83cd 100644
--- a/stack/awscluster/src/main/dist/init_instance/init_rest_server.sh
+++ b/stack/awscluster/src/main/dist/init_instance/init_rest_server.sh
@@ -51,8 +51,7 @@ cd /usr/share/usergrid/init_instance
 ./install_yourkit.sh
 
 # set Tomcat memory and threads based on instance type
-export NOFILE=50000
-export TOMCAT_CONNECTIONS=10000
+export NOFILE=100000
 case `(curl http://169.254.169.254/latest/meta-data/instance-type)` in
 'm1.small' )
     export TOMCAT_RAM=1250M
@@ -70,29 +69,30 @@ case `(curl http://169.254.169.254/latest/meta-data/instance-type)` in
     export TOMCAT_RAM=12G
     export TOMCAT_THREADS=2000
 ;;
-'m3.large' )
-    export TOMCAT_RAM=6G
-    export TOMCAT_THREADS=6000
-;;
 'm3.xlarge' )
     export TOMCAT_RAM=12G
-    export TOMCAT_THREADS=8000
+    export TOMCAT_THREADS=3300
+;;
+'m3.large' )
+    export TOMCAT_RAM=6G
+    export TOMCAT_THREADS=1600
 ;;
 'c3.2xlarge' )
     export TOMCAT_RAM=12G
-    export TOMCAT_THREADS=10000
+    export TOMCAT_THREADS=2000
 ;;
 'c3.4xlarge' )
     export TOMCAT_RAM=24G
-    export TOMCAT_THREADS=12000
+    export TOMCAT_THREADS=4000
 esac
 
+export TOMCAT_CONNECTIONS=10000
 sed -i.bak "s/Xmx128m/Xmx${TOMCAT_RAM} -Xms${TOMCAT_RAM} -Dlog4j\.configuration=file:\/usr\/share\/usergrid\/lib\/log4j\.properties/g" /etc/default/tomcat7
 sed -i.bak "s/<Connector/<Connector maxThreads=\"${TOMCAT_THREADS}\" acceptCount=\"${TOMCAT_THREADS}\" maxConnections=\"${TOMCAT_CONNECTIONS}\"/g" /var/lib/tomcat7/conf/server.xml
 
 # set file limits
 sed -i.bak "s/# \/etc\/init\.d\/tomcat7 -- startup script for the Tomcat 6 servlet engine/ulimit -n ${NOFILE}/" /etc/init.d/tomcat7
-sed -i.bak "s/#@student        -       maxlogins       4/*\t\t\-\tnofile\t\t${NOFILE}\nroot\t\t\-\tnofile\t\t${NOFILE}"/ /etc/security/limits.conf
+sed -i.bak "s/@student/a *\t\thard\tnofile\t\t${NOFILE}\n*\t\tsoft\tnofile\t\t${NOFILE}" /etc/security/limits.conf
 echo "$NOFILE" | sudo tee > /proc/sys/fs/nr_open
 echo "$NOFILE" | sudo tee > /proc/sys/fs/file-max
 cat >> /etc/pam.d/su << EOF

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/cc08a047/stack/awscluster/src/main/dist/init_instance/install_elasticsearch.sh
----------------------------------------------------------------------
diff --git a/stack/awscluster/src/main/dist/init_instance/install_elasticsearch.sh b/stack/awscluster/src/main/dist/init_instance/install_elasticsearch.sh
index 51f7c60..d398591 100644
--- a/stack/awscluster/src/main/dist/init_instance/install_elasticsearch.sh
+++ b/stack/awscluster/src/main/dist/init_instance/install_elasticsearch.sh
@@ -57,16 +57,16 @@ case `(curl http://169.254.169.254/latest/meta-data/instance-type)` in
     export ES_HEAP_SIZE=5G
 ;;
 'm3.xlarge' )
-    export ES_HEAP_SIZE=10G
+    export ES_HEAP_SIZE=5G
 ;;
 'm3.large' )
-    export ES_HEAP_SIZE=5G
+    export ES_HEAP_SIZE=2G
 ;;
 'c3.2xlarge' )
-    export ES_HEAP_SIZE=10G
+    export ES_HEAP_SIZE=4G
 ;;
 'c3.4xlarge' )
-    export ES_HEAP_SIZE=15G
+    export ES_HEAP_SIZE=12G
 esac
 
 cat >> /etc/default/elasticsearch << EOF